Call it
curl https://api.peume.com/v1/call/list-ads \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"page": 1,
"limit": 50,
"source": "all",
"view": "full"
}
}'const res = await fetch("https://api.peume.com/v1/call/list-ads", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"page": 1,
"limit": 50,
"source": "all",
"view": "full"
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/list-ads",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"page": 1,
"limit": 50,
"source": "all",
"view": "full"
}
},
)
print(res.json()["output"])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: list-ads.
Parameters
pageintegerPage number (1-based)
Example: 1
limitintegerExample: 50
sourcestringall (default) = -created + platform-discovered ads. = restrict to -created only.
peume · all
Example: all
statusstringplatformstringfacebook · instagram · tiktok · linkedin · pinterest · google · twitter · openai · reddit · microsoft · amazon · tradedesk …
accountIdstringAccount ID
adAccountIdstringPlatform ad account ID (e.g. act_123 for Meta). Mirrors the same filter on /v1/ads/campaigns and /v1/ads/tree.
pageIdstringMeta only: Facebook Page ID. Returns only ads whose creative is backed by this Page (a Meta ad account serves ads for every Page in the Business Manager). Matches each ad's `creative.pageId`; ads with no page signal (rare IG-only creatives) never match. Mirrors the same filter on /v1/ads/campaigns and /v1/ads/tree.
campaignIdstringPlatform campaign ID (filter ads within a campaign)
adSetIdstringPlatform ad set ID (filter ads within an ad set, the /{adset_id}/ads read of an adset-centric dashboard).
platformAdIdstringMeta ad ID. Returns the ad with this platform-side ad ID.
effectiveObjectStoryIdstringFacebook `{pageId}_{postId}` of the post the ad's engagement lives on (Meta `effective_object_story_id`). Use to map a Business-Manager-visible post back to the ad.
effectiveInstagramMediaIdstringInstagram media ID of the boosted post (Meta `effective_instagram_media_id`). Use to map a Business-Manager-visible IG post back to the ad. For a boosted reel it can differ from the media ID you boosted (`platformPostId`), so filter by the ID shown on the ad, not the original reel ID.
fromDatestringStart of metrics date range (YYYY-MM-DD). Defaults to 90 days ago.
toDatestringEnd of metrics date range (YYYY-MM-DD). Defaults to today. Max 730-day range.
viewstring`full` (default) returns every field. `summary` is about 80% smaller per ad and keeps only: - `_id`, `name`, `platform`, `status`, `platformStatus`, `servingStatuses` (left out when empty), `configuredStatus`, `reviewStatus`, `rejectionReason`, `goal`. - The platform ids, `accountId`, `profileId`, `campaignName`, `adSetName`, `budget`, `currency`, `isExternal`, `creativeType`, `platformCreatedAt`, `createdAt`. - `postId` as the post id, not the expanded post. - `creative` with only `headline`, `body` (cut to 200 characters), `linkUrl`, `callToAction` and `effectiveObjectStoryId`. - `metrics`
full · summary
Example: full
