Call it
curl https://api.peume.com/v1/call/get-ad-details \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"live": false,
"adId": "your adId"
}
}'const res = await fetch("https://api.peume.com/v1/call/get-ad-details", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"live": false,
"adId": "your adId"
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/get-ad-details",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"live": False,
"adId": "your adId"
}
},
)
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: get-ad-details.
Parameters
livebooleanRead the on/off switches live from the platform instead of returning synced values. See "Status freshness" in the operation description. - The fresh values are stored (later reads return them too), and the response carries `statusReadAt`, the time of the read. - At most 20 platform objects are read per request. - Where a read fails (credentials, platform error, no reader on that platform), stored values come back with `statusReadAt: null`. **On GET /v1/ads/{adId} for a TikTok ad** the creative is read live too: ad text, call to action, landing page, video, format and identity, returned over
Example: false
accountIdstringMeta only. A connection id ( or Facebook connection) used when `{adId}` is a Meta ad not in 's synced store, e.g. an Ads Manager ad on an ad account reached only through a Facebook connection. The ad is then read live from Meta through that connection, and the response carries `synced: false`. Ads Meta reports as DELETED are returned too, with their status. Same rules as GET /v1/ads/campaigns/{campaignId}: - Connection on a profile the API key cannot access: 404. - Ad on an ad account outside the connection's selected ad accounts: 403 `ad_account_not_selected`. - Id Met
adIdRequiredstring`_id` (hex), Meta `platformAdId` (numeric), or one of the creative's effective story/media IDs. See description for details.
