Skip to content

Commit

Permalink
Add new gateway intents for poll vote changes
Browse files Browse the repository at this point in the history
Adds the new gateway intents for receiving dispatch messages about votes
being added/removed from polls.

Also documents the auto moderator intents that were already present but undocumented.
  • Loading branch information
jb3 committed Apr 14, 2024
1 parent 7414520 commit 11ba7e5
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 4 deletions.
22 changes: 19 additions & 3 deletions guides/intro/gateway_intents.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,15 +90,31 @@ direct_message_reactions:
direct_message_typing:
- TYPING_START
GUILD_SCHEDULED_EVENTS:
message_content*:
- MESSAGE_CONTENT
guild_scheduled_events:
- GUILD_SCHEDULED_EVENT_CREATE
- GUILD_SCHEDULED_EVENT_UPDATE
- GUILD_SCHEDULED_EVENT_DELETE
- GUILD_SCHEDULED_EVENT_USER_ADD
- GUILD_SCHEDULED_EVENT_USER_REMOVE
message_content*:
- MESSAGE_CONTENT
auto_moderation_configuration:
- AUTO_MODERATION_RULE_CREATE
- AUTO_MODERATION_RULE_DELETE
- AUTO_MODERATION_RULE_UPDATE
auto_moderation_execution:
- AUTO_MODERATION_RULE_EXECUTION
guild_message_polls:
- MESSAGE_POLL_VOTE_ADD
- MESSAGE_POLL_VOTE_REMOVE
direct_message_polls:
- MESSAGE_POLL_VOTE_ADD
- MESSAGE_POLL_VOTE_REMOVE
```

Besides an explicit list of atoms, acceptable configuration values are `:all` and `:nonprivileged`.
Expand Down
4 changes: 3 additions & 1 deletion lib/nostrum/shard/intents.ex
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@ defmodule Nostrum.Shard.Intents do
message_content: 1 <<< 15,
guild_scheduled_events: 1 <<< 16,
auto_moderation_configuration: 1 <<< 20,
auto_moderation_execution: 1 <<< 21
auto_moderation_execution: 1 <<< 21,
guild_message_polls: 1 <<< 24,
direct_message_polls: 1 <<< 25
]
end

Expand Down

0 comments on commit 11ba7e5

Please # to comment.