Discord
WednesdayAI connects to Discord via the Discord Bot API. Setup requires creating a Discord application, adding a bot to your server, and configuring the bot token.Quick setup
1. Create a Discord application and bot:- Go to the Discord Developer Portal
- Click New Application → give it a name
- In the sidebar, click Bot → Add Bot
- Copy the bot token (click Reset Token to reveal it)
- Message Content Intent (
MESSAGE_CONTENT) — required for reading message content - Server Members Intent — recommended for user lookup
The Server Members intent also requires opting in via config:
channels.discord.intents.guildMembers: true. Without this, the gateway does not request the GuildMembers intent even when enabled in the Portal.GUILD_MESSAGE_REACTIONS— required for reaction-based interactions
- Go to OAuth2 → URL Generator
- Scopes:
bot,applications.commands - Bot Permissions: View Channels, Send Messages, Read Message History, Embed Links, Attach Files, Add Reactions
- Copy the URL and open it in your browser to add the bot
~/.openclaw/openclaw.json:
Access control
DM policy
user:<id> or <@id> format. Unquoted numeric literals are rejected by schema validation — IDs must be JSON strings. Bare quoted strings ("987654321098765432") are accepted, but the user: prefix is preferred for clarity.
Server (guild) policy
requireMention: false lets the bot respond to all messages in allowed channels without needing an @mention.
Native slash commands
native: false, the gateway clears previously registered commands on next startup.
Default slash command behavior: responses are ephemeral (only visible to the invoking user). Configure per command if needed.
Live streaming
partial edits a single message in-place as tokens arrive. off disables streaming — bot shows typing then sends the complete response.
Thread support
| Key | Type | Default | Description |
|---|---|---|---|
threadBindings.enabled | boolean | true | Participate in threads |
threadBindings.idleHours | integer | 24 | Hours of inactivity before a thread is considered idle |
threadBindings.maxAgeHours | integer | 0 | Maximum thread age in hours (0 = disabled by default) |
threadBindings.spawnSubagentSessions | boolean | false | Spawn a subagent session per thread |
threadBindings.spawnAcpSessions | boolean | false | Spawn an ACP session per thread |
Delivery settings
| Key | Type | Default | Description |
|---|---|---|---|
textChunkLimit | integer | 2000 | Maximum characters per outbound chunk (Discord’s per-message limit is 2000) |
chunkMode | string | "length" | length splits at character count; newline splits at paragraph boundaries |
Voice channels
Requires:- Native commands enabled (
commands.native: "auto") - Bot permissions: Connect, Speak in voice channels
/vc join (Discord native command only).
Forum channels
The bot can post to Discord forum channels. Send a message to the forum parent channel ID — the bot automatically creates a thread:message thread create tool action in an agent.
Troubleshooting
Bot not receiving messages / 'Missing Access'
Bot not receiving messages / 'Missing Access'
- Verify Message Content Intent is enabled in the Developer Portal
- Verify the bot has “View Channels” and “Read Message History” permissions in the server
- Restart the gateway after enabling intents
Guild messages blocked despite requireMention: false
Guild messages blocked despite requireMention: false
Check the
groupPolicy — if it is "allowlist", the guild must be in guilds map AND the sender must be in users or have an allowed roles entry. requireMention: false only removes the mention requirement; allowlist enforcement is separate.Slash commands not appearing in Discord
Slash commands not appearing in Discord
Commands can take up to 1 hour to propagate globally. For testing, use guild-specific command registration (contact maintainer for config). Check
openclaw logs --follow | grep "discord.*command" for registration errors.Long-running handlers time out
Long-running handlers time out
Discord has a 3-second timeout on interaction acknowledgment. For slow tools, increase the event queue timeout:The default is already 120 000 ms — use a value higher than that, e.g., 300 000 ms (5 min).