i'm trying to connect to Discord gateway, but i didn't receive all events (like MESSAGE_REACTION_ADD, MESSAGE_REACTION_REMOVE, all threads events and more) because I don't know the intent code for get all events.
Payload that I actually send to Discord:
let payload = {
op: 2,
d: {
token: "bot token",
intents: 513,
properties: {
$os: "linux",
$browser: "chrome",
$device: "chrome",
},
},
};
My current intent code doesn't works for all events.
What code I need to insert for get all events?
Discord documentation isn't very clean about this.
Thanks in advice and sorry for bad english!
If you want every intent you can use 32767
, to find what the number you need to add together all the intents you need. Each number is listen in the documentation here. So if I wanted to have GUILDS
, GUILD_MESSAGES
, GUILD_MESSAGE_REACTIONS
, and GUILD_MESSAGE_TYPING
and I would just add together 1 << 0
, 1 << 9
, 1 << 10
, and 1 << 11
which is 3585
.