Hi,

Once you have created audiences using the AddAudience.php 
<https://github.com/googleads/googleads-php-lib/blob/master/examples/AdWords/v201607/Remarketing/AddAudience.php>
 
example, you need to add a CampaignCriterion 
<https://developers.google.com/adwords/api/docs/reference/v201607/CampaignCriterionService.NegativeCampaignCriterion>
 of 
type CriterionUserList. Please note that a UserList can only be excluded 
from a Campaign. To actively target a UserList, you need to create a 
CriterionUserList 
<https://developers.google.com/adwords/api/docs/reference/v201607/AdGroupCriterionService.CriterionUserList>
 at 
the AdGroup level using the code below: 


$criterionUserList = new CriterionUserList();
$criterionUserList->userListId = $userListId;
$criterionUserList->type = "USER_LIST";
$adGroupCriterion = new BiddableAdGroupCriterion();
$adGroupCriterion->adGroupId = $adGroupId;
$adGroupCriterion->criterion = $criterionUserList;
$adGroupCriteria[] = $adGroupCriterion;
// Create operation.
$operation = new AdGroupCriterionOperation();
$operation->operand = $adGroupCriterion;
$operation->operator = 'ADD';
$operations[] = $operation;
$result = $adGroupCriterionService->mutate($operations);


The table provided here 
<https://developers.google.com/adwords/api/docs/appendix/criteria-usage> shows 
the options available for different criterion types at the campaign and ad 
group level. 

Regards,
Shwetha, AdWords API Team.
 

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and Google+:
https://googleadsdeveloper.blogspot.com/
https://plus.google.com/+GoogleAdsDevelopers/posts
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords 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 Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@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/59455b55-86b6-4a53-a8e3-7633bd71624b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to