I am trying with below request.But it is giving internal error.


# Add the negative campaign criterion.

  negative_campaign_criterion_operand = {

      'xsi_type': 'NegativeCampaignCriterion',

      'campaignId': CAMPAIGN_ID,

      'criterion': {

          'xsi_type': 'CriterionUserInterest',

          'id': '80142'

      }

  }

  operations.append({

      'operator': 'ADD',

      'operand': negative_campaign_criterion_operand

  })


  # Make the mutate request.

  result = campaign_criterion_service.mutate(operations)




On Friday, October 25, 2019 at 2:46:20 PM UTC-4, Arnab Ganguly wrote:
>
> Hey Anthony,
> Thanks for your reply.Do we plan to support this for positive campaign as 
> well ?
> Regards,
> Arnab
>
> On Fri, Oct 25, 2019 at 2:37 PM Google Ads API Forum Advisor Prod <
> adsapiforumadvi...@gmail.com> wrote:
>
>> Hi Arnab,
>>
>> Thank you for reaching out. As seen here 
>> <https://developers.google.com/adwords/api/docs/appendix/targetingtypes#target_type_table>,
>>  
>> user interest criteria are only supported for negative criterion at the 
>> campaign level. You would do this through the CampaignCriterionService 
>> <https://developers.google.com/adwords/api/docs/reference/v201809/CampaignCriterionService>
>> . Here  
>> <https://developers.google.com/adwords/api/docs/samples/python/targeting#add-targeting-criteria-to-a-campaign>is
>>  
>> an example for adding supported criterion types to a campaign (or here  
>> <https://developers.google.com/google-ads/api/docs/samples/add-campaign-targeting-criteria#python>if
>>  
>> you're using Google Ads API).
>>
>> Regards,
>> Anthony
>> Google Ads API Team
>>
>>
>> ref:_00D1U1174p._5001UKOW98:ref
>>
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@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 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/96814195-d3d3-48f2-92ad-3d997b17003f%40googlegroups.com.

Reply via email to