Skip to content

Instantly share code, notes, and snippets.

@SudoPlz
Last active December 3, 2025 17:55
Show Gist options
  • Select an option

  • Save SudoPlz/78a539d286a17b33261216c71c629a50 to your computer and use it in GitHub Desktop.

Select an option

Save SudoPlz/78a539d286a17b33261216c71c629a50 to your computer and use it in GitHub Desktop.

Network events

Category Subcategory Event Description & Trigger Implementation File Example Payload Confirmed
✅ Network events network_usage app_network_usage Snapshot of how many bytes we sent/received when the NetStats poller runs. modules/network/NetStats.android.tsx
View
{
  "event": "app_network_usage",
  "total_receive_bytes": 312345678,
  "total_send_bytes": 182345123
}

Gestures

Category Subcategory Event Description & Trigger Implementation File Example Payload Confirmed
✅ Gestures tap guild_clicked User tapped a guild bubble in the sidetab. modules/guilds_bar/native/GuildsBarGuild.tsx
View
{
  "event": "guild_clicked",
  "guild_id": "281683040739262465",
  "index": 3
}
✅ Gestures swipe member_list_swipe_toggled Swipe gesture fully opened or closed the member list panel. modules/main_tabs_v2/native/channel/SwipeForMemberListWrapper.tsx
View
{
  "event": "member_list_swipe_toggled",
  "channel_id": "1024367971537272842",
  "member_list_open": false
}
✅ Gestures swipe member_list_swipe_peek User barely swiped the member list so it “peeked” out. modules/main_tabs_v2/native/channel/SwipeForMemberListWrapper.tsx
View
{
  "event": "member_list_swipe_peek",
  "channel_id": "1024367971537272842"
}
✅ Gestures scroll collectibles_shop_scrolled Collectibles shop scroller reported how far down the user is. modules/app_analytics/web/usePageScrollPosition.tsx
View
{
  "event": "collectibles_shop_scrolled",
  "page_session_id": "69535a4c-9482-466b-a762-550332d1b0e8",
  "scroll_visible_percent": 0.42
}
❌ Gestures tap all_taps (missing) We need a catch‑all tap event so every button press shows up here. Not implemented Example unavailable (event missing)
❌ Gestures scroll all_scrolls (missing) Same idea for scrolls—track scroll depth for every scroll view. Not implemented Example unavailable (event missing)
❌ Gestures swipe all_swipes (missing) Generic swipe metric so we know when folks swipe carousels/panels. Not implemented Example unavailable (event missing)

Navigation events

Category Subcategory Event Description & Trigger Implementation File Example Payload Confirmed
✅ Navigation events lifecycle app_opened First thing we log when the app wakes up (load id + device info). modules/tti_analytics/native/TTIAnalyticsUtils.tsx
View
{
  "event": "app_opened",
  "device_model": "Pixel 7",
  "opened_from": "launcher"
}
✅ Navigation events lifecycle app_ui_viewed Legacy “first screen rendered” ping so we know the UI showed up. modules/tti_analytics/native/TTIAnalyticsUtils.tsx
View
{
  "event": "app_ui_viewed",
  "load_id": "d3f70a53-5bf0-49c5-8c18-2ba306c2246a",
  "screen_name": "unknownn"
}
✅ Navigation events lifecycle app_ui_viewed2 Newer TTI payload once content + data are actually ready. modules/tti_analytics/native/TTIAnalyticsUtils.tsx
View
{
  "event": "app_ui_viewed2",
  "screen_name": "guild-text",
  "time_first_contentful_paint": 2834
}
✅ Navigation events navigation channel_opened AutoAnalytics screaming “user switched channels”. components_native/AutoAnalytics.tsx
View
{
  "event": "channel_opened",
  "channel_id": "1359162066891571490",
  "channel_type": 1
}
✅ Navigation events navigation guild_viewed Same story but for guild switches, plus pending guild metadata. components_native/AutoAnalytics.tsx
View
{
  "event": "guild_viewed",
  "guild_id": "281683040739262465",
  "postable_channels": 7
}
❌ Navigation events navigation screen_view (missing) Need a universal “screen_view” so every route shows up in funnels. Not implemented Example unavailable (event missing)

Bottom sheets

Category Subcategory Event Description & Trigger Implementation File Example Payload Confirmed
✅ Bottom sheets voice_controls voice_bottom_sheet_expanded Someone pulled up the voice controls drawer to see more actions. modules/video_calls/native/components/FocusedControls.tsx
View
{
  "event": "voice_bottom_sheet_expanded",
  "channel_id": "640765029750145024",
  "application_id": "1211781489931452447"
}
❌ Bottom sheets bottom_sheet bottom_sheet_closed (missing) We don’t log when drawers collapse—need that to know exits. Not implemented Example unavailable (event missing)

Modals

Category Subcategory Event Description & Trigger Implementation File Example Payload Confirmed
✅ Modals modal open_modal Modal mounted (camera preview, shop details, etc.). modules/video_calls/web/CameraPreviewModal.tsx
View
{
  "event": "open_modal",
  "type": "Collectibles Shop Details Modal",
  "sku_id": "1437881614314242240"
}
❌ Modals modal modal_closed (missing) No global “modal closed” yet, so we lose the exit signal. Not implemented Example unavailable (event missing)

Keyboard views

Category Subcategory Event Description & Trigger Implementation File Example Payload Confirmed
❌ Keyboard views keyboard keyboard_opened (missing) Need to know when any keyboard pops up (text, emoji, etc.). Not implemented Example unavailable (event missing)
❌ Keyboard views keyboard keyboard_closed (missing) Same for closing—otherwise input funnels have gaps. Not implemented Example unavailable (event missing)
❌ Keyboard views keyboard keyboard_type_changed (missing) Track when users swap between emoji/sticker/native keyboards. Not implemented Example unavailable (event missing)

Background / foreground state

Category Subcategory Event Description & Trigger Implementation File Example Payload Confirmed
✅ Background / foreground state lifecycle app_background Fired the moment we drop out of foreground so flows can pause. modules/core/native/handleAppStateChanged.tsx
View
{
  "event": "app_background",
  "previous_state": "active",
  "next_state": "background"
}

Notification events

Category Subcategory Event Description & Trigger Implementation File Example Payload Confirmed
✅ Notification events push push_notification_received Logged whenever the push service hands us a payload (even BG). modules/notifications/native/NativeNotificationsManager.tsx
View
{
  "event": "push_notification_received",
  "notif_instance_id": "bbed9b6c-9c3e-4d9f-93a0-1d5e9e32c111",
  "channel_id": "1024367971537272842"
}
✅ Notification events permission notification_permission_status Periodic ping of OS + app notification toggles. modules/nuf/native/NotificationPermissionManager.tsx
View
{
  "event": "notification_permission_status",
  "os_enabled": false,
  "foreground_app_enabled": true
}
✅ Notification events in_app in_app_notification_clicked User tapped our in-app banner (not OS push). modules/in_app_notifications/native/InAppNotificationContainer.tsx
View
{
  "event": "in_app_notification_clicked",
  "notif_channel_id": "1359162066891571490",
  "percent": 59
}
❌ Notification events push push_notification_opened (missing) Need to know when a push tap actually launches the client. Not implemented Example unavailable (event missing)

Websocket messages

Category Subcategory Event Description & Trigger Implementation File Example Payload Confirmed
✅ Websocket messages gateway_error gateway_socket_reset Logged when we nuke the Gateway connection after a fatal dispatch. modules/gateway/GatewaySocket.tsx
View
{
  "event": "gateway_socket_reset",
  "action": "dispatch",
  "error_message": "Guild data was missing from store"
}
❌ Websocket messages gateway_event gateway_payload_received (missing) Need a sampled “we got OPCODE X” event to rebuild timelines. Not implemented Example unavailable (event missing)

Call lifecycle

Category Subcategory Event Description & Trigger Implementation File Example Payload Confirmed
✅ Call lifecycle join join_voice_channel We fired up RTC and are entering a voice channel. components_native/AutoAnalytics.tsx
View
{
  "event": "join_voice_channel",
  "channel_id": "1359162066891571490",
  "connection_type": "wifi"
}
✅ Call lifecycle leave leave_voice_channel User bailed from voice; includes duration + RTC stats. components_native/AutoAnalytics.tsx
View
{
  "event": "leave_voice_channel",
  "channel_id": "1359162066891571490",
  "duration": 357
}
✅ Call lifecycle video video_call_ended When we stop sending camera, we log how long the video ran. lib/RTCConnection.tsx
View
{
  "event": "video_call_ended",
  "media_session_id": "4fc13ba9f31975fdee7bcb42f20c6803",
  "camera_enabled_duration": 12456
}
✅ Call lifecycle callkit callkit_clicked iOS CallKit button (answer/decline) was tapped. modules/calls/mobile/CallKitManager.ios.tsx
View
{
  "event": "callkit_clicked",
  "action_type": "join",
  "channel_id": "640765029750145024"
}
✅ Call lifecycle disconnect voice_disconnect RTC tore down; we attach battery + audio stack stats. lib/RTCConnection.tsx
View
{
  "event": "voice_disconnect",
  "channel_id": "1359162066891571490",
  "battery_usage": -3
}
❌ Call lifecycle incoming call_received (missing) Need a ping when a call rings before the user answers. Not implemented Example unavailable (event missing)

Device events

Category Subcategory Event Description & Trigger Implementation File Example Payload Confirmed
✅ Device events thermal activity_device_thermal_state_changed OS told us the device is heating up, so we stash the new state. modules/activities/native/EmbeddedActivitiesNativeManager.tsx
View
{
  "event": "activity_device_thermal_state_changed",
  "channel_id": "1359162066891571490",
  "thermal_state": 1
}
✅ Device events background_service background_sync_completed Headless sync finished; we log how many messages/files it touched. modules/app_database/background_sync/native/BackgroundSync.tsx
View
{
  "event": "background_sync_completed",
  "num_guild_channel_messages": 260,
  "time_save_guild_channel_messages": 3077
}
❌ Device events background_service background_service_started (missing) Need a “background job started” ping to pair with the completion one. Not implemented Example unavailable (event missing)
❌ Device events power charger_state_changed (missing) Would love to know when users plug/unplug so we can correlate drains. Not implemented Example unavailable (event missing)
❌ Device events share share_sheet_opened (missing) Missing instrumentation for when a native share sheet is shown. Not implemented Example unavailable (event missing)

Context menus & sheets

Category Subcategory Event Description & Trigger Implementation File Example Payload Confirmed
✅ Context menus & sheets action_sheet message_action_sheet_opened Long‑press on a message opened the action sheet. modules/messages/native/long_press/LongPressMessageActionSheet.tsx
View
{
  "event": "message_action_sheet_opened",
  "channel_id": "1024367971537272842",
  "guild_id": "281683040739262465"
}
❌ Context menus & sheets context_menu context_menu_shown (missing) Need a generic hook for any context menu/popover that shows up. Not implemented Example unavailable (event missing)

Confirmed means I was able to see them being dispatched. Unconfirmed means I found them in our codebase but wasn't able to actually see them being dispatched.

@anthony-capunay-discord
Copy link

One thing I would note is that some of these events are implemented and running correctly for some platforms, but not for others. For example (an event not listed here), media_play_finished works well for mobile, but not for desktop.

For other events, the event is implemented correctly in some cases, but not in others. For example, I believe for a lot of notification events, only some notification types trigger the right events, but other notification types trigger no events or only a subset of the events.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment