ads

PATCH /v1/ads/autopilot-decisions

Set the campaigns the autopilot must not touch and the keywords it must protect.

All ads endpoints

All developer docs →

Zinn®, our Viking, hammering at his anvil beside an API endpoint sending events to several listeners.

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 PATCH https://api.zinndigital.com/v1/ads/autopilot-decisions \
  -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 action ads.autopilot_decisions_update. A field left out keeps its value. A held campaign gets no automatic change at all; a pinned campaign keeps its budget and bidding; a protected keyword is never paused or added as a negative by itself. A person's approved change and an Undo are never bound. Campaign ids are digits; keywords are compared without match-type brackets, case-insensitively. A refused list answers 422 with one code: notAList, notStrings, entryLength, campaignNotDigits or tooManyEntries.

Request body

NameTypeRequiredWhat it is
org_idstringNo—
pinned_campaignsstring[]No—
held_campaignsstring[]No—
protected_keywordsstring[]No—

Response

NameTypeRequiredWhat it is
pinned_campaignsstring[]Yes—
held_campaignsstring[]Yes—
protected_keywordsstring[]Yes—
held_backobject[]YesThe latest automatic changes these decisions held back, newest first (at most 50 shown).
held_back_totalintegerYes—
updated_bystringNo—
updated_atobjectNo—

Errors this endpoint can return

400 · 401 · 403 · 404 · 422 · 429