ads
PUT /v1/ads/tracking-hub
Change the hub's tag ids and conversion ids.
Authentication
Send an API key as a bearer token. The key must carry the ads.manage permission; a key without it is refused with 403, not 404.
Where your organisation id goes
This endpoint takes org_id as a field in the JSON body.
Your organisation id is on the API keys screen in your dashboard, beside the key itself. It is the same id in every call you make.
Try it
Replace anything in angle brackets with your own values, and the key placeholder with a key from your dashboard.
curl -X PUT https://api.zinndigital.com/v1/ads/tracking-hub \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ }'Signed in? The API console in your dashboard fills in your real organisation id and your own key, and runs the request against the live API so you can see the actual response. Open this endpoint in the API console
Details
Gated on ads.manage; audit-logged (ads.tracking_hub_updated). tags and conversions each REPLACE the stored map when present (a blank id removes it). Each tag id is checked against its network's format; a wrong one is a 422 (refusal.adsconnect.trackingHub.*) naming the field, e.g. tags.ga4. The version goes up by one and the cached script of every site tag of the organisation is rewritten.
Request body
| Name | Type | Required | What it is |
|---|---|---|---|
org_id | string | No | — |
tags | object | No | — |
conversions | object | No | Network -> {outcome kind: conversion id}. A LinkedIn conversion id is numeric and an X event id is tw-PIXEL-EVENT (for example tw-o1abc-o1xyz); any other shape for those two is… |
Response
| Name | Type | Required | What it is |
|---|---|---|---|
org_id | string | Yes | — |
tags | object | Yes | Network -> its browser tag id (google_ads, ga4, microsoft_uet, meta_pixel, tiktok_pixel, linkedin_insight, x_pixel, pinterest_tag, amazon_tag, chatgpt_pixel). |
conversions | object | Yes | Network -> outcome kind -> conversion id (a Google Ads label, a Meta custom conversion, a TikTok event …). |
server_keys | object[] | Yes | — |
server_routes | object | Yes | Network -> how its server-side conversions travel. |
server_sends | object | Yes | Key kind -> what that key really sent (docs/1006 §122), computed from the per-outcome delivery receipts. Only outcomes whose source reported ad_user_data consent GRANTED are sent,… |
networks | string[] | Yes | — |
kinds | string[] | Yes | — |
version | integer | Yes | 0 when no hub has been saved yet. |
updated_at | string | Yes | — |
Errors this endpoint can return
401 · 403 · 404 · 422