Hi,
Hope this message finds you well.
I need some help applying user_list criteria to my ad_group. I keep getting
the error "AttributeError: Assignment not allowed to field "user_list" in
protocol message object."
def set_targeting(self, client, customer_id, ad_group_id, audience_id):
ad_group_service = client.get_service('AdGroupService', version='v2')
ad_group_criterion_service = client.get_service('AdGroupCriterionService',
version='v2')
ad_group_criterion_operations = client.get_type('AdGroupCriterionOperation',
version='v2')
ad_group_criterion = ad_group_criterion_operations.create
ad_group_criterion.ad_group.value = ad_group_service.ad_group_path(
customer_id, ad_group_id)
ad_group_criterion.type = client.get_type('CriterionTypeEnum', version='v2'
).USER_LIST
ad_group_criterion.user_list = audience_id
Any advice would be appreciated.
Thanks!
-Matt
--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 [email protected]
To unsubscribe from this group, send email to
[email protected]
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
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/adwords-api/427f0375-dc66-4fe7-9f7d-3d1c90fd90cb%40googlegroups.com.