agentleFS
sepivipsepivip/meta-ads-skill/SKILL.md

meta-ads

Skill14 starsChanged 59 days agoMITView on GitHub

Use when creating, launching, monitoring, or troubleshooting Meta (Facebook/Instagram) ad campaigns through the Meta Ads MCP server (mcp.facebook.com/ads) or Meta's Ads CLI — campaigns, ad sets, creatives, ads, budgets, insights queries, location and radius targeting, ad copy in any language, and errors like "socket connection was closed", INTERNAL create failures, "app that is in development mode", "No permissions available" during token generation, or "prohibited from advertising".

14 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use google-ads.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • thatrebeccaraeSkill

    google-ads

    Google Ads platform expertise. Audit campaigns, keywords, audiences, bidding, and conversion tracking. Use when the user asks about Google Ads, PPC, search advertising, Performance Max, Shopping ads, display campaigns, YouTube ads, or paid search optimization.

    Also in 7 projects that use this

The file

We split this skill into the rules it gives an agent

1 rule. 0 are common, 1 is distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 12 edited versions we read keep these.

  • 1

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    NOT for: organic page posting, Instagram content management

    line 18

“Common” is measured: kept by at least 6 in 10 of the 12 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Meta Ads (MCP-first)

Overview

Core principle: the Meta Ads MCP's tool contracts are NOT the Graph API you remember. Parameter names, shapes, and field lists differ exactly where it breaks calls. Never write a call from memory — check references/tool-contracts.md first, and when a VALIDATION error returns a "Supported fields are:" list, treat that list as the source of truth over anything you believed.

When to use

  • Launching a campaign end-to-end via MCP tools (ads_create_campaign → ads_create_ad_set → ads_create_creative → ads_create_ad → ads_activate_entity)
  • Querying performance (ads_get_ad_entities, reports)
  • Recovering from MCP/API errors mid-flight
  • Setting up auth: official MCP (preferred, no developer app) vs Ads CLI / system-user token (headless fallback)
  • NOT for: organic page posting, Instagram content management

The launch pipeline (each step's landmine)

StepToolLandmine
1. Accountads_get_ad_accountsCheck is_ads_mcp_enabled, is_queryable, AND has_payment_method — creation without a payment method fails at delivery
2. Pageads_get_ad_account_pagesA Facebook Page is mandatory ad identity
3. Imagesads_creative_upload_imageURL-only — cannot read local files. Local file? See troubleshooting §Images
4. Campaignads_create_campaignbuying_type is REQUIRED (AUCTION). Budgets in cents of account currency. CBO = budget here; lifetime budget needs campaign_stop_time
5. Ad setads_create_ad_settargeting is a JSON string, required. NO budget fields under a CBO parent (pre-validated rejection). Hard age caps need targeting_automation.advantage_audience: 0
6. Creativeads_create_creativeFlat params (page_id, image_hash, link_url, message, headline, call_to_action_type) — NOT object_story_spec
7. Adads_create_adcreative is a JSON string "{\"creative_id\":\"...\"}"; name param is ad_name
8. Previewads_get_ad_previewInclude the returned preview_url as a link for the user
9. Activateads_activate_entityONLY after explicit user confirmation. Top-down: campaign → ad set → every ad. entity_type is ad_set (underscore), not adset

Everything creates PAUSED by default — that's the safety model. Build the whole structure, show previews, get the user's explicit go, then activate.

Insights in one line

Metrics require date_preset (or time_range). Field names: name (not ad_name), amount_spent (not spend), link clicks = actions:link_click, cost = cost_per_link_click — bare actions is invalid. Sort = <field>_descending. Full list: references/tool-contracts.md.

Targeting quick recipes

Radius around any point (no city-key lookup needed — the MCP has no targeting-search tool):

{"geo_locations":{"custom_locations":[{"latitude":51.5074,"longitude":-0.1278,"radius":25,"distance_unit":"kilometer"}]},"age_min":18,"age_max":55}

distance_unit is kilometer or mile. Whole country: {"geo_locations":{"countries":["GB"]}} (ISO country codes). Ad copy in any language or script in message/headline is plain UTF-8 — works as-is. Budget is in the ad account's fixed currency (check currency on step 1; "$100" in a EUR account is a conversion conversation, not a relabel).

Errors — first aid

SymptomDo
"socket connection was closed unexpectedly"Retry once — transient, common on first call after idle
INTERNAL error on a create, is_retryable: falseList entities first to check it wasn't created server-side, then retry once. Never blind-retry a create
VALIDATION "Unsupported field(s)"The error's "Supported fields are:" list is authoritative — fix and retry
"This tool is new and is being gradually rolled out"Feature-gate per account (e.g. ads_get_ig_accounts). Work without it; note the limitation
"app that is in development mode" / token permission walls / "prohibited from advertising"references/troubleshooting.md

Full playbook with the worked end-to-end example: references/launch-playbook.md.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.