I am trying to fetch top performing ads using attributes like impressions, clickx etc
I tried google adwords reporting api first, but reporting api do not support ORDER BY
clause. And I couldn't find any AdsService
in the service list. Closest I could find AdGroupsAd
which seeems do not have attributes like impressions clicks, etc. Am I missing something ?
query = "SELECT Headline,AdGroupName,AdType,CampaignName, Clicks FROM AD_PERFORMANCE_REPORT ORDER BY Clicks"
CSV.parse(report_utils.download_report_with_awql(query, 'CSV'))
AdwordsApi::Errors::ReportXmlError: HTTP code: 400, error type: 'QueryError.ORDER_BY_CLAUSE_NOT_SUPPORTED', trigger: '', field path: ''