Instagram DM MCP Server
Instagram DM MCP サーバー
Instagram の DM を送受信するための MCP (Model Context Protocol) サーバーです。
クイックスタート
uv run mcp_server.pyサーバーは stdin/stdout を介して JSON-RPC 2.0 で通信します。
Related MCP server: Instagram MCP Server
セットアップ
config/config.json.templateをconfig/config.jsonにコピーし、sessionid、任意のusername、max_messages_per_threadを追加します。config/recipients.json.templateをconfig/recipients.jsonにコピーします。オプションのエイリアスを持つ Instagram ユーザー名のリストです。.jsonファイルは gitignore されています。.templateファイルはガイドとして追跡されます。
ツール
send_dm(recipient, message)
特定の受信者に DM を送信します。
パラメータ:
recipient(必須) - DM を送信する Instagram ユーザー名message(必須) - 送信するメッセージテキスト
read_dm(recipient, max_messages=10)
特定の受信者のスレッドから最新の N 件のメッセージを読み取ります。
パラメータ:
recipient(必須) - DM を読み取る Instagram ユーザー名max_messages(オプション) - スレッドごとの最大メッセージ数 (省略時は設定ファイルのmax_messages_per_threadを使用)
list_recipients()
設定済みの全受信者とそのエイリアスを一覧表示します。エージェントはこのツールを使用して、メッセージを送信できる相手を把握する必要があります。
パラメータ: なし
設定
フィールド | デフォルト | 説明 |
| (必須) | あなたの Instagram セッション ID |
|
| あなたの Instagram ユーザー名 (オプション) |
|
| send_dm 使用時に送信されるメッセージ |
|
| スレッドごとに読み取る最大メッセージ数 |
recipients.json 内の受信者にのみ送信してください。スクリプトを直接変更しないでください。
受信者エイリアス
recipients.json では、各エントリにエージェントが使用する alias フィールドを含めることができます:
[
{
"username": "john_doe",
"alias": "John Doe"
}
]エイリアスはオプションです。省略した場合はユーザー名が使用されます。設定済みのエイリアスを確認するには、list_recipients ツールを使用してください。プレーンな文字列エントリ (後方互換) もサポートされています:
["john_doe", "jane_smith"]This server cannot be deployed
Maintenance
Related MCP Connectors
Instagram, WhatsApp and Messenger DMs through official Meta Business APIs.
Instagram for AI agents: publish, read comments and DMs, insights, and engage from your account.
Manage your Instagram in chat: stats, comments, DMs, publishing and scheduling after you approve.
- cloziqOAuthcom.cloziq
Create your offers and launch AI Instagram DM sales agents from any MCP client, over OAuth.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables AI assistants to read, send, and manage Instagram direct messages, including viewing conversations, sending DMs to users, reacting to messages, and searching for users by username.10-
- FlicenseBqualityDmaintenanceEnables AI agents to control Instagram accounts programmatically, supporting profile management, media interaction, direct messaging, and follower management.132-
- FlicenseAqualityCmaintenanceEnables agents to interact with Instagram through 49 tools for direct messages, feed, profiles, search, and persona discovery, with write actions disabled by default until explicitly enabled.449-
- AlicenseNot gradedqualityBmaintenanceEnables reading and replying to direct messages, comments, and templates across Instagram, WhatsApp, and Messenger through official Meta Business APIs, with support for human handover and AI assistant controls.22 npmMIT