A Discord MCP server, local or on AgentCore
A small Model Context Protocol server that gives Claude Code a Discord bot to work through: list servers and channels, read recent messages, post, reply, react and start threads.
Tools
Eight tools, mapped one to one onto the Discord API: list_guilds,
list_channels (including active threads), read_messages,
send_message, edit_message, delete_message,
add_reaction and create_thread. Mentions in posted messages never
ping anyone.
Keeping it on a short leash
DISCORD_READ_ONLY=trueexposes only the read tools.DISCORD_ALLOWED_GUILDSrestricts which servers the bot will touch.DISCORD_ALLOWED_USERS(AWS only) restricts who can sign in. Without it, any Discord user can.- The bot gets only the permissions it needs: view channels, read history, send messages (also in threads), create public threads and add reactions.
Two ways to run it
Locally, with Docker
Set the bot token, optionally an MCP_AUTH_TOKEN, run
docker compose up, and add it to Claude Code as an HTTP MCP server on
localhost:8000/mcp.
On AWS, with Bedrock AgentCore
Hosted on AgentCore, the server sits behind a Discord OAuth sign-in, using the application's client ID and secret. Combined with the user allow-list, that turns a personal tool into one a small team can share without handing out the bot token.