Caution: You are viewing documentation for the API's REST interface. Most of our official client libraries use gRPC. See the REST Introduction for details.

Method: customers.keywordPlans.generateForecastMetrics

Returns the requested Keyword Plan forecasts.

List of thrown errors: AuthenticationError AuthorizationError HeaderError InternalError KeywordPlanError QuotaError RequestError

HTTP request

POST https://googleads.googleapis.com/v7/{keywordPlan=customers/*/keywordPlans/*}:generateForecastMetrics

The URL uses gRPC Transcoding syntax.

Path parameters

Parameters
keywordPlan

string

Required. The resource name of the keyword plan to be forecasted.

Request body

The request body must be empty.

Response body

If successful, the response body contains data with the following structure:

Response message for KeywordPlanService.GenerateForecastMetrics.

JSON representation
{
  "campaignForecasts": [
    {
      object (KeywordPlanCampaignForecast)
    }
  ],
  "adGroupForecasts": [
    {
      object (KeywordPlanAdGroupForecast)
    }
  ],
  "keywordForecasts": [
    {
      object (KeywordPlanKeywordForecast)
    }
  ]
}
Fields
campaignForecasts[]

object (KeywordPlanCampaignForecast)

List of campaign forecasts. One maximum.

adGroupForecasts[]

object (KeywordPlanAdGroupForecast)

List of ad group forecasts.

keywordForecasts[]

object (KeywordPlanKeywordForecast)

List of keyword forecasts.

Authorization Scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/adwords

For more information, see the OAuth 2.0 Overview.

KeywordPlanCampaignForecast

A campaign forecast.

JSON representation
{
  "campaignForecast": {
    object (ForecastMetrics)
  },
  "keywordPlanCampaign": string
}
Fields
campaignForecast

object (ForecastMetrics)

The forecast for the Keyword Plan campaign.

keywordPlanCampaign

string

The resource name of the Keyword Plan campaign related to the forecast.

customers/{customerId}/keywordPlanCampaigns/{keyword_plan_campaign_id}

KeywordPlanAdGroupForecast

An ad group forecast.

JSON representation
{
  "adGroupForecast": {
    object (ForecastMetrics)
  },
  "keywordPlanAdGroup": string
}
Fields
adGroupForecast

object (ForecastMetrics)

The forecast for the Keyword Plan ad group.

keywordPlanAdGroup

string

The resource name of the Keyword Plan ad group related to the forecast.

customers/{customerId}/keywordPlanAdGroups/{keyword_plan_ad_group_id}

KeywordPlanKeywordForecast

A keyword forecast.

JSON representation
{
  "keywordForecast": {
    object (ForecastMetrics)
  },
  "keywordPlanAdGroupKeyword": string
}
Fields
keywordForecast

object (ForecastMetrics)

The forecast for the Keyword Plan keyword.

keywordPlanAdGroupKeyword

string

The resource name of the Keyword Plan keyword related to the forecast.

customers/{customerId}/keywordPlanAdGroupKeywords/{keyword_plan_ad_group_keyword_id}