Adding adgroup Audience segments (Affinity + in-market) Observation

100 views
Skip to first unread message

Patrick

unread,
Mar 17, 2022, 6:37:35 AM3/17/22
to Google Ads API and AdWords API Forum
Hi,

Are there any guidelines on how to add specific affinity and In-market audience segments to an adgroup in observation mode with the api?

In the UI they are under Audience > Edit audience segments.  Then from there you can choose Observation > "What their interests and habits are" (Affinity), etc.

Thanks

Patrick

unread,
Mar 17, 2022, 11:16:59 AM3/17/22
to Google Ads API and AdWords API Forum
Hi, I think I got this working by using an AdGroupCriterion and setting the UserInterestCategory, (snippet of php code below)

...
$adGroupCriterion = new AdGroupCriterion();
$userInterestInfo = new UserInterestInfo();
$userInterestInfo->setUserInterestCategory(ResourceNames::forUserInterest($customerId, $interestId));
$adGroupCriterion->setUserInterest($userInterestInfo);
$adGroupCriterion->setAdGroup(ResourceNames::forAdGroup($customerId, $adGroupId));
...

Does that sound right?
Thanks

Ngon Nguyen

unread,
Mar 17, 2022, 8:09:18 PM3/17/22
to gapis...@gmail.com, Google Ads API and AdWords API Forum
Chào mừng bạn đến với bảng nhớ tạm của Gboard, bất kỳ văn bản nào bạn sao chép sẽ được lưu tại đây.Sử dụng biểu tượng chỉnh sửa để ghim, thêm hoặc xóa đoạn.Nhấn vào một đoạn để dán vào hộp văn bản.Chạm và giữ một đoạn để ghim đoạn đó. Các đoạn đã bỏ ghim sẽ bị xóa sau 1 giờ.

Vào 17:37, Th 5, 17 thg 3, 2022 Patrick <gapis...@gmail.com> đã viết:
--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
 
You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwor...@googlegroups.com
To unsubscribe from this group, send email to
adwords-api...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
---
You received this message because you are subscribed to the Google Groups "Google Ads API and AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adwords-api...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/adwords-api/6e871faf-78ca-4e21-bec5-f3a404042b7bn%40googlegroups.com.

Google Ads API Forum Advisor

unread,
Mar 17, 2022, 9:29:55 PM3/17/22
to gapis...@gmail.com, adwor...@googlegroups.com
Hi Patrick,

Thank you for posting your concern.

I am afraid that there is no sample code for targeting user interest (Affinity and in-market) at ad group level. However, I would suggest you utilize this sample code as your base code because the setting of user interest should be similar to the sample implementation. Also, since your concern is more code related, I would suggest reaching out to the author of the PHP client library via this link as they are more equipped to this topic.

Furthermore, it appears that you are using the correct service, operation and object for associating user interest at ad group level.

As for your question on how to add the criteria as observation, set bid_only to true, the targeting setting will be set to "Observation", and the criteria won't be used to restrict traffic, but will allow you to bid differently for different users on your lists. Setting bid_only to false sets targeting setting to "Targeting" and enables the criteria to restrict ad group traffic only to users on the targeted list.

Let me know if you have further questions.

Regards,
Google Logo
Ernie John
Google Ads API Team
 


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