Skip to content

Event list

Every event class lives in bostie.events. Listen to one with @bot.listen, as the events guide explains. The intents column names the intents Discord needs to send the event, any one of them enough; an empty cell means Discord sends it without an intent, or only as the answer to a request. Every gateway event also has shard_id, raw_json and raw. The API reference has every field with its type.

Session

Event Dispatch Intents Fields
Ready READY user, guilds (unavailable until their GuildCreate), application, session_id, shard
Resumed RESUMED
UserUpdate USER_UPDATE user, the bot's; old
GatewayRateLimited RATE_LIMITED opcode, retry_after, meta

Guilds

Event Dispatch Intents Fields
GuildCreate GUILD_CREATE GUILDS guild, joined, channels, threads, voice_states, stage_instances, guild_scheduled_events, soundboard_sounds, members, presences
GuildUpdate GUILD_UPDATE GUILDS guild, old
GuildDelete GUILD_DELETE GUILDS guild_id, unavailable, guild (cached)
RoleCreate GUILD_ROLE_CREATE GUILDS guild_id, role
RoleUpdate GUILD_ROLE_UPDATE GUILDS guild_id, role, old
RoleDelete GUILD_ROLE_DELETE GUILDS guild_id, role_id, role (cached)
EmojisUpdate GUILD_EMOJIS_UPDATE GUILD_EXPRESSIONS guild_id, emojis, old
StickersUpdate GUILD_STICKERS_UPDATE GUILD_EXPRESSIONS guild_id, stickers, old
SoundboardSoundCreate GUILD_SOUNDBOARD_SOUND_CREATE GUILD_EXPRESSIONS sound
SoundboardSoundUpdate GUILD_SOUNDBOARD_SOUND_UPDATE GUILD_EXPRESSIONS sound, old
SoundboardSoundDelete GUILD_SOUNDBOARD_SOUND_DELETE GUILD_EXPRESSIONS sound_id, guild_id, sound
SoundboardSoundsUpdate GUILD_SOUNDBOARD_SOUNDS_UPDATE GUILD_EXPRESSIONS soundboard_sounds, guild_id, old
SoundboardSounds SOUNDBOARD_SOUNDS soundboard_sounds, guild_id; the answer to bot.request_soundboard_sounds
AuditLogEntryCreate GUILD_AUDIT_LOG_ENTRY_CREATE GUILD_MODERATION guild_id, entry
BanAdd GUILD_BAN_ADD GUILD_MODERATION guild_id, user
BanRemove GUILD_BAN_REMOVE GUILD_MODERATION guild_id, user
GuildIntegrationsUpdate GUILD_INTEGRATIONS_UPDATE GUILD_INTEGRATIONS guild_id
IntegrationCreate INTEGRATION_CREATE GUILD_INTEGRATIONS guild_id, integration
IntegrationUpdate INTEGRATION_UPDATE GUILD_INTEGRATIONS guild_id, integration
IntegrationDelete INTEGRATION_DELETE GUILD_INTEGRATIONS id, guild_id, application_id
WebhooksUpdate WEBHOOKS_UPDATE GUILD_WEBHOOKS guild_id, channel_id
CommandPermissionsUpdate APPLICATION_COMMAND_PERMISSIONS_UPDATE permissions

Members and presences

Event Dispatch Intents Fields
MemberJoin GUILD_MEMBER_ADD GUILD_MEMBERS guild_id, member
MemberUpdate GUILD_MEMBER_UPDATE GUILD_MEMBERS guild_id, user, roles, nick, joined_at, communication_disabled_until and the other member fields; old
MemberRemove GUILD_MEMBER_REMOVE GUILD_MEMBERS guild_id, user, member (cached)
MembersChunk GUILD_MEMBERS_CHUNK guild_id, members, presences, not_found, chunk_index, chunk_count, nonce; the answer to bot.request_members
PresenceUpdate PRESENCE_UPDATE GUILD_PRESENCES guild_id, presence, old

Channels and threads

Event Dispatch Intents Fields
ChannelCreate CHANNEL_CREATE GUILDS channel
ChannelUpdate CHANNEL_UPDATE GUILDS channel, old
ChannelDelete CHANNEL_DELETE GUILDS channel
ChannelPinsUpdate CHANNEL_PINS_UPDATE GUILDS, DIRECT_MESSAGES guild_id, channel_id, last_pin_timestamp
ThreadCreate THREAD_CREATE GUILDS channel, newly_created, member
ThreadUpdate THREAD_UPDATE GUILDS channel, old
ThreadDelete THREAD_DELETE GUILDS id, guild_id, parent_id, type, thread (cached)
ThreadListSync THREAD_LIST_SYNC GUILDS guild_id, channel_ids, threads, members
ThreadMemberUpdate THREAD_MEMBER_UPDATE GUILDS guild_id, thread_member, the bot's
ThreadMembersUpdate THREAD_MEMBERS_UPDATE GUILDS, GUILD_MEMBERS id, guild_id, member_count, added_members, removed_member_ids
StageInstanceCreate STAGE_INSTANCE_CREATE GUILDS stage_instance
StageInstanceUpdate STAGE_INSTANCE_UPDATE GUILDS stage_instance, old
StageInstanceDelete STAGE_INSTANCE_DELETE GUILDS stage_instance
InviteCreate INVITE_CREATE GUILD_INVITES code, channel_id, guild_id, inviter, max_age, max_uses, expires_at and more
InviteDelete INVITE_DELETE GUILD_INVITES channel_id, guild_id, code

Messages, reactions and polls

Event Dispatch Intents Fields
MessageCreate MESSAGE_CREATE GUILD_MESSAGES, DIRECT_MESSAGES message
MessageUpdate MESSAGE_UPDATE GUILD_MESSAGES, DIRECT_MESSAGES message, old
MessageDelete MESSAGE_DELETE GUILD_MESSAGES, DIRECT_MESSAGES id, channel_id, guild_id, message (cached)
MessageDeleteBulk MESSAGE_DELETE_BULK GUILD_MESSAGES ids, channel_id, guild_id, messages (cached)
TypingStart TYPING_START GUILD_MESSAGE_TYPING, DIRECT_MESSAGE_TYPING channel_id, guild_id, user_id, timestamp, member
ReactionAdd MESSAGE_REACTION_ADD GUILD_MESSAGE_REACTIONS, DIRECT_MESSAGE_REACTIONS user_id, channel_id, message_id, guild_id, emoji, burst, type, member, message_author_id, burst_colors
ReactionRemove MESSAGE_REACTION_REMOVE GUILD_MESSAGE_REACTIONS, DIRECT_MESSAGE_REACTIONS user_id, channel_id, message_id, guild_id, emoji, burst, type
ReactionRemoveAll MESSAGE_REACTION_REMOVE_ALL GUILD_MESSAGE_REACTIONS, DIRECT_MESSAGE_REACTIONS channel_id, message_id, guild_id
ReactionRemoveEmoji MESSAGE_REACTION_REMOVE_EMOJI GUILD_MESSAGE_REACTIONS, DIRECT_MESSAGE_REACTIONS channel_id, message_id, guild_id, emoji
PollVoteAdd MESSAGE_POLL_VOTE_ADD GUILD_MESSAGE_POLLS, DIRECT_MESSAGE_POLLS user_id, channel_id, message_id, guild_id, answer_id
PollVoteRemove MESSAGE_POLL_VOTE_REMOVE GUILD_MESSAGE_POLLS, DIRECT_MESSAGE_POLLS user_id, channel_id, message_id, guild_id, answer_id

The content of messages, and the content of AutoModerationActionExecution, needs the MESSAGE_CONTENT intent, except in DMs and messages that mention the bot.

Voice

Event Dispatch Intents Fields
VoiceStateUpdate VOICE_STATE_UPDATE GUILD_VOICE_STATES voice_state, old
VoiceServerUpdate VOICE_SERVER_UPDATE token, guild_id, endpoint
VoiceChannelEffectSend VOICE_CHANNEL_EFFECT_SEND GUILD_VOICE_STATES channel_id, guild_id, user_id, emoji, animation_type, animation_id, sound_id, sound_volume
VoiceChannelStatusUpdate VOICE_CHANNEL_STATUS_UPDATE GUILDS id, guild_id, status
VoiceChannelStartTimeUpdate VOICE_CHANNEL_START_TIME_UPDATE GUILDS id, guild_id, voice_start_time
ChannelInfo CHANNEL_INFO guild_id, channels; the answer to bot.request_channel_info

The events of the bot's own voice connections are listed in the voice guide.

Interactions, moderation and scheduled events

Event Dispatch Intents Fields
InteractionCreate INTERACTION_CREATE interaction
AutoModerationRuleCreate AUTO_MODERATION_RULE_CREATE AUTO_MODERATION_CONFIGURATION rule
AutoModerationRuleUpdate AUTO_MODERATION_RULE_UPDATE AUTO_MODERATION_CONFIGURATION rule
AutoModerationRuleDelete AUTO_MODERATION_RULE_DELETE AUTO_MODERATION_CONFIGURATION rule
AutoModerationActionExecution AUTO_MODERATION_ACTION_EXECUTION AUTO_MODERATION_EXECUTION guild_id, action, rule_id, rule_trigger_type, user_id, channel_id, message_id, content, matched_keyword, matched_content
ScheduledEventCreate GUILD_SCHEDULED_EVENT_CREATE GUILD_SCHEDULED_EVENTS scheduled_event
ScheduledEventUpdate GUILD_SCHEDULED_EVENT_UPDATE GUILD_SCHEDULED_EVENTS scheduled_event, old
ScheduledEventDelete GUILD_SCHEDULED_EVENT_DELETE GUILD_SCHEDULED_EVENTS scheduled_event
ScheduledEventUserAdd GUILD_SCHEDULED_EVENT_USER_ADD GUILD_SCHEDULED_EVENTS guild_scheduled_event_id, user_id, guild_id
ScheduledEventUserRemove GUILD_SCHEDULED_EVENT_USER_REMOVE GUILD_SCHEDULED_EVENTS guild_scheduled_event_id, user_id, guild_id

Monetization

Event Dispatch Intents Fields
EntitlementCreate ENTITLEMENT_CREATE entitlement, a PartialEntitlement for a test entitlement
EntitlementUpdate ENTITLEMENT_UPDATE entitlement; for a subscription, only when it ends
EntitlementDelete ENTITLEMENT_DELETE entitlement
SubscriptionCreate SUBSCRIPTION_CREATE subscription
SubscriptionUpdate SUBSCRIPTION_UPDATE subscription
SubscriptionDelete SUBSCRIPTION_DELETE subscription

Webhook events

Discord sends these only to the app's Webhook Events URL, which ASGIApp serves. The entitlement events above arrive there too.

Event Type Fields
ApplicationAuthorized APPLICATION_AUTHORIZED integration_type, user, scopes, guild
ApplicationDeauthorized APPLICATION_DEAUTHORIZED user
QuestUserEnrollment QUEST_USER_ENROLLMENT
LobbyMessageCreate LOBBY_MESSAGE_CREATE message
LobbyMessageUpdate LOBBY_MESSAGE_UPDATE message
LobbyMessageDelete LOBBY_MESSAGE_DELETE id, lobby_id
GameDirectMessageCreate GAME_DIRECT_MESSAGE_CREATE message
GameDirectMessageUpdate GAME_DIRECT_MESSAGE_UPDATE message
GameDirectMessageDelete GAME_DIRECT_MESSAGE_DELETE message

Any dispatch

Event Dispatch Intents Fields
RawEvent any name, seq, raw, raw_json; for any dispatch, modelled or not

Events of the bot

These come from bostie, not from Discord; their names are bostie's own.

Event Name Fields Sent when
Starting bot.starting start() is about to sync and connect; REST works
Started bot.started every shard is ready, once per start()
Stopping bot.stopping close() began after Started; the gateway is still open
Stopped bot.stopped close() finished; the gateway and REST are gone
ShardReady shard.ready shard_id a shard's new session is ready and its guilds arrived
ShardDisconnect shard.disconnect shard_id, code, reason, resuming a shard lost its connection
ShardStop shard.stop shard_id, code, reason a shard stopped for good
ShardBackpressure shard.backpressure shard_id, queued_bytes a shard paused reading because the event loop falls behind
ListenerError bot.listener_error listener, event, error a listener raised
TaskError bot.task_error task, error a background task raised