Skip to content

Approve a campaign

POST
/api/v1/ads/campaigns/{id}/approve
curl --request POST \
--url https://digize.com/api/v1/ads/campaigns/example/approve \
--header 'Idempotency-Key: 5f1c2a8e-3b7d-4c55-9a0e-1f2d3c4b5a69' \
--header 'x-api-key: <x-api-key>'

Approves a campaign waiting on the approver, which sends it to its platforms.

Needs the ads:write permission. It can’t be undone.

id
required
string
>= 1 characters <= 64 characters
Idempotency-Key
string
>= 1 characters <= 255 characters

Makes the request safe to send again: for 24 hours the same key and request answer the first response without repeating the change.

Example

5f1c2a8e-3b7d-4c55-9a0e-1f2d3c4b5a69

Done

Media typeapplication/json
Any of:
object
impressions
required
number
clicks
required
number
results
required

What the objective counts, as the platform reports it: purchases, leads, clicks or people reached.

number
spend
required
number
revenue
required

What the store’s orders attributed to it came to.

number
id
required
string
name
required
string
objective
required
string
Allowed values: sales leads traffic awareness
status
required

The most hopeful of its platforms’ statuses.

string
Allowed values: in_review active paused rejected ended
dailyBudget
required
number
startsAt
required
string format: date-time
endsAt
required
Any of:
string format: date-time
createdAt
required
string format: date-time
createdBy
required
string
finalUrl
required
string
audience
required
object
locations
required
Array<string>
<= 50 items
ageMin
required
integer
>= 13 <= 65
ageMax
required

65 means 65 and over.

integer
>= 13 <= 65
interests
required
Array<string>
<= 50 items
keywords
required
Array<string>
<= 200 items
audiences
required
Array<string>
<= 20 items
platforms
required
Array<object>
object
impressions
required
number
clicks
required
number
results
required

What the objective counts, as the platform reports it: purchases, leads, clicks or people reached.

number
spend
required
number
revenue
required

What the store’s orders attributed to it came to.

number
platform
required
string
Allowed values: google meta tiktok linkedin microsoft pinterest
status
required
string
Allowed values: in_review active paused rejected ended
externalId
required

The campaign’s id on the platform, once it’s there.

string | null
formats
required
Array<string>
Allowed values: google_search google_pmax facebook_feed instagram_feed instagram_story instagram_reels tiktok_feed linkedin_feed microsoft_search pinterest_pin
dailyBudget
required
number
rejection
required
string | null
publish
required
string
Allowed values: awaiting_approval pending published failed
orders
required

Store orders attributed to it, last 30 days.

number
awaitingApproval
required

Who it waits on before going out, by user id (* for any owner or admin); empty when it needn’t wait.

Array<string>
adGroups
required
Array<object>
object
impressions
required
number
clicks
required
number
results
required

What the objective counts, as the platform reports it: purchases, leads, clicks or people reached.

number
spend
required
number
revenue
required

What the store’s orders attributed to it came to.

number
id
required
string
platform
required
string
Allowed values: google meta tiktok linkedin microsoft pinterest
name
required
string
status
required
string
Allowed values: in_review active paused rejected ended
targeting
required
string
ads
required
Array<object>
object
impressions
required
number
clicks
required
number
results
required

What the objective counts, as the platform reports it: purchases, leads, clicks or people reached.

number
spend
required
number
revenue
required

What the store’s orders attributed to it came to.

number
id
required
string
campaignId
required
string
campaignName
required
string
adGroupId
required
string
adGroupName
required
string
platform
required
string
Allowed values: google meta tiktok linkedin microsoft pinterest
format
required
string
Allowed values: google_search google_pmax facebook_feed instagram_feed instagram_story instagram_reels tiktok_feed linkedin_feed microsoft_search pinterest_pin
name
required
string
status
required
string
Allowed values: active in_review rejected paused
rejection
required
string | null
creative
required
object
headlines
required
Array<string>
<= 15 items
primaryText
required
string
<= 2200 characters
descriptions
required
Array<string>
<= 5 items
media
required
Any of:
object
kind
required
string
Allowed values: image video
name
required
string
<= 120 characters
tone
required
string
Allowed values: primary accent secondary success warning info destructive
seconds
required
number | null
sound
required
boolean
assetId
Any of:
string
<= 64 characters
thumbnail
Any of:
string
<= 2000 characters
callToAction
required
string
Allowed values: shop_now learn_more sign_up book_now subscribe get_offer
finalUrl
required
string
<= 2000 characters
displayUrl
required
string
<= 200 characters
createdAt
required
string format: date-time
orders
required

Store orders attributed to it, last 30 days.

number
events
required
Array<object>
object
id
required
string
at
required
string format: date-time
kind
required
string
Allowed values: created submitted approved rejected paused resumed budget ended approval signed_off failed
actor
required
string
platform
required
Any of:
string
Allowed values: google meta tiktok linkedin microsoft pinterest
ads
required
number | null
adName
required
string | null
reason
required
string | null
from
required
number | null
to
required
number | null
days
required
Array<object>
object
date
required

Noon on the day, on the workspace’s clock.

string format: date-time
platforms
required
object
key
additional properties
object
impressions
required
number
clicks
required
number
results
required

What the objective counts, as the platform reports it: purchases, leads, clicks or people reached.

number
spend
required
number
revenue
required

What the store’s orders attributed to it came to.

number

Example

{
"objective": "sales",
"status": "in_review",
"platforms": [
{
"platform": "google",
"status": "in_review",
"formats": [
"google_search"
],
"publish": "awaiting_approval"
}
],
"adGroups": [
{
"platform": "google",
"status": "in_review"
}
],
"ads": [
{
"platform": "google",
"format": "google_search",
"status": "active",
"creative": {
"media": {
"kind": "image",
"tone": "primary"
},
"callToAction": "shop_now"
}
}
],
"events": [
{
"kind": "created",
"platform": "google"
}
]
}

What was sent isn’t valid (invalid).

Media typeapplication/json
object
error
required
object
code
required
string
Allowed values: invalid unauthorized forbidden not_found conflict too_large rate_limited unavailable internal
message
required
string
details
object
key
additional properties
any

Example

{
"error": {
"code": "invalid"
}
}

No key, or one that’s unknown, off or expired.

Media typeapplication/json
object
error
required
object
code
required
string
Allowed values: invalid unauthorized forbidden not_found conflict too_large rate_limited unavailable internal
message
required
string
details
object
key
additional properties
any

Example

{
"error": {
"code": "invalid"
}
}

The key doesn’t have the permission this needs.

Media typeapplication/json
object
error
required
object
code
required
string
Allowed values: invalid unauthorized forbidden not_found conflict too_large rate_limited unavailable internal
message
required
string
details
object
key
additional properties
any

Example

{
"error": {
"code": "invalid"
}
}

Nothing has that id (not_found).

Media typeapplication/json
object
error
required
object
code
required
string
Allowed values: invalid unauthorized forbidden not_found conflict too_large rate_limited unavailable internal
message
required
string
details
object
key
additional properties
any

Example

{
"error": {
"code": "invalid"
}
}

A request with the same Idempotency-Key is still running (conflict).

Media typeapplication/json
object
error
required
object
code
required
string
Allowed values: invalid unauthorized forbidden not_found conflict too_large rate_limited unavailable internal
message
required
string
details
object
key
additional properties
any

Example

{
"error": {
"code": "invalid"
}
}

The Idempotency-Key was used with a different request.

Media typeapplication/json
object
error
required
object
code
required
string
Allowed values: invalid unauthorized forbidden not_found conflict too_large rate_limited unavailable internal
message
required
string
details
object
key
additional properties
any

Example

{
"error": {
"code": "invalid"
}
}

Over the rate limit; see retry-after.

Media typeapplication/json
object
error
required
object
code
required
string
Allowed values: invalid unauthorized forbidden not_found conflict too_large rate_limited unavailable internal
message
required
string
details
object
key
additional properties
any

Example

{
"error": {
"code": "invalid"
}
}