Nika
Nika — Discord MCPサーバー
AIアシスタントがDiscordコミュニティを運営できるようにする包括的なModel Context Protocolサーバー:メッセージング、モデレーション、ロール、チャンネル、フォーラム、ウェブフック、招待、予定イベント、AutoMod、オンボーディング、絵文字/ステッカー、権限上書き、音声管理 — 111ツール、さらに生のRESTパススルー(discord_api_request)により、Discord APIができることはすべて到達可能です。
Python + discord.py(永続的なゲートウェイ接続)とFastMCPで構築されています。
セットアップ
1. Discordボットを作成する(済み)
アプリケーション: Nika(ID
1538805149865091092)有効なインテント: Server Members、Message Content
トークン:
.envに保存(絶対にコミットしないでください —.gitignoreが保護します)
2. ボットをサーバーに招待する
このURLを開いてサーバーを選択してください(完全な機能を利用するにはAdministratorを付与してください):
https://discord.com/api/oauth2/authorize?client_id=1538805149865091092&permissions=8&scope=bot%20applications.commands⚠️ ボットがサーバーに参加していないと、ほとんどのツールは何もできません。
3. インストールと設定
python -m venv .venv
.venv\Scripts\pip install -e ".[dev]".env(既に作成済み):
DISCORD_TOKEN=... # bot token
DISCORD_GUILD_ID= # optional: default server id → makes guildId optional everywhere
MCP_TRANSPORT=stdio # stdio | http
HTTP_HOST=0.0.0.0 # HTTP mode only
HTTP_PORT=8085
LOG_LEVEL=INFORelated MCP server: Cloud Discord
使用方法
stdio(デフォルト — Claude Desktop、VS Code、Cursor など)
.venv\Scripts\python -m discord_mcpClaude Desktop の claude_desktop_config.json:
{
"mcpServers": {
"nika": {
"command": "d:\\Projects\\david\\DiscordMCP\\.venv\\Scripts\\python.exe",
"args": ["-m", "discord_mcp"],
"cwd": "d:\\Projects\\david\\DiscordMCP"
}
}
}HTTP(ストリーミング) — リモートアクセス、n8n、マルチクライアント
.venv\Scripts\python -m discord_mcp --transport http --port 8085
# endpoint: http://localhost:8085/mcpクライアント設定:
{
"mcpServers": {
"nika": { "url": "http://localhost:8085/mcp" }
}
}Docker
docker compose up -d # builds + runs HTTP mode on :8085
docker run -i --rm -e DISCORD_TOKEN=$env:DISCORD_TOKEN discord-mcp:latest # stdioMCP Inspector でテストする
npx @modelcontextprotocol/inspector .venv\Scripts\python.exe -m discord_mcpツールリファレンス(111ツール)
領域 | ツール |
サーバー |
|
チャンネル |
|
メッセージ |
|
メンバー |
|
ロール |
|
DM |
|
モデレーション |
|
ボイス |
|
イベント |
|
権限 |
|
招待 |
|
ウェブフック |
|
フォーラム |
|
絵文字とステッカー |
|
AutoMod |
|
オンボーディングと監査 |
|
生API |
|
設計メモ
ハイブリッドゲートウェイ + REST: 1つの永続的な discord.py ゲートウェイ接続がライブ状態(メンバー/チャンネルの検索、名前→ID)を提供し、変更は同じクライアントを通じて行われます。ツール呼び出しは
asyncio.run_coroutine_threadsafeでゲートウェイループにブリッジされます。安全性: 生ツールは変更メソッドに対して
confirmDestructive=trueを要求します。prune_membersはデフォルトでドライランです。破壊的なツールはreasonを受け付け、監査ログに書き込まれます。オプションの
guildId:.envにDISCORD_GUILD_IDを設定すると、すべてのguildIdパラメータがオプションになります。エラー: Discord エラーは読みやすいメッセージに変換されます(例:
Missing permissions: ...)。
制限事項
ボットトークンが必要です(ユーザートークン/セルフボットの自動化はDiscordの利用規約に違反します)。
メッセージの読み取りには、ボットがチャンネルを閲覧できることと(内容を取得するには)Message Contentインテントが必要です。
音声のストリーミング/受信はサポートされていません。
開発
.venv\Scripts\python -m pytest # 22 unit testsレイアウト: discord_mcp/bot.py(ゲートウェイブリッジ) · discord_mcp/server.py(FastMCP) · discord_mcp/tools/*.py(ドメインごとに1モジュール) · discord_mcp/utils/(シリアライザー、埋め込み)。
ライセンス
MIT
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseBqualityDmaintenanceA Discord MCP server that enables AI assistants to interact with Discord platforms, providing functionalities like sending messages, managing channels, creating forum posts, and handling webhooks.214651MIT
- Alicense-qualityDmaintenanceAn MCP server that gives AI agents full admin control over Discord servers with 59 tools for messaging, moderation, roles, channels, forums, reactions, files, and more, deployed on Cloudflare Workers.4MIT
- Alicense-qualityDmaintenanceComprehensive Discord MCP server with 66 tools that provides rich message context including emoji reactions, thread indicators, and attachment metadata inline. Enables AI assistants to interact with Discord servers for messaging, moderation, roles, channels, and more.1591MIT
- AlicenseBqualityDmaintenanceA Discord MCP server that enables AI assistants to interact with the Discord platform, providing features like message sending, channel management, forum operations, reactions, and webhook management.22465MIT
Related MCP Connectors
An MCP server that integrates with Discord to provide AI-powered features.
MCP server for Gainium — manage trading bots, deals, and balances via AI assistants
Security-first WordPress MCP server. 129 tools for Claude, ChatGPT, Gemini. Free on wp.org.
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/alive2/discord-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server