Skip to content
API Blog

Discord

Lobu’s Discord adapter supports direct messages, server channels, and interactive workflows. Under the hood, Lobu uses the Chat SDK Discord adapter to handle DMs and server messaging.

  1. Create a Discord application at the Discord Developer Portal.
  2. Under Bot, create a bot and copy the bot token.
  3. Copy the Application ID and Public Key from the General Information page.
  4. Under OAuth2 → URL Generator, select the bot scope plus message-send, read-history, and slash-command permissions. Use the generated URL to invite the bot to your server.
  5. Use Agents → Connections in the web app to add Discord, or declare a discord connection in lobu.config.ts.
FieldRequiredTypeDescription
botTokenNostringDiscord bot token.
applicationIdNostringDiscord application ID.
publicKeyNostringApplication public key for webhook signature verification.
mentionRoleIdsNostring[]Role IDs that trigger mention handlers (in addition to direct mentions).
userNameNostringOverride bot username.
  • Direct messages and server channel mentions trigger the agent.
  • Role-based triggers — configure specific roles that activate the agent beyond direct mentions.
  • Streaming responses with throttled message edits.
  • Markdown formatting — agent responses render as Discord-flavored markdown.
  • Interactive elements — buttons and cards for user prompts, permission grants, and configuration.
  • Access control — restrict which users or groups can interact with the agent.
  • Team assistant in a Discord server (engineering, support, knowledge base).
  • Community bot that answers questions using your agent’s skills and tools.
  • Developer tool that runs commands or queries APIs on behalf of server members.