Remove negative keywords

39 views
Skip to first unread message

fabiosil...@gmail.com

unread,
Apr 16, 2019, 6:10:20 AM4/16/19
to AdWords API and Google Ads API Forum
Is there any AdGroupCriterionField that removes the negative keywords of a selector?

I'm using this code:

Selector selector = builder
                .fields(
                    AdGroupCriterionField.Id,
                    AdGroupCriterionField.CriteriaType,
                    AdGroupCriterionField.KeywordMatchType,
                    AdGroupCriterionField.KeywordText,
                    AdGroupCriterionField.CriteriaCoverage)
                .orderAscBy(AdGroupCriterionField.KeywordText)
                .offset(offset)
                .limit(PAGE_SIZE)
                .in(AdGroupCriterionField.AdGroupId, adGroupId.toString())
                .in(AdGroupCriterionField.CriteriaType, "KEYWORD")
                .equals(AdGroupCriterionField.Status, "ENABLED")
                .build();

I need to take off the selector those keywords which are declared as negative.



googleadsapi...@google.com

unread,
Apr 16, 2019, 10:09:44 AM4/16/19
to fabiosil...@gmail.com, AdWords API and Google Ads API Forum
Hi,

You can add a filter on the criterionUse to either only include BIDDABLE or exclude NEGATIVE. 

Cheers,
Anthony
Google Ads API Team


=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
    https://ads-developers.googleblog.com/search/label/google_ads_api
    https://developers.google.com/adwords/api/community/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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+unsubscribe@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+unsubscribe@googlegroups.com.
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/3402e4d0-342f-41a2-bbb7-6704e4109332%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages