Kord Extensions Help

Intents

The intents builder allows you to configure which Gateway Intents your bot requires. Intents define what events your bot is sent by the gateway, and what data it has access to. Defining a limited set of intents can be useful to cut down on event processing or to help ensure your users' privacy, by preventing your bot from processing data it doesn't strictly need.

Additionally, there are a number of privileged intents, which must be enabled in the developer console for your bot. Verified bots must justify to Discord why they need these intents, and their access to them may be restricted by Discord.

ExtensibleBot(TOKEN) { // ... intents(true, true) { +Intent.GuildMembers +Intent.GuildPresences } }

Intents may be added and removed using the unary + and - operators, respectively. There are also some additional parameters you can pass to the intents builder function:

Parameter

Type

Default

Description

addDefaultIntents

Boolean

true

Whether to add all non-privileged intents to the builder by default.

addExtensionIntents

Boolean

true

Whether to automatically add the intents required by the bot's loaded extensions to the builder.

The above parameters mirror the default behavior of the intents builder, if you choose not to provide your own.

Last modified: 20 November 2024