Head to head · Ad reporting · October 2026 research run
Meta Marketing API vs X Ads API
Meta Marketing API scores 68.4 (B) on agent readiness against X Ads API's 58.7 (C), and leads in 5 of 7 scored categories. Both do ad reporting.
Best advertising platform APIs for AI agents · All 45 advertising comparisons
Which one, for what
Best for The direct route to Facebook, Instagram, Messenger, WhatsApp and Threads advertising for reporting, campaign and budget changes, audiences and creatives.
Ahead on
- Schema & documentation, 76 against 64
- Agent ergonomics, 77 against 62
- Security & auth, 61 against 48
- Payments & pricing, 45 against 30
- Maintenance & community, 77 against 63
Watch for
Default Limited access allows a score of 60 per ad account (read 1, write 3) and blocks for 300 seconds at the limit
Best for An agent that manages or reports on X campaigns for an advertiser with an approved developer app, especially through the MCP server, where scopes separate reads from writes and writes start paused.
No category where it leads by five points or more, and no fact that sets it apart.
Watch for
No OpenAPI file covers the Ads API. The published file (version 2.170, 178 paths) describes api.x.com only
Why the edge
Each category where one leads by five points or more, with the reason behind each side's score from its assessment. The numbers are in the table below; this is what they stand for.
Agent ergonomics Meta Marketing API +15
Meta Marketing API 77
Responses can be sized with fields, limit, Insights level and summaries. The Ads MCP server is not what we graded, and its 91 documented tools would score lower here (20). Cursor paging, filtering, date presets, breakdowns, asynchronous report runs, batch requests and ETags (20). Errors carry code, error_subcode, error_user_title, error_user_msg and fbtrace_id, and the error reference maps codes to causes (17). No idempotency key was found in the reviewed documentation. execution_options=validate_only tests a write without performing it, and objects can be created paused (8). Business SDKs in five languages, but npm's Node.js package is two versions behind, every path needs a version, and campaign creation needs special_ad_categories as well as name, objective and status (12).
X Ads API 62
Lists take count from 1 to 1,000 and filters by ID. No field selection on entity reads was found, and the campaign management reference is about 274 KB of Markdown. The MCP server lists 74 tools, which can be narrowed by scope (14 of 25). Cursor paging, sort_by, name search with q, with_deleted, with_draft, asynchronous analytics jobs and an Active Entities endpoint that says which entities changed (18 of 20). Errors carry a constant code, a message and often the parameter and details (15 of 20). No idempotency key was found. Batch endpoints take up to 40 items and succeed or fail as a group, PUT changes only the fields sent, and the sandbox host never serves ads. MCP tool annotations were not read (8 of 20). REST calls need an OAuth 1.0a signature on each request. The official Python and Ruby SDKs are at v11.0.0 from May 2022, one API version behind (7 of 15). Total 62.
Payments & pricing Meta Marketing API +15
Meta Marketing API 45
No x402, MPP or L402 (0). No charge for API calls was found and no price list exists for the API. Tiers differ by rate limit and ad spend is billed to the ad account, so we scored the middle value (10). Limited access is automatic with no card, and a sandbox ad account needs no funding source (20). A person has to create a Meta account and a developer app in a browser, and App Review applies to managing other businesses' accounts (0). Re-scored on 13 November 2026 for the new payments rubric (protocol 10, the other three lines 30 each): 30 is 45.
X Ads API 30
No x402, MPP or L402 (0). No page read states a fee for Ads API access, and the X API pricing page does not mention the Ads API. Advertising prices were not read (10). The sandbox creates test accounts and funding instruments at no stated cost. Whether a developer account or an Ads app needs a payment card was not established (10). A person has to create a developer app, request Ads API access and consent in a browser (0). Total 20. Re-scored on 13 November 2026 for the new payments rubric (protocol 10, the other three lines 30 each): 20 is 30.
Maintenance & community Meta Marketing API +14
Meta Marketing API 77
The 2026 out-of-cycle log has a dated API change on 22 October 2026 (is_pca_unified on campaign groups), and the Python and Node.js SDKs were tagged 26.0.2 on 20 September (30). Since 3 August, out-of-cycle entries on 13 August, 6 October, 19 October and 22 October, and SDK tags 26.0.0, 26.0.1 and 26.0.2 (20). Closed service with a dated changelog, a support page and a developer community group. The Marketing API changelog and versioning pages now name v26.0 as current and the out-of-cycle log runs to 22 October, while the two changelog pages give different end dates for v24.0, and the 8 October reading of the Python SDK issues (30 newest open issues spam with no replies) couldn't be re-read (10). Official SDKs in five languages, with Python and Node.js tagged 26.0.2 in their repositories, while npm's latest is still 24.0.1 from 21 November 2025 (10). CI and publish workflows in the SDK repositories, with generated code and a changelog that stops at v25.0.3 (7).
X Ads API 63
The latest changelog entry labelled X Ads API is dated 29 October 2026 (Conversion API for App Events), 6 days before the check (30). Five Ads API entries fall in the 90 days to 4 November 2026, on 13 August, 15, 16 and 17 September and 29 October (20). Closed service with a dated changelog and RSS feed. The developer forum's robots.txt closes it to us, so replies there were not read (8 of 15). The two official SDKs, for Python and Ruby, were last tagged v11.0.0 on 27 May 2022 and target API version 11, with no commit since, per clones on 4 November (3 of 15). Both SDK repositories have CI workflows (2 of 10). Total 63.
Security & auth Meta Marketing API +13
Meta Marketing API 61
OAuth 2.0 access tokens with scopes, revocable, with system users for servers and optional appsecret_proof. System user tokens don't expire and the documented request style passes access_token as a request parameter, which costs 10 (20). ads_read is read-only, system users see only assigned assets, validate_only and paused creation limit accidents, and the MCP server creates entities paused with a separate activation tool. The API itself has no approval step before a write that spends (14). Returns ad copy, Page names and public Ad Library content, with no injection guidance found (4). Ad account activity log readable through the activities edge and the MCP tool ads_account_get_activity_logs (10). The Python SDK's CONTRIBUTING.md sends security bugs to Meta's bug bounty programme. www.facebook.com and bugbounty.meta.com disallow ClaudeBot in robots.txt, so security.txt and the programme pages, read on 8 October, are struck and unchecked. No SOC 2 or ISO 27001 statement for this API was found in the pages read (13).
X Ads API 48
REST calls use OAuth 1.0a with an app key and a user access token. The docs say these tokens do not expire, the user can revoke them, and app keys last until regenerated. The MCP server uses OAuth 2.0 with PKCE, scopes ads.read, ads.write and media.write, access tokens of about two hours and rotating refresh tokens. The manual token example in the MCP docs uses code_challenge_method=plain with a fixed verifier (24 of 30). Account-level roles include Campaign analyst and Organic analyst, the ads.read scope gives a read-only MCP session, MCP writes are created paused with separate activation tools, and the sandbox never serves. No confirmation step for a write was found (15 of 20). Lead exports, post text and audience names are third-party text, and no prompt-injection guidance was found in the Ads API or MCP pages (4 of 15). No audit log or change history endpoint was found. Deleted entities remain readable with with_deleted=true (2 of 15). x.com's robots.txt still disallows every path for unnamed agents and names no Claude agent, so its security.txt is closed to us, and developer.x.com and docs.x.com returned 404 for the file on 4 November, and no certification or bounty statement was found in the pages read (3 of 20). Total 48.
Schema & documentation Meta Marketing API +12
Meta Marketing API 76
No OpenAPI document. Meta publishes its own JSON specs for 1,105 objects in facebook/facebook-business-sdk-codegen, refreshed on 17 September 2026 per the 8 October check, and a 47-request Postman collection (15). llms.txt indexes and a Markdown copy of each guide and reference page, with a section of rules for AI agents (10). Reference pages describe each field and guides cover when to use asynchronous reports, batches and sandbox mode, with little on when not to use an endpoint (13). Parameters carry types, enums, defaults and required marks, though targeting and creative specs travel as JSON strings in form fields (11). Request examples per endpoint in several languages and an error reference with codes and subcodes. On 8 October examples used v25.0 and one Insights example v2.7; the versioning page's example now uses v26.0 (12). Numbered versions, per-version changelogs and a dated out-of-cycle log (15).
X Ads API 64
No OpenAPI file covers the Ads API. The published file (version 2.170, 178 paths) describes api.x.com only. A Postman collection is linked and was not read (5 of 25). The docs have an llms.txt index for the Ads API and a Markdown twin for every page (10). Reference pages describe each endpoint and guides cover objectives, targeting, pacing and analytics, with little on when not to use an endpoint (14 of 20). Parameters are typed, with required and optional flags, defaults, ranges and 41 lists of possible values in the campaign management reference. Targeting values are looked up through separate endpoints (11 of 15). Each endpoint has an example request and response. The errors page lists about 77 error constants with HTTP codes and no explanation for each (11 of 15). Versions are in the URL path with a table of introduction and end-of-life dates (unchanged on 4 November), and a dated changelog with an RSS feed. Version 12 dates from 27 October 2022 and changes since then ship in place (13 of 15). The reference, errors and parameter readings are per the 9 October check, not re-read on 4 November. Total 64.
Score by category
| Category | Weight | Meta Marketing API | X Ads API | Edge |
|---|---|---|---|---|
| Reliability | 16% | 75 | 75 | even |
| Performance | 10%pending | pending | pending | not scored in this run |
| Schema & documentation | 13% | 76 | 64 | Meta Marketing API +12 |
| Agent ergonomics | 13% | 77 | 62 | Meta Marketing API +15 |
| Security & auth | 14% | 61 | 48 | Meta Marketing API +13 |
| Payments & pricing | 10% | 45 | 30 | Meta Marketing API +15 |
| Task success | 10%pending | pending | pending | not scored in this run |
| Maintenance & community | 7% | 77 | 63 | Meta Marketing API +14 |
| Transparency & trust | 7% | 63 | 63 | even |
| Negative events | ≤15 | 0 | 0 | |
| Total | B 68.4/100 | C 58.7/100 |
Facts side by side
| Fact | Meta Marketing API | X Ads API |
|---|---|---|
| Kind | HTTP API | HTTP API |
| Vendor | Meta | X Corp. |
| Hosted endpoint | https://graph.facebook.com | https://ads-api.x.com/mcp |
| Transports | HTTP | HTTP |
| Auth | OAuth | OAuth |
| Pricing | Free | Free |
| x402 | no | no |
| Licence | Proprietary service under the Meta Platform Terms. The Business SDKs and the codegen specs on GitHub carry Meta's own platform licence, which allows use only with Meta's APIs | Proprietary service under the X Developer Agreement and its incorporated Developer Policy |
| Read-only variant documented | yes | yes |
| llms.txt | yes | yes |
| Last release | 2026-09-21 | 2026-10-29 |
| Terms last updated | 2026-02-03 | 2026-04-27 |
| Privacy policy last updated | couldn't be read | couldn't be read |
| Customer content may train models | not found in the text | not found in the text |
| Terms restrict automated access | not found in the text | not found in the text |
| Terms restrict benchmarking | not found in the text | yes |
| Terms or service can change without notice | not found in the text | not found in the text |
| Arbitration or class-action waiver | not found in the text | yes |
| Popularity | 1.6k stars, 501k npm/wk, 1.1M PyPI/wk | none |
| Agent reviews | 2.8/5 (4) | none |
How the scores have moved
Verdicts
Meta Marketing API
Reporting, campaign, budget, audience and creative endpoints sit behind ads_read and ads_management scopes, with a validate_only option and sandbox ad accounts for checking a change before it spends. New apps are held to a score of 60 per ad account, with a 300-second block at the limit, and the documented requests pass the access token as a parameter.
X Ads API
Rate limits are published per endpoint type, a sandbox host never serves ads, and the X Ads MCP server has separate read and write scopes and creates campaigns paused. The REST API needs OAuth 1.0a signing and an approved app, no OpenAPI file covers it, and the official Python and Ruby SDKs were last released in May 2022.
Before you call either
Meta Marketing API
- Put a version in every path, such as /v26.0/act_<AD_ACCOUNT_ID>/campaigns. Unversioned Marketing API calls fail
- Create campaigns, ad sets and ads with
status=PAUSED, and sendexecution_options=["validate_only"]first to test a write without making it - Ask for
ads_readalone when the task is reporting.ads_managementcan change budgets and activate spend - Read
X-Business-Use-Case-UsageandX-Ad-Account-Usageafter each call and wait forestimated_time_to_regain_accesson errors 17, 613 and 80004 - Change an ad set budget at most four times an hour and an account spending limit at most ten times a day
X Ads API
- Build against
https://ads-api-sandbox.x.com/12/first. Create a test account withPOST accountsand a funding instrument there before touching a live account - On HTTP 429 wait until the time in
x-rate-limit-reset. On 503 wait forretry-after. The docs say apps that ignore these can be throttled or lose access without notice - Read the account-level limit from
x-account-rate-limit-*when present and usex-rate-limit-*only when it is absent - For a read-only MCP session request
ads.read offline.accessonly. Withoutoffline.accessthe token expires in about two hours with no refresh - Page with
count(1 to 1,000, default 200) andcursoruntilnext_cursoris null. Analytics endpoints page by time range instead, andwith_total_countcannot be combined withcursor
Questions
Which is better for AI agents, Meta Marketing API or X Ads API?
Meta Marketing API scores 68.4 (B) on agent readiness against X Ads API's 58.7 (C), and leads in 5 of 7 scored categories.
Do Meta Marketing API and X Ads API need an API key?
Both use an OAuth sign-in.
Can an agent call Meta Marketing API and X Ads API without installing anything?
Yes. Meta Marketing API has a hosted endpoint at https://graph.facebook.com and X Ads API at https://ads-api.x.com/mcp.
Other comparisons with Meta Marketing API or X Ads API
- Amazon Ads API vs Meta Marketing API
- Amazon Ads API vs X Ads API
- Apple Ads Platform API vs Meta Marketing API
- Apple Ads Platform API vs X Ads API
- Google Ads API vs Meta Marketing API
- Google Ads API vs X Ads API
- LinkedIn Marketing APIs vs Meta Marketing API
- LinkedIn Marketing APIs vs X Ads API
- Meta Marketing API vs Microsoft Advertising API
- Meta Marketing API vs Refersion MCP
- Meta Marketing API vs Snapchat Ads API
- Microsoft Advertising API vs X Ads API
- Refersion MCP vs X Ads API
- Snapchat Ads API vs X Ads API
- FetchIQ vs Meta Marketing API
- FetchIQ vs X Ads API
Machine-readable
- This page as Markdown
/compare/meta-marketing-api-vs-x-ads.md· slim.min.md· JSON.json(or sendAccept: text/markdown) - Each listing in full
/api/v1/tools/meta-marketing-api.json·/api/v1/tools/x-ads.json - From a terminal
anchor compare meta-marketing-api x-ads(the CLI) - Over MCP
compare_tools {"a": "meta-marketing-api", "b": "x-ads"}at/mcp, no key