List Ad Groups

📘

URL: POST/api/v1/adGroups/list

Request Parameters

ParameterParameter DescriptionTypeRequiredPossible Values
advertiserIdID of advertiserintegerYAdvertiser ID for which the ad group needs to be updated for delivery status
campaignIdID of the campaignintegerYUnique numeric identifier.
Filter[name]A valid ad group name with which the desired ad group can be searched in the absence of ad group IDarrayNProvide an ad group name to search the relevant ad group by name instead of ad group ID
Filter[status]Filter based on the ad group statusstringNEnum values:
• draft
• live
• scheduled
• paused
• completed
• archived
Filter[lastModifiedDate]Provide a date to fetch only those ad groups which were modified on or after that datestringNDate format must follow ISO 8601 time zone format:
• yyyy-MM-dd'T'HH:mm:ss.SSSXXX
Filter[adGroupId]ID of the ad groups you wish to list details for.

Note: if no adGroupId is specified, all ad groups in the campaign will be returned
arrayNUnique numeric identifier. Maximum list size is 25 entries.
startIndexYou can use this parameter in combination with count, to fetch specific number of ad groups from a list.
This indicates the starting position of the list
integerNInteger value. Default = 0

Example: To return the first ten ad groups, set startIndex=0 and count=10
countDefines the total number of ad groups to be returned.

You can use this parameter in combination with startIndex, to fetch specific number of ad groups from a list.
integerNInteger value.
Default = 0
Max = 100
Min = 1

Example: To return the first ten adGroups, set startIndex=0 and count=10

Headers

Header NameDescriptionRequiredValues
AuthorizationThe token will provide you the access to the API. It is same for all advertisers you access through the API.YPlease utilize the generated auth_token shared with you at the time of partner onboarding from the Getting Started Guide
Content-Typeapplication/jsonYn/a
WM_CONSUMER.IDWe will provide you the consumer ID to access the API. It is same for all advertisers you access through the API.   YPlease use the generated ConsumerId shared with you at the time of partner onboarding. Refer to the Getting Started Guide for more information
WM_SEC.AUTH_SIGNATUREAuth signature as an API key.YUse the signature generator code from Getting Started Guide to generate this value
WM_SEC.KEY_VERSIONWe will provide you with the KEY VERSION to access the API. It is same for all advertisers you access through the API.Y1
WM_CONSUMER.intimestampTimestamp for which the auth signature is generated. Use Unix epoch format for the timestamp.YUse the signature generator code from Getting Started Guide to generate this value

Sample Request

curl -X POST \ 'https://developer.api.us.stg.walmart.com/api-proxy/service/display/api/v1/api/v1/adGroups/list' \ --header 'Content-Type: application/json' \ --header 'Authorization: Bearer <auth_token>'
--header 'WM_SEC.AUTH_SIGNATURE: **************' \ --header 'WM_SEC.KEY_VERSION: 1' \ --header 'WM_CONSUMER.ID: adfwe-v23-faasd2r-afs-asdfqeff' \ --header 'WM_CONSUMER.intimestamp: 1565309779' \ --data ' { "advertiserId": 1, "campaignId": 1, "Filter[name]": ["string"], "Filter[status]": "string", "Filter[lastModifiedDate]": "string", "Filter[adGroupId]": [1, 2], "startIndex": 0, "count": 10 } ' 

Response

FieldDescriptionData TypePossible Values
totalResultsNumber of ad groups returned matching the filter criteriaIntegersuccess, failure
responseArray of ad group objects. Each object within the response field corresponds to a different ad group.Array

Response Object Fields

Each object within the response field corresponds to a different ad group.

FieldDescriptionData TypePossible Values
campaignIdID of the campaign the ad group belongs toInteger
adGroupIdInternal ID of the ad groupInteger
adGroupExtIdExternal ad server ID of the ad groupInteger
nameName of the ad groupString
statusStatus of the ad groupStringDRAFT, LIVE, SCHEDULED, PAUSED, COMPLETED, ARCHIVED
startDateAd group start date (ISO 8601 format)Date
endDateAd group end date (ISO 8601 format); returns 9999-12-31T00:00:00-05:00 for indefinite runDate
isInventoryAwareOpt in / opt out of inventory-aware delivery at the ad group levelBooleantrue, false
budgetTypeBudget typeStringDAILY, TOTAL
deliverySpeedPacing strategyStringFRONTLOADED, EVENLY
dailyBudgetDaily budget (if applicable)Double
totalBudgetTotal budget (if applicable)Double
rateTypePricing structureStringCPM
frequencyCapDayDaily frequency cap per userInteger
frequencyCapWeekWeekly frequency cap per userInteger
frequencyCapMonthMonthly frequency cap per userInteger
baseBidStarting bidDouble
maxBidMaximum bidDouble
targetingTargeting configuration for the ad group. Supports keywords, contextual, behavioral, or run-of-site (only one allowed), optionally combined with geo targetingObject[]
creationDateAd group creation timestamp (ISO 8601 format)Date
lastUpdatedDateLast modified timestamp (ISO 8601 format)Date
attributesSetOnAdGroupLevelIndicates whether budget and schedule are set at the ad group levelBooleantrue, false
creativeRotationModeCreative rotation strategyStringOPTIMIZE_PERFORMANCE, ROTATE_EVENLY
mediaTypeMedia type of the ad groupStringBANNER, VIDEO

Sample Response

{ "totalResults": 2, "response": [ { "campaignId": 1, "adGroupId": 1, "adGroupExtId": 1, "name": "string", "status": "string", "startDate": "string", "endDate": "string", "budgetType": "string", "deliverySpeed": "string", "dailyBudget": 0, "totalBudget": 0, "rateType": "string", "frequencyCapDay": 0, "frequencyCapWeek": 0, "frequencyCapMonth": 0, "baseBid": 0, "maxBid": 0, "targeting": { "and": [ { "behavioral": [ { "audienceType": "RETAIL", "attribute": "HISTORICAL", "id": 1, "name": "tropicana", "mappingType": "PRODUCT_CATEGORY" }, { "audienceType": "RETAIL", "attribute": "HISTORICAL", "id": 5, "name": "sprite", "mappingType": "PRODUCT_FAMILY" } ] }, { "geoTargets": [ { "id": 2, "name": "Alabama", "locationType": "STATE" }, { "id": 3, "name": "Alaska", "locationType": "STATE" }, { "id": 10, "name": "Abbeville", "locationType": "CITY" } ] } ] }, "creationDate": "string", "lastUpdatedDate": "string", "attributesSetOnAdGroupLevel": true, "creativeRotationMode": "string" }, { "campaignId": 1, "adGroupId": 2, "adGroupExtId": 2, "name": "string", "status": "string", "startDate": "string", "endDate": "string", "budgetType": "string", "deliverySpeed": "string", "dailyBudget": 0, "totalBudget": 0, "rateType": "string", "frequencyCapDay": 0, "frequencyCapWeek": 0, "frequencyCapMonth": 0, "baseBid": 0, "maxBid": 0, "targeting": { "and": [ { "behavioral": [ { "audienceType": "CATEGORY", "attribute": "HISTORICAL", "id": 1, "name": "tropicana", "mappingType": "PRODUCT_CATEGORY" }, { "audienceType": "CATEGORY", "attribute": "HISTORICAL", "id": 5, "name": "sprite", "mappingType": "PRODUCT_FAMILY" } ] }, { "geoTargets": [ { "zipCode": "35004" } ] } ] }, "creationDate": "string", "lastUpdatedDate": "string", "attributesSetOnAdGroupLevel": true, "creativeRotationMode": "string" } ]
}