How to get the products ID, Impressions and Click from Google Ads using Ads Script?

657 views
Skip to first unread message

Marcus D'Suza

unread,
Dec 23, 2021, 9:41:13 AM12/23/21
to Google Ads Scripts Forum
I am working with Google Ads Script, please do not mind me as I am a novice to the domain. I was reading the Google Ads Scrips Documentation and couldn't find any method or class that would allow me to retrieve information (stats) about all products in the current Ads Account. 

What might be the best approach to get the list of all products and with all their statistics? Also, I went through existing questions here on the forum, StackOverflow, and other online communities but couldn't find anything helpful. 
Message has been deleted

Google Ads Scripts Forum Advisor

unread,
Dec 23, 2021, 10:50:17 PM12/23/21
to adwords...@googlegroups.com
Hi Marcus,

Thanks for reaching out. Harry here, from the Google Ads Scripts Team.

Products from the Merchant Center or your Shopping Campaigns are not directly supported in Google Ads Scripts but you can retrieve ProductAds, ShoppingCampaigns and etc. You would have to either use the Shopping Content Service or pull one of the following reports to meet your requirement. Thanks,
Google Logo
Harry Cliford Rivera
Google Ads Scripts Team
 


ref:_00D1U1174p._5004Q2TkCeT:ref

Marcus D'Suza

unread,
Dec 24, 2021, 9:11:29 AM12/24/21
to Google Ads Scripts Forum
I appreciate your response, Harry. So, it is not possible to do this with Javascript, right? I will need Java/Python/PHP/PERL/RUBY/.NET to call the four mentioned Reports is Adwords API? 

If so, would I be able to get statistics from the Google Merchent Center? By statistics, I meas the impression, clicks and other details associated with individual product using the Shopping Content Service in Apps Script. 

Please respond back as I am stuck with the process. Thank you 

Marcus

Marcus D'Suza

unread,
Dec 24, 2021, 6:07:57 PM12/24/21
to Google Ads Scripts Forum
I wrote this script to get the product impressions, clicks, and ctr from the Google Merchant Account. So fat, it is going well but I am facing issue if  I want to retrieve any additional metrics as mentioned here in Reports.Search Endpoint. It only allows me to get the ''Impressions, Clicks and CTR with offer_id". In addition to that, I only get back products metrics with one of the three mentioned metrics set to value other than 0, and don't get the other 113 products with zero impressions, clicks and ctr in my account.

Also, does the offer_id mean the product Id? I am not sure how the Report.Search distinguishes individual products and their statistics. I really would appreciate your response. 

Best, 
marcus

Google Ads Scripts Forum Advisor

unread,
Dec 27, 2021, 4:41:32 AM12/27/21
to adwords...@googlegroups.com
Hello,

I work along with Harry. Thank you for getting back to us.

With regard to your concern, unfortunately, we cannot provide an in-depth insight on Adwords API as this is out of scope to our team. You may want to check this out with AdWords API team via this forum for further assistance.  As per the offer_id field, it it the Offer/item ID of the product.

Regards,
Google Logo
Teejay Wennie Pimentel
Google Ads Scripts Team
 


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