How do I connect a Discord bot?
Make an application with a bot in the Discord developer portal, copy the bot's token and invite the bot to your Discord server. Then select Connect a bot in Settings > Connected bots, choose Discord and the agent, enter the bot's name and paste its token.
A Discord bot lets you and the people on your Discord server chat with one of your agents. Each bot talks to one agent.
Make the bot in Discord
- Sign in to the Discord developer portal and make a new application.
- Open the application's Bot page and copy the bot's token. If you can't see it, reset the token to get a new one.
- On the same page, turn on Message Content Intent, so the bot can read the messages sent to it.
- Invite the bot to your Discord server with an invite link from the portal, with the bot scope and permission to read and send messages.
Connect it to an agent
- Go to Settings > Connected bots in your dashboard and select Connect a bot.
- Choose Discord as the App, and the Agent it should talk to.
- Enter the Bot name.
- Paste the Bot token and select Connect.
The bot shows Live once it's connected. Send it a message on your Discord server.
You can also connect a Discord bot while you deploy, in the Messaging step of Deploy an agent.
Your bot's token lets anyone control the bot. Paste it only into your Rarity dashboard. If it's ever shared, reset it in the developer portal and connect the bot again.