Get customer_id from campaign_id

18 views
Skip to first unread message

Mads Refer

unread,
Jan 25, 2022, 10:00:21 AM1/25/22
to Google Ads API and AdWords API Forum
Is it possible to retrieve the customer id through the Google Ads API knowing only one of its campaign id's? I believe that the opposite is possible using GoogleAdsService and search_stream. 

Thanks in advance

Google Ads API Forum Advisor

unread,
Jan 25, 2022, 9:09:58 PM1/25/22
to mads....@business-science.dk, adwor...@googlegroups.com
Hi Mads,

While it is possible to include the customer attributes in the SELECT query for the campaign report (see Attributed resources section of the linked document) and use the campaign.id as filter, the API request itself would already require that you know and specify the customer_id of the client account where the said campaign is associated to.

That being said, you should be able to instead, retrieve a list of campaign IDs if you already know the customer_id of the account you wish to pull campaign details from.

Best regards,

Google Logo
Peter Laurence Napa Oliquino
Google Ads API Team
 


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