|
|
@ -322,6 +322,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
If the ``channel`` is a :class:`TextChannel` then the ``user`` parameter
|
|
|
|
If the ``channel`` is a :class:`TextChannel` then the ``user`` parameter
|
|
|
|
is a :class:`Member`, otherwise it is a :class:`User`.
|
|
|
|
is a :class:`Member`, otherwise it is a :class:`User`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.typing` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param channel: The location where the typing originated from.
|
|
|
|
:param channel: The location where the typing originated from.
|
|
|
|
:type channel: :class:`abc.Messageable`
|
|
|
|
:type channel: :class:`abc.Messageable`
|
|
|
|
:param user: The user that started typing.
|
|
|
|
:param user: The user that started typing.
|
|
|
@ -333,6 +335,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Called when a :class:`Message` is created and sent.
|
|
|
|
Called when a :class:`Message` is created and sent.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.messages` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
.. warning::
|
|
|
|
.. warning::
|
|
|
|
|
|
|
|
|
|
|
|
Your bot's own messages and private messages are sent through this
|
|
|
|
Your bot's own messages and private messages are sent through this
|
|
|
@ -354,6 +358,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
If this occurs increase the :attr:`Client.max_messages` attribute
|
|
|
|
If this occurs increase the :attr:`Client.max_messages` attribute
|
|
|
|
or use the :func:`on_raw_message_delete` event instead.
|
|
|
|
or use the :func:`on_raw_message_delete` event instead.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.messages` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param message: The deleted message.
|
|
|
|
:param message: The deleted message.
|
|
|
|
:type message: :class:`Message`
|
|
|
|
:type message: :class:`Message`
|
|
|
|
|
|
|
|
|
|
|
@ -369,6 +375,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
If this occurs increase the :attr:`Client.max_messages` attribute
|
|
|
|
If this occurs increase the :attr:`Client.max_messages` attribute
|
|
|
|
or use the :func:`on_raw_bulk_message_delete` event instead.
|
|
|
|
or use the :func:`on_raw_bulk_message_delete` event instead.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.messages` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param messages: The messages that have been deleted.
|
|
|
|
:param messages: The messages that have been deleted.
|
|
|
|
:type messages: List[:class:`Message`]
|
|
|
|
:type messages: List[:class:`Message`]
|
|
|
|
|
|
|
|
|
|
|
@ -380,6 +388,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
If the message is found in the message cache,
|
|
|
|
If the message is found in the message cache,
|
|
|
|
it can be accessed via :attr:`RawMessageDeleteEvent.cached_message`
|
|
|
|
it can be accessed via :attr:`RawMessageDeleteEvent.cached_message`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.messages` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:type payload: :class:`RawMessageDeleteEvent`
|
|
|
|
:type payload: :class:`RawMessageDeleteEvent`
|
|
|
|
|
|
|
|
|
|
|
@ -391,6 +401,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
If the messages are found in the message cache,
|
|
|
|
If the messages are found in the message cache,
|
|
|
|
they can be accessed via :attr:`RawBulkMessageDeleteEvent.cached_messages`
|
|
|
|
they can be accessed via :attr:`RawBulkMessageDeleteEvent.cached_messages`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.messages` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:type payload: :class:`RawBulkMessageDeleteEvent`
|
|
|
|
:type payload: :class:`RawBulkMessageDeleteEvent`
|
|
|
|
|
|
|
|
|
|
|
@ -415,6 +427,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
- The message's embeds were suppressed or unsuppressed.
|
|
|
|
- The message's embeds were suppressed or unsuppressed.
|
|
|
|
- A call message has received an update to its participants or ending time.
|
|
|
|
- A call message has received an update to its participants or ending time.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.messages` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param before: The previous version of the message.
|
|
|
|
:param before: The previous version of the message.
|
|
|
|
:type before: :class:`Message`
|
|
|
|
:type before: :class:`Message`
|
|
|
|
:param after: The current version of the message.
|
|
|
|
:param after: The current version of the message.
|
|
|
@ -436,6 +450,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
denotes an "embed" only edit, which is an edit in which only the embeds are updated by the Discord
|
|
|
|
denotes an "embed" only edit, which is an edit in which only the embeds are updated by the Discord
|
|
|
|
embed server.
|
|
|
|
embed server.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.messages` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:type payload: :class:`RawMessageUpdateEvent`
|
|
|
|
:type payload: :class:`RawMessageUpdateEvent`
|
|
|
|
|
|
|
|
|
|
|
@ -449,6 +465,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
To get the :class:`Message` being reacted, access it via :attr:`Reaction.message`.
|
|
|
|
To get the :class:`Message` being reacted, access it via :attr:`Reaction.message`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.reactions` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param reaction: The current state of the reaction.
|
|
|
|
:param reaction: The current state of the reaction.
|
|
|
|
:type reaction: :class:`Reaction`
|
|
|
|
:type reaction: :class:`Reaction`
|
|
|
|
:param user: The user who added the reaction.
|
|
|
|
:param user: The user who added the reaction.
|
|
|
@ -459,6 +477,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
Called when a message has a reaction added. Unlike :func:`on_reaction_add`, this is
|
|
|
|
Called when a message has a reaction added. Unlike :func:`on_reaction_add`, this is
|
|
|
|
called regardless of the state of the internal message cache.
|
|
|
|
called regardless of the state of the internal message cache.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.reactions` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:type payload: :class:`RawReactionActionEvent`
|
|
|
|
:type payload: :class:`RawReactionActionEvent`
|
|
|
|
|
|
|
|
|
|
|
@ -472,6 +492,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
To get the message being reacted, access it via :attr:`Reaction.message`.
|
|
|
|
To get the message being reacted, access it via :attr:`Reaction.message`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.reactions` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param reaction: The current state of the reaction.
|
|
|
|
:param reaction: The current state of the reaction.
|
|
|
|
:type reaction: :class:`Reaction`
|
|
|
|
:type reaction: :class:`Reaction`
|
|
|
|
:param user: The user who added the reaction.
|
|
|
|
:param user: The user who added the reaction.
|
|
|
@ -482,6 +504,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
Called when a message has a reaction removed. Unlike :func:`on_reaction_remove`, this is
|
|
|
|
Called when a message has a reaction removed. Unlike :func:`on_reaction_remove`, this is
|
|
|
|
called regardless of the state of the internal message cache.
|
|
|
|
called regardless of the state of the internal message cache.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.reactions` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:type payload: :class:`RawReactionActionEvent`
|
|
|
|
:type payload: :class:`RawReactionActionEvent`
|
|
|
|
|
|
|
|
|
|
|
@ -491,6 +515,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
if the message is not found in the internal message cache, then this event
|
|
|
|
if the message is not found in the internal message cache, then this event
|
|
|
|
will not be called. Consider using :func:`on_raw_reaction_clear` instead.
|
|
|
|
will not be called. Consider using :func:`on_raw_reaction_clear` instead.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.reactions` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param message: The message that had its reactions cleared.
|
|
|
|
:param message: The message that had its reactions cleared.
|
|
|
|
:type message: :class:`Message`
|
|
|
|
:type message: :class:`Message`
|
|
|
|
:param reactions: The reactions that were removed.
|
|
|
|
:param reactions: The reactions that were removed.
|
|
|
@ -501,6 +527,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
Called when a message has all its reactions removed. Unlike :func:`on_reaction_clear`,
|
|
|
|
Called when a message has all its reactions removed. Unlike :func:`on_reaction_clear`,
|
|
|
|
this is called regardless of the state of the internal message cache.
|
|
|
|
this is called regardless of the state of the internal message cache.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.reactions` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:type payload: :class:`RawReactionClearEvent`
|
|
|
|
:type payload: :class:`RawReactionClearEvent`
|
|
|
|
|
|
|
|
|
|
|
@ -510,6 +538,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
if the message is not found in the internal message cache, then this event
|
|
|
|
if the message is not found in the internal message cache, then this event
|
|
|
|
will not be called. Consider using :func:`on_raw_reaction_clear_emoji` instead.
|
|
|
|
will not be called. Consider using :func:`on_raw_reaction_clear_emoji` instead.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.reactions` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
.. versionadded:: 1.3
|
|
|
|
.. versionadded:: 1.3
|
|
|
|
|
|
|
|
|
|
|
|
:param reaction: The reaction that got cleared.
|
|
|
|
:param reaction: The reaction that got cleared.
|
|
|
@ -520,6 +550,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
Called when a message has a specific reaction removed from it. Unlike :func:`on_reaction_clear_emoji` this is called
|
|
|
|
Called when a message has a specific reaction removed from it. Unlike :func:`on_reaction_clear_emoji` this is called
|
|
|
|
regardless of the state of the internal message cache.
|
|
|
|
regardless of the state of the internal message cache.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.reactions` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
.. versionadded:: 1.3
|
|
|
|
.. versionadded:: 1.3
|
|
|
|
|
|
|
|
|
|
|
|
:param payload: The raw event payload data.
|
|
|
|
:param payload: The raw event payload data.
|
|
|
@ -530,6 +562,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Called whenever a private channel is deleted or created.
|
|
|
|
Called whenever a private channel is deleted or created.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.messages` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param channel: The private channel that got created or deleted.
|
|
|
|
:param channel: The private channel that got created or deleted.
|
|
|
|
:type channel: :class:`abc.PrivateChannel`
|
|
|
|
:type channel: :class:`abc.PrivateChannel`
|
|
|
|
|
|
|
|
|
|
|
@ -537,6 +571,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Called whenever a private group DM is updated. e.g. changed name or topic.
|
|
|
|
Called whenever a private group DM is updated. e.g. changed name or topic.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.messages` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param before: The updated group channel's old info.
|
|
|
|
:param before: The updated group channel's old info.
|
|
|
|
:type before: :class:`GroupChannel`
|
|
|
|
:type before: :class:`GroupChannel`
|
|
|
|
:param after: The updated group channel's new info.
|
|
|
|
:param after: The updated group channel's new info.
|
|
|
@ -558,6 +594,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Note that you can get the guild from :attr:`~abc.GuildChannel.guild`.
|
|
|
|
Note that you can get the guild from :attr:`~abc.GuildChannel.guild`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.guilds` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param channel: The guild channel that got created or deleted.
|
|
|
|
:param channel: The guild channel that got created or deleted.
|
|
|
|
:type channel: :class:`abc.GuildChannel`
|
|
|
|
:type channel: :class:`abc.GuildChannel`
|
|
|
|
|
|
|
|
|
|
|
@ -565,6 +603,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Called whenever a guild channel is updated. e.g. changed name, topic, permissions.
|
|
|
|
Called whenever a guild channel is updated. e.g. changed name, topic, permissions.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.guilds` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param before: The updated guild channel's old info.
|
|
|
|
:param before: The updated guild channel's old info.
|
|
|
|
:type before: :class:`abc.GuildChannel`
|
|
|
|
:type before: :class:`abc.GuildChannel`
|
|
|
|
:param after: The updated guild channel's new info.
|
|
|
|
:param after: The updated guild channel's new info.
|
|
|
@ -574,6 +614,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Called whenever a message is pinned or unpinned from a guild channel.
|
|
|
|
Called whenever a message is pinned or unpinned from a guild channel.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.guilds` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param channel: The guild channel that had its pins updated.
|
|
|
|
:param channel: The guild channel that had its pins updated.
|
|
|
|
:type channel: :class:`abc.GuildChannel`
|
|
|
|
:type channel: :class:`abc.GuildChannel`
|
|
|
|
:param last_pin: The latest message that was pinned as a naive datetime in UTC. Could be ``None``.
|
|
|
|
:param last_pin: The latest message that was pinned as a naive datetime in UTC. Could be ``None``.
|
|
|
@ -585,6 +627,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Called whenever an integration is created, modified, or removed from a guild.
|
|
|
|
Called whenever an integration is created, modified, or removed from a guild.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.integrations` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param guild: The guild that had its integrations updated.
|
|
|
|
:param guild: The guild that had its integrations updated.
|
|
|
|
:type guild: :class:`Guild`
|
|
|
|
:type guild: :class:`Guild`
|
|
|
|
|
|
|
|
|
|
|
@ -592,6 +636,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Called whenever a webhook is created, modified, or removed from a guild channel.
|
|
|
|
Called whenever a webhook is created, modified, or removed from a guild channel.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.webhooks` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param channel: The channel that had its webhooks updated.
|
|
|
|
:param channel: The channel that had its webhooks updated.
|
|
|
|
:type channel: :class:`abc.GuildChannel`
|
|
|
|
:type channel: :class:`abc.GuildChannel`
|
|
|
|
|
|
|
|
|
|
|
@ -600,6 +646,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Called when a :class:`Member` leaves or joins a :class:`Guild`.
|
|
|
|
Called when a :class:`Member` leaves or joins a :class:`Guild`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.members` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param member: The member who joined or left.
|
|
|
|
:param member: The member who joined or left.
|
|
|
|
:type member: :class:`Member`
|
|
|
|
:type member: :class:`Member`
|
|
|
|
|
|
|
|
|
|
|
@ -614,6 +662,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
- nickname
|
|
|
|
- nickname
|
|
|
|
- roles
|
|
|
|
- roles
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.members` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param before: The updated member's old info.
|
|
|
|
:param before: The updated member's old info.
|
|
|
|
:type before: :class:`Member`
|
|
|
|
:type before: :class:`Member`
|
|
|
|
:param after: The updated member's updated info.
|
|
|
|
:param after: The updated member's updated info.
|
|
|
@ -629,6 +679,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
- username
|
|
|
|
- username
|
|
|
|
- discriminator
|
|
|
|
- discriminator
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.members` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param before: The updated user's old info.
|
|
|
|
:param before: The updated user's old info.
|
|
|
|
:type before: :class:`User`
|
|
|
|
:type before: :class:`User`
|
|
|
|
:param after: The updated user's updated info.
|
|
|
|
:param after: The updated user's updated info.
|
|
|
@ -639,6 +691,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
Called when a :class:`Guild` is either created by the :class:`Client` or when the
|
|
|
|
Called when a :class:`Guild` is either created by the :class:`Client` or when the
|
|
|
|
:class:`Client` joins a guild.
|
|
|
|
:class:`Client` joins a guild.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.guilds` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param guild: The guild that was joined.
|
|
|
|
:param guild: The guild that was joined.
|
|
|
|
:type guild: :class:`Guild`
|
|
|
|
:type guild: :class:`Guild`
|
|
|
|
|
|
|
|
|
|
|
@ -656,6 +710,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
In order for this event to be invoked then the :class:`Client` must have
|
|
|
|
In order for this event to be invoked then the :class:`Client` must have
|
|
|
|
been part of the guild to begin with. (i.e. it is part of :attr:`Client.guilds`)
|
|
|
|
been part of the guild to begin with. (i.e. it is part of :attr:`Client.guilds`)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.guilds` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param guild: The guild that got removed.
|
|
|
|
:param guild: The guild that got removed.
|
|
|
|
:type guild: :class:`Guild`
|
|
|
|
:type guild: :class:`Guild`
|
|
|
|
|
|
|
|
|
|
|
@ -668,6 +724,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
- Changed AFK timeout
|
|
|
|
- Changed AFK timeout
|
|
|
|
- etc
|
|
|
|
- etc
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.guilds` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param before: The guild prior to being updated.
|
|
|
|
:param before: The guild prior to being updated.
|
|
|
|
:type before: :class:`Guild`
|
|
|
|
:type before: :class:`Guild`
|
|
|
|
:param after: The guild after being updated.
|
|
|
|
:param after: The guild after being updated.
|
|
|
@ -680,6 +738,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
To get the guild it belongs to, use :attr:`Role.guild`.
|
|
|
|
To get the guild it belongs to, use :attr:`Role.guild`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.guilds` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param role: The role that was created or deleted.
|
|
|
|
:param role: The role that was created or deleted.
|
|
|
|
:type role: :class:`Role`
|
|
|
|
:type role: :class:`Role`
|
|
|
|
|
|
|
|
|
|
|
@ -687,6 +747,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Called when a :class:`Role` is changed guild-wide.
|
|
|
|
Called when a :class:`Role` is changed guild-wide.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.guilds` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param before: The updated role's old info.
|
|
|
|
:param before: The updated role's old info.
|
|
|
|
:type before: :class:`Role`
|
|
|
|
:type before: :class:`Role`
|
|
|
|
:param after: The updated role's updated info.
|
|
|
|
:param after: The updated role's updated info.
|
|
|
@ -696,6 +758,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Called when a :class:`Guild` adds or removes :class:`Emoji`.
|
|
|
|
Called when a :class:`Guild` adds or removes :class:`Emoji`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.emojis` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param guild: The guild who got their emojis updated.
|
|
|
|
:param guild: The guild who got their emojis updated.
|
|
|
|
:type guild: :class:`Guild`
|
|
|
|
:type guild: :class:`Guild`
|
|
|
|
:param before: A list of emojis before the update.
|
|
|
|
:param before: A list of emojis before the update.
|
|
|
@ -709,6 +773,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
Called when a guild becomes available or unavailable. The guild must have
|
|
|
|
Called when a guild becomes available or unavailable. The guild must have
|
|
|
|
existed in the :attr:`Client.guilds` cache.
|
|
|
|
existed in the :attr:`Client.guilds` cache.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.emojis` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param guild: The :class:`Guild` that has changed availability.
|
|
|
|
:param guild: The :class:`Guild` that has changed availability.
|
|
|
|
|
|
|
|
|
|
|
|
.. function:: on_voice_state_update(member, before, after)
|
|
|
|
.. function:: on_voice_state_update(member, before, after)
|
|
|
@ -722,6 +788,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
- A member is muted or deafened by their own accord.
|
|
|
|
- A member is muted or deafened by their own accord.
|
|
|
|
- A member is muted or deafened by a guild administrator.
|
|
|
|
- A member is muted or deafened by a guild administrator.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.voice_states` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param member: The member whose voice states changed.
|
|
|
|
:param member: The member whose voice states changed.
|
|
|
|
:type member: :class:`Member`
|
|
|
|
:type member: :class:`Member`
|
|
|
|
:param before: The voice state prior to the changes.
|
|
|
|
:param before: The voice state prior to the changes.
|
|
|
@ -733,6 +801,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Called when user gets banned from a :class:`Guild`.
|
|
|
|
Called when user gets banned from a :class:`Guild`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.bans` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param guild: The guild the user got banned from.
|
|
|
|
:param guild: The guild the user got banned from.
|
|
|
|
:type guild: :class:`Guild`
|
|
|
|
:type guild: :class:`Guild`
|
|
|
|
:param user: The user that got banned.
|
|
|
|
:param user: The user that got banned.
|
|
|
@ -744,6 +814,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
|
|
|
|
|
|
|
|
Called when a :class:`User` gets unbanned from a :class:`Guild`.
|
|
|
|
Called when a :class:`User` gets unbanned from a :class:`Guild`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.bans` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param guild: The guild the user got unbanned from.
|
|
|
|
:param guild: The guild the user got unbanned from.
|
|
|
|
:type guild: :class:`Guild`
|
|
|
|
:type guild: :class:`Guild`
|
|
|
|
:param user: The user that got unbanned.
|
|
|
|
:param user: The user that got unbanned.
|
|
|
@ -761,6 +833,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
There is a rare possibility that the :attr:`Invite.guild` and :attr:`Invite.channel`
|
|
|
|
There is a rare possibility that the :attr:`Invite.guild` and :attr:`Invite.channel`
|
|
|
|
attributes will be of :class:`Object` rather than the respective models.
|
|
|
|
attributes will be of :class:`Object` rather than the respective models.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.invites` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param invite: The invite that was created.
|
|
|
|
:param invite: The invite that was created.
|
|
|
|
:type invite: :class:`Invite`
|
|
|
|
:type invite: :class:`Invite`
|
|
|
|
|
|
|
|
|
|
|
@ -779,6 +853,8 @@ to handle it, which defaults to print a traceback and ignoring the exception.
|
|
|
|
Outside of those two attributes, the only other attribute guaranteed to be
|
|
|
|
Outside of those two attributes, the only other attribute guaranteed to be
|
|
|
|
filled by the Discord gateway for this event is :attr:`Invite.code`.
|
|
|
|
filled by the Discord gateway for this event is :attr:`Invite.code`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This requires :attr:`Intents.invites` to be enabled.
|
|
|
|
|
|
|
|
|
|
|
|
:param invite: The invite that was deleted.
|
|
|
|
:param invite: The invite that was deleted.
|
|
|
|
:type invite: :class:`Invite`
|
|
|
|
:type invite: :class:`Invite`
|
|
|
|
|
|
|
|
|
|
|
|