ads
POST /v1/ads/connect/chatgpt
Connect ChatGPT Ads with an Advertiser API key (za-318).
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 POST https://api.zinndigital.com/v1/ads/connect/chatgpt \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "api_key": <string> }'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. ChatGPT Ads (OpenAI) has no OAuth app open to us (OpenAI publishes no client registration for its AdsOAuth scheme; it is the API-partner path), so the customer pastes an Advertiser API key made at https://ads.openai.com/settings. One key reaches ONE ad account. The key is read against OpenAI's GET /v1/ad_account at once and kept in Vault as the grant (never in the database, never echoed); the answer is the grant id the ordinary account picker reads (listAdsConnectChatGPTAccounts). A value that cannot be a key is a 422 netBadKey before any call. A key OpenAI refuses still answers a grant whose picker carries the §2.57 failure (a rejected key links the keys page). Not gated on "Coming soon" (that gates the dashboard's offer). ChatGPT Ads writes (an ad group paused or resumed, a campaign's daily spend limit) are ON for a customer's own connection (owner 2026-11-09): an approved change goes through the approve-first queue, ceilings and Undo. The emergency switch ZINN_ADS_CHATGPT_WRITES set to anything but on (or unset) refuses every write chatgptWritesOff, and a house connection (the platform org or a staff org) is always refused the same way; nothing reaches OpenAI when refused.
Request body
| Name | Type | Required | What it is |
|---|---|---|---|
api_key | string | Yes | The Advertiser API key (a secret; never returned). |
org_id | string | No | — |
Response
| Name | Type | Required | What it is |
|---|---|---|---|
grant_id | string | Yes | — |
Errors this endpoint can return
401 · 403 · 404 · 422 · 429