Con gli asset e il budget prerequisiti, ora è possibile creare la campagna.
Le campagne Performance Max hanno un
AdvertisingChannelType
di PERFORMANCE_MAX
. Non deve essere impostato alcun AdvertisingChannelSubType
.
Le uniche strategie di offerta supportate sono:
Se non monitori i valori e se tutte le conversioni hanno la stessa importanza, utilizza la strategia di offerta
MaximizeConversions
. È possibile impostare un CPA target (costo per azione) facoltativo. Scopri di più.Se monitori i valori insieme alle conversioni, imposta la strategia di offerta
MaximizeConversionValue
. Può essere impostato un ROAS target (ritorno sulla spesa pubblicitaria) facoltativo. Scopri di più.
Le strategie di offerta di portafoglio
create utilizzando
BiddingStrategyService
non sono
supportate dalle campagne Performance Max. Anziché creare più campagne
in una strategia di offerta di portafoglio, utilizza meno campagne e più
gruppi di asset.
Java
/** Creates a MutateOperation that creates a new Performance Max campaign. */ private MutateOperation createPerformanceMaxCampaignOperation( long customerId, boolean brandGuidelinesEnabled) { Campaign performanceMaxCampaign = Campaign.newBuilder() .setName("Performance Max campaign #" + getPrintableDateTime()) // Sets the campaign status as PAUSED. The campaign is the only entity in // the mutate request that should have its status set. .setStatus(CampaignStatus.PAUSED) // All Performance Max campaigns have an advertising_channel_type of // PERFORMANCE_MAX. The advertising_channel_sub_type should not be set. .setAdvertisingChannelType(AdvertisingChannelType.PERFORMANCE_MAX) // Bidding strategy must be set directly on the campaign. // Setting a portfolio bidding strategy by resource name is not supported. // Max Conversion and Maximize Conversion Value are the only strategies // supported for Performance Max campaigns. // An optional ROAS (Return on Advertising Spend) can be set for // maximize_conversion_value. The ROAS value must be specified as a ratio in // the API. It is calculated by dividing "total value" by "total spend". // For more information on Maximize Conversion Value, see the support // article: http://support.google.com/google-ads/answer/7684216. // A targetRoas of 3.5 corresponds to a 350% return on ad spend. .setMaximizeConversionValue( MaximizeConversionValue.newBuilder().setTargetRoas(3.5).build()) // Sets the Final URL expansion opt out. This flag is specific to // Performance Max campaigns. If opted out (True), only the final URLs in // the asset group or URLs specified in the advertiser's Google Merchant // Center or business data feeds are targeted. // If opted in (False), the entire domain will be targeted. For best // results, set this value to false to opt in and allow URL expansions. You // can optionally add exclusions to limit traffic to parts of your website. .setUrlExpansionOptOut(false) // Sets if the campaign is enabled for brand guidelines. For more information on brand // guidelines, see https://support.google.com/google-ads/answer/14934472. .setBrandGuidelinesEnabled(brandGuidelinesEnabled) // Assigns the resource name with a temporary ID. .setResourceName( ResourceNames.campaign(customerId, PERFORMANCE_MAX_CAMPAIGN_TEMPORARY_ID)) // Sets the budget using the given budget resource name. .setCampaignBudget(ResourceNames.campaignBudget(customerId, BUDGET_TEMPORARY_ID)) // Declares whether this campaign serves political ads targeting the EU. .setContainsEuPoliticalAdvertising(DOES_NOT_CONTAIN_EU_POLITICAL_ADVERTISING) // Optional fields. .setStartDate(new DateTime().plusDays(1).toString("yyyyMMdd")) .setEndDate(new DateTime().plusDays(365).toString("yyyyMMdd")) .build(); return MutateOperation.newBuilder() .setCampaignOperation( CampaignOperation.newBuilder().setCreate(performanceMaxCampaign).build()) .build(); }
C#
/// Creates a MutateOperation that creates a new Performance Max campaign. /// <param name="campaignResourceName">The campaign resource name.</param> /// <param name="campaignBudgetResourceName">The campaign budget resource name.</param> /// <param name="brandGuidelinesEnabled">Whether or not to enable brand guidelines.</param> /// <returns>A MutateOperations that will create this new campaign.</returns> private MutateOperation CreatePerformanceMaxCampaignOperation( string campaignResourceName, string campaignBudgetResourceName, bool brandGuidelinesEnabled) { MutateOperation operation = new MutateOperation() { CampaignOperation = new CampaignOperation() { Create = new Campaign() { Name = "Performance Max campaign #" + ExampleUtilities.GetRandomString(), // Set the campaign status as PAUSED. The campaign is the only entity in // the mutate request that should have its status set. Status = CampaignStatus.Paused, // All Performance Max campaigns have an AdvertisingChannelType of // PerformanceMax. The AdvertisingChannelSubType should not be set. AdvertisingChannelType = AdvertisingChannelType.PerformanceMax, // Bidding strategy must be set directly on the campaign. Setting a // portfolio bidding strategy by resource name is not supported. Max // Conversion and Maximize Conversion Value are the only strategies // supported for Performance Max campaigns. BiddingStrategyType is // read-only and cannot be set by the API. An optional ROAS (Return on // Advertising Spend) can be set to enable the MaximizeConversionValue // bidding strategy. The ROAS value must be specified as a ratio in the API. // It is calculated by dividing "total value" by "total spend". // // For more information on Maximize Conversion Value, see the support // article: // http://support.google.com/google-ads/answer/7684216. // // A target_roas of 3.5 corresponds to a 350% return on ad spend. MaximizeConversionValue = new MaximizeConversionValue() { TargetRoas = 3.5 }, // Set the Final URL expansion opt out. This flag is specific to // Performance Max campaigns. If opted out (True), only the final URLs in // the asset group or URLs specified in the advertiser's Google Merchant // Center or business data feeds are targeted. // If opted in (False), the entire domain will be targeted. For best // results, set this value to false to opt in and allow URL expansions. You // can optionally add exclusions to limit traffic to parts of your website. UrlExpansionOptOut = false, // Use the temporary resource name created earlier ResourceName = campaignResourceName, // Set the budget using the given budget resource name. CampaignBudget = campaignBudgetResourceName, // Set if the campaign is enabled for brand guidelines. For more information // on brand guidelines, see https://support.google.com/google-ads/answer/14934472. BrandGuidelinesEnabled = brandGuidelinesEnabled, // Declare whether or not this campaign contains political ads targeting the EU. ContainsEuPoliticalAdvertising = EuPoliticalAdvertisingStatus.DoesNotContainEuPoliticalAdvertising, // Optional fields StartDate = DateTime.Now.AddDays(1).ToString("yyyyMMdd"), EndDate = DateTime.Now.AddDays(365).ToString("yyyyMMdd") } } }; return operation; }
PHP
private static function createPerformanceMaxCampaignOperation( int $customerId, bool $brandGuidelinesEnabled ): MutateOperation { // Creates a mutate operation that creates a campaign operation. return new MutateOperation([ 'campaign_operation' => new CampaignOperation([ 'create' => new Campaign([ 'name' => 'Performance Max campaign #' . Helper::getPrintableDatetime(), // Assigns the resource name with a temporary ID. 'resource_name' => ResourceNames::forCampaign( $customerId, self::PERFORMANCE_MAX_CAMPAIGN_TEMPORARY_ID ), // Sets the budget using the given budget resource name. 'campaign_budget' => ResourceNames::forCampaignBudget( $customerId, self::BUDGET_TEMPORARY_ID ), // The campaign is the only entity in the mutate request that should have its // status set. // Recommendation: Set the campaign to PAUSED when creating it to prevent // the ads from immediately serving. 'status' => CampaignStatus::PAUSED, // All Performance Max campaigns have an advertising_channel_type of // PERFORMANCE_MAX. The advertising_channel_sub_type should not be set. 'advertising_channel_type' => AdvertisingChannelType::PERFORMANCE_MAX, // Bidding strategy must be set directly on the campaign. // Setting a portfolio bidding strategy by resource name is not supported. // Max Conversion and Maximize Conversion Value are the only strategies // supported for Performance Max campaigns. // An optional ROAS (Return on Advertising Spend) can be set for // maximize_conversion_value. The ROAS value must be specified as a ratio in // the API. It is calculated by dividing "total value" by "total spend". // For more information on Maximize Conversion Value, see the support // article: http://support.google.com/google-ads/answer/7684216. // A target_roas of 3.5 corresponds to a 350% return on ad spend. 'maximize_conversion_value' => new MaximizeConversionValue([ 'target_roas' => 3.5 ]), // Sets the Final URL expansion opt out. This flag is specific to // Performance Max campaigns. If opted out (true), only the final URLs in // the asset group or URLs specified in the advertiser's Google Merchant // Center or business data feeds are targeted. // If opted in (false), the entire domain will be targeted. For best // results, set this value to false to opt in and allow URL expansions. You // can optionally add exclusions to limit traffic to parts of your website. 'url_expansion_opt_out' => false, // Sets if the campaign is enabled for brand guidelines. For more information // on brand guidelines, see // https://support.google.com/google-ads/answer/14934472. 'brand_guidelines_enabled' => $brandGuidelinesEnabled, // Declare whether or not this campaign serves political ads targeting the EU. 'contains_eu_political_advertising' => EuPoliticalAdvertisingStatus::DOES_NOT_CONTAIN_EU_POLITICAL_ADVERTISING, // Optional fields. 'start_date' => date('Ymd', strtotime('+1 day')), 'end_date' => date('Ymd', strtotime('+365 days')) ]) ]) ]); }
Python
def create_performance_max_campaign_operation( client: GoogleAdsClient, customer_id: str, brand_guidelines_enabled: bool, ) -> MutateOperation: """Creates a MutateOperation that creates a new Performance Max campaign. A temporary ID will be assigned to this campaign so that it can be referenced by other objects being created in the same Mutate request. Args: client: an initialized GoogleAdsClient instance. customer_id: a client customer ID. brand_guidelines_enabled: a boolean value indicating if the campaign is enabled for brand guidelines. Returns: a MutateOperation that creates a campaign. """ mutate_operation: MutateOperation = client.get_type("MutateOperation") campaign: Campaign = mutate_operation.campaign_operation.create campaign.name = f"Performance Max campaign #{uuid4()}" # Set the campaign status as PAUSED. The campaign is the only entity in # the mutate request that should have its status set. campaign.status = client.enums.CampaignStatusEnum.PAUSED # All Performance Max campaigns have an advertising_channel_type of # PERFORMANCE_MAX. The advertising_channel_sub_type should not be set. campaign.advertising_channel_type = ( client.enums.AdvertisingChannelTypeEnum.PERFORMANCE_MAX ) # Bidding strategy must be set directly on the campaign. # Setting a portfolio bidding strategy by resource name is not supported. # Max Conversion and Maximize Conversion Value are the only strategies # supported for Performance Max campaigns. # An optional ROAS (Return on Advertising Spend) can be set for # maximize_conversion_value. The ROAS value must be specified as a ratio in # the API. It is calculated by dividing "total value" by "total spend". # For more information on Maximize Conversion Value, see the support # article: http://support.google.com/google-ads/answer/7684216. # A target_roas of 3.5 corresponds to a 350% return on ad spend. campaign.bidding_strategy_type = ( client.enums.BiddingStrategyTypeEnum.MAXIMIZE_CONVERSION_VALUE ) campaign.maximize_conversion_value.target_roas = 3.5 # Set the Final URL expansion opt out. This flag is specific to # Performance Max campaigns. If opted out (True), only the final URLs in # the asset group or URLs specified in the advertiser's Google Merchant # Center or business data feeds are targeted. # If opted in (False), the entire domain will be targeted. For best # results, set this value to false to opt in and allow URL expansions. You # can optionally add exclusions to limit traffic to parts of your website. campaign.url_expansion_opt_out = False # Set if the campaign is enabled for brand guidelines. For more information # on brand guidelines, see https://support.google.com/google-ads/answer/14934472. campaign.brand_guidelines_enabled = brand_guidelines_enabled # Assign the resource name with a temporary ID. campaign_service: CampaignServiceClient = client.get_service( "CampaignService" ) campaign.resource_name = campaign_service.campaign_path( customer_id, _PERFORMANCE_MAX_CAMPAIGN_TEMPORARY_ID ) # Set the budget using the given budget resource name. campaign.campaign_budget = campaign_service.campaign_budget_path( customer_id, _BUDGET_TEMPORARY_ID ) # Declare whether or not this campaign serves political ads targeting the # EU. Valid values are: # CONTAINS_EU_POLITICAL_ADVERTISING # DOES_NOT_CONTAIN_EU_POLITICAL_ADVERTISING campaign.contains_eu_political_advertising = ( client.enums.EuPoliticalAdvertisingStatusEnum.DOES_NOT_CONTAIN_EU_POLITICAL_ADVERTISING ) # Optional fields campaign.start_date = (datetime.now() + timedelta(1)).strftime("%Y%m%d") campaign.end_date = (datetime.now() + timedelta(365)).strftime("%Y%m%d") return mutate_operation
Ruby
# Creates a MutateOperation that creates a new Performance Max campaign. # # A temporary ID will be assigned to this campaign so that it can # be referenced by other objects being created in the same Mutate request. def create_performance_max_campaign_operation( client, customer_id, brand_guidelines_enabled) client.operation.mutate do |m| m.campaign_operation = client.operation.create_resource.campaign do |c| c.name = "Performance Max campaign #{SecureRandom.uuid}" # Set the campaign status as PAUSED. The campaign is the only entity in # the mutate request that should have its status set. c.status = :PAUSED # All Performance Max campaigns have an advertising_channel_type of # PERFORMANCE_MAX. The advertising_channel_sub_type should not be set. c.advertising_channel_type = :PERFORMANCE_MAX # Bidding strategy must be set directly on the campaign. # Setting a portfolio bidding strategy by resource name is not supported. # Max Conversion and Maximize Conversion Value are the only strategies # supported for Performance Max campaigns. # An optional ROAS (Return on Advertising Spend) can be set for # maximize_conversion_value. The ROAS value must be specified as a ratio in # the API. It is calculated by dividing "total value" by "total spend". # For more information on Maximize Conversion Value, see the support # article: http://support.google.com/google-ads/answer/7684216. # A target_roas of 3.5 corresponds to a 350% return on ad spend. c.bidding_strategy_type = :MAXIMIZE_CONVERSION_VALUE c.maximize_conversion_value = client.resource.maximize_conversion_value do |mcv| mcv.target_roas = 3.5 end # Set the Final URL expansion opt out. This flag is specific to # Performance Max campaigns. If opted out (true), only the final URLs in # the asset group or URLs specified in the advertiser's Google Merchant # Center or business data feeds are targeted. # If opted in (false), the entire domain will be targeted. For best # results, set this value to false to opt in and allow URL expansions. You # can optionally add exclusions to limit traffic to parts of your website. c.url_expansion_opt_out = false # Set if the campaign is enabled for brand guidelines. For more # information on brand guidelines, see # https://support.google.com/google-ads/answer/14934472. c.brand_guidelines_enabled = brand_guidelines_enabled # Assign the resource name with a temporary ID. c.resource_name = client.path.campaign(customer_id, PERFORMANCE_MAX_CAMPAIGN_TEMPORARY_ID) # Set the budget using the given budget resource name. c.campaign_budget = client.path.campaign_budget(customer_id, BUDGET_TEMPORARY_ID) # Declare whether or not this campaign serves political ads targeting the EU. # Valid values are CONTAINS_EU_POLITICAL_ADVERTISING and # DOES_NOT_CONTAIN_EU_POLITICAL_ADVERTISING. c.contains_eu_political_advertising = :DOES_NOT_CONTAIN_EU_POLITICAL_ADVERTISING # Optional fields c.start_date = DateTime.parse((Date.today + 1).to_s).strftime('%Y%m%d') c.end_date = DateTime.parse(Date.today.next_year.to_s).strftime('%Y%m%d') end end end
Perl
sub create_performance_max_campaign_operation { my ($customer_id, $brand_guidelines_enabled) = @_; # Create a mutate operation that creates a campaign operation. return Google::Ads::GoogleAds::V21::Services::GoogleAdsService::MutateOperation-> new({ campaignOperation => Google::Ads::GoogleAds::V21::Services::CampaignService::CampaignOperation ->new({ create => Google::Ads::GoogleAds::V21::Resources::Campaign->new({ # Assign the resource name with a temporary ID. resourceName => Google::Ads::GoogleAds::V21::Utils::ResourceNames::campaign( $customer_id, PERFORMANCE_MAX_CAMPAIGN_TEMPORARY_ID ), name => "Performance Max campaign #" . uniqid(), # Set the budget using the given budget resource name. campaignBudget => Google::Ads::GoogleAds::V21::Utils::ResourceNames::campaign_budget( $customer_id, BUDGET_TEMPORARY_ID ), # Set the campaign status as PAUSED. The campaign is the only entity in # the mutate request that should have its status set. status => Google::Ads::GoogleAds::V21::Enums::CampaignStatusEnum::PAUSED, # All Performance Max campaigns have an advertisingChannelType of # PERFORMANCE_MAX. The advertisingChannelSubType should not be set. advertisingChannelType => PERFORMANCE_MAX, # Bidding strategy must be set directly on the campaign. # Setting a portfolio bidding strategy by resource name is not supported. # Max Conversion and Maximize Conversion Value are the only strategies # supported for Performance Max campaigns. # An optional ROAS (Return on Advertising Spend) can be set for # maximizeConversionValue. The ROAS value must be specified as a ratio in # the API. It is calculated by dividing "total value" by "total spend". # For more information on Maximize Conversion Value, see the support # article: http://support.google.com/google-ads/answer/7684216. # A targetRoas of 3.5 corresponds to a 350% return on ad spend. maximizeConversionValue => Google::Ads::GoogleAds::V21::Common::MaximizeConversionValue-> new({ targetRoas => 3.5 } ), # Set the final URL expansion opt out. This flag is specific to # Performance Max campaigns. If opted out (true), only the final URLs in # the asset group or URLs specified in the advertiser's Google Merchant # Center or business data feeds are targeted. # If opted in (false), the entire domain will be targeted. For best # results, set this value to false to opt in and allow URL expansions. You # can optionally add exclusions to limit traffic to parts of your website. urlExpansionOptOut => "false", # Set if the campaign is enabled for brand guidelines. For more information # on brand guidelines, see https://support.google.com/google-ads/answer/14934472. brandGuidelinesEnabled => $brand_guidelines_enabled, # Optional fields. startDate => strftime("%Y%m%d", localtime(time + 60 * 60 * 24)), endDate => strftime("%Y%m%d", localtime(time + 60 * 60 * 24 * 365)), # Declare whether or not this campaign serves political ads targeting the EU. # Valid values are CONTAINS_EU_POLITICAL_ADVERTISING and # DOES_NOT_CONTAIN_EU_POLITICAL_ADVERTISING. containsEuPoliticalAdvertising => DOES_NOT_CONTAIN_EU_POLITICAL_ADVERTISING })})}); }
Consigli sulle offerte
L'API Google Ads offre due tipi di consigli per aiutarti a ottimizzare le offerte della campagna Performance Max:
MAXIMIZE_CONVERSION_VALUE_OPT_IN
consiglia di utilizzare la strategia di offerta Massimizza il valore di conversione per le tue campagne.MAXIMIZE_CONVERSIONS_OPT_IN
consiglia di utilizzare la strategia di offerta Massimizza le conversioni per le tue campagne e fornisce un importo del budget suggerito.
Per ulteriori informazioni sull'utilizzo dei consigli, consulta la guida Punteggio di ottimizzazione e consigli.
Linee guida per il brand
Le linee guida per il brand controllano in che modo
il tuo brand viene rappresentato negli asset o nei
formati automatici delle campagne Performance Max. A partire dalla versione 21 dell'API Google Ads, le campagne Performance Max attivano automaticamente le linee guida per il brand in tutte le nuove campagne Performance Max per le vendite online o la generazione di lead (standard) e Performance Max per le vendite online con un feed dei prodotti (retail). Se non vuoi attivare le linee guida per il brand nelle nuove campagne,
imposta
Campaign.brand_guidelines_enabled
su false
quando crei la nuova campagna Performance Max.
Le campagne Performance Max con le linee guida per il brand attivate utilizzano asset a livello di campagna per i tipi di campi degli asset brand (BUSINESS_NAME
, LOGO
e LANDSCAPE_LOGO
). Devi collegare gli asset brand alla campagna utilizzando CampaignAsset
e la campagna deve avere:
- Esattamente un asset
BUSINESS_NAME
- Almeno un asset
LOGO
e fino a quattro asset logo aggiuntivi facoltativi di tipoLOGO
oLANDSCAPE_LOGO
Le linee guida facoltative per il colore e il carattere della campagna possono essere impostate utilizzando il campo
Campaign.brand_guidelines
:
main_color
imposta il colore principale. Il colore deve essere fornito come stringa di codice esadecimale (ad es. #00ff00).accent_color
imposta il colore secondario. Il colore deve essere fornito come stringa di codice esadecimale (ad es. #00ff00).- Utilizza
predefined_font_family
per impostare il carattere. Il valore deve essere uno dei seguenti caratteri Google Fonts (rispettano la distinzione tra maiuscole e minuscole): Open Sans, Roboto, Montserrat, Poppins, Lato, Oswald, Playfair Display, Roboto Slab.
Migrazione automatica
A partire dal 1° giugno 2025, inizieremo ad attivare automaticamente le linee guida per il brand per le campagne Performance Max che utilizzano gli stessi asset brand (BUSINESS_NAME
, LOGO
e LANDSCAPE_LOGO
) in tutti i gruppi di asset. Tutte le campagne per le quali è possibile
eseguire la migrazione automatica verranno migrate entro il 30 ottobre 2025.
- La migrazione automatica verrà eseguita solo per le campagne che utilizzano un nome e un logo dell'attività coerenti in ogni gruppo di asset. Se la tua campagna presenta varianti in questi asset, non verrà eseguita la migrazione automatica.
- Tutte le campagne Performance Max idonee con un ID cliente verranno migrate contemporaneamente.
- Dopo la migrazione, ogni campagna migrata avrà il proprio set di asset
del brand memorizzati a livello di campagna utilizzando
CampaignAsset
.
Puoi sapere se una campagna è stata migrata controllando il campo
Campaign.brand_guidelines_enabled
.
Migrazione manuale
Le campagne non idonee per la migrazione automatica richiedono la migrazione manuale per attivare le linee guida per il brand.
Campaign.brand_guidelines_enabled
indica se una campagna esistente è abilitata per le linee guida per il brand. Per attivare manualmente
le linee guida per il brand per una campagna esistente, utilizza
CampaignService.EnablePMaxBrandGuidelines
anziché aggiornare direttamente il campo brand_guidelines_enabled
, in quanto il campo
è immutabile. Imposta
auto_populate_brand_assets
su true
per compilare automaticamente la campagna con gli asset del brand con il rendimento migliore. In caso contrario, devi fornire manualmente le risorse nell'operazione con
brand_assets
. La disattivazione delle linee guida per il brand per una campagna non è supportata.
(Facoltativo) Espansione dell'URL finale
L'espansione dell'URL ti aiuta a ottimizzare il rendimento delle campagne Performance Max. Utilizza l'espansione dell'URL per sostituire l'URL finale con una pagina di destinazione e un titolo dinamico più pertinenti in base all'intenzione dei clienti. Per impostazione predefinita, l'espansione dell'URL è:
- Off, se sono stati applicati filtri di prodotto.
- Attivato quando il targeting è impostato su tutti i prodotti.
Imposta
Campaign.final_url_expansion_opt_out
per modificare questi valori predefiniti.
Utilizza i WEBPAGE
criteri della campagna per impostare le esclusioni dell'espansione dell'URL.
Per visualizzare gli asset creati automaticamente dall'impostazione di espansione dell'URL finale, utilizza
final_url_expansion_asset_view
.
Puoi rimuovere un asset di espansione dell'URL creato automaticamente utilizzando
AutomaticallyCreatedAssetRemovalService
.