Get all ads, keywords and sitelinks serving

58 views
Skip to first unread message

Danny

unread,
Feb 23, 2017, 1:29:25 PM2/23/17
to AdWords API Forum
Hi

Is there a way to get all ads, keywords and sitelinks serving without checking whether the campaign and adgroup is enabled?

Currently the only way I can think of is to get all enabled keywords (for example), and retrieve the adgroup and campaign (based on the IDs) it belongs to and check whether the status is enabled. However, let's say if you have like thousands of keywords, this seems pretty inefficient and involves a lot of API calls.

I'm wondering if there's such a thing where you can filter out the entities that are serving (keyword AND adgroup AND campaign is enabled) in a single API call?

Shwetha Vastrad (AdWords API Team)

unread,
Feb 23, 2017, 3:09:14 PM2/23/17
to AdWords API Forum
Hi Danny,

You can use AdWords API reports instead to retrieve Adskeywords and sitelinks from the corresponding report types and query for rows where the CampaignStatus and AdGroupStatus is ENABLED using predicates. This way you wont have to make a second request to check the AdGroup and Campaign status. This guide provides more details on using the AdWords API to download reports. The DownloadCriteriaReport Java example demonstrates how to download a Criteria Performance Report. Example code in other languages is available here
 
Regards,
Shwetha, AdWords API Team.

Danny

unread,
Feb 23, 2017, 4:39:30 PM2/23/17
to AdWords API Forum
Thanks Shwetha.

Seems like using this approach I'll need to download a file - something I'd like to avoid.

Is there a way to do this and get a JSON response instead?

Shwetha Vastrad (AdWords API Team)

unread,
Feb 23, 2017, 5:19:13 PM2/23/17
to AdWords API Forum
Hi Danny,

I'm afraid AdWords API reports can only be downloaded in the formats listed here. You can retrieve the reports in one of the supported formats and use a parser to convert to JSON in your application. 
Reply all
Reply to author
Forward
0 new messages