Retrieve Audit Snapshots

Description: 

You can retrieve audit snapshot by providing snapshot id and advertiser id for an advertiser.

Note:

  • The output is generated in a “zip/gzip” file depending upon format chosen
  • The file type in zip file will be JSON
  • You will receive null value for all the entity types except the one whose audit snapshot is being retrieved
  • auditVersions is history of different audit events on this entity whose audit snapshot is being retrieved
  • auditData is the data that you receive in response when you perform GET operation on entity in question

URL: GET/api/v1/snapshot

Sample Request

curl -X GET\
"https://developer.api.stg.walmart.com/api-proxy/service/WPA/Api/v1/api/v1/snapshot?advertiserId=600001&snapshotId=1" \
--header "Authorization: Bearer <auth_token>\ --header "accept: application/json”\
--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" \

Response

ElementDescriptionType
snapshotIdId of the snapshot to be retrievedstring
jobStatusIt is an indicator to confirm status of snapshot generation. The possible values of jobStatus are: pending, processing, done, failed, expiredstring
detailsURL of the snapshot file once jobStatus reaches to state “donestring
codeThe response code can have following values:   success, failurestring

Sample Response

[ { "code" : "success", "snapshotId": "12", "details" : "https://advertising.walmart.com/file/30", " jobStatus ": "done" }
]

Example of the content of audit snapshot with snapshot id “12”. The file format is “json”.

{ "campaigns": null, "adGroups": null, "adItems": null, "bidMultipliers": null, "placements": null, "sbaProfiles": null, "adGroupMedia": null, "categories": null, "keywords": [ { "entityId": 600001, "auditVersions": [ { "updatedAt": "2020-07-03T10:29:57", "modifier": "API User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600001, "state": "enabled", "keywordText": "keyword 1 normalized", "status": "rejected", "matchType": "exact", "bid": 5.9 } }, { "updatedAt": "2020-07-03T10:30:57", "modifier": "API User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600001, "state": "enabled", "keywordText": "keyword 1 normalized", "status": "rejected", "matchType": "exact", "bid": 5.82 } }, { "updatedAt": "2020-07-03T10:35:57", "modifier": "AdOps User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600001, "state": "enabled", "keywordText": "keyword 1 normalized", "status": "rejected", "matchType": "exact", "bid": 5.81 } }, { "updatedAt": "2020-07-03T10:29:57", "modifier": "API User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600001, "state": "enabled", "keywordText": "keyword 1 normalized", "status": "pending", "matchType": "broad", "bid": 5.85 } }, { "updatedAt": "2020-07-03T11:29:57", "modifier": "API User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600001, "state": "enabled", "keywordText": "keyword 1 normalized", "status": "pending", "matchType": "exact", "bid": 6.66 } }, { "updatedAt": "2020-07-03T11:35:57", "modifier": "API User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600001, "state": "enabled", "keywordText": "keyword 1 normalized", "status": "pending", "matchType": "phrase", "bid": 5.85 } }, { "updatedAt": "2020-07-03T11:40:57", "modifier": "API User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600001, "state": "enabled", "keywordText": "keyword 1 normalized", "status": "pending", "matchType": "exact", "bid": 5.85 } } ] }, { "entityId": 600003, "auditVersions": [ { "updatedAt": "2020-07-04T01:29:57", "modifier": "API User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600003, "state": "enabled", "keywordText": "keyword 3 normalized", "status": "pending", "matchType": "broad", "bid": 2.5 } }, { "updatedAt": "2020-07-04T02:29:57", "modifier": "API User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600003, "state": "archived", "keywordText": "keyword 3 normalized", "status": "approved", "matchType": "broad", "bid": 2.5 } }, { "updatedAt": "2020-07-04T03:29:57", "modifier": "AdOps User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600003, "state": "enabled", "keywordText": "keyword 3 normalized", "status": "approved", "matchType": "broad", "bid": 2.5 } }, { "updatedAt": "2020-07-04T04:29:57", "modifier": "API User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600003, "state": "enabled", "keywordText": "keyword 3 normalized", "status": "pending", "matchType": "broad", "bid": 2.5 } }, { "updatedAt": "2020-07-04T05:29:57", "modifier": "API User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600003, "state": "archived", "keywordText": "keyword 3 normalized", "status": "pending", "matchType": "broad", "bid": 2.5 } }, { "updatedAt": "2020-07-04T06:29:57", "modifier": "API User", "auditData": { "campaignId": 600001, "adGroupId": 600001, "keywordId": 600003, "state": "enabled", "keywordText": "keyword 3 normalized", "status": "pending", "matchType": "broad", "bid": 2.5 } } ] } ]
}