Hi,
I'm getting the ERROR --> [RequestError.UNSUPPORTED_TYPE_IS_USED @
operations[0].operand.type; trigger:'PAGE_ONE_PROMOTED']
This is my PHP code for creating a campaing with PageOnePromotedBidding
private static function createBiddingStrategy(
AdWordsServices $adWordsServices,
AdWordsSession $session
) {
$biddingStrategyService = $adWordsServices->get($session,
BiddingStrategyService::class);
// Create a portfolio bidding strategy.
$biddingStrategy = new SharedBiddingStrategy();
$biddingStrategy->setName("Maximize Clicks " . uniqid());
$biddingStrategy->setType(PAGE_ONE_PROMOTED);
$biddingScheme = new PageOnePromotedBiddingScheme();
// Optionally set additional bidding scheme parameters.
$bidCeiling = new Money();
$bidCeiling->setMicroAmount(200);
$biddingScheme->setBidCeiling($bidCeiling);
$biddingScheme->setStrategyGoal(PageOnePromotedBiddingSchemeStrategyGoal::PAGE_ONE_PROMOTED);
$biddingScheme->setBidModifier(1);
$biddingStrategy->setBiddingScheme($biddingScheme);
// Create the bidding strategy operation.
$operation = new BiddingStrategyOperation();
$operation->setOperator(Operator::ADD);
$operation->setOperand($biddingStrategy);
$result = $biddingStrategyService->mutate([$operation]);
$newBiddingStrategy = $result->getValue()[0];
printf(
"Portfolio bidding strategy with name '%s' and ID %d of
type %s was created.\n",
$newBiddingStrategy->getName(),
$newBiddingStrategy->getId(),
$newBiddingStrategy->getType()
);
return $newBiddingStrategy;
}
Can somebody help me???
--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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/d505b560-fa2f-4807-973a-6f79153bd6f7%40googlegroups.com.