EventHandlers
@discordeno/bot • Docs
Documentation / @discordeno/bot / EventHandlers
Interface: EventHandlers<TProps, TBehavior, TBot>
Type Parameters
• TProps extends TransformersDesiredProperties
• TBehavior extends DesiredPropertiesBehavior
• TBot extends Bot
<TProps
, TBehavior
> = Bot
<TProps
, TBehavior
>
Properties
applicationCommandPermissionsUpdate()
applicationCommandPermissionsUpdate: (
command
) =>unknown
Parameters
• command: GuildApplicationCommandPermissions
Returns
unknown
Defined in
automodActionExecution()
automodActionExecution: (
payload
) =>unknown
Parameters
• payload: AutoModerationActionExecution
Returns
unknown
Defined in
automodRuleCreate()
automodRuleCreate: (
rule
) =>unknown
Parameters
• rule: AutoModerationRule
Returns
unknown
Defined in
automodRuleDelete()
automodRuleDelete: (
rule
) =>unknown
Parameters
• rule: AutoModerationRule
Returns
unknown
Defined in
automodRuleUpdate()
automodRuleUpdate: (
rule
) =>unknown
Parameters
• rule: AutoModerationRule
Returns
unknown
Defined in
botUpdate()
botUpdate: (
user
) =>unknown
Parameters
• user: TBot
["transformers"
]["$inferredTypes"
]["user"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:135
channelCreate()
channelCreate: (
channel
) =>unknown
Parameters
• channel: TBot
["transformers"
]["$inferredTypes"
]["channel"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:112
channelDelete()
channelDelete: (
channel
) =>unknown
Parameters
• channel: TBot
["transformers"
]["$inferredTypes"
]["channel"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:114
channelPinsUpdate()
channelPinsUpdate: (
data
) =>unknown
Parameters
• data
• data.channelId: bigint
• data.guildId?: bigint
• data.lastPinTimestamp?: number
Returns
unknown
Defined in
packages/bot/src/events.ts:115
channelUpdate()
channelUpdate: (
channel
) =>unknown
Parameters
• channel: TBot
["transformers"
]["$inferredTypes"
]["channel"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:116
debug()
debug: (
text
, ...args
) =>unknown
Parameters
• text: string
• ...args: any
[]
Returns
unknown
Defined in
dispatchRequirements()
dispatchRequirements: (
data
,shardId
) =>unknown
Parameters
• data: DiscordGatewayPayload
• shardId: number
Returns
unknown
Defined in
packages/bot/src/events.ts:113
entitlementCreate()
entitlementCreate: (
entitlement
) =>unknown
Parameters
• entitlement: TBot
["transformers"
]["$inferredTypes"
]["entitlement"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:143
entitlementDelete()
entitlementDelete: (
entitlement
) =>unknown
Parameters
• entitlement: TBot
["transformers"
]["$inferredTypes"
]["entitlement"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:145
entitlementUpdate()
entitlementUpdate: (
entitlement
) =>unknown
Parameters
• entitlement: TBot
["transformers"
]["$inferredTypes"
]["entitlement"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:144
guildAuditLogEntryCreate()
guildAuditLogEntryCreate: (
log
,guildId
) =>unknown
Parameters
• log: AuditLogEntry
• guildId: bigint
Returns
unknown
Defined in
guildBanAdd()
guildBanAdd: (
user
,guildId
) =>unknown
Parameters
• user: TBot
["transformers"
]["$inferredTypes"
]["user"
]
• guildId: bigint
Returns
unknown
Defined in
packages/bot/src/events.ts:124
guildBanRemove()
guildBanRemove: (
user
,guildId
) =>unknown
Parameters
• user: TBot
["transformers"
]["$inferredTypes"
]["user"
]
• guildId: bigint
Returns
unknown
Defined in
packages/bot/src/events.ts:125
guildCreate()
guildCreate: (
guild
) =>unknown
Parameters
• guild: TBot
["transformers"
]["$inferredTypes"
]["guild"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:126
guildDelete()
guildDelete: (
id
,shardId
) =>unknown
Parameters
• id: bigint
• shardId: number
Returns
unknown
Defined in
packages/bot/src/events.ts:127
guildEmojisUpdate()
guildEmojisUpdate: (
payload
) =>unknown
Parameters
• payload
• payload.emojis: Collection
<bigint
, TBot
["transformers"
]["$inferredTypes"
]["emoji"
]>
• payload.guildId: bigint
Returns
unknown
Defined in
packages/bot/src/events.ts:120
guildMemberAdd()
guildMemberAdd: (
member
,user
) =>unknown
Parameters
• member: TBot
["transformers"
]["$inferredTypes"
]["member"
]
• user: TBot
["transformers"
]["$inferredTypes"
]["user"
]
Returns
unknown
Defined in
guildMemberRemove()
guildMemberRemove: (
user
,guildId
) =>unknown
Parameters
• user: TBot
["transformers"
]["$inferredTypes"
]["user"
]
• guildId: bigint
Returns
unknown
Defined in
guildMemberUpdate()
guildMemberUpdate: (
member
,user
) =>unknown
Parameters
• member: TBot
["transformers"
]["$inferredTypes"
]["member"
]
• user: TBot
["transformers"
]["$inferredTypes"
]["user"
]
Returns
unknown
Defined in
guildStickersUpdate()
guildStickersUpdate: (
payload
) =>unknown
Parameters
• payload
• payload.guildId: bigint
• payload.stickers: TBot
["transformers"
]["$inferredTypes"
]["sticker"
][]
Returns
unknown
Defined in
guildUnavailable()
guildUnavailable: (
id
,shardId
) =>unknown
Parameters
• id: bigint
• shardId: number
Returns
unknown
Defined in
packages/bot/src/events.ts:128
guildUpdate()
guildUpdate: (
guild
) =>unknown
Parameters
• guild: TBot
["transformers"
]["$inferredTypes"
]["guild"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:129
integrationCreate()
integrationCreate: (
integration
) =>unknown
Parameters
• integration: Integration
Returns
unknown
Defined in
integrationDelete()
integrationDelete: (
payload
) =>unknown
Parameters
• payload
• payload.applicationId?: bigint
• payload.guildId: bigint
• payload.id: bigint
Returns
unknown
Defined in
integrationUpdate()
integrationUpdate: (
payload
) =>unknown
Parameters
• payload
• payload.guildId: bigint
Returns
unknown
Defined in
interactionCreate()
interactionCreate: (
interaction
) =>unknown
Parameters
• interaction: TBot
["transformers"
]["$inferredTypes"
]["interaction"
]
Returns
unknown
Defined in
inviteCreate()
inviteCreate: (
invite
) =>unknown
Parameters
• invite: TBot
["transformers"
]["$inferredTypes"
]["invite"
]
Returns
unknown
Defined in
inviteDelete()
inviteDelete: (
payload
) =>unknown
Parameters
• payload
• payload.channelId: bigint
• payload.code: string
• payload.guildId?: bigint
Returns
unknown
Defined in
messageCreate()
messageCreate: (
message
) =>unknown
Parameters
• message: TBot
["transformers"
]["$inferredTypes"
]["message"
]
Returns
unknown
Defined in
messageDelete()
messageDelete: (
payload
,message
?) =>unknown
Parameters
• payload
• payload.channelId: bigint
• payload.guildId?: bigint
• payload.id?: bigint
• message?: TBot
["transformers"
]["$inferredTypes"
]["message"
]
Returns
unknown
Defined in
messageDeleteBulk()
messageDeleteBulk: (
payload
) =>unknown
Parameters
• payload
• payload.channelId: bigint
• payload.guildId?: bigint
• payload.ids: bigint
[]
Returns
unknown
Defined in
messagePollVoteAdd()
messagePollVoteAdd: (
payload
) =>unknown
Parameters
• payload
• payload.answerId: number
• payload.channelId: bigint
• payload.guildId?: bigint
• payload.messageId: bigint
• payload.userId: bigint
Returns
unknown
Defined in
packages/bot/src/events.ts:149
messagePollVoteRemove()
messagePollVoteRemove: (
payload
) =>unknown
Parameters
• payload
• payload.answerId: number
• payload.channelId: bigint
• payload.guildId?: bigint
• payload.messageId: bigint
• payload.userId: bigint
Returns
unknown
Defined in
packages/bot/src/events.ts:150
messageUpdate()
messageUpdate: (
message
) =>unknown
Parameters
• message: TBot
["transformers"
]["$inferredTypes"
]["message"
]
Returns
unknown
Defined in
presenceUpdate()
presenceUpdate: (
presence
) =>unknown
Parameters
• presence: PresenceUpdate
Returns
unknown
Defined in
raw()
raw: (
data
,shardId
) =>unknown
Parameters
• data: DiscordGatewayPayload
• shardId: number
Returns
unknown
Defined in
packages/bot/src/events.ts:130
reactionAdd()
reactionAdd: (
payload
) =>unknown
Parameters
• payload
• payload.burst: boolean
• payload.burstColors?: string
[]
• payload.channelId: bigint
• payload.emoji: TBot
["transformers"
]["$inferredTypes"
]["emoji"
]
• payload.guildId?: bigint
• payload.member?: TBot
["transformers"
]["$inferredTypes"
]["member"
]
• payload.messageAuthorId?: bigint
• payload.messageId: bigint
• payload.user?: TBot
["transformers"
]["$inferredTypes"
]["user"
]
• payload.userId: bigint
Returns
unknown
Defined in
reactionRemove()
reactionRemove: (
payload
) =>unknown
Parameters
• payload
• payload.burst: boolean
• payload.channelId: bigint
• payload.emoji: TBot
["transformers"
]["$inferredTypes"
]["emoji"
]
• payload.guildId?: bigint
• payload.messageId: bigint
• payload.userId: bigint
Returns
unknown
Defined in
reactionRemoveAll()
reactionRemoveAll: (
payload
) =>unknown
Parameters
• payload
• payload.channelId: bigint
• payload.guildId?: bigint
• payload.messageId: bigint
Returns
unknown
Defined in
reactionRemoveEmoji()
reactionRemoveEmoji: (
payload
) =>unknown
Parameters
• payload
• payload.channelId: bigint
• payload.emoji: TBot
["transformers"
]["$inferredTypes"
]["emoji"
]
• payload.guildId?: bigint
• payload.messageId: bigint
Returns
unknown
Defined in
ready()
ready: (
payload
,rawPayload
) =>unknown
Parameters
• payload
• payload.applicationId: bigint
• payload.guilds: bigint
[]
• payload.sessionId: string
• payload.shard?: number
[]
• payload.shardId: number
• payload.user: TBot
["transformers"
]["$inferredTypes"
]["user"
]
• payload.v: number
• rawPayload: DiscordReady
Returns
unknown
Defined in
roleCreate()
roleCreate: (
role
) =>unknown
Parameters
• role: TBot
["transformers"
]["$inferredTypes"
]["role"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:131
roleDelete()
roleDelete: (
payload
) =>unknown
Parameters
• payload
• payload.guildId: bigint
• payload.roleId: bigint
Returns
unknown
Defined in
packages/bot/src/events.ts:132
roleUpdate()
roleUpdate: (
role
) =>unknown
Parameters
• role: TBot
["transformers"
]["$inferredTypes"
]["role"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:133
scheduledEventCreate()
scheduledEventCreate: (
event
) =>unknown
Parameters
• event: TBot
["transformers"
]["$inferredTypes"
]["scheduledEvent"
]
Returns
unknown
Defined in
scheduledEventDelete()
scheduledEventDelete: (
event
) =>unknown
Parameters
• event: TBot
["transformers"
]["$inferredTypes"
]["scheduledEvent"
]
Returns
unknown
Defined in
scheduledEventUpdate()
scheduledEventUpdate: (
event
) =>unknown
Parameters
• event: TBot
["transformers"
]["$inferredTypes"
]["scheduledEvent"
]
Returns
unknown
Defined in
scheduledEventUserAdd()
scheduledEventUserAdd: (
payload
) =>unknown
Parameters
• payload
• payload.guildId: bigint
• payload.guildScheduledEventId: bigint
• payload.userId: bigint
Returns
unknown
Defined in
scheduledEventUserRemove()
scheduledEventUserRemove: (
payload
) =>unknown
Parameters
• payload
• payload.guildId: bigint
• payload.guildScheduledEventId: bigint
• payload.userId: bigint
Returns
unknown
Defined in
soundboardSoundCreate()
soundboardSoundCreate: (
payload
) =>unknown
Parameters
• payload: TBot
["transformers"
]["$inferredTypes"
]["soundboardSound"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:151
soundboardSoundDelete()
soundboardSoundDelete: (
payload
) =>unknown
Parameters
• payload
• payload.guildId: bigint
• payload.soundId: bigint
Returns
unknown
Defined in
packages/bot/src/events.ts:153
soundboardSounds()
soundboardSounds: (
payload
) =>unknown
Parameters
• payload
• payload.guildId: bigint
• payload.soundboardSounds: TBot
["transformers"
]["$inferredTypes"
]["soundboardSound"
][]
Returns
unknown
Defined in
packages/bot/src/events.ts:155
soundboardSoundsUpdate()
soundboardSoundsUpdate: (
payload
) =>unknown
Parameters
• payload
• payload.guildId: bigint
• payload.soundboardSounds: TBot
["transformers"
]["$inferredTypes"
]["soundboardSound"
][]
Returns
unknown
Defined in
packages/bot/src/events.ts:154
soundboardSoundUpdate()
soundboardSoundUpdate: (
payload
) =>unknown
Parameters
• payload: TBot
["transformers"
]["$inferredTypes"
]["soundboardSound"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:152
stageInstanceCreate()
stageInstanceCreate: (
data
) =>unknown
Parameters
• data
• data.channelId: bigint
• data.guildId: bigint
• data.id: bigint
• data.topic: string
Returns
unknown
Defined in
packages/bot/src/events.ts:117
stageInstanceDelete()
stageInstanceDelete: (
data
) =>unknown
Parameters
• data
• data.channelId: bigint
• data.guildId: bigint
• data.id: bigint
• data.topic: string
Returns
unknown
Defined in
packages/bot/src/events.ts:118
stageInstanceUpdate()
stageInstanceUpdate: (
data
) =>unknown
Parameters
• data
• data.channelId: bigint
• data.guildId: bigint
• data.id: bigint
• data.topic: string
Returns
unknown
Defined in
packages/bot/src/events.ts:119
subscriptionCreate()
subscriptionCreate: (
subscription
) =>unknown
Parameters
• subscription: TBot
["transformers"
]["$inferredTypes"
]["subscription"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:146
subscriptionDelete()
subscriptionDelete: (
subscription
) =>unknown
Parameters
• subscription: TBot
["transformers"
]["$inferredTypes"
]["subscription"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:148
subscriptionUpdate()
subscriptionUpdate: (
subscription
) =>unknown
Parameters
• subscription: TBot
["transformers"
]["$inferredTypes"
]["subscription"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:147
threadCreate()
threadCreate: (
thread
) =>unknown
Parameters
• thread: TBot
["transformers"
]["$inferredTypes"
]["channel"
]
Returns
unknown
Defined in
threadDelete()
threadDelete: (
thread
) =>unknown
Parameters
• thread: TBot
["transformers"
]["$inferredTypes"
]["channel"
]
Returns
unknown
Defined in
threadListSync()
threadListSync: (
payload
) =>unknown
Parameters
• payload
• payload.channelIds?: bigint
[]
• payload.guildId: bigint
• payload.members: ThreadMember
[]
• payload.threads: TBot
["transformers"
]["$inferredTypes"
]["channel"
][]
Returns
unknown
Defined in
threadMembersUpdate()
threadMembersUpdate: (
payload
) =>unknown
Parameters
• payload
• payload.addedMembers?: ThreadMember
[]
• payload.guildId: bigint
• payload.id: bigint
• payload.removedMemberIds?: bigint
[]
Returns
unknown
Defined in
threadMemberUpdate()
threadMemberUpdate: (
payload
) =>unknown
Parameters
• payload
• payload.flags: number
• payload.guildId: bigint
• payload.id: bigint
• payload.joinedAt: number
Returns
unknown
Defined in
threadUpdate()
threadUpdate: (
thread
) =>unknown
Parameters
• thread: TBot
["transformers"
]["$inferredTypes"
]["channel"
]
Returns
unknown
Defined in
typingStart()
typingStart: (
payload
) =>unknown
Parameters
• payload
• payload.channelId: bigint
• payload.guildId: undefined
| bigint
• payload.member: undefined
| TBot
["transformers"
]["$inferredTypes"
]["member"
]
• payload.timestamp: number
• payload.userId: bigint
Returns
unknown
Defined in
packages/bot/src/events.ts:136
voiceChannelEffectSend()
voiceChannelEffectSend: (
payload
) =>unknown
Parameters
• payload
• payload.animationId?: number
• payload.animationType?: DiscordVoiceChannelEffectAnimationType
• payload.channelId: bigint
• payload.emoji?: TBot
["transformers"
]["$inferredTypes"
]["emoji"
]
• payload.guildId: bigint
• payload.soundId?: number
| bigint
• payload.soundVolume?: number
• payload.userId: bigint
Returns
unknown
Defined in
packages/bot/src/events.ts:100
voiceServerUpdate()
voiceServerUpdate: (
payload
) =>unknown
Parameters
• payload
• payload.endpoint?: string
• payload.guildId: bigint
• payload.token: string
Returns
unknown
Defined in
packages/bot/src/events.ts:110
voiceStateUpdate()
voiceStateUpdate: (
voiceState
) =>unknown
Parameters
• voiceState: TBot
["transformers"
]["$inferredTypes"
]["voiceState"
]
Returns
unknown
Defined in
packages/bot/src/events.ts:111
webhooksUpdate()
webhooksUpdate: (
payload
) =>unknown
Parameters
• payload
• payload.channelId: bigint
• payload.guildId: bigint
Returns
unknown