PeumeAPI

Ads

Rank ads by performance

Returns an ads account's ads ranked by spend, impressions, clicks, results or ROAS over a date range, each with its creative (type, thumbnail, headline, body, link) and campaign.

$0.002 per callRuns on an account you connect

Call it

curl https://api.peume.com/v1/call/rank-ads-by-performance \
  -H "Authorization: Bearer $PEUME_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "input": {
    "accountId": "your accountId",
    "fromDate": "your fromDate",
    "toDate": "your toDate",
    "sortBy": "spend",
    "limit": 50
  }
}'

Answer: {"id": "run_…", "status": "completed", "cost_usd": …, "output": {…}}. Long jobs answer 202 with a run id to read later. From an AI agent, connect the MCP server and ask for this by name: rank-ads-by-performance.

Parameters

accountIdRequiredstring

Account ID. Sibling-expanded to its linked posting and ads pair. An id the API key cannot reach answers 404.

adAccountIdstring

Optional platform-native ad account ID (e.g. Meta `act_…`) to rank one ad account only.

fromDateRequiredstring

Inclusive start of the range (YYYY-MM-DD).

toDateRequiredstring

Inclusive end of the range (YYYY-MM-DD). Max 730-day range.

platformstring

Restrict to one platform.

facebook · instagram · tiktok · linkedin · pinterest · google · twitter · openai · reddit · microsoft · amazon · applovin …

sortBystring

Metric the ads are ranked by, highest first.

spend · impressions · clicks · conversions · roas

Example: spend

limitinteger

How many ads to return.

Example: 50

Start free · $1 of calls included

Every API your product needs. One key.

7,267 endpoints, one bill, and you only pay for calls that work.