Get ad tracking tags
Unified read of the platform's native click-URL tracking params.
- Meta (facebook/instagram): the creative's
url_tags(and template_url_spec). - Google (googleads): the campaign's
trackingUrlTemplate+finalUrlSuffix. Subject to the Google Ads API access-tier daily quota; bulk audits need Standard access. - LinkedIn (linkedinads): the campaign's Dynamic UTM
dynamicValueParameters+customValueParameters. Returns 405 for platforms without a click-URL tracking surface (TikTok, X, Pinterest).
API key authentication - use your Zernio API key as a Bearer token
In: header
Path Parameters
Ad id (hex _id, platformAdId, or effective story/media id).
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.ads.getAdTrackingTags({ path: { adId: 'ad_abc123', },});console.log(data);{
"platform": "string",
"level": "creative",
"urlTags": "string",
"templateUrlSpec": {},
"trackingUrlTemplate": "string",
"finalUrlSuffix": "string",
"dynamicValueParameters": {},
"customValueParameters": {}
}{
"error": "Unauthorized"
}List TikTok Business Centers GET
Returns the TikTok Business Centers (BCs) the connected `tiktokads` account can read. Each BC reports its advertiser count so callers can build agency-style pickers without re-walking `/v1/ads/accounts` per BC. TikTok-only. Solo advertisers (non-agency tokens) return an empty array.
Set ad tracking tags PATCH
Unified update. Send only the fields for the ad's platform: - Meta: `urlTags` (array of {key,value}). Meta creatives are immutable, so this rebuilds the creative and repoints the ad. By DEFAULT we PRESERVE the existing creative verbatim (re-post its object_story_spec + the new url_tags, reusing the image), so you send `urlTags` ALONE — no need to read back headline/body/CTA. `creative` (headline, body, callToAction, linkUrl, imageUrl) is OPTIONAL and only needed to rebuild explicitly, or for SHARE / page-post / dark / asset_feed creatives whose object_story_spec Meta strips (those return 422 asking for `creative`). - Google: `trackingUrlTemplate` and/or `finalUrlSuffix` (full template strings; account quota applies). - LinkedIn: `dynamicValueParameters` and/or `customValueParameters` (campaign-level Dynamic UTM).