how to set bid modifier to a placement in a ad group

18 views
Skip to first unread message

ken...@blvnp.com

unread,
Dec 7, 2017, 2:38:03 AM12/7/17
to AdWords API Forum
I am trying to set bid modifier to a placement in a ad group

    $placement = new Placement();
    $placement->setUrl('wordpress.com');

    $biddableAdGroupCriterion = new BiddableAdGroupCriterion();
    $biddableAdGroupCriterion->setAdGroupId(47069225942);
    $biddableAdGroupCriterion->setCriterion($placement);
    $biddableAdGroupCriterion->setBidModifier(1.5);

    // Create an ad group criterion operation and add it to the list.
    $biddableAdGroupCriterionOperation = new AdGroupCriterionOperation();
    $biddableAdGroupCriterionOperation->setOperand($biddableAdGroupCriterion);
    $biddableAdGroupCriterionOperation->setOperator(Operator::ADD);


    $operations[] = $biddableAdGroupCriterionOperation;

    $result = $adGroupCriterionService->mutate($operations);

Peter Oliquino

unread,
Dec 7, 2017, 3:59:27 AM12/7/17
to AdWords API Forum
Hi,

My apologies as I specialize more in Java instead of PHP. However, looking at your code, it appears already correct since you have specified the Placement criterion as the Criterion of the ad group and included a value for the BidModifier field. For more information,  you may also refer to our bidding guide and specifically to this section for adding bids at the ad group or ad group criterion level.

I hope this helps and feel free to write back for any further clarifications.

Thanks and regards,
Peter
AdWords API Team
Reply all
Reply to author
Forward
0 new messages