/v2/advertisers/{advertiserId}/reports/ad-groups.csv
POST
https://<pcm-domain>/v2/advertisers/{advertiserId}/reports/ad-groups.csv
Path Parameters
- advertiserIdinteger<int32>requiredFormatint32
Query Parameters
- localestring
Body Parameters
- bodyV2AdvertiserAdGroupReportRequestrequired
- filtersFilterValuesAdvertiserAdGroupReportFilterField[]
- fieldstring<CAMPAIGN_NAME | AD_GROUP_NAME | AD_GROUP_TYPE>AllowedCAMPAIGN_NAMEAD_GROUP_NAMEAD_GROUP_TYPE
- valuesobject[]
- startDatestring<date>requiredFormatdate
- endDatestring<date>requiredFormatdate
- attributionProfilestring<IMP_1_DAY_CLK_14_DAYS | IMP_1_DAY | CLK_14_DAYS>AllowedIMP_1_DAY_CLK_14_DAYSIMP_1_DAYCLK_14_DAYS
- pageinteger<int32>Formatint32Minimum0Maximum1000
- limitinteger<int32>Formatint32Minimum1Maximum10000
- sortTypestring<ASC | DESC>AllowedASCDESC
- dateBreakdownboolean
- orderBystring<CAMPAIGN_NAME | AD_GROUP_NAME | DATE | IMPRESSIONS | CLICKS | LOADS | CONVERSIONS | UNITS_SOLD | CLICK_THROUGH_RATE | CONVERSION_RATE | CONVERSION_VALUE | AD_SPEND_REVENUE | COST_PER_CLICK | COST_PER_MILLE | IMPRESSIONS_COST_PER_MILLE | LOADS_COST_PER_MILLE | RETURN_ON_AD_SPEND>AllowedCAMPAIGN_NAMEAD_GROUP_NAMEDATEIMPRESSIONSCLICKSLOADSCONVERSIONSUNITS_SOLDCLICK_THROUGH_RATECONVERSION_RATECONVERSION_VALUEAD_SPEND_REVENUECOST_PER_CLICKCOST_PER_MILLEIMPRESSIONS_COST_PER_MILLELOADS_COST_PER_MILLERETURN_ON_AD_SPEND
Responses
200
- StreamingResponseBody
401
403
404
- ExceptionResponse
- messagesstring[]
422
- ExceptionResponse
- messagesstring[]
curl
curl --request POST \
--url https://<pcm-domain>/v2/advertisers/{advertiserId}/reports/ad-groups.csv \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data '{
"startDate": "",
"endDate": ""
}'javascript
var myHeaders = new Headers();
myHeaders.append("accept", "application/json");
myHeaders.append("content-type", "application/json");
var raw = JSON.stringify({
"startDate": "",
"endDate": ""
});
var requestOptions = {
method: 'POST',
headers: myHeaders,
body: raw,
redirect: 'follow'
};
fetch("https://<pcm-domain>/v2/advertisers/{advertiserId}/reports/ad-groups.csv", requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));ruby
require "uri"
require "json"
require "net/http"
url = URI("https://<pcm-domain>/v2/advertisers/{advertiserId}/reports/ad-groups.csv")
https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true
request = Net::HTTP::Post.new(url)
request["accept"] = "application/json"
request["content-type"] = "application/json"
request.body = JSON.dump({
"startDate": "",
"endDate": ""
})
response = https.request(request)
puts response.read_body
python
import requests
import json
url = "https://<pcm-domain>/v2/advertisers/{advertiserId}/reports/ad-groups.csv"
payload = json.dumps({
"startDate": "",
"endDate": ""
})
headers = {
'accept': 'application/json',
'content-type': 'application/json'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text)
200
// OK
{}401
// Unauthorized
403
// Forbidden
404
// Not Found
{
"messages": [
""
]
}422
// Unprocessable Entity
{
"messages": [
""
]
}