Discord Bot Setup
Step-by-step guide to connect your Claw Buff agent to Discord
Connect your Claw Buff AI agent to a Discord server. Your bot will respond to DMs and channel messages. Setup takes about 10 minutes.
Prerequisites
- A Discord account
- A Discord server where you have Manage Server permission
- A deployed Claw Buff agent (Getting Started)
Step 1: Create a Discord Application
Open the Developer Portal
Go to the Discord Developer Portal and click New Application. Give it a name (e.g., "My AI Agent").
Create a Bot
In the sidebar, click Bot. Customize the bot's username and avatar if you like.
Enable Message Content Intent
Scroll down to Privileged Gateway Intents and enable:
- Message Content Intent — Required for reading messages
- Server Members Intent — Recommended for role-based access
Click Save Changes.
Copy the Bot Token
Click Reset Token (or Copy if shown) to get your bot token. Save it — you'll need it next.
Your bot token is a secret. Never share it publicly. If it's compromised, immediately reset it in the Developer Portal.
Step 2: Invite the Bot to Your Server
Generate an invite link
In the Developer Portal sidebar, click OAuth2 → URL Generator.
Select these scopes:
botapplications.commands
Then select these bot permissions:
View ChannelsSend MessagesRead Message HistoryEmbed LinksAttach Files
Invite the bot
Copy the generated URL and open it in your browser. Select the server you want to add the bot to, then click Authorize.
Step 3: Connect to Claw Buff
- Open the Claw Buff Console → Channels page
- Find the Discord card and click Connect
- Paste your Bot Token from Step 1
- Click Save & Activate
Your bot will come online within seconds.
Step 4: Pair Your Account
Before the bot responds, you need to pair your Discord account:
- DM the bot — Click the bot's name in the server member list and send any message (e.g., "hello")
- The bot will reply with a pairing code (e.g.,
X7QTGBD4) - Go to the Claw Buff Console → Channels page
- You'll see a Pending Pairing Requests section — click Approve next to the code
Once approved, the bot will respond to your DMs immediately.
Step 5: Enable Server Channels (Optional)
By default, the bot only works in DMs. To use it in server channels:
- In Discord, right-click your server icon → Copy Server ID
If you don't see "Copy Server ID", enable Developer Mode first: User Settings → Advanced → toggle on Developer Mode.
- In the Console, go to Channels → click Manage on the Discord card
- Under Authorized Servers, paste your Server ID and click Add
The bot will now respond to @mentions in that server's channels. You can add multiple servers.
When mentioning the bot, make sure you select the bot user (shown under "Members" with an APP tag), not the role with the same name. Discord creates a role with the same name as your bot — mentioning the role will not trigger a response.
Features
| Feature | Supported |
|---|---|
| Direct Messages | Yes |
| Channel Messages | Yes (mention required) |
| Streaming Responses | Yes (real-time editing) |
| Slash Commands | Yes |
| Rich Embeds | Yes |
| File Attachments | Yes |
| Voice Channels | Yes |
Frequently Asked Questions
1. Bot is offline in Discord?
- Check the token — Make sure you pasted the complete token
- Check intents — Message Content Intent must be enabled in the Developer Portal
- Check the Console — The Channels page shows connection status and error logs
2. Bot doesn't respond to messages?
- Make sure Message Content Intent is enabled (Step 1)
- In channels, the bot requires an @mention to respond
- Make sure you mention the bot user, not the role — When typing
@, select the bot from the "Members" section (with the APP tag), not from the "Roles" section. Discord creates a role with the same name as your bot, but mentioning the role will not trigger a response. - Check that the bot has View Channels and Read Message History permissions in the channel
3. "Missing Permissions" error?
The bot needs the correct permissions in the channel. Check that it has at minimum: View Channels, Send Messages, Read Message History, and Embed Links.