List custom audiences
Returns custom audiences for the given ad account. Supports Meta, Google, TikTok, and Pinterest.
API key authentication - use your Zernio API key as a Bearer token
In: header
Query Parameters
Social account ID
Platform ad account ID
"facebook" | "instagram" | "googleads" | "tiktok" | "pinterest"Response Body
application/json
application/json
import Zernio from '@zernio/node';const zernio = new Zernio({ apiKey: process.env.ZERNIO_API_KEY });const { data } = await zernio.adaudiences.listAdAudiences({ query: { accountId: 'account_abc123', adAccountId: 'adaccount_abc123', },});console.log(data);{
"audiences": [
{
"id": "string",
"platformAudienceId": "string",
"name": "string",
"description": "string",
"type": "customer_list",
"platform": "string",
"size": 0,
"status": "string"
}
]
}{
"error": "Unauthorized"
}Duplicate a campaign POST
Duplicates a campaign, including its ad sets, ads, creatives, and targeting by default (`deepCopy: true`). The copy is created paused so callers can review before launching. Per-platform implementation: - **Meta** uses the native `POST /{campaign-id}/copies` endpoint. - **TikTok** has no native copy primitive; Zernio walks the source graph (`/v2/campaign/get/`, `/v2/adgroup/get/`, `/v2/ad/get/`) and recreates each entity via the corresponding `/create/` endpoints, carrying over budget / targeting / bid_type / bid_price / deep_bid_type / creative fields. Spark Ad linkage (`tiktok_item_id`) is preserved. The new hierarchy is asynchronous to materialize in our DB — we trigger sync discovery automatically. Set `syncAfter: false` to skip and poll `/v1/ads/tree` on your own cadence. Other platforms return 501 Not Implemented.
Create custom audience POST
Create a customer list, website retargeting, or lookalike audience on Meta (Facebook/Instagram).