Getting adwords history using awql

402 Views Asked by At

I am building an app where users can authorize and we take their data daily and also on initial authorization we pull the last 365 days of data.

So far I can pull data, but it gives me totals of the last 365 days, I wanted to know if adwords api has any features like analytics api in which you can set dimensions to grab the data for each day of the 365 days.

$reportQuery = 'SELECT Date, CampaignId, AdGroupId, Id, Impressions, Clicks, Cost, Conversions, CostPerConversion FROM CRITERIA_PERFORMANCE_REPORT DURING 20160101, 20160702';

$reportUtils = new ReportUtils();
$data = $reportUtils->DownloadReportWithAwql($reportQuery, null, $user, "CSV");
1

There are 1 best solutions below

0
Stewart_R On

If you simply include Date in your AWQL query then adwords will give you the data segmented by date.

details of the segments, metrics and attributes available are listed here: https://developers.google.com/adwords/api/docs/appendix/reports/criteria-performance-report#date