Meta Social MCP

Meta Social MCP

Enables publishing and managing organic Facebook Page and Instagram content directly through Meta's Graph API without paid third-party services.

Category
Visit Server

README

Meta Social MCP

A free, self-hosted Model Context Protocol server that lets Claude (or any MCP client) publish and manage your organic Facebook Page and Instagram content directly through Meta's own Graph API — no paid third-party service in the middle.

It complements an ads connector (e.g. Pipeboard's Meta Ads MCP): use the ads connector for campaigns, and this one for organic posts, scheduling, comments and insights.

What it can do

Facebook Page

  • facebook_publish_post — publish a text, link, or photo post; schedule it for later
  • facebook_list_posts — list recent published and scheduled posts
  • facebook_get_comments — read comments on a post
  • facebook_reply_to_comment — reply to a comment
  • facebook_get_insights — post- or Page-level performance

Instagram (Business/Creator)

  • instagram_publish_photo — single photo + caption
  • instagram_publish_carousel — 2–10 image carousel
  • instagram_publish_reel — video reel
  • instagram_publish_container — publish a prepared container (retry reels / schedule)
  • instagram_list_media — recent media
  • instagram_get_comments — read comments
  • instagram_reply_to_comment — reply to a comment
  • instagram_get_insights — media- or account-level performance

Utility

  • meta_whoami — confirm your token, Page and IG account resolve correctly

Honest limitations (read these)

  • Facebook scheduling is native (via scheduled_publish_time, 10 min–75 days ahead). Instagram has no native scheduled-publish API — to schedule IG posts you publish at the target time (e.g. an OS cron / external scheduler that calls the publish tool, or a container created earlier and published later with instagram_publish_container).
  • Instagram posting only works on a Business or Creator account linked to a Facebook Page. Personal IG accounts cannot post via the API.
  • Images/videos must be at public URLs — Instagram fetches media from a URL; it does not accept direct file uploads through this API.
  • Going beyond your own assets / into production requires Meta app review and business verification for the publishing permissions.

Prerequisites

  1. A Facebook Page you manage.
  2. For Instagram: an Instagram Business/Creator account linked to that Page.
  3. A Meta developer app and an access token with these permissions:
    • pages_show_list
    • pages_read_engagement
    • pages_manage_posts
    • pages_manage_engagement (for replying to comments)
    • read_insights
    • instagram_basic
    • instagram_content_publish
    • instagram_manage_comments / instagram_manage_insights (for IG comments/insights)

Getting a token (quick start for your own Page)

  1. Go to https://developers.facebook.com/apps → Create App → type Business.
  2. Add the Facebook Login and Instagram Graph API products.
  3. Open the Graph API Explorer (https://developers.facebook.com/tools/explorer), select your app, and Add permissions for the scopes listed above.
  4. Generate Access Token and approve the dialog. This gives a short-lived user token.
  5. Exchange it for a long-lived token (≈60 days):
    https://graph.facebook.com/v21.0/oauth/access_token?grant_type=fb_exchange_token&client_id=APP_ID&client_secret=APP_SECRET&fb_exchange_token=SHORT_LIVED_TOKEN
    
  6. Find your Page ID: open the Page → About, or call GET /me/accounts.
  7. Find your IG user ID: GET /{page-id}?fields=instagram_business_account.

Put the long-lived user token in META_ACCESS_TOKEN — the server resolves the Page token for you. (A Page token also works directly.)

Install

git clone https://github.com/<your-username>/meta-social-mcp.git
cd meta-social-mcp
pip install -r requirements.txt        # or: pip install -e .
cp .env.example .env                   # then fill in your values

Configure

Set these as environment variables or in .env:

Variable Required Description
META_ACCESS_TOKEN yes Long-lived user or Page access token
FB_PAGE_ID yes* Facebook Page ID (*required for Facebook posting)
IG_USER_ID no Instagram Business/Creator user ID
GRAPH_API_VERSION no Defaults to v21.0

Run / connect to Claude

Add to your MCP client config (Claude Desktop claude_desktop_config.json, or the custom connector settings). Example stdio config:

{
  "mcpServers": {
    "meta-social": {
      "command": "python",
      "args": ["-m", "meta_social_mcp.server"],
      "cwd": "/absolute/path/to/meta-social-mcp",
      "env": {
        "META_ACCESS_TOKEN": "EAAB...",
        "FB_PAGE_ID": "1234567890",
        "IG_USER_ID": "1789xxxxxxxxxx",
        "GRAPH_API_VERSION": "v21.0"
      }
    }
  }
}

Then ask Claude things like:

  • "Post to my Facebook Page: 'New off-market deal just listed', schedule it for tomorrow 9am."
  • "Publish this image to Instagram with a caption about our latest project."
  • "Show me the comments on my last Instagram post and draft replies."

Verify it works

python -m py_compile meta_social_mcp/*.py     # syntax check
python -c "from meta_social_mcp.server import mcp; print('tools ok')"

Then in your client, run meta_whoami first — it confirms the token, Page and IG account resolve before you try to post.

License

MIT.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured