Discord Raw API MCP Server
Discord Raw API MCP Server
This MCP server provides raw Discord API access through a single flexible tool. It supports both REST API calls and slash command syntax.
<a href="https://glama.ai/mcp/servers/ct3fi5s557"><img width="380" height="200" src="https://glama.ai/mcp/servers/ct3fi5s557/badge" alt="Discord Raw API Server MCP server" /></a>
Installation
- Set up your Discord bot:
- Create a new application at Discord Developer Portal
- Create a bot and copy the token
- Enable required privileged intents:
- MESSAGE CONTENT INTENT
- PRESENCE INTENT
- SERVER MEMBERS INTENT
- Invite the bot to your server using OAuth2 URL Generator
- Clone and install the package:
Configuration
Add this to your claude_desktop_config.json
Usage
REST API Style
Slash Command Style
Examples
- Create a role:
- Send a message:
- Get server information:
Reccomendations:
Put server, channel and user IDs and some examples in project knowledge to avoid having to remind the model of those, along with something like this to get it started:
"Here's how to effectively use the Discord raw API tool: The tool is called discord_api and takes three parameters:
- method: HTTP method ("GET", "POST", "PUT", "PATCH", "DELETE")
- endpoint: Discord API endpoint (e.g., "guilds/{guild.id}/roles")
- payload: Optional JSON object for the request body Key examples I've used:
- Creating roles:
- Creating categories and channels:
- Moving channels to categories:
- Sending messages:
- Assigning roles:
The tool supports the full Discord API, so you can reference the Discord API documentation for more endpoints and features. The responses include IDs and other metadata you can use for subsequent requests. Pro tips:
- Save IDs returned from creation requests to use in follow-up requests
Unicode emojis can be included directly in message content? Tell the model to use discord emoji like :champagne_glass: - Messages with unicode emoji hangs Claude Desktop?- Channel types: 0 = text, 2 = voice, 4 = category, 13 = stage
- Role colors are in decimal format (not hex)
- Most modification endpoints use PATCH method
- Empty payloads should be {} not null"
License
MIT License
Enables direct interaction with the Discord API using both REST API calls and slash command syntax for bot management, server configuration, and message operations.