get
https://sandbox-api.viantinc.com/{basePath}/adorder/getAllAdOrders
Returns details about all of the ad orders under the account.
Request
GET /adorder/getAllAdOrders
Response
| JSON Fields | Type | Description |
|---|---|---|
| messages | Object Array | An array of any error messages. |
| messages[].level | String | Error level. |
| messages[].code | String | Error code. |
| messages[].message | String | Error message. |
| entity | Object Array | An array of ad order objects. |
| entity[].id | Number | Ad order ID. |
| entity[].name | String | Ad order name. |
| entity[].campaignId | Number | Campaign ID associated with the ad order. |
| entity[].startDate | Number | Start date of the ad order, passed as Unix time in milliseconds. |
| entity[].endDate | Number | End date of the ad order, passed as Unix time in milliseconds. |
| entity[].optimizationGoal | String | Optimization goal for the ad order, one of:
|
| entity[].lifetimeBudget | Number | The total lifetime budget for the ad order in USD. |
| entity[].frequencyCap | Object | A frequency cap settings object. |
| entity[].frequencyCap.limit | Number | The maximum number of impressions a user is exposed to per frequency cap time period duration. See frequencyCap.duration and frequencyCap.timePeriod. |
| entity[].frequencyCap.duration | Number | The number of given frequencyCap.timePeriod. |
| entity[].frequencyCap.timePeriod | String | One of:
|
| entity[].channelsV2 | String Array (channelV2 account) Null (channelV1 account) |
Channels the Ad Order will be capable of serving on, one of:
|
| entity[].audienceWeightsEnabled | Boolean | Controls whether audience weights are enabled. |
| entity[].costOptimizationEnabled | Boolean | Controls whether cost optimization is enabled. Available only if the feature is enabled on the Account. |
| entity[].audiences | Object Array | An array of audience objects targeted by the ad order. |
| entity[].audiences[].id | Number | Audience ID. |
| entity[].audiences[].name | String | Audience name. |
| entity[].audiences[].weight | Integer | Audience weight. |
| entity[].audiences[].pmpDeals | Number Array | An array of any targeted PMP deals IDs, where the IDs are the internal Viant IDs. |
| entity[].audiences[].exchanges | Object | If this object is not present, the audience will not modify exchange targeting criteria. |
| entity[].audiences[].exchanges.include | Number Array | An array of any targeted exchange IDs. |
| entity[].audiences[].exchanges.exclude | Number Array | An array of any excluded exchange IDs. |
| entity[].audiences[].siteLists | Object | If this object is not present, the audience will not modify site list targeting criteria. |
| entity[].audiences[].siteLists.include | Number Array | An array of any targeted site list IDs. |
| entity[].audiences[].siteLists.exclude | Number Array | An array of any excluded site list IDs. |
| entity[].goalMode | String | Sets goal prioritization. One of:
|
| entity[].hourlyPacingMode | String | One of:
|
| entity[].hourlyFrontload | Number | Percentage frontload between 0.00 and 100.00. Null if hourlyPacingMode is ASAP |
| entity[].io_number | String | External reference field |
| entity[].externalAdOrderId | String | External reference field. |
Note
io_number and externalAdOrderId both serve the same purpose and refer to the same value: an external ID for use by clients. These fields point to the same value; on input, a caller should use one field or the other, not both; on output, both fields are provided (currently), and will have the same value.
Submitting a record with both fields is an error condition, and will result in a 400 response.
Example
Request
curl -u <user>:<password> https://sandbox-api.viant.com/v1/adorder/getAllAdOrders
Response
{
"messages": [],
"entity": [
{
"id": 9991,
"name": "Mobile Web",
"campaignId": 90,
"startDate": 1464739200000,
"endDate": 1483228800000,
"optimizationGoal": "CPM",
"lifetimeBudget": 10000,
"frequencyCap": {
"limit": 5,
"duration": 3,
"timePeriod": "DAY"
},
"channelsV2": null,
"audiences": [
{
"id": 9800,
"name": "Default Audience",
"weight": 1,
"pmpDeals": null,
"siteLists": {
"include": [
100,
101
],
"exclude": []
},
"exchanges": {
"include": [],
"exclude": [
96
]
}
}
],
"audienceWeightsEnabled": false,
"goalMode": "PERFORMANCE",
"hourlyPacingMode": "ASAP",
"hourlyFrontload": null
"io_number": null,
"externalAdOrderId": null
},
{
"id": 9993,
"name": "iOS",
"campaignId": 91,
"startDate": 1462060800000,
"endDate": 1464652800000,
"optimizationGoal": "CPM",
"lifetimeBudget": 15000.50,
"frequencyCap": {
"limit": 5,
"duration": 3,
"timePeriod": 2
},
"channelsV2": [
"Display",
"Video",
"CTV"
]
"audiences": [
{
"id": 9801,
"name": "Default Audience",
"weight": 1,
"pmpDeals": [
5656,
6565
],
"siteLists": {
"include": [
100,
101
],
"exclude": []
},
"exchanges": {
"include": [],
"exclude": [
96
]
}
}
],
"audienceWeightsEnabled": false,
"goalMode": "PERFORMANCE",
"hourlyPacingMode": "ASAP",
"hourlyFrontload": null
}
]
}