Recomendações

As recomendações são geradas automaticamente pelo Google Ads e oferecem ideias para otimizar sua conta, como aumentar o orçamento de uma campanha limitada ou adicionar palavras-chave relevantes. Confira a lista completa de tipos de recomendação na documentação da API Google Ads.

Recuperar recomendações

Para recuperar recomendações, use o seletor AdsApp.recommendations(), que funciona de maneira semelhante a outros seletores, pois permite que você especifique condições em que tipos de recomendações retornar:

const selector = AdsApp.recommendations()
  .withCondition('recommendation.type IN (CAMPAIGN_BUDGET)');
const recommendations = selector.get();

Aplicar recomendações

Depois de buscar as recomendações, aplique-as assim:

for (const recommendation of recommendations) {
  // Perform whatever check here that works for your use case.
  // You can also potentially skip this step if you've sufficiently narrowed
  // down what recommendations you're selecting initially with customized
  // withCondition clauses in the previous step.
  if (shouldApply(recommendation)) {
    recommendation.apply();
  }
}