Skip to content

Discord setup ​

Each character is one Discord application.

  1. In the Discord Developer Portal create an application, copy the token on the Bot page and put it in .env (e.g. DISCORD_LUNA_TOKEN: …).
  2. Under Bot → Privileged Gateway Intents enable Message Content Intent, otherwise the bot cannot read ordinary messages.
  3. Under OAuth2 → URL Generator select bot and applications.commands, with the permissions View Channels, Send Messages, Read Message History, Send Messages in Threads, Attach Files, Add Reactions. Administrator is not needed.
  4. Invite the bot with the generated link and put the server and channel IDs in discord.guilds (right-click → Copy ID in developer mode).

On startup each character registers its slash commands in its servers. Replies use Discord Markdown, are split above 2000 characters, and never trigger @ notifications.

BSD 2-Clause License