Sign inConnect your AI
api

API reference

Every route of API v1 under https://www.adspy.sh/api/v1, generated from the OpenAPI 3.1 description the API itself is checked against.

Updated · API v1

The description

Download openapi.json (OpenAPI 3.1, JSON Schema 2020-12) for code generators and API clients. Errors on every route follow the problem format; lists page with cursors.

Brands

Search brands

GET/api/v1/brands

Brands in Adspy's library, by name. Each brand carries its key (brand_key), which every brand route takes. social_only_brands lists brands Adspy knows only from a TikTok or YouTube account matching the query (first page only). Needs the read permission.

Parameters

NameInTypeDescription
queryquerystringPart of the brand's name. Without it, brands are listed by name.
limitqueryintegerItems per page, 1 to 100 (default 20). 1 to 100, default 20
cursorquerystringThe next_cursor of the previous page. Send it with the same filters; it is valid for 24 hours.

Response 200

FieldTypeDescription
dataobject[]
data[].brand_keystring
data[].namestring
data[].logo_urlstring or nullA signed media link (21 days).
data[].websitestring or null
data[].ad_platformsstring[]The ad libraries the brand runs ads in: meta, google.
data[].industrystring or null
data[].creative_countinteger or null
data[].socialobject or nullThe brand's collected TikTok and YouTube accounts, or null.
has_moreboolean
next_cursorstring or nullSend it as cursor, with the same filters, for the next page.
totalinteger or null
social_only_brandsobject[]
social_only_brands[].brand_keystring
social_only_brands[].namestring or null
social_only_brands[].socialobject
social_only_brands[].accountsobject[]
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 invalid_cursor, 401 unauthorized, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 429 rate_limited, 500 internal_error, 503 service_unavailable

Get a brand

GET/api/v1/brands/{brand_key}

One brand: its name, website, ad platforms, industry, creative count and collected social accounts. Needs the read permission.

Parameters

NameInTypeDescription
brand_keypathstringThe brand's key, from GET /v1/brands. Required.

Response 200

FieldTypeDescription
brand_keystring
namestring
logo_urlstring or nullA signed media link (21 days).
websitestring or null
ad_platformsstring[]The ad libraries the brand runs ads in: meta, google.
industrystring or null
creative_countinteger or null
socialobject or nullThe brand's collected TikTok and YouTube accounts, or null.
social.platforms"tiktok" | "youtube"[]
social.postsinteger or nullPosts Adspy holds for these accounts; null when unknown or when it would include Instagram.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable

List a brand's creatives

GET/api/v1/brands/{brand_key}/creatives

The brand's creatives with the creative search filters. Pages can be shorter than limit: follow has_more. Needs the read permission.

Parameters

NameInTypeDescription
brand_keypathstringThe brand's key, from GET /v1/brands. Required.
queryquerystringWords to find, in the scope chosen.
scopequery"all" | "ad_copy" | "content_transcript" | "visual_analysis" | "all_keywords" | "hooks"Where query is matched (default all). default "all"
platformquery"all" | "meta" | "google"The ad library: meta (Facebook, Instagram and Messenger placements) or google (Search, YouTube, Display).
formatquery"all" | "image" | "video" | "carousel"
statusquery"all" | "active" | "inactive"Whether the library last saw the ad running.
sortquery"newest" | "oldest" | "longest"newest or oldest first sighting, or longest running (default newest). default "newest"
tagsquerystringAI tags the creative must all carry, comma-separated, e.g. hook_type:Question.
languagequerystring
min_days_activequeryintegerOnly creatives seen running for at least this many days. 0 to 36500
limitqueryintegerItems per page, 1 to 100 (default 20). 1 to 100, default 20
cursorquerystringThe next_cursor of the previous page. Send it with the same filters; it is valid for 24 hours.

Response 200

FieldTypeDescription
dataobject[]
data[].idstringThe creative's id (its media hash).
data[].brand_keystring or null
data[].brand_namestring or null
data[].brand_logo_urlstring or null
data[].platformstring or nullmeta or google.
data[].formatstring or nullimage, video or carousel.
data[].media_urlstring or nullThe creative's media: a signed link, valid 21 days.
data[].poster_urlstring or null
data[].media_urlsstring[]
data[].external_watch_urlstring or nullA YouTube link for Google video ads, when the file is not stored.
data[].titlestring or null
data[].bodystring or null
data[].first_seenstring or null
data[].last_seenstring or null
data[].statusstring or nullactive, inactive or unknown.
data[].days_activeinteger or null
data[].ads_countinteger or nullSource ads that run this creative.
data[].tagsstring[]
data[].languagestring or null
data[].media_availabilitystring or null
data[].media_unavailable_reasonstring or null
data[].transcriptstring or null
has_moreboolean
next_cursorstring or nullSend it as cursor, with the same filters, for the next page.
totalinteger or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 invalid_cursor, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable, 504 timeout

Reports

Get a brand's X-Ray

GET/api/v1/brands/{brand_key}/xray

The brand's X-Ray: the observed creative strategy (formats, hooks, funnel, longevity, audience estimates, destinations, changes) over a range, from public creatives. Evidence, not ad performance. A report is reused for 24 hours. Needs the actions permission.

Parameters

NameInTypeDescription
brand_keypathstringThe brand's key, from GET /v1/brands. Required.
rangequery"30d" | "90d" | "180d" | "all"The window of first sightings the report covers (default 90d). default "90d"

Response 200

FieldTypeDescription
instagram_excludedbooleanOptional.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 402 payment_required, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable, 504 timeout

Get a brand's social report

GET/api/v1/brands/{brand_key}/social

The brand's organic TikTok and YouTube report: accounts, cadence, views and engagement per view with confidence intervals, breakouts, paid reach (listed apart from organic numbers) and posts run as ads. Instagram is left out; aggregates over all platforms are null when the brand also has Instagram (instagram_excluded). Needs the actions permission.

Parameters

NameInTypeDescription
brand_keypathstringThe brand's key, from GET /v1/brands. Required.
rangequery"30d" | "90d"The statistics window: the last 30 or 90 days (default 90d). default "90d"

Response 200

FieldTypeDescription
instagram_excludedbooleanOptional.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 402 payment_required, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable

Run a brand's Full Analysis

POST/api/v1/brands/{brand_key}/full-analysis

The Brand Full Analysis: the ads, the organic posts and the links between them, with every number's n, confidence interval and test, multiple-testing corrected. Evidence from public data, never spend or results. Reused for 24 hours. When the brand has Instagram, Instagram is left out and the cross-platform aggregates are withheld (instagram_excluded). Needs the actions permission.

Parameters

NameInTypeDescription
brand_keypathstringThe brand's key, from GET /v1/brands. Required.
Idempotency-KeyheaderstringRequired. A unique key per new request; the same key on retries.

Request body

FieldTypeDescription
range"30d" | "90d" | "180d" | "all"The ads' mix, hooks and destinations cover this range; each finding states its own window (default 90d). default "90d" Optional.

Response 200

FieldTypeDescription
instagram_excludedbooleanOptional.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 idempotency_key_required, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 402 payment_required, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 409 idempotency_conflict, 409 operation_in_progress, 413 payload_too_large, 415 unsupported_media_type, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable, 504 timeout

Compare brands

POST/api/v1/compare/brands

The X-Rays of 2 to 5 brands over one range, side by side. Each brand's report is reused for 24 hours. Needs the actions permission.

Parameters

NameInTypeDescription
Idempotency-KeyheaderstringRequired. A unique key per new request; the same key on retries.

Request body

FieldTypeDescription
brand_keysstring[]2 to 5 brand keys.
range"30d" | "90d" | "180d" | "all"The window of first sightings the report covers (default 90d). default "90d" Optional.

Response 200

FieldTypeDescription
reportsobject[]
reports[].instagram_excludedbooleanOptional.
missingobject[]
missing[].brand_keystring
missing[].reasonstring
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 idempotency_key_required, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 402 payment_required, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 409 idempotency_conflict, 409 operation_in_progress, 413 payload_too_large, 415 unsupported_media_type, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable, 504 timeout

Compare brands on TikTok or YouTube

POST/api/v1/compare/social

2 to 5 brands' organic posts on one platform: engagement per view and views per post, each brand's median against its peers with a stratified bootstrap, cadence, breakouts and paid reach. Needs the actions permission.

Parameters

NameInTypeDescription
Idempotency-KeyheaderstringRequired. A unique key per new request; the same key on retries.

Request body

FieldTypeDescription
brand_keysstring[]2 to 5 brand keys.
platform"tiktok" | "youtube"tiktok or youtube. Instagram is not available in the API.
range"30d" | "90d"The statistics window: the last 30 or 90 days (default 90d). default "90d" Optional.

Response 200

FieldTypeDescription
instagram_excludedbooleanOptional.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 idempotency_key_required, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 402 payment_required, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 409 idempotency_conflict, 409 operation_in_progress, 413 payload_too_large, 415 unsupported_media_type, 422 instagram_not_in_api, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable

Social

List a brand's posts run as ads

GET/api/v1/brands/{brand_key}/posts-run-as-ads

Pairs of a brand's organic post and the ad cut from it (or the ad later posted organically), matched by media. Instagram pairs are left out; without platform, summary is null when the brand also has Instagram. Needs the read permission.

Parameters

NameInTypeDescription
brand_keypathstringThe brand's key, from GET /v1/brands. Required.
rangequery"30d" | "90d" | "180d" | "all"Posts published in this window (default 90d). default "90d"
platformquery"tiktok" | "youtube"tiktok or youtube. Instagram is not available in the API.
directionquery"organic_to_paid" | "paid_to_organic" | "all"organic_to_paid: posts later run as ads. paid_to_organic: ads later posted organically. default "organic_to_paid"
limitqueryintegerItems per page, 1 to 100 (default 20). 1 to 100, default 20
cursorquerystringThe next_cursor of the previous page. Send it with the same filters; it is valid for 24 hours.

Response 200

FieldTypeDescription
dataobject[]
data[].pair_idstring
data[].directionstring
data[].lag_daysnumber or null
data[].matchstring or null
data[].postobject
data[].adobjectThe ad: creative_id, source, ad_type, ad_first_seen, in_library, creative.
has_moreboolean
next_cursorstring or nullSend it as cursor, with the same filters, for the next page.
summaryobject or null
accountsobject[]
accounts[].account_idstring
accounts[].platform"tiktok" | "youtube"tiktok or youtube. Instagram is not available in the API.
accounts[].handlestring or null
accounts[].display_namestring or null
accounts[].profile_urlstring or null
accounts[].verifiedboolean or null
accounts[].followersinteger or null
accounts[].followers_roundedboolean or null
accounts[].posts_countinteger or null
accounts[].history_completeboolean or null
accounts[].last_success_atstring or null
accounts[].statusstring or null
matchingobject or null
instagram_excludedbooleanOptional.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 invalid_cursor, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 422 instagram_not_in_api, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable

Search social accounts

GET/api/v1/social/accounts

TikTok or YouTube accounts for a brand or a handle: the ones Adspy collects, then the platform's own search. official is true only with proof that the account is the brand's. Needs the read permission.

Parameters

NameInTypeDescription
queryquerystringA brand name or a handle. Required.
platformquery"tiktok" | "youtube"tiktok or youtube. Instagram is not available in the API. Required.
brand_keyquerystringThe Adspy brand, when known: its linked accounts and website are used as proof.

Response 200

FieldTypeDescription
dataobject[]
data[].platform"tiktok" | "youtube"tiktok or youtube. Instagram is not available in the API.
data[].handlestring or null
data[].urlstring or null
data[].display_namestring or null
data[].verifiedboolean or null
data[].followersinteger or null
data[].officialboolean or nullTrue only with proof that the account is the brand's.
data[].labelstring or null
data[].trackedboolean or nullAdspy already collects it: reading it is free.
data[].account_idstring or null
data[].brand_keystring or null
statusstring or nullfound, not_found, search_unavailable, …
reasonstring or null
retry_after_secondsinteger or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 422 instagram_not_in_api, 429 rate_limited, 500 internal_error, 503 service_unavailable

Collect a social account

POST/api/v1/social/fetches

Asks Adspy to collect a TikTok or YouTube account's posts. An account Adspy already collects is returned at once (state existing), and one already being collected answers its running job: neither counts. New collections count toward the contract's monthly quota, shared with the organization's MCP connections. Follow the job with GET /v1/fetches/{id}. Needs the actions permission.

Parameters

NameInTypeDescription
Idempotency-KeyheaderstringRequired. A unique key per new request; the same key on retries.

Request body

FieldTypeDescription
platform"tiktok" | "youtube"tiktok or youtube. Instagram is not available in the API.
urlstringThe profile link, e.g. tiktok.com/@handle. Give url or handle. Optional.
handlestringThe @handle. Optional.
brand_keystringThe brand the account belongs to: it is linked on proof only. Optional.

Response 202

FieldTypeDescription
job_idstring
kind"brand_fetch" | "social_fetch"
statestringexisting (Adspy already had it: read it now), queued, pending, submitting, processing, waiting (social: retried automatically at retry_at), completed or failed.
is_completebooleanThe only signal that the collection is done; never infer it from progress.
is_terminalboolean
poll_after_secondsinteger or nullWhen to read the job again; null once terminal.
brand_keystring or null
created_atstring or null
updated_atstring or null
source"meta" | "google" or nullBrand fetches: the ad library.
business_idstring or nullBrand fetches: the advertiser's id in that library.
brand_namestring or null
total_adsinteger or null
processed_adsinteger or null
remaining_adsinteger or null
result_capinteger or null
source_coverageobject or nullBrand fetches: how much of the advertiser's library was collected, when known.
source_coverage.statusstring or null
source_coverage.expected_ads_estimateinteger or null
source_coverage.observed_valid_adsinteger or null
source_coverage.low_confidenceboolean or null
source_coverage.reasonsstring[]
source_coverage.last_scraped_atstring or null
platform"tiktok" | "youtube" or nullSocial fetches.
account_idstring or null
handlestring or null
display_namestring or null
urlstring or null
total_postsinteger or null
processed_postsinteger or null
remaining_postsinteger or null
new_postsinteger or null
posts_countinteger or null
history_completeboolean or null
history_daysinteger or null
retry_atstring or null
progress_percentnumber or null
error_codestring or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 idempotency_key_required, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 402 payment_required, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 409 idempotency_conflict, 409 operation_in_progress, 413 payload_too_large, 415 unsupported_media_type, 422 instagram_not_in_api, 429 rate_limited, 429 partner_fair_use, 429 fetch_quota_exceeded, 429 fetch_limited, 500 internal_error, 503 service_unavailable

List social posts

GET/api/v1/social/posts

A brand's (or one account's) organic TikTok and YouTube posts with their public counts. Instagram posts are left out, so a page can hold fewer posts than limit: follow has_more. Needs the read permission.

Parameters

NameInTypeDescription
brand_keyquerystringThe brand; give brand_key or account_id.
account_idquerystringAn account id, e.g. social:tiktok:6643891469239320582.
platformquery"tiktok" | "youtube"tiktok or youtube. Instagram is not available in the API.
formatquery"video" | "short" | "live" | "carousel" | "image"TikTok: video, carousel (photo post), live. YouTube: video, short, live.
sincequerystringPosts published on or after this date (YYYY-MM-DD).
sortquery"recent" | "engagement" | "breakouts"recent: newest first. engagement: highest engagement per view first. breakouts: the posts far above the account's usual views (90-day statistics). default "recent"
limitqueryintegerItems per page, 1 to 100 (default 20). 1 to 100, default 20
cursorquerystringThe next_cursor of the previous page. Send it with the same filters; it is valid for 24 hours.

Response 200

FieldTypeDescription
dataobject[]
data[].idstring
data[].platform"tiktok" | "youtube"tiktok or youtube. Instagram is not available in the API.
data[].post_idstring
data[].account_idstring or null
data[].handlestring or null
data[].brand_keystring or null
data[].permalinkstring or null
data[].published_atstring or null
data[].published_at_approxboolean or null
data[].formatstring or null
data[].titlestring or null
data[].captionstring or null
data[].hashtagsstring[]
data[].duration_secnumber or null
data[].thumb_urlstring or null
data[].countsobjectPublic counts; null when the platform does not show one (never zero).
data[].counts_roundedboolean or null
data[].counts_atstring or null
data[].engagement_ratenumber or nullEngagement per view (posts with 50+ views).
data[].reachstring or nullbreakout, paid_reach or null (90-day statistics).
data[].ran_as_adboolean or null
data[].promoted_flagboolean or null
data[].pinnedboolean or null
data[].deleted_atstring or null
has_moreboolean
next_cursorstring or nullSend it as cursor, with the same filters, for the next page.
accountsobject[]
accounts[].account_idstring
accounts[].platform"tiktok" | "youtube"tiktok or youtube. Instagram is not available in the API.
accounts[].handlestring or null
accounts[].display_namestring or null
accounts[].profile_urlstring or null
accounts[].verifiedboolean or null
accounts[].followersinteger or null
accounts[].followers_roundedboolean or null
accounts[].posts_countinteger or null
accounts[].history_completeboolean or null
accounts[].last_success_atstring or null
accounts[].statusstring or null
reach_labelsobject or null
analysisobject or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 invalid_cursor, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 422 instagram_not_in_api, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable

Get a social post

GET/api/v1/social/posts/{id}

One TikTok or YouTube post with its count snapshots, ad links, pre-ad counts and, on request, its AI tags. Needs the read permission.

Parameters

NameInTypeDescription
idpathstringA post id, platform:native id, e.g. tiktok:7675005480867073311. Required.
include_analysisquery"true" | "false"true adds the post's AI tags (default false).

Response 200

FieldTypeDescription
idstring
platform"tiktok" | "youtube"tiktok or youtube. Instagram is not available in the API.
post_idstring
account_idstring or null
handlestring or null
brand_keystring or null
permalinkstring or null
published_atstring or null
published_at_approxboolean or null
formatstring or null
titlestring or null
captionstring or null
hashtagsstring[]
duration_secnumber or null
thumb_urlstring or null
countsobjectPublic counts; null when the platform does not show one (never zero).
counts.viewsinteger or null
counts.likesinteger or null
counts.commentsinteger or null
counts.sharesinteger or null
counts.savesinteger or null
counts_roundedboolean or null
counts_atstring or null
engagement_ratenumber or nullEngagement per view (posts with 50+ views).
reachstring or nullbreakout, paid_reach or null (90-day statistics).
ran_as_adboolean or null
promoted_flagboolean or null
pinnedboolean or null
deleted_atstring or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 422 instagram_not_in_api, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable

Creatives

Search creatives

GET/api/v1/creatives

Meta and Google creatives in Adspy's library, with filters. Live offset pages, not a fixed snapshot: a page can repeat or skip an item when the library changes between pages. Needs the read permission.

Parameters

NameInTypeDescription
queryquerystringWords to find, in the scope chosen.
scopequery"all" | "ad_copy" | "content_transcript" | "visual_analysis" | "all_keywords" | "hooks"Where query is matched (default all). default "all"
platformquery"all" | "meta" | "google"The ad library: meta (Facebook, Instagram and Messenger placements) or google (Search, YouTube, Display).
formatquery"all" | "image" | "video" | "carousel"
statusquery"all" | "active" | "inactive"Whether the library last saw the ad running.
sortquery"newest" | "oldest" | "longest"newest or oldest first sighting, or longest running (default newest). default "newest"
tagsquerystringAI tags the creative must all carry, comma-separated, e.g. hook_type:Question.
languagequerystring
min_days_activequeryintegerOnly creatives seen running for at least this many days. 0 to 36500
brand_keyquerystringOnly this brand's creatives.
brand_keysquerystringOnly these brands' creatives, comma-separated (up to 100).
limitqueryintegerItems per page, 1 to 100 (default 20). 1 to 100, default 20
cursorquerystringThe next_cursor of the previous page. Send it with the same filters; it is valid for 24 hours.

Response 200

FieldTypeDescription
dataobject[]
data[].idstringThe creative's id (its media hash).
data[].brand_keystring or null
data[].brand_namestring or null
data[].brand_logo_urlstring or null
data[].platformstring or nullmeta or google.
data[].formatstring or nullimage, video or carousel.
data[].media_urlstring or nullThe creative's media: a signed link, valid 21 days.
data[].poster_urlstring or null
data[].media_urlsstring[]
data[].external_watch_urlstring or nullA YouTube link for Google video ads, when the file is not stored.
data[].titlestring or null
data[].bodystring or null
data[].first_seenstring or null
data[].last_seenstring or null
data[].statusstring or nullactive, inactive or unknown.
data[].days_activeinteger or null
data[].ads_countinteger or nullSource ads that run this creative.
data[].tagsstring[]
data[].languagestring or null
data[].media_availabilitystring or null
data[].media_unavailable_reasonstring or null
data[].transcriptstring or null
has_moreboolean
next_cursorstring or nullSend it as cursor, with the same filters, for the next page.
totalinteger or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 invalid_cursor, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable, 504 timeout

Search creatives by meaning

GET/api/v1/creatives/by-meaning

Creatives whose transcript says what you describe, closest meaning first, in any language and even with other words. A creative without a transcript is never found here: use the creative search for exact words, ad copy or a brand's full list. Filters apply before ordering. Status, tags and days active are not offered here. Needs the read permission.

Parameters

NameInTypeDescription
queryquerystringWhat the ads should say, in plain words and any language: an idea, an angle, a pain point. Required.
brand_keyquerystringOnly this brand's creatives.
brand_keysquerystringOnly these brands' creatives, comma-separated (up to 100).
platformquery"all" | "meta" | "google"The ad library: meta (Facebook, Instagram and Messenger placements) or google (Search, YouTube, Display).
formatquery"all" | "image" | "video" | "carousel"
languagequerystring
sincequerystringOnly creatives first seen on or after this day, e.g. 2026-09-01.
limitqueryintegerItems per page, 1 to 100 (default 20). 1 to 100, default 20
cursorquerystringThe next_cursor of the previous page. Send it with the same filters; it is valid for 24 hours.

Response 200

FieldTypeDescription
dataobject[]
data[].idstringThe creative's id (its media hash).
data[].brand_keystring or null
data[].brand_namestring or null
data[].brand_logo_urlstring or null
data[].platformstring or nullmeta or google.
data[].formatstring or nullimage, video or carousel.
data[].media_urlstring or nullThe creative's media: a signed link, valid 21 days.
data[].poster_urlstring or null
data[].media_urlsstring[]
data[].external_watch_urlstring or nullA YouTube link for Google video ads, when the file is not stored.
data[].titlestring or null
data[].bodystring or null
data[].first_seenstring or null
data[].last_seenstring or null
data[].statusstring or nullactive, inactive or unknown.
data[].days_activeinteger or null
data[].ads_countinteger or nullSource ads that run this creative.
data[].tagsstring[]
data[].languagestring or null
data[].media_availabilitystring or null
data[].media_unavailable_reasonstring or null
data[].transcriptstring or null
data[].match_scorenumberHow close the meaning is, from 0 to 1. Never a measure of results.
has_moreboolean
next_cursorstring or nullSend it as cursor, with the same filters, for the next page.
totalinteger or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 invalid_cursor, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable, 504 timeout

Get a creative

GET/api/v1/creatives/{id}

One creative with its transcript, source ads (variants), hook, AI tags, CTA and landing pages. Needs the read permission.

Parameters

NameInTypeDescription
idpathstringThe creative id. Required.

Response 200

FieldTypeDescription
idstringThe creative's id (its media hash).
brand_keystring or null
brand_namestring or null
brand_logo_urlstring or null
platformstring or nullmeta or google.
formatstring or nullimage, video or carousel.
media_urlstring or nullThe creative's media: a signed link, valid 21 days.
poster_urlstring or null
media_urlsstring[]
external_watch_urlstring or nullA YouTube link for Google video ads, when the file is not stored.
titlestring or null
bodystring or null
first_seenstring or null
last_seenstring or null
statusstring or nullactive, inactive or unknown.
days_activeinteger or null
ads_countinteger or nullSource ads that run this creative.
tagsstring[]
languagestring or null
media_availabilitystring or null
media_unavailable_reasonstring or null
transcriptstring or null
transcript_statusstring or null
transcript_partsobject[]
transcript_parts[].kindstring
transcript_parts[].labelstring
transcript_parts[].textstring
variantsobject[]The source ads that run this creative, newest first.
variants_limitedboolean
variants_countinteger or null
active_variants_countinteger or null
hookobject or null
ai_tagsobject[]
ai_tags[].idstring
ai_tags[].labelstring
ai_tags[].tagsobject[]
ctastring or null
landing_page_urlstring or null
overviewobject or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable

Get a creative's AI analysis

GET/api/v1/creatives/{id}/analysis

The creative's record with its AI analysis: scores (an AI reading of the execution, not measured performance), objective, timed moments and the full analysis document. Needs the read permission.

Parameters

NameInTypeDescription
idpathstringThe creative id. Required.

Response 200

FieldTypeDescription
idstringThe creative's id (its media hash).
brand_keystring or null
brand_namestring or null
brand_logo_urlstring or null
platformstring or nullmeta or google.
formatstring or nullimage, video or carousel.
media_urlstring or nullThe creative's media: a signed link, valid 21 days.
poster_urlstring or null
media_urlsstring[]
external_watch_urlstring or nullA YouTube link for Google video ads, when the file is not stored.
titlestring or null
bodystring or null
first_seenstring or null
last_seenstring or null
statusstring or nullactive, inactive or unknown.
days_activeinteger or null
ads_countinteger or nullSource ads that run this creative.
tagsstring[]
languagestring or null
media_availabilitystring or null
media_unavailable_reasonstring or null
transcriptstring or null
transcript_statusstring or null
transcript_partsobject[]
transcript_parts[].kindstring
transcript_parts[].labelstring
transcript_parts[].textstring
variantsobject[]The source ads that run this creative, newest first.
variants_limitedboolean
variants_countinteger or null
active_variants_countinteger or null
hookobject or null
ai_tagsobject[]
ai_tags[].idstring
ai_tags[].labelstring
ai_tags[].tagsobject[]
ctastring or null
landing_page_urlstring or null
overviewobject or null
scoresobject[]AI reading of the creative's execution, not measured ad performance.
scores[].idstring
scores[].labelstring
scores[].valuenumber or null
scores[].out_ofnumber or null
scores[].meaningstring or null
objectivestring or null
momentsobject[]
analysisobject or null
analysis_statusstring or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable

List similar creatives

GET/api/v1/creatives/{id}/similar

Creatives of other brands that share the creative's execution and topic tags, ranked. Needs the read permission.

Parameters

NameInTypeDescription
idpathstringThe creative id. Required.
limitqueryintegerMatches to return, 1 to 100 (default 20). 1 to 100, default 20

Response 200

FieldTypeDescription
dataobject[]
data[].creativeobject
candidates_reviewedinteger or null
candidate_limitinteger or null
candidate_pool_limitedboolean or null
methodstring or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable

Fetches

Search advertisers in public ad libraries

GET/api/v1/advertisers

Advertisers on the Meta Ad Library or Google Ads Transparency, for a brand Adspy does not have yet. Give the chosen one's url to POST /v1/fetches. Needs the read permission.

Parameters

NameInTypeDescription
queryquerystringThe advertiser's name. Required.
sourcequery"meta" | "google"The public ad library to search: Meta Ad Library or Google Ads Transparency. Required.

Response 200

FieldTypeDescription
dataobject[]
data[].sourcestring
data[].business_idstring
data[].namestring or null
data[].logo_urlstring or null
data[].ad_countinteger or null
data[].countrystring or null
data[].urlstringGive it to POST /v1/fetches.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 429 rate_limited, 500 internal_error, 503 service_unavailable

Collect a new brand

POST/api/v1/fetches

Asks Adspy to collect an advertiser's ads. A brand Adspy already has is returned at once (state existing), and one already being collected answers its running job: neither counts. New collections count toward the contract's monthly quota, shared with the organization's MCP connections. Follow the job with GET /v1/fetches/{id}. Needs the actions permission.

Parameters

NameInTypeDescription
Idempotency-KeyheaderstringRequired. A unique key per new request; the same key on retries.

Request body

FieldTypeDescription
urlstringThe advertiser's page in the Meta Ad Library (view_all_page_id) or Google Ads Transparency, from GET /v1/advertisers.
namestringThe brand's name.
result_capintegerSuggested page size for reading the new creatives later; not an ingestion limit. 1 to 100, default 20 Optional.

Response 202

FieldTypeDescription
job_idstring
kind"brand_fetch" | "social_fetch"
statestringexisting (Adspy already had it: read it now), queued, pending, submitting, processing, waiting (social: retried automatically at retry_at), completed or failed.
is_completebooleanThe only signal that the collection is done; never infer it from progress.
is_terminalboolean
poll_after_secondsinteger or nullWhen to read the job again; null once terminal.
brand_keystring or null
created_atstring or null
updated_atstring or null
source"meta" | "google" or nullBrand fetches: the ad library.
business_idstring or nullBrand fetches: the advertiser's id in that library.
brand_namestring or null
total_adsinteger or null
processed_adsinteger or null
remaining_adsinteger or null
result_capinteger or null
source_coverageobject or nullBrand fetches: how much of the advertiser's library was collected, when known.
source_coverage.statusstring or null
source_coverage.expected_ads_estimateinteger or null
source_coverage.observed_valid_adsinteger or null
source_coverage.low_confidenceboolean or null
source_coverage.reasonsstring[]
source_coverage.last_scraped_atstring or null
platform"tiktok" | "youtube" or nullSocial fetches.
account_idstring or null
handlestring or null
display_namestring or null
urlstring or null
total_postsinteger or null
processed_postsinteger or null
remaining_postsinteger or null
new_postsinteger or null
posts_countinteger or null
history_completeboolean or null
history_daysinteger or null
retry_atstring or null
progress_percentnumber or null
error_codestring or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 idempotency_key_required, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 402 payment_required, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 409 idempotency_conflict, 409 operation_in_progress, 409 conflict, 413 payload_too_large, 415 unsupported_media_type, 429 rate_limited, 429 partner_fair_use, 429 fetch_quota_exceeded, 429 fetch_limited, 500 internal_error, 503 service_unavailable

Get a fetch job

GET/api/v1/fetches/{id}

A brand or social account collection: its state and progress. A job is complete only when is_complete is true; then read the brand's creatives (GET /v1/brands/{brand_key}/creatives) or the account's posts (GET /v1/social/posts). Needs the actions permission.

Parameters

NameInTypeDescription
idpathstringThe fetch job id. Required.

Response 200

FieldTypeDescription
job_idstring
kind"brand_fetch" | "social_fetch"
statestringexisting (Adspy already had it: read it now), queued, pending, submitting, processing, waiting (social: retried automatically at retry_at), completed or failed.
is_completebooleanThe only signal that the collection is done; never infer it from progress.
is_terminalboolean
poll_after_secondsinteger or nullWhen to read the job again; null once terminal.
brand_keystring or null
created_atstring or null
updated_atstring or null
source"meta" | "google" or nullBrand fetches: the ad library.
business_idstring or nullBrand fetches: the advertiser's id in that library.
brand_namestring or null
total_adsinteger or null
processed_adsinteger or null
remaining_adsinteger or null
result_capinteger or null
source_coverageobject or nullBrand fetches: how much of the advertiser's library was collected, when known.
source_coverage.statusstring or null
source_coverage.expected_ads_estimateinteger or null
source_coverage.observed_valid_adsinteger or null
source_coverage.low_confidenceboolean or null
source_coverage.reasonsstring[]
source_coverage.last_scraped_atstring or null
platform"tiktok" | "youtube" or nullSocial fetches.
account_idstring or null
handlestring or null
display_namestring or null
urlstring or null
total_postsinteger or null
processed_postsinteger or null
remaining_postsinteger or null
new_postsinteger or null
posts_countinteger or null
history_completeboolean or null
history_daysinteger or null
retry_atstring or null
progress_percentnumber or null
error_codestring or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 429 rate_limited, 500 internal_error, 503 service_unavailable

Collections

List collections

GET/api/v1/collections

The workspace's collections of saved creatives, 100 per page. Needs the read permission.

Parameters

NameInTypeDescription
cursorquerystringThe next_cursor of the previous page. Send it with the same filters; it is valid for 24 hours.

Response 200

FieldTypeDescription
dataobject[]
data[].idstring
data[].namestring
data[].descriptionstring or null
data[].countinteger or null
has_moreboolean
next_cursorstring or nullSend it as cursor, with the same filters, for the next page.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 invalid_cursor, 401 unauthorized, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 429 rate_limited, 500 internal_error, 503 service_unavailable

Save creatives to a new collection

POST/api/v1/collections

Creates a collection with these creatives, or adds them to your collection that already has this name. Creatives the library does not hold are left out and listed in not_saved; when none is held, nothing is created (404). Needs the actions permission.

Parameters

NameInTypeDescription
Idempotency-KeyheaderstringRequired. A unique key per new request; the same key on retries.

Request body

FieldTypeDescription
namestringThe collection's name. An existing collection of yours with this name is reused.
creative_idsstring[]1 to 100 creative ids.

Response 201

FieldTypeDescription
collection_idstring
updatedboolean
not_savedstring[]Creative ids the library does not hold, left out of the save. Optional.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 idempotency_key_required, 401 unauthorized, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 409 idempotency_conflict, 409 operation_in_progress, 413 payload_too_large, 415 unsupported_media_type, 429 rate_limited, 500 internal_error, 503 service_unavailable

Get a collection

GET/api/v1/collections/{id}

A collection and its creatives with their notes. expand=true adds each creative's record. Needs the read permission.

Parameters

NameInTypeDescription
idpathstringThe collection id. Required.
expandquery"true" | "false"true adds each creative's record (default false).
limitqueryintegerItems per page, 1 to 100 (default 20). 1 to 100, default 20
cursorquerystringThe next_cursor of the previous page. Send it with the same filters; it is valid for 24 hours.

Response 200

FieldTypeDescription
dataobject[]
data[].creative_idstring
data[].notestring
data[].added_atstring or null
data[].creativeobjectOptional.
has_moreboolean
next_cursorstring or nullSend it as cursor, with the same filters, for the next page.
collectionobject
collection.idstring
collection.namestring
collection.descriptionstring or null
collection.colorstring or null
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 invalid_cursor, 401 unauthorized, 402 partner_key_cap_reached, 402 partner_tenant_cap_reached, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 429 rate_limited, 429 partner_fair_use, 500 internal_error, 503 service_unavailable

Add creatives to a collection

POST/api/v1/collections/{id}/creatives

Adds creatives to the collection. A creative already in it keeps its note. Creatives the library does not hold are left out and listed in not_saved; when none is held, nothing is added (404). Needs the actions permission.

Parameters

NameInTypeDescription
idpathstringThe collection id. Required.
Idempotency-KeyheaderstringRequired. A unique key per new request; the same key on retries.

Request body

FieldTypeDescription
creative_idsstring[]1 to 100 creative ids.

Response 200

FieldTypeDescription
collection_idstring
updatedboolean
not_savedstring[]Creative ids the library does not hold, left out of the save. Optional.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 idempotency_key_required, 401 unauthorized, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 409 idempotency_conflict, 409 operation_in_progress, 413 payload_too_large, 415 unsupported_media_type, 429 rate_limited, 500 internal_error, 503 service_unavailable

Set a creative's note

PATCH/api/v1/collections/{id}/creatives/{creative_id}

Sets the note of a creative in the collection. Sending the same note again changes nothing. Needs the actions permission.

Parameters

NameInTypeDescription
idpathstringThe collection id. Required.
creative_idpathstringThe creative id. Required.

Request body

FieldTypeDescription
notestringThe note; an empty string clears it.

Response 200

FieldTypeDescription
collection_idstring
creative_idstring
notestring
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 404 not_found, 413 payload_too_large, 415 unsupported_media_type, 429 rate_limited, 500 internal_error, 503 service_unavailable

Exports

Create an export

POST/api/v1/exports

Exports up to 10,000 items as CSV, Excel, JSON, ZIP (with media), PDF, Markdown or HTML. The file is built in the background: follow the job with GET /v1/exports/{id}. Files are kept 7 days. Social exports take platform tiktok or youtube. Needs the export permission.

Parameters

NameInTypeDescription
Idempotency-KeyheaderstringRequired. A unique key per new request; the same key on retries.

Request body

FieldTypeDescription
sourceobject
formatobjectcsv: one table. xlsx: sheets with an About sheet. json: everything with a manifest. zip: CSV + JSON + media files. pdf: reports, X-Rays and comparisons. markdown and html: creatives only.
includeobjectOptional.
include.analysisbooleanAdd analyses or AI tags. default false Optional.
include.transcriptsbooleanAdd creative transcripts. Optional.
include.media"none" | "thumbnails" | "originals"zip only: thumbnails (default, up to 2,000 files) or originals (up to 200 files and 2 GB). Optional.

Response 202

FieldTypeDescription
job_idstring
state"pending" | "running" | "partial" | "completed" | "failed"
titlestring or nullA short name of what is exported, such as "120 ads of Northstar".
sourceobject or nullWhat is exported: its kind (creatives, creative_ids, collection, social_posts, post_ad_pairs, social_comparison, brand_xray) and size.
source.kindstring
formatstring or null
completed_itemsinteger or null
requested_itemsinteger or null
missing_countinteger or null
bytesinteger or null
filenamestring or null
created_atstring or null
expires_atstring or null
error_codestring or null
download_urlstring or nullA link valid 5 minutes, when the file is ready. Read the job again for a new one.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 idempotency_key_required, 401 unauthorized, 402 payment_required, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 403 not_offered_to_partner, 409 idempotency_conflict, 409 operation_in_progress, 413 payload_too_large, 415 unsupported_media_type, 422 instagram_not_in_api, 429 rate_limited, 500 internal_error, 503 service_unavailable

List exports

GET/api/v1/exports

The exports the key's user made in its workspace in the last 7 days, newest first, through the API or in Adspy. Exports of a source the API does not offer (Instagram among them) are left out, so a page can hold fewer than limit: follow has_more. Needs the export permission.

Parameters

NameInTypeDescription
statequery"pending" | "running" | "completed" | "partial" | "failed"
limitqueryintegerItems per page, 1 to 50 (default 20). 1 to 50, default 20
cursorquerystringThe next_cursor of the previous page. Send it with the same filters; it is valid for 24 hours.

Response 200

FieldTypeDescription
dataobject[]
data[].job_idstring
data[].state"pending" | "running" | "partial" | "completed" | "failed"
data[].titlestring or nullA short name of what is exported, such as "120 ads of Northstar".
data[].sourceobject or nullWhat is exported: its kind (creatives, creative_ids, collection, social_posts, post_ad_pairs, social_comparison, brand_xray) and size.
data[].formatstring or null
data[].completed_itemsinteger or null
data[].requested_itemsinteger or null
data[].missing_countinteger or null
data[].bytesinteger or null
data[].filenamestring or null
data[].created_atstring or null
data[].expires_atstring or null
data[].error_codestring or null
data[].download_urlstring or nullA link valid 5 minutes, when the file is ready. Read the job again for a new one.
has_moreboolean
next_cursorstring or nullSend it as cursor, with the same filters, for the next page.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 400 invalid_cursor, 401 unauthorized, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 403 not_offered_to_partner, 429 rate_limited, 500 internal_error, 503 service_unavailable

Get an export

GET/api/v1/exports/{id}

An export job and, when the file is ready, a download link valid 5 minutes. An export of a source the API does not offer, made in Adspy, is not available here. Needs the export permission.

Parameters

NameInTypeDescription
idpathstringThe export job id. Required.

Response 200

FieldTypeDescription
job_idstring
state"pending" | "running" | "partial" | "completed" | "failed"
titlestring or nullA short name of what is exported, such as "120 ads of Northstar".
sourceobject or nullWhat is exported: its kind (creatives, creative_ids, collection, social_posts, post_ad_pairs, social_comparison, brand_xray) and size.
source.kindstring
formatstring or null
completed_itemsinteger or null
requested_itemsinteger or null
missing_countinteger or null
bytesinteger or null
filenamestring or null
created_atstring or null
expires_atstring or null
error_codestring or null
download_urlstring or nullA link valid 5 minutes, when the file is ready. Read the job again for a new one.
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 403 not_offered_to_partner, 404 not_found, 422 instagram_not_in_api, 429 rate_limited, 500 internal_error, 503 service_unavailable

Usage

Get usage

GET/api/v1/usage

The organization's plan, the contract's limits, this month's new collections and the operations of the last 30 days. Enterprise has no credit count: its credit fields are null or 0. Needs the read permission.

Response 200

FieldTypeDescription
planstring or nullThe organization's plan: Enterprise.
unlimitedbooleanTrue on Enterprise: there is no credit count.
creditsobjectIts fields are null on Enterprise, which has no credit count.
credits.availablenumber or null
credits.used_this_monthnumber or null
credits.renews_atstring or null
limitsobject
limits.requests_per_minuteintegerRequests a minute for this key, set by the contract. -9007199254740991 to 9007199254740991
limits.fetches_per_monthintegerNew brand or account collections a month for the organization, set by the contract. -9007199254740991 to 9007199254740991
limits.fetches_this_monthintegerNew collections the organization started this month (UTC), from its API keys and its MCP connections: the count fetch_quota_exceeded checks. -9007199254740991 to 9007199254740991
spentobject
spent.daysinteger-9007199254740991 to 9007199254740991
spent.by_operationobject[]
billingobjectWhat the request charged. Partner keys get it on every answer, free ones too. Optional.
billing.credits_chargedintegerCredits this request charged: always 0 on Enterprise, which has no credit count. On a partner key, the credits the partner bills: each new item read, and reports and new collections at their price. -9007199254740991 to 9007199254740991
billing.usd_microsintegerPartner keys only: what the partner bills, in micro-dollars. -9007199254740991 to 9007199254740991 Optional.
billing.operation_idstring or nullPartner keys only: the settled operation, for reconciliation; null when nothing was settled. Optional.
billing.replayedbooleanPartner keys only: true when the answer replays an earlier request, billed then. Optional.
billing.price_versionstringPartner keys only: the version of the partner prices applied. Optional.

Errors

400 invalid_request, 401 unauthorized, 403 enterprise_required, 403 insufficient_scope, 403 forbidden, 403 not_offered_to_partner, 429 rate_limited, 500 internal_error, 503 service_unavailable