Method: customers.generateKeywordHistoricalMetrics

返回关键字历史指标列表。

抛出的错误列表:AuthenticationError AuthorizationError CollectionSizeError HeaderError InternalError QuotaError RequestError

HTTP 请求

POST https://googleads.googleapis.com/v16/customers/{customerId}:generateKeywordHistoricalMetrics

网址采用 gRPC 转码语法。

路径参数

参数
customerId

string

提供建议的客户的 ID。

请求正文

请求正文中包含结构如下的数据:

JSON 表示法
{
  "keywords": [
    string
  ],
  "includeAdultKeywords": boolean,
  "geoTargetConstants": [
    string
  ],
  "keywordPlanNetwork": enum (KeywordPlanNetwork),
  "aggregateMetrics": {
    object (KeywordPlanAggregateMetrics)
  },
  "historicalMetricsOptions": {
    object (HistoricalMetricsOptions)
  },
  "language": string
}
字段
keywords[]

string

用于获取历史指标的关键字列表。执行近乎精确的去重后,并非所有输入都会返回。例如,如果请求“car”和“cars”的统计信息,则将仅返回“car”。最多可以使用 10,000 个关键字。

includeAdultKeywords

boolean

如果为 true,响应中将包含成人关键字。默认值为 false。

geoTargetConstants[]

string

目标地理位置的资源名称。最大值为 10。可以使用空列表来指定所有目标地理位置。

keywordPlanNetwork

enum (KeywordPlanNetwork)

定位广告网络。如果未设置此政策,系统将会使用 Google 搜索与合作伙伴网络。

aggregateMetrics

object (KeywordPlanAggregateMetrics)

要包含在响应中的汇总字段。

historicalMetricsOptions

object (HistoricalMetricsOptions)

历史指标数据的选项。

language

string

要定位的语言的资源名称。每个关键字都属于一组语言;如果语言是某个关键字的语言之一,就会包含该关键字。如果未设置,则将包括所有关键字。

响应正文

KeywordPlanIdeaService.GenerateKeywordHistoricalMetrics 的响应消息。

如果成功,响应正文将包含结构如下的数据:

JSON 表示法
{
  "results": [
    {
      object (GenerateKeywordHistoricalMetricsResult)
    }
  ],
  "aggregateMetricResults": {
    object (KeywordPlanAggregateMetricResults)
  }
}
字段
results[]

object (GenerateKeywordHistoricalMetricsResult)

关键字及其历史指标的列表。

aggregateMetricResults

object (KeywordPlanAggregateMetricResults)

所有关键字的汇总指标。

授权范围

需要以下 OAuth 作用域:

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

有关详情,请参阅 OAuth 2.0 概览

GenerateKeywordHistoricalMetricsResult

关键字历史指标的生成结果。

JSON 表示法
{
  "closeVariants": [
    string
  ],
  "keywordMetrics": {
    object (KeywordPlanHistoricalMetrics)
  },
  "text": string
}
字段
closeVariants[]

string

所请求关键字的紧密变体形式列表,其统计信息已合并到此 GenerateKeywordHistoryMetricsResult。

keywordMetrics

object (KeywordPlanHistoricalMetrics)

文字及其紧密变体形式的历史指标

text

string

与一个或多个关键字相关联的查询文本。请注意,我们会删除重复的关键字列表,删除紧密变体形式,然后以文本形式返回关键字。例如,如果您的请求最初包含关键字“car”和“cars”,则返回的搜索查询将仅包含“cars”。去重查询的列表将包含在 closeVariants 字段中。