Skip to main content
PATCH
/
campaigns
Update a campaign
curl --request PATCH \
  --url https://your_a2_service/campaigns \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "bid_strategy": "highest_volume",
  "end_date": "2023-11-07T05:31:56Z",
  "goal": "click",
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "name": "<string>",
  "owner_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "start_date": "2023-11-07T05:31:56Z",
  "status": "okay",
  "audience_segments": {},
  "budget": 0,
  "created_at": "2023-11-07T05:31:56Z",
  "crid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "daily_budget": 123,
  "description": "<string>",
  "max_bid": 0,
  "min_daily_imp": 1000,
  "sub_goal": "<string>",
  "tagid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "target_cpa": 0,
  "target_cpm": 0,
  "target_volume": 0,
  "updated_at": "2023-11-07T05:31:56Z"
}
'
{
  "bid_strategy": "highest_volume",
  "end_date": "<string>",
  "goal": "click",
  "name": "<string>",
  "no": 123,
  "owner_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "start_date": "<string>",
  "status": "okay",
  "audience_segments": {},
  "budget": 0,
  "created_at": "2023-11-07T05:31:56Z",
  "crid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "daily_budget": 123,
  "description": "<string>",
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "max_bid": 0,
  "min_daily_imp": 1000,
  "sub_goal": "<string>",
  "tagid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "target_cpa": 0,
  "target_cpm": 0,
  "target_volume": 0,
  "updated_at": "2023-11-07T05:31:56Z"
}

Documentation Index

Fetch the complete documentation index at: https://docs.aiderx.io/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Body

application/json

Schema for updating campaign entity.

bid_strategy
enum<string>
required
deprecated

Bidding strategy for the campaign

Available options:
highest_volume,
bid_cap
end_date
string<date-time>
required

The datetime in RFC 3339 format when the campaign ends.

goal
enum<string>
required

Campaign objective

Available options:
click,
reach,
impression,
conversion
id
string<uuid>
required
name
string
required

The name of the campaign.

owner_id
string<uuid>
required

The owner's ID of the campaign

start_date
string<date-time>
required

The datetime in RFC 3339 format when the campaign starts. For example, 2017-07-21 17:32:28

status
enum<string>
required

Enum for campaign status.

Available options:
okay,
preparing,
ready,
archived
audience_segments
Audience Segments · object

The list of audience segments for targeting

budget
number
default:0

The total budget of the campaign

created_at
string<date-time> | null

The date and time the entity was created.

crid
string<uuid> | null
deprecated
daily_budget
number | null
deprecated
description
string | null

The description of the campaign

max_bid
number
default:0

Maximum bid per impression (only available for 'maximize_volume' bid strategy)

Required range: x >= 0
min_daily_imp
number
default:1000

Internal purpose

Required range: x >= 1000
sub_goal
string | null

The sub-goal of the campaign

tagid
string<uuid> | null
deprecated
target_cpa
number
default:0

Target cost per action

Required range: x >= 0
target_cpm
number
default:0

Target cost per thousand impressions (only available for 'target_cpm' sub-goal)

Required range: x >= 0
target_volume
number
default:0

Guaranteed impressions within the campaign period (only available for 'target_volume' sub-goal)

Required range: x >= 0
updated_at
string<date-time> | null

The date and time the entity was last updated.

Response

Successful Response

Schema representing a campaign entity with all its properties and metadata.

bid_strategy
enum<string>
required
deprecated

Bidding strategy for the campaign

Available options:
highest_volume,
bid_cap
end_date
string
required

The datetime in RFC 3339 format when the campaign ends.

goal
enum<string>
required

Campaign objective

Available options:
click,
reach,
impression,
conversion
name
string
required

The name of the campaign.

no
integer
required
owner_id
string<uuid>
required

The owner's ID of the campaign

start_date
string
required

The datetime in RFC 3339 format when the campaign starts. For example, 2017-07-21 17:32:28

status
enum<string>
required

Enum for campaign status.

Available options:
okay,
preparing,
ready,
archived
audience_segments
Audience Segments · object

The list of audience segments for targeting

budget
number
default:0

The total budget of the campaign

created_at
string<date-time> | null

The date and time the entity was created.

crid
string<uuid> | null
deprecated
daily_budget
number | null
deprecated
description
string | null

The description of the campaign

id
string<uuid>

The id of the campaign

max_bid
number
default:0

Maximum bid per impression (only available for 'maximize_volume' bid strategy)

Required range: x >= 0
min_daily_imp
number
default:1000

Internal purpose

Required range: x >= 1000
sub_goal
string | null

The sub-goal of the campaign

tagid
string<uuid> | null
deprecated
target_cpa
number
default:0

Target cost per action

Required range: x >= 0
target_cpm
number
default:0

Target cost per thousand impressions (only available for 'target_cpm' sub-goal)

Required range: x >= 0
target_volume
number
default:0

Guaranteed impressions within the campaign period (only available for 'target_volume' sub-goal)

Required range: x >= 0
updated_at
string<date-time> | null

The date and time the entity was last updated.