# Set the bidding strategy and budget.
campaign.manual_cpc.enhanced_cpc_enabled.value = False
campaign.campaign_budget.value = campaign_budget_response.results[0].resource_name
campaign.bidding_strategy_type = client.get_type('BiddingStrategyTypeEnum', version='v1').MANUAL_CPM
# Set the campaign network options.
campaign.network_settings.target_google_search.value = False
campaign.network_settings.target_search_network.value = False
campaign.network_settings.target_content_network.value = True
campaign.network_settings.target_partner_search_network.value = False
When I run this, the program runs fine, but when I open the UI , it shows me the "Bidding" set to "Manual CPC".
Could you please check on the same and revert ? Is it some known issue with the API ?
Thanks and Regards,
Vinutha Nayak
campaign.manual_cpc.enhanced_cpc_enabled.value = False
campaign.bidding_strategy_type = client.get_type('BiddingStrategyTypeEnum', version='v1').MANUAL_CPM
1 . One is false and one is true, how are both getting set in the code shared earlier ?
2. Also, when bidding_strategy can be one of the different things, how can a API allow 2 options to be set ? wouldn't it flag an error ?
In any case, I would like to know how MANUAL_CPC is getting set, considering I am doing no such thing in the code.
Thanks and Regards,
Vinutha Nayak
campaign.campaign_bidding_strategy
.manual_cpm = "ManualCpm".
campaign.manual_cpm = "ManualCpm".
I tried to set as above, but both are not working. I want to set Standard Manual CPM bidding strategy.
Thanks and Regards,
Vinutha Nayak
Hello Vinutha,
You will be able to set the Manual CPM bid strategy using the ManualCpm builder. Please find the code snippet below in Java as a reference:
Campaign.newBuilder()
.setName(StringValue.of("Interplanetary Cruise #" + System.currentTimeMillis()))
.setAdvertisingChannelType(AdvertisingChannelType.DISPLAY)
.setStatus(CampaignStatus.PAUSED)
.setManualCpm(ManualCpm.newBuilder().build())
.setCampaignBudget(StringValue.of(budgetResourceName))
.setNetworkSettings(networkSettings)
.setStartDate(StringValue.of(new DateTime().plusDays(1).toString("yyyyMMdd")))
.setEndDate(StringValue.of(new DateTime().plusDays(30).toString("yyyyMMdd")))
.build();