Hello, i'm receive 500 internal error while trying to add topic exclusions
using Ads API
here is part of the code:
campaign_service = client.get_service('CampaignService', version='v1')
campaign_criterion_service = client.get_service('CampaignCriterionService',
version='v1')
campaign_criterion_operation =
client.get_type('CampaignCriterionOperation', version='v1')
campaign_criterion = campaign_criterion_operation.create
campaign_criterion.campaign.value =
campaign_service.campaign_path(customer_id, campaign_id)
campaign_criterion.negative.value = True
for category in ['Arts&Entertainment', 'Offbeat']:
topic_path = campaign_criterion.topic.path.add()
topic_path.value = category
campaign_criterion_service.mutate_campaign_criteria(customer_id,
[campaign_criterion_operation])
also it would great to know if there is a better solution, like
.extend(['Arts&Entertainment', 'Offbeat']), because .extend doesn't work in
this case
Thanks!
--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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/218b816b-8133-4491-b4da-6f6a464e3008%40googlegroups.com.