Hello,
I am unable to change the CpcBid value of my adgroup using API.
Here is my python function which tries to change the cpc bid of a particular adgroup
-- I am unable to change the CpcBid value of my adgroup using API.
Here is my python function which tries to change the cpc bid of a particular adgroup
def change_bid(client, myAdGroupID, myVal):
service = client.GetService('AdGroupService', version='v201605')
# Create operations.
operations = [
{
'operator': 'SET',
'operand': {
'id' : myAdGroudID,
'biddingStrategyConfiguration' : {
'biddingStrategyType' : 'MANUAL_CPC',
'bids' : [{
'Bids.Type' : 'CpcBid',
'bid': {
'ComparableValue.Type' : 'Money',
'microAmount' : myVal
},
'cpcBidSource' : 'ADGROUP'
}]
}
}
}
]
#Make Changes
service.mutate(operations)
I am following the API and I have come up with above operation structure by seeing the result of 'get' . Following is the sample
Help is appreciated :)
Thanks!
I am following the API and I have come up with above operation structure by seeing the result of 'get' . Following is the sample
(AdGroup){
id = 26354412271
campaignId = 368972071
campaignName = "rm_construction-contractor_india_day-0-1"
name = "all_construction-contractor"
biddingStrategyConfiguration =
(BiddingStrategyConfiguration){
biddingStrategyType = "MANUAL_CPC"
bids[] =
(CpcBid){
Bids.Type = "CpcBid"
bid =
(Money){
ComparableValue.Type = "Money"
microAmount = 5000000
}
cpcBidSource = "ADGROUP"
},
}
baseCampaignId = 368972071
baseAdGroupId = 26354412271
}
I just want to change the value of MicroAmount
Right now I am getting the error : Type not found: 'bid'
I just want to change the value of MicroAmount
Right now I am getting the error : Type not found: 'bid'
Help is appreciated :)
Thanks!
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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+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 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/1803224e-3ff3-4e71-aa54-e0041c3bd484%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
No comments:
Post a Comment