Get parent campaign name of ad group feed item target

23 views
Skip to first unread message

Yuxiang Wang

unread,
Jul 18, 2019, 10:56:25 PM7/18/19
to AdWords API and Google Ads API Forum
Hi,

For feed_item_target which target type is ad group, how could we get the parent campaign name of this ad group?
I tried to select campaign.name, but seems it will return nothing.

Really appreciate your help~

Thanks,
Marcus

Yuxiang Wang

unread,
Jul 18, 2019, 10:58:11 PM7/18/19
to AdWords API and Google Ads API Forum
Just to clarify, I'm using Google Ads API.

Google Ads API Forum Advisor Prod

unread,
Jul 19, 2019, 1:35:15 PM7/19/19
to wangyux...@gmail.com, adwor...@googlegroups.com
Hi Wang, 

You may use the feed_item_target.campaign and feed_item_target.ad_group to pull the campaign and ad group details together. Please find the sample report query below as a reference:

"SELECT campaign.id, feed_item_target.ad_group, feed_item_target.campaign FROM feed_item_target"

Could you please give this a try and let us know if you have any issues?

Thanks,
Bharani, Google Ads API Team



ref:_00D1U1174p._5001U8MIxg:ref

Yuxiang Wang

unread,
Jul 19, 2019, 10:24:05 PM7/19/19
to AdWords API and Google Ads API Forum
Thanks for your reply!

Seems this query not works for me. feed_item_target.ad_group will return a string as "customers/{customer.id}/ad_group/{ad_group.id}". I can only extract the ad_group.id from this field. But I just can't  get the parent campaing name of this ad_group from it.

In AdWords API, there is a simply way: just to call FeedItemAdGroupTarget.parentCampaignName. (refer to https://developers.google.com/adwords/api/docs/reference/v201809/FeedItemTargetService.FeedItemAdGroupTarget). Is there a way to do it in Google Ads API?

Thanks again for your help!



On Friday, July 19, 2019 at 10:56:25 AM UTC+8, Yuxiang Wang wrote:

Google Ads API Forum Advisor Prod

unread,
Jul 22, 2019, 2:04:20 PM7/22/19
to wangyux...@gmail.com, adwor...@googlegroups.com
Hello Wang, 

Can you make sure that you are also including the feed_item_target.campaign in your query? This will return the specific campaign details. If you're having an issue, could you please share the report query along with the CID using Reply privately to author option?
Reply all
Reply to author
Forward
0 new messages