Instagram MCP Server
Instagram MCPサーバー
AIエージェントがInstagramビジネスアカウントの分析やインサイトにアクセスできるようにするMCPサーバーです。
ツール
ツール | 説明 |
| フォロワー数、自己紹介、メディア数 |
| いいね数、コメント数、タイムスタンプを含む最近の投稿 |
| 個別の投稿に関する詳細な指標(リーチ、保存数、シェア数) |
| フォロワーの属性(都市、国、年齢/性別) |
| 期間ごとのリーチ数とインプレッション数 |
| エンゲージメント順に並べ替えたパフォーマンスの高い投稿 |
Related MCP server: Instagram Complete MCP Server
セットアップ
cd instagram-mcp
python3 -m venv .venv
source .venv/bin/activate
pip install --upgrade pip
pip install "mcp[cli]" httpx認証情報を記載した .env ファイルを作成します:
INSTAGRAM_ACCESS_TOKEN=your_token
INSTAGRAM_ACCOUNT_ID=17841...Instagram認証情報の取得方法
Meta for Developers にアクセスし、アプリを作成します(タイプ:ビジネス)
アプリに Instagram Graph API プロダクトを追加します
Graph API Explorer (
developers.facebook.com/tools/explorer) にて:ドロップダウンからアプリを選択します
Generate Access Token をクリックします
権限を付与します:
instagram_basic,instagram_manage_insights,pages_show_list,pages_read_engagement
InstagramビジネスアカウントIDを取得します:
Graph API Explorerで
me/accountsをクエリし、ページIDを取得します次に
{page-id}?fields=instagram_business_accountをクエリしますレスポンス内の
idフィールドがINSTAGRAM_ACCOUNT_IDです
Explorerから取得したトークンは短期間(1時間)のみ有効です。長期トークンを取得するには:
oauth/access_token?grant_type=fb_exchange_token&client_id={app-id}&client_secret={app-secret}&fb_exchange_token={short-lived-token}で交換しますこれにより60日間有効なトークンが取得できます
注意: Instagramアカウントは、Facebookページにリンクされたビジネスアカウントまたはクリエイターアカウントである必要があります。
Claude Codeでの使用方法
claude mcp add instagram-mcp -e INSTAGRAM_ACCESS_TOKEN=your_token -e INSTAGRAM_ACCOUNT_ID=17841... -- python3 -m src.serverその後、Claudeに以下のように質問します:
「今月、最もパフォーマンスの高かった投稿は何ですか?」
「オーディエンスの属性を表示して」
「保存数が最も多かった投稿はどれ?」
「エンゲージメント率の傾向はどうなっていますか?」
コンテンツストラテジストエージェント
Instagramのデータを分析し、7つの投稿アイデア、キャプション、投稿時間を含む週次コンテンツプランを生成するスタンドアロンエージェントです。
エージェントの実行
source .venv/bin/activate
python -m agent.content_strategistAWS認証情報の設定(Anthropic Bedrockを使用)と、MCPサーバーと同じ .env 変数が必要です。エージェントは以下の処理を行います:
アカウント情報、最近の投稿、トップ投稿、オーディエンス属性を取得
パフォーマンスの良い投稿のパターンを特定
具体的なキャプション、ハッシュタグ、タイミングを含む7日間のコンテンツプランを生成
プランをHTMLファイルとして保存し、ブラウザで開く
This server cannot be deployed
Maintenance
Related MCP Connectors
Instagram for AI agents: publish, read comments and DMs, insights, and engage from your account.
Social media analytics, post insights, and competitor benchmarking for AI agents.
- ReelDropOAuthio.reeldrop
Schedule Instagram reels, manage comment-to-DM automations, and read analytics
Instagram profiles for AI agents — followers, similar accounts, keyword and location search.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI applications to interact with Instagram Business accounts through the Graph API, supporting profile management, media publishing, insights retrieval, and direct messaging capabilities.MIT
- FlicenseNot gradedqualityDmaintenanceEnables AI assistants to manage Instagram Business accounts by automating content publishing, scheduling posts, and analyzing performance metrics. Supports posts, stories, reels, and carousels with detailed audience insights and hashtag discovery.-
- AlicenseAqualityCmaintenanceEnables AI assistants to manage Instagram and Threads accounts — publish content, handle comments, view insights, search hashtags, and manage DMs through the Meta Graph API.5913 npm12MIT
- AlicenseAqualityDmaintenanceEnables Instagram and Facebook analytics via the Meta Graph API, offering account insights, media analytics, and post engagement data.196MIT