Bid management script for a Google Ads Shopping campaign

90 views
Skip to first unread message

lu

unread,
Sep 18, 2025, 4:40:52 AM (12 days ago) Sep 18
to Google Ads Scripts Forum
I try to write a bid management script for a  standard Google Shopping  campaign. Bids should be set at the product subgroup level. A product subgroup bid should be set depending on search impressions over the past 7 days. Is it real?

Google Ads Scripts Forum Advisor

unread,
Sep 18, 2025, 9:03:24 AM (12 days ago) Sep 18
to adwords...@googlegroups.com
Hi,

Thank you for reaching out to the Google Ads API support team.

Please be informed that it is possible to create a Google Ads script that sets bids at the product subgroup level based on search impressions over the past 7 days. I would recommend you refer to the guides Shopping campaigns, Bidding and the sample example to get more information on how Google Ads scripts let you manage bidding for your campaigns.

I hope this helps! Feel free to get back to us in case of any further queries.
 

Thanks,
 
Google Logo Google Ads Scripts Team

Feedback
How was our support today?

rating1    rating2    rating3    rating4    rating5
[2025-09-18 13:02:50Z GMT] This message is in relation to case "ref:!00D1U01174p.!500Ht01u6xCx:ref" (ADR-00333109)



lu

unread,
Sep 18, 2025, 9:52:41 AM (12 days ago) Sep 18
to Google Ads Scripts Forum
Hi team,
Thank you a lot for your answer. 
I wasn't able to create such a script. The script is not able to change the product group or subgroup bid. Only the ad group bid can be changed. Here I cannot find an example for the product groups or subgroups.

Google Ads Scripts Forum Advisor

unread,
Sep 18, 2025, 1:46:23 PM (11 days ago) Sep 18
to adwords...@googlegroups.com
Hi,

In order to investigate your issue further, kindly provide us with the following details:
  • Google Ads account ID / CID
  • Name of the affected script
  • If the script uses a spreadsheet, please provide a shareable link to the spreadsheet.
You can send the details via Reply privately to the author option, or direct private reply to this email.
 

Thanks,
 
Google Logo Google Ads Scripts Team

Feedback
How was our support today?

rating1    rating2    rating3    rating4    rating5

[2025-09-18 17:45:47Z GMT] This message is in relation to case "ref:!00D1U01174p.!500Ht01u6xCx:ref" (ADR-00333109)



lu

unread,
Sep 19, 2025, 2:32:24 AM (11 days ago) Sep 19
to Google Ads Scripts Forum
Hi,
Thanks for the feedback. 
999-818-1106, the script name is "For shopping".

Google Ads Scripts Forum

unread,
Sep 23, 2025, 4:53:10 AM (7 days ago) Sep 23
to Google Ads Scripts Forum

Hi,

I could see that you are using a “adGroup.productGroups()” method in the script and the method doesn’t support “getType()”. I would recommend that you refer to the “AdsApp.​ProductGroup” documentation for more information about the available methods. The condition “pg.getType() !== "UNIT"” cannot be used. Also it is only possible to set max cpc of a shopping product by using the method “setMaxCpc(maxCpc)” and “setCpc()” is not a valid method. I would recommend that you use the valid methods so that the script will work as intended.

I hope this helps! Feel free to get back to us for any further concerns.

Thanks,
Google Ads Scripts team

lu

unread,
Sep 23, 2025, 8:56:06 AM (7 days ago) Sep 23
to Google Ads Scripts Forum
Hi team,
Thank you for the answer. 
It seems that Impression share metric is not available at product group (divided by brand) level when working with a script. Is it true?

Sigurd Fabrin

unread,
Sep 24, 2025, 5:33:15 AM (6 days ago) Sep 24
to Google Ads Scripts Forum
I would very much advise against using any of those ratios that you cannot verify for bidding purposes. The data does not show what Google suggests it does.

Example:

Even excluded product groups with 0 impressions, can have a decent impression share, absolute top position share etc

Screenshot 2025-09-24 at 11.17.05.png


Sigurd

lu

unread,
Sep 24, 2025, 8:01:52 AM (6 days ago) Sep 24
to Google Ads Scripts Forum
Hi,
Thank you a lot for the feedback. 
It's not a problem to add a condition to not change the bid if there were no impressions.
But we are still curious if the Impression share metric is available at product group level when working with a script.

Sigurd Fabrin

unread,
Sep 24, 2025, 8:54:38 AM (6 days ago) Sep 24
to Google Ads Scripts Forum
"It's not a problem to add a condition to not change the bid if there were no impressions"

Why would it be wrong when a product group has 0 impressions but correct in all other cases?
The problem with these ratios is that only Google has the underlying data, so you cannot confirm. And when it's demonstrably wrong sometimes...

"[...] we are still curious if the Impression share metric is available at product group level when working with a script"

At least it's available in api reports that you can access via scripts



Sigurd

Google Ads Scripts Forum Advisor

unread,
Sep 24, 2025, 10:45:37 AM (6 days ago) Sep 24
to adwords...@googlegroups.com
Hi,

As mentioned earlier, you can't get the Impression Share metric directly at the product group level using Google Ads Scripts.

I hope this helps!
 

Thanks,
 
Google Logo Google Ads Scripts Team

Feedback
How was our support today?

rating1    rating2    rating3    rating4    rating5

[2025-09-24 14:44:59Z GMT] This message is in relation to case "ref:!00D1U01174p.!500Ht01u6xCx:ref" (ADR-00333109)



Reply all
Reply to author
Forward
0 new messages