MCP META ADS B2 TECH

Model Context Protocol · Meta Marketing API — Graph v25

Run your campaigns
straight from Claude.

An MCP server that wires Claude into the Meta Marketing API — read insights with per-campaign ROAS, create campaigns, ad sets, ads and creatives, duplicate what works and send server-side conversions (CAPI), without opening Ads Manager. Embedded Meta login, never-expiring token. Status: LIVE.

29 tools · Graph API v25 · Meta login · multi-tenant

Meta Marketing API — Graph v25 Writes are born PAUSED Context-safe insights summary Server-side CAPI · hashed PII BISU token: never expires confirm=true to pause Multi-tenant on Vercel Meta Marketing API — Graph v25 Writes are born PAUSED Context-safe insights summary Server-side CAPI · hashed PII BISU token: never expires confirm=true to pause Multi-tenant on Vercel
What it is

Your ad account, operated in natural language

MCP META ADS B2 TECH is a Model Context Protocol server that gives Claude real access to your ad accounts — not a chatbot that guesses, but typed calls into the Meta Marketing API (Graph v25).

Real connection

Claude talks to your ad account

List accounts, campaigns, ad sets, ads, creatives, pages and pixels; read synchronous insights with a summary that fits the context, or run async reports for large ranges. "What's the ROAS of my active campaigns?" becomes an API call, not a guess.

The full loop

Closes the fleet's media loop

The sibling MCPs (GA4, Google Ads, GTM, Cloudflare, Instagram) measure, tag and publish; Meta Ads creates the campaign, ships the creative, reads the result and sends the conversion back via CAPI. All in one conversation.

Status

LIVE in production

Multi-tenant deploy at mcp-meta-ads-alpha.vercel.app — embedded OAuth 2.1 Authorization Server bridging to Meta's Login for Business, tokens encrypted in Supabase, cache on Upstash. Same stack as the sibling MCPs.

What it already does

The complete tool catalog

29 tools grouped by function — from account discovery to the ROAS report, from the creative to the server-side conversion. Everything below is implemented and live.

Auth & onboarding

5 tools
  • meta_loginStarts Meta's Login for Business (consent in the browser).
  • meta_token_statusTells whether the credential is valid and what it reaches.
  • meta_refresh_tokenRenews the credential when applicable (BISU doesn't even need it — it never expires).
  • connect_hotmartLinks your student purchase: emails a 6-digit code to the purchase address.
  • confirm_hotmartConfirms the code and unlocks access.

Discovery

7 tools
  • list_ad_accountsEvery ad account the credential can see.
  • list_campaignsCampaigns of an account, with objective and status.
  • list_adsetsAd sets, with budget and optimization goal.
  • list_adsAds, with effective delivery status.
  • list_creativesThe account's creatives.
  • list_pagesPages the credential manages.
  • list_pixelsThe account's pixels — direct input for CAPI.

Insights

2 · highlight
  • get_insightsOne row per campaign/ad set/ad with spend, clicks, CPC, purchases and ROAS — a summary that fits the context. Filter by effective_status=["ACTIVE"] server-side, in a single call.
  • run_insights_reportAsync report for large ranges or many objects.

Create — born PAUSED

5 tools
  • create_campaignCreates the campaign with its objective — paused.
  • create_adsetTargeting, budget and optimization — paused.
  • create_adWires a creative into the ad set — paused.
  • create_creativeLink creative (object_story_spec), image by URL/hash, Advantage+ enhancements opted in per feature.
  • create_pixelCreates a new pixel on the account.

Optimize

3 tools
  • update_campaignChanges name, budget or status (partial update).
  • update_adsetAdjusts budget, bids and targeting.
  • update_adSwaps the ad's name, status or creative.

Pause

3 · confirm=true
  • pause_campaignWithout confirm, returns a preview of what would be paused — and executes nothing.
  • pause_adsetSame guard: preview first, pauses only with confirm=true.
  • pause_adLikewise — nothing goes offline by accident.

Duplicate

3 tools
  • copy_campaignDuplicates the winning campaign — the copy is born paused.
  • copy_adsetDuplicates an ad set in place or into another campaign.
  • copy_adDuplicates an ad into another ad set.

Conversions — CAPI

1 · server-side
  • send_capi_eventPosts events to the Conversions API with the tenant's own token — no Events Manager token needed. PII normalized + SHA-256 server-side; event_id defaults to uuid4 for Pixel dedup; test_event_code targets the Test Events tab.

From diagnosis to result in one conversation: get_insights → duplicate what works → ship a new creative → send_capi_event closing the measurement loop.

Write safety model

Claude doesn't spend your budget on its own

A live campaign is money leaving your account — so every write goes through explicit barriers, inherited from the sibling MCPs.

Writes are born PAUSED

create_campaign, create_adset, create_ad and the copies deliver the object paused. Nothing starts delivering until you explicitly ask to activate it.

Pausing requires confirm=true

pause_campaign, pause_adset and pause_ad without confirm return a preview of what would be paused and execute nothing — nothing goes offline by accident.

Encrypted BISU token, clean logs

The login issues a Business Integration System User (BISU) token that never expires, AES-GCM-encrypted in Supabase with default-deny RLS. No tool ever returns a token; HTTP loggers are silenced so it can't leak.

appsecret_proof on every call

Every Graph request is signed, with bounded retry/backoff. Meta errors become safe messages with a "what to do" hint — raw payloads and tokens never reach the model.

Hashed PII in CAPI

Identifiers in send_capi_event are normalized and hashed (SHA-256) server-side — never logged or echoed. event_id defaults to uuid4 for dedup with the browser Pixel.

Tenant is never an argument

The tenant is derived from your Meta login and resolved per request. No tool accepts "which client" — impossible to operate the wrong account. OAuth with PKCE and state validation.

How to connect

Up and running in minutes

Hosted, multi-tenant server, zero setup: add the connector, log in with your Meta account and Claude is already operating your campaigns. One login — the token never expires.

Zero setup

Hosted — mcp-meta-ads-alpha.vercel.app

Add the MCP server as a connector in Claude and log in with Meta. Nothing to install; one login handles everything.

  1. Add the connector. In Claude.ai → Settings → Connectors → Add custom connector, paste https://mcp-meta-ads-alpha.vercel.app/api/mcp. In Claude Code, use the command below.
    # Claude Code
    claude mcp add --transport http \
      meta-ads https://mcp-meta-ads-alpha.vercel.app/api/mcp
  2. Log in with Meta. The OAuth handshake opens Login for Business automatically; in Claude Code, complete it via /mcp. The login issues a token that never expires — one login, durable access, CAPI included. B2Tech student with the same email as your purchase? Access links automatically — otherwise run connect_hotmart.
  3. Confirm. Run meta_token_status to validate the credential and list_ad_accounts to see your ad accounts. Ready to operate.
First steps

What to ask Claude

Real requests the server resolves end to end — everything created is born paused.

  1. Report.
    # you, in the chat:
    "How much did I spend per active campaign
     in the last 7 days, and what was the ROAS?"
    # → get_insights level=campaign, ACTIVE only
  2. Create.
    "Create a conversion campaign with an ad set
     for this audience and this creative"
    # → everything born PAUSED; you activate when ready
  3. Convert.
    "Duplicate the winning ad set and send a
     test Purchase to the pixel"
    # → copy_adset + send_capi_event (hashed PII)

Frequently asked questions

Still unsure about something? Write to bruno@b2tech.io.

How much does it cost?
The MCP Meta Ads server is an exclusive benefit for Claude Code Architect students: access to the hosted server is unlocked by an active Hotmart purchase. If your Meta login email matches the purchase email, the link is automatic; otherwise connect_hotmart emails a 6-digit code to the purchase address and confirm_hotmart completes the link. Not a student yet? Check out the training at claude-code.b2tech.io.
Is it safe? Can Claude spend my budget on its own?
No. Every created object (campaign, ad set, ad) is born PAUSED — activation is always an explicit request from you. And pausing what is live requires confirm=true: without it, the pause_* tools return a preview of what would be paused and execute nothing.
Do I need to install anything?
No. The server is hosted and multi-tenant (mcp-meta-ads-alpha.vercel.app) and the source code is private — there is no version to run on your own machine. You just add the connector in Claude and log in with your Meta account; we handle the rest.
Does the login expire?
No. The configured Login for Business issues Business Integration System User (BISU) tokens that never expire — one login, durable access, CAPI included. If the credential is revoked on Meta's side, meta_token_status points it out and meta_login redoes the link.
Where do my tokens live?
AES-GCM-encrypted in a Supabase project with default-deny RLS on every table. The tenant is derived from your Meta login and resolved per request — no tool accepts a token or tenant as an argument. Every Graph call is signed with appsecret_proof, and structured logs carry no PII and no tokens.
How do I read metrics without blowing up the context?
get_insights with the default summary returns spend, clicks, CPC, purchases and ROAS already flattened — one row per campaign/ad set/ad — and filters by effective_status=["ACTIVE"] server-side, in a single call. Large reports come back with the low-spend tail trimmed into an informational _truncated row — not an error. For long ranges or many objects, run_insights_report runs asynchronously.
Can I send conversions without an Events Manager token?
Yes. send_capi_event posts events to the Conversions API using the tenant's own token — no Events Manager token needed. PII is normalized and hashed (SHA-256) server-side, never logged or echoed; event_id defaults to uuid4 for dedup with the browser Pixel; test_event_code targets the Test Events tab before going to production.
Start now

Stop clicking through Ads Manager.
Ask Claude and it creates, optimizes and reports.

Campaigns, ad sets, ads, creatives, duplication of what works, insights with ROAS and server-side conversions — from diagnosis to result in one conversation, with writes born PAUSED and pausing locked behind confirm=true.

29 tools · Meta login · multi-tenant on Vercel