Skip to main content
The Adspirer REST API exposes every tool the MCP server does, over plain HTTP. Use it from any client that can’t speak SSE — n8n, Zapier, Make, GitHub Actions, Python scripts, cron jobs, or your own backend.

Get your API key

Generate a key at adspirer.ai/keys, then call any of the endpoints below with a bearer token. Free tier includes 15 calls — enough to test everything.

Use cases

Real patterns teams ship on the REST API today. Each one is just a few HTTP calls — the hard part is already done for you.

Slack ChatOps for campaigns

Team member posts a campaign brief in #campaign-activation → n8n parses it → REST API creates the campaign PAUSED → bot confirms in the thread. Nobody needs a Meta / Google login.

Daily account briefings

Every morning, pull CPL / ROAS / spend for each account manager’s book of business and deliver a Slack digest. Alert states (🟢 on-track, 🟡 watch, 🔴 red) computed against targets you store in a Google Sheet.

Portfolio rollups for owners

Weekly health summary across every client account — who’s over/under target, budget utilization, top / bottom 5 performers, per-manager breakdown.

Alert thresholds & auto-pause

Watch CPL vs target, flag breaches, pause underperforming ad sets on a rule. create_monitor handles the poll loop on our side so you don’t run a cron.

SaaS product embedding

Your app creates a starter campaign for every new customer during onboarding. Idempotency-Key makes signup retries safe even under network flakiness.

Headless CI / scheduled ops

Launch seasonal campaigns from GitHub Actions, kick off end-of-month reports from cron, trigger pause / resume on holiday calendars. No browser, no OAuth dance — just an API key.

How they wire up

Each pattern is a small variation on the same two primitives: read-only tools for data, write tools for changes.
Agency pattern: pass ad_account_id, customer_id, or advertiser_id on every call to route to the right client account. One API key can manage hundreds of connected accounts from a single backend.

Why use the REST API?

You’re already using ChatGPT, Claude, or Cursor with Adspirer’s MCP server — and that’s great for interactive work. But there are jobs an AI conversation can’t do:
  • Your agent shuts off when you close the tab. A cron that pulls daily performance at 9am needs to run without a human watching.
  • No-code automation tools don’t speak MCP. n8n, Zapier, and Make only know HTTP. MCP uses SSE.
  • Your backend wants to embed campaign creation. A SaaS onboarding flow that creates a starter campaign for every new customer can’t open a chat with Claude.
  • Multi-step workflows need to be deterministic. “If CTR drops below 2%, pause the campaign” belongs in code, not a prompt.
The REST API gives you the same tools, over plain HTTP that every automation platform understands.

How it relates to MCP

Same backend. Same auth. Same quota. Same write-guards. Only the transport differs. One logical endpoint per tool: POST /api/v1/tools/<tool_name>/execute. Call add_meta_ad from a chat via MCP or from a cron via REST — the result, the quota cost, and the log entry are identical.

Quickstart

Core concepts

Authentication

Every call requires an API key generated at adspirer.ai/keys. Pass it as a bearer token — keys are prefixed sk_live_. Treat them as secrets; never commit them. Keys provide the same access as OAuth tokens used by MCP clients — same tools, same quotas.

Request envelope

Every endpoint takes a POST with tool-specific input wrapped in an arguments object:

Response envelope

Success:
Error:

Quota & billing

Every successful billable call decrements your monthly tool-call allowance. The current counter is attached to every 200 response under data.quota. When the limit is hit, the API returns HTTP 402 with a quota block including upgrade_url. Read-only diagnostic tools never consume quota: get_usage_status, list_connected_accounts, get_connections_status. See Pricing for tier limits.

Idempotency

Write operations accept an Idempotency-Key header. A repeated call with the same key returns the cached result rather than executing twice.
Strongly recommended for n8n, Zapier, and any retry-prone client. Generate a fresh UUID per logical operation — not per retry — so retries collapse into one write.

Multi-account users

If you’ve connected multiple accounts on the same platform (e.g. an agency with 10 Meta ad accounts), specify the account on every call:
  • ad_account_id — Meta Ads
  • customer_id — Google Ads
  • advertiser_id — TikTok Ads, LinkedIn Ads
  • account_id — generic fallback
Omitting the field returns HTTP 400 with a list of valid IDs. Use list_connected_accounts to discover them.

HTTP status codes

No streaming

This endpoint is plain request/response JSON. No SSE, no chunked streaming. Safe to use from n8n Cloud, Zapier, Make, curl, Python requests, Node fetch, Go net/http, and every mainstream HTTP library.

Tool coverage

Google Ads

51 tools — campaigns, ad groups, keywords, extensions, Performance Max, Demand Gen

Meta Ads

36 tools — image, video, carousel, DCO, audiences, placements

LinkedIn Ads

45 tools — campaigns, creatives, audiences, conversion tracking

TikTok Ads

29 tools — campaigns, ad groups, ads, geo, optimization events

Monitoring & Reporting

13 tools — cross-platform performance, wasted spend, search terms

Account Management

3 tools — list connected accounts, connection status, usage
The endpoint reference above is being expanded to the full 400+ tool surface. Amazon Ads (61 tools) and ChatGPT Ads (31 tools), plus the newest Google Shopping/App, Meta Advantage+ Catalog, and LinkedIn tools, are all available over the same REST transport today — every MCP tool has a matching POST /api/v1/tools/{tool_name}/execute endpoint. See the Tool Catalog for the complete, current list while the interactive reference pages are regenerated.

Architecture patterns

Slack ChatOps — campaign creation from a message

Every campaign is created PAUSED — the requester reviews and activates manually. The Idempotency-Key header means a retry from n8n never creates a duplicate campaign.

Daily briefings — scheduled read-only reports

Read-only tools (get_*, list_*, analyze_*) don’t consume quota. At ~3 calls per account per briefing, 100 accounts = 300 calls / morning.

Guarded auto-pause — Adspirer-hosted monitor

You don’t run the cron — Adspirer does. Use this when you want rules to fire without babysitting an n8n workflow.

SaaS onboarding — embedded create

Reusing signup-{customer.id} as the key means signup retries never double-create.

What’s excluded from REST

These exist in MCP but are intentionally omitted from the REST surface — call the underlying tools directly instead:
  • Unified aggregators (ads_query, ads_optimize, ads_create, ads_manage, account_info) — LLM-convenience wrappers that dispatch to real tools.
  • Federated router meta-tools (google_ads, meta_ads, linkedin_ads, tiktok_ads, monitoring_and_reporting) — MCP-transport workaround for Claude Desktop’s tool-list size limit. Irrelevant for REST.

FAQ

Yes. Both transports decrement the same monthly allowance on your Adspirer plan. A call made from ChatGPT (MCP) and a call made from a curl script (REST) count the same.
Technically yes, but don’t. An API key in browser JavaScript is visible to anyone who opens DevTools. Call the REST API from your backend, or use the MCP server for user-facing AI experiences.
If an upstream ad platform rate-limits us, you’ll see HTTP 429. Back off and retry — typically 30–60 seconds is enough. Adspirer’s internal rate limits (HTTP 402 for quota) are separate from upstream limits.
Not yet. For “run every X hours” style jobs, use create_monitor — it polls on our side and emits alerts you can wire into Slack or email. For true push-based webhooks, book a call.
Yes. Keys aren’t pinned to a device. Just be aware that concurrent calls share one quota — if you parallelize heavily, you may hit HTTP 402 sooner.
Revoke it immediately at adspirer.ai/keys and generate a new one. Revoked keys stop working within seconds.
Last modified on July 8, 2026