Which API method can fetch the resource IDs for a campaign?

28 views
Skip to first unread message

Stiofán Ó Riain

unread,
Feb 28, 2022, 6:22:37 AM2/28/22
to Google Ads API and AdWords API Forum
Hi there

Currently I am using CampaignCriterionOperation and mutateCampaignCriteria to add IPs to campaigns' IP Exclusion List.

After adding an IP to a campaign's IP Exclusion List, I receive the resource ID as a response and I save it in my database.

My concern is if my database crashes and I lose the data. How can I get a list of the resource IDs for a particular campaign?

In other words, what API call can I make to fetch all the resource IDs of the IPs in a campaign's IP Exclusion List?

Thanks

Google Ads API Forum Advisor

unread,
Feb 28, 2022, 11:58:52 PM2/28/22
to off...@countyjobs.ie, adwor...@googlegroups.com

Hello Stiofán,

Thank you for reaching out to us.

With regard to retrieving those campaign criterion, you can use the campaign_criterion view. You can then filter by campaign and its type (IP_BLOCK) to only capture the Exclusion list.

Regards,

Google Logo
Mark Kevin
Google Ads API Team
 


ref:_00D1U1174p._5004Q2XjtBx:ref
Reply all
Reply to author
Forward
0 new messages