Discord Raw API MCP Server
Servidor MCP de la API de Discord Raw
Este servidor MCP proporciona acceso directo a la API de Discord mediante una única herramienta flexible. Admite llamadas a la API REST y la sintaxis de comandos slash.
Instalación
Instalación mediante herrería
Para instalar Discord Raw API para Claude Desktop automáticamente a través de Smithery :
npx -y @smithery/cli install @hanweg/mcp-discord-raw --client claudeInstalación manual
Configura tu bot de Discord:
Crea una nueva aplicación en el Portal para desarrolladores de Discord
Crea un bot y copia el token
Habilitar intenciones privilegiadas requeridas:
INTENCIÓN DEL CONTENIDO DEL MENSAJE
INTENCIÓN DE PRESENCIA
INTENCIÓN DE LOS MIEMBROS DEL SERVIDOR
Invita al bot a tu servidor usando el generador de URL OAuth2
Clonar e instalar el paquete:
# Clone the repository
git clone https://github.com/hanweg/mcp-discord-raw.git
cd mcp-discord-raw
# Create and activate virtual environment
uv venv
.venv\Scripts\activate
### If using Python 3.13+ - install audioop library: `uv pip install audioop-lts`
# Install the package
uv pip install -e .Related MCP server: Discord MCP Server
Configuración
Agregue esto a su claude_desktop_config.json
"discord-raw": {
"command": "uv",
"args": [
"--directory",
"PATH/TO/mcp-discord-raw",
"run",
"discord-raw-mcp"
],
"env": {
"DISCORD_TOKEN": "YOUR-BOT-TOKEN"
}
}Uso
Estilo de API REST
{
"method": "POST",
"endpoint": "guilds/123456789/roles",
"payload": {
"name": "Bot Master",
"permissions": "8",
"color": 3447003,
"mentionable": true
}
}Estilo de comando de barra
{
"method": "POST",
"endpoint": "/role create name:Bot_Master color:blue permissions:8 mentionable:true guild_id:123456789"
}Ejemplos
Crear un rol:
{
"method": "POST",
"endpoint": "/role create name:Moderator color:red permissions:moderate_members guild_id:123456789"
}Enviar un mensaje:
{
"method": "POST",
"endpoint": "channels/123456789/messages",
"payload": {
"content": "Hello from the API!"
}
}Obtener información del servidor:
{
"method": "GET",
"endpoint": "guilds/123456789"
}Recomendaciones:
Coloque los identificadores de servidor, canal y usuario y algunos ejemplos en el conocimiento del proyecto para evitar tener que recordarle al modelo sobre ellos, junto con algo como esto para comenzar:
A continuación, se explica cómo usar eficazmente la herramienta Discord Raw API: La herramienta se llama discord_api y acepta tres parámetros:
método: método HTTP ("GET", "POST", "PUT", "PATCH", "DELETE")
punto final: punto final de la API de Discord (por ejemplo, "guilds/{guild.id}/roles")
carga útil: objeto JSON opcional para el cuerpo de la solicitud Ejemplos clave que he utilizado:
Creación de roles:
discord_api
method: POST
endpoint: guilds/{server_id}/roles
payload: {
"name": "Role Name",
"color": 3447003, // Blue color in decimal
"mentionable": true
}Creación de categorías y canales:
// Category
discord_api
method: POST
endpoint: guilds/{server_id}/channels
payload: {
"name": "Category Name",
"type": 4 // 4 = category
}
// Text channel in category
discord_api
method: POST
endpoint: guilds/{server_id}/channels
payload: {
"name": "channel-name",
"type": 0, // 0 = text channel
"parent_id": "category_id",
"topic": "Channel description"
}Mover canales a categorías:
discord_api
method: PATCH
endpoint: channels/{channel_id}
payload: {
"parent_id": "category_id"
}Envío de mensajes:
discord_api
method: POST
endpoint: channels/{channel_id}/messages
payload: {
"content": "Message text with emojis \ud83d\ude04"
}Asignación de roles:
discord_api
method: PUT
endpoint: guilds/{server_id}/members/{user_id}/roles/{role_id}
payload: {}La herramienta es compatible con la API de Discord completa, por lo que puedes consultar la documentación de la API de Discord para obtener más puntos de conexión y funciones. Las respuestas incluyen ID y otros metadatos que puedes usar en solicitudes posteriores. Consejos profesionales:
Guardar los ID devueltos de las solicitudes de creación para utilizarlos en solicitudes de seguimiento
¿Se pueden incluir emojis Unicode directamente en el contenido del mensaje? ¿Indicar al modelo que use emojis de Discord como :champagne_glass:? ¿Los mensajes con emojis Unicode bloquean Claude Desktop?
Tipos de canal: 0 = texto, 2 = voz, 4 = categoría, 13 = escenario
Los colores de los roles están en formato decimal (no hexadecimal)
La mayoría de los puntos finales de modificación utilizan el método PATCH
Las cargas útiles vacías deben ser {} y no nulas"
Licencia
Licencia MIT
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Tools
Related MCP Servers
- AlicenseBqualityDmaintenanceEnables comprehensive Discord bot management and server operations through MCP, including channel management, message handling, member moderation, role management, and voice operations. Provides secure Discord API integration with built-in permission controls and audit logging capabilities.1915918MIT
- AlicenseBqualityFmaintenanceEnables interaction with Discord channels through a bot, allowing users to send messages and files, retrieve messages with advanced filtering, and download attachments of any type.5264MIT
- FlicenseNot gradedqualityBmaintenanceEnables interaction with Discord through natural language, including reading and sending messages, managing servers, and user actions.
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to interact with Discord through the REST API and real-time events, supporting message management, user info, channel operations, and more with security controls.131MIT
Related MCP Connectors
Search, document and execute authenticated API calls across 700+ apps via one MCP server
Voice and chat for AI agents — Discord, Teams, Meet, Slack, Zoom, Telegram, WhatsApp, NC Talk, SIP
Access the Notra API for managing posts, brand identities, integrations, and schedules.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/hanweg/mcp-discord-raw'
If you have feedback or need assistance with the MCP directory API, please join our Discord server