was-fb-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@was-fb-mcp List all Facebook Pages I manage."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Facebook / Meta MCP Server (was-fb-mcp)
Shareable Facebook & Meta Graph API Model Context Protocol (MCP) server. Exposes 10 powerful tools to manage Facebook Pages, Posts, Comments, Ad Accounts, Campaigns, Insights, and execute any raw Graph API request from your favorite AI coding assistant (Claude Desktop, Cursor, Google Antigravity, VS Code, Zed).
Prerequisites
Node.js 18+
A Facebook / Meta Account & Meta Developer App
A Facebook User Access Token or Page Access Token (generated via Meta for Developers Graph API Explorer)
Related MCP server: Facebook MCP Server
Quick Start — 3 Steps
Step 1 — Get credentials
Select your App and click Generate Access Token.
Grant permissions such as
pages_show_list,pages_read_engagement,pages_manage_posts,ads_read,read_insights.
Step 2 — Connect
Run the interactive setup command in your terminal:
npx -y github:was-member-keramat/was-fb-mcp authPaste your Access Token when prompted. Credentials will be securely saved locally to ~/.was-fb-mcp/config.json with restricted file permissions (0600).
Step 3 — Add to your AI Client
Add the following 4 lines to your AI tool's MCP configuration (claude_desktop_config.json, mcp_config.json, etc.):
{
"mcpServers": {
"Facebook MCP": {
"command": "npx",
"args": ["-y", "github:was-member-keramat/was-fb-mcp"]
}
}
}What you can ask the AI
Here are example prompts you can use with your AI assistant:
Discovery: "List all Facebook Pages I manage."
Content Creation: "Publish a new post to my Page with ID
100123456saying 'Hello World!'."Feed & Comments: "Show the latest 10 posts on my Page feed and list the comments on the top post."
Interaction: "Reply to comment ID
987654321with 'Thank you for your feedback!'."Ads Management: "List my Meta Ad Accounts and show active campaigns in
act_123456789."Analytics: "Get post engagement insights for Page
100123456."Universal Access: "Use
fb_apito GETv19.0/me/photos."
All Tools (10 Total)
Category | Tool | Description |
Account |
| Get details of authenticated user / token owner |
Pages |
| List Facebook Pages managed by user |
Feed & Posts |
| Publish a post on a Facebook Page feed |
Feed & Posts |
| Fetch recent posts from a Page feed |
Comments |
| Get comments on a Facebook post |
Comments |
| Post a comment or reply to a post/comment |
Meta Ads |
| List accessible Meta Ad accounts |
Meta Ads |
| List ad campaigns in an Ad Account |
Analytics |
| Fetch metrics/insights for Page or Ad Account |
Universal |
| Execute raw GET/POST/DELETE Graph API calls |
CLI Commands
# Connect / re-connect credentials
npx -y github:was-member-keramat/was-fb-mcp auth
# Check saved configuration status
npx -y github:was-member-keramat/was-fb-mcp status
# Delete saved credentials
npx -y github:was-member-keramat/was-fb-mcp logout
# View CLI usage help
npx -y github:was-member-keramat/was-fb-mcp helpMulti-Account Setup
You can bypass the local config file by passing environment variables in your AI client config:
{
"mcpServers": {
"Facebook Account A": {
"command": "npx",
"args": ["-y", "github:was-member-keramat/was-fb-mcp"],
"env": {
"FB_ACCESS_TOKEN": "EAAX..."
}
},
"Facebook Account B": {
"command": "npx",
"args": ["-y", "github:was-member-keramat/was-fb-mcp"],
"env": {
"FB_ACCESS_TOKEN": "EAAY..."
}
}
}
}Troubleshooting
Windows PowerShell Script Execution Error
If you see:
File C:\...\npx.ps1 cannot be loaded because running scripts is disabled
Run in PowerShell:
Set-ExecutionPolicy -Scope CurrentUser -ExecutionPolicy RemoteSignedForce Update / Clear npx Cache on Windows
If npx is serving cached old versions:
Remove-Item -Recurse -Force "$env:LOCALAPPDATA\npm-cache" -ErrorAction SilentlyContinue
npm cache clean --forceGraph API Error Response
If a tool call returns an error, the MCP decodes Meta Graph API's exact error structure (code, error_subcode, fbtrace_id) so the AI assistant can fix permissions or parameters immediately.
License
MIT © 2026 WAS.
Available Tools
10 toolsfb_apiB
Universal Graph API tool. Execute any GET, POST, or DELETE request on Facebook Graph API endpoints directly.
Inputs: path (required), body, token, method, +1 more.
fb_create_postC
Create a new post on a Facebook Page feed.
Inputs: pageId (required), message (required), link, pageToken.
fb_get_insightsC
Get metrics and insights for a Facebook Page, Post, or Ad Account.
Inputs: metric (required), objectId (required), period.
fb_get_meC
Get details of the currently authenticated Facebook User, Page, or Token owner.
Inputs: fields.
fb_get_page_feedC
Fetch recent posts published on a Facebook Page.
Inputs: pageId (required), limit, pageToken.
fb_get_post_commentsB
Get comments on a Facebook post or photo.
Inputs: postId (required), limit.
fb_list_ad_accountsB
List Meta Ad Accounts accessible by the token.
Inputs: fields.
fb_list_campaignsB
List ad campaigns inside a Meta Ad Account.
Inputs: adAccountId (required), limit.
fb_list_pagesB
List Facebook Pages managed by the authenticated user.
Inputs: fields.
fb_reply_commentB
Publish a reply or comment to a Facebook post or parent comment.
Inputs: message (required), targetId (required), accessToken.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 10 tools
Each tool targets a distinct operation or resource: commenting, campaign listing, insights, raw API, user info, page listing, post creation, feed fetching, comment retrieval, and ad account listing. No overlap or ambiguity.
All tools follow a consistent 'fb_' prefix followed by verb_noun in snake_case (e.g., fb_reply_comment, fb_list_campaigns). The pattern is uniform and predictable.
10 tools cover core Facebook/Meta operations: pages, posts, comments, ads, insights, and a universal API fallback. Well-scoped for a Facebook MCP server without being bloated or sparse.
Covers common CRUD for posts and comments, ad management, and insights. Missing update/delete for posts and comments, but the raw API tool (fb_api) can fill gaps. Minor but acceptable shortfall.
Maintenance
Related MCP Connectors
Publish and schedule Facebook Page posts from your AI assistant.
Instagram and Facebook Pages for AI agents: publish, comments, DM by keyword, inbox, insights.
The simplest way to manage your Meta (Facebook and Instagram) ad accounts with your AI agent.
60+ Meta Ads tools for AI agents: audits, campaign management, audiences and CAPI tracking.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables AI agents to manage Facebook profiles, pages, posts, and engagement via the Graph API with OAuth authentication.2-
- AlicenseNot gradedqualityDmaintenanceAutomates Facebook Page management via Graph API, enabling posting, comment moderation, and analytics through AI agents.1MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to automate Facebook Page management including posting, commenting, and analytics via the Facebook Graph API.MIT
- AlicenseAqualityBmaintenanceEnables AI agents to manage Facebook Pages through Meta's Graph API, including posting, scheduling, drafts, reading insights, and moderating comments.1544 npm2MIT