Hi Costantin,

You may refer to the GetCampaignTargetingCriteria 
<https://developers.google.com/adwords/api/docs/samples/python/targeting#get-all-campaign-criteria>
 code 
example in Python (available in other languages) in order to query a list 
of campaign criteria based on PROXIMITY criterion type 
<https://developers.google.com/adwords/api/docs/reference/v201806/CampaignCriterionService.Criterion#type>
 for 
a specified campaign. 

Let me know if you have any further concern.

Thanks,
Luis
AdWords API Team

On Friday, November 2, 2018 at 9:12:01 PM UTC+8, cosbgn wrote:
>
> Hello,
>
> I'm adding different locations programmatically to a particular campaign. 
> However this does not edit the current locations but instead simply adds 
> new ones on top.
> I'm now trying to first remove all existing locations and then add the new 
> ones.
>
> My code looks like this:
>
>  for criterion_id in criterions_to_remove:
>  operations.append({
>  'operator': 'REMOVE',
>  'operand': {'xsi_type': 'CampaignCriterion', 'campaignId': campaign_id, 
> 'criterion': {'id': criterion_id }}
>  })
>  result = campaign_criterion_service.mutate(operations)
>
> However, I'm now sure how can I query a list of criterions_to_remove for 
> a specific campaign. How can I get all criterion_ids of a campaign, 
> starting with the campaign ID?
>
> The criterions I add to the campaign are: 'xsi_type': 'Proximity'
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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].
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/4481000c-1d9e-4984-bec8-6e2b2ac41c40%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
  • ... cosbgn
    • ... 'Luis Xander Talag (AdWords API Team)' via AdWords API and Google Ads API Forum

Reply via email to