Work In Progress
This documentation is in beta. It's missing lots of content, search is broken, and many links go nowhere. These problems will be fixed before release, but there's plenty of work left!
Skip to main content

Intents

The intents { } builder allows you to configure what Discord gateway intents your bot requires.

Intents define what events the Discord gateway sends to your bot and what data it has access to. Using a limited set of intents can be useful to cut down on event processing overhead or to help ensure your users' privacy by preventing your bot from processing data it doesn't strictly need.

Some intents are privileged, and you'll need to enable them in Discord's developer console. Discord requires verification for any bot that reaches 100 servers, and you'll need to justify why you need these intents. If your bot uses chat commands, this may also include the Message Content intent — if you only use this intent for chat commands, Discord will require that you switch to slash commands, unless this is impossible then.

ExtensibleBot(TOKEN) {
// ...

intents {
+Intent.GuildMembers
+Intent.GuildPresences
}
}

You can add and remove intents using the unary + and - operators.

intents(...) { ... }Receiver: Intents.Builder

Configure your bot's intents.

By default, all non-privileged intents are enabled, along with the message content intent if you're using chat commands, and any intents your bot's extensions need, based on their event handlers.

Function Arguments
addDefaultIntentsType: BooleanDefault: true

Whether to enable all non-privileged intents, as well as the message content intent if you're using chat commands.

addExtensionIntentsType: BooleanDefault: true

Whether to automatically enable the intents required by your extensions, based on their event handlers.