Prerequisites
- A Discord account
- A Discord server where you have Manage Server permission
- A Claw instance (create one here)
Setup Guide
Create a Discord Application
- Go to the Discord Developer Portal
- Click New Application
- Give it a name (e.g., “My AI Bot”) and click Create
Create a Bot
- In your application, go to the Bot tab
- Click Add Bot → Yes, do it!
- Under Privileged Gateway Intents, enable:
- Message Content Intent (required)
- Server Members Intent (recommended)
- Click Reset Token to generate a bot token
- Copy the token — you’ll need it next
Invite the Bot to Your Server
- Go to the OAuth2 tab → URL Generator
- Under Scopes, select:
bot,applications.commands - Under Bot Permissions, select:
Send Messages,Read Message History - Copy the generated URL and open it in your browser
- Select your server and click Authorize
Configure in LemonData Dashboard
- Go to your Claw Dashboard
- Click the settings icon on your instance
- Open the IM Integrations tab
- Expand the Discord section
- Paste your Bot Token
- Click Save
Using in Servers
Group Settings
Configure server (guild) behavior in the IM Integrations tab of your Dashboard:| Setting | Options | Description |
|---|---|---|
| Group Policy | Open (default) / Allowlist / Disabled | Controls access to server channels |
| Require @mention | On / Off | Bot only responds when @mentioned (recommended) |
| Group IDs | List of guild IDs | Restrict to specific servers (empty = all servers) |
Discord uses per-guild user allowlists instead of a global group allowlist. For advanced per-guild user filtering, configure directly in the OpenClaw config file.
DM Policy
Control who can send direct messages to your bot:| Policy | Behavior |
|---|---|
| Pairing (default) | New users get a pairing code — enter it in the WebUI to authorize |
| Allowlist | Only user IDs you specify can DM the bot |
| Open | Anyone can DM the bot (use with caution) |
Troubleshooting
Bot is online but doesn't respond
Bot is online but doesn't respond
- Make sure Message Content Intent is enabled in the Developer Portal
- Verify the bot token is correct
- Check that the bot has permission to read and send messages in the channel
Bot shows as offline
Bot shows as offline
- Check your instance status in the dashboard (should be green/running)
- Try restarting the instance
- Verify the token hasn’t been reset in the Developer Portal
409 Conflict errors in logs
409 Conflict errors in logs
- This happens when two instances try to use the same bot token
- Make sure only one Claw instance is configured with this token