---
title: "GDP 增长率 API：实际增速 | Narwhal API"
description: "GDP 增长率 API 可获取一个国家某个季度的官方实际 GDP 增长率，按不变价格计算，以百分比表示。页面详细列出该接口的请求参数、调用示例、错误说明、数据新鲜度和覆盖范围，方便按国家和期间取值。"
url: "https://narwhalapi.com/zh/docs/api/economics/gdp-growth"
---

# GDP 增长率 API 参考

获取一个季度的官方实际 GDP 增长率，按不变价格计算，以百分比表示。

`economics_get_gdp_growth` 可通过 REST 和 `economics_get_gdp_growth` MCP 工具调用。两者返回相同的数据结构，并使用同一额度。

## 端点与请求

REST 端点

```
GET /v1/economics/{country}/gdp-growth
```

请求示例

```
curl --request GET \
  --url "https://api.narwhalapi.com/v1/economics/USA/gdp-growth?period=2026-Q2" \
  --header "Authorization: Bearer $NARWHAL_API_KEY"
```

MCP 使用工具 `economics_get_gdp_growth` ，并传入下方对应的参数。

## 参数

此操作接受的期间格式是 `YYYY-QN`。

| 名称 | 必填 | 类型 | 含义 |
| --- | --- | --- | --- |
| `country` | 是 | 路径·ISO alpha-3 | 一个受支持的大写国家代码；请参阅此操作的覆盖列表。 |
| `period` | 否 | 查询·YYYY-QN | 省略此参数可获取已采纳的最新完整发布数据，也可传入一个具体期间。 |
| `version_id` | 否 | 查询·UUID | 可选的不可变发布版本。可使用 `dataset.published` 或 `dataset.revised` 事件中的 `resource_version`；省略时读取当前已收录的指标。 |

## 响应

响应示例

```
{
  "country": "USA",
  "period": "2026-Q2",
  "year_over_year": "2.2",
  "quarter_over_quarter": "0.6",
  "released_on": "2026-10-29",
  "calculated": [
    "quarter_over_quarter"
  ]
}
```

| 字段 | 类型 | 必填 | 含义 |
| --- | --- | --- | --- |
| `country` | 字符串 | 是 | 所请求的大写 ISO 三字母国家代码。 |
| `period` | 字符串 | 是 | 返回的官方观测期间。 |
| `year_over_year` | 十进制字符串 | 是 | 与上年同一季度相比的实际 GDP 变化率，单位为百分比。 |
| `quarter_over_quarter` | 十进制字符串 | 否 | 与上一季度相比的实际 GDP 变化率，单位为百分比，未换算为年率。发布机构只发布同比数据时，以及年度期间，该字段会被省略。 |
| `year_to_date` | 十进制字符串 | 否 | 来源发布时提供的官方年初至今增长率，单位为百分比；否则省略。 |
| `seasonal_adjustment` | 字符串或 null | 是 | 该数据是否经过季节调整，以发布机构的说明为准：`seasonally_adjusted`、`not_seasonally_adjusted`、`calendar_adjusted` 或 `trend`。`null` 表示发布机构没有说明。请勿将 `null` 理解为已调整。`mixed` 表示两个增长数据的基准不同。日本就是一例：其同比增长未经调整，环比增长经过调整。 |
| `year_over_year_seasonal_adjustment` | 字符串或 null | 是 | 每个增长数据各自的基准，取值与上述相同。仅当 `seasonal_adjustment` 为 `mixed` 时才会填写。其他情况，或发布内容没有说明该增长数据的基准时，为 `null`。 |
| `quarter_over_quarter_seasonal_adjustment` | 字符串或 null | 是 | 每个增长数据各自的基准，取值与上述相同。仅当 `seasonal_adjustment` 为 `mixed` 时才会填写。其他情况，或发布内容没有说明该增长数据的基准时，为 `null`。 |
| `annualization` | 字符串或 null | 是 | 环比增长是否已年化：`annualized` 或 `not_annualized`。如果返回结果中没有环比数据，则为 `null`。同比增长从不年化。 |
| `not_seasonally_adjusted` | `true` | 否 | 仅在增长率未经季节性调整时出现，值为 true。 |
| `annualized` | `true` | 否 | 仅在已发布的增长率经过年化时出现，值为 true。 |
| `year_over_year_not_seasonally_adjusted` | `true` | 否 | 仅当某国混用不同基准且其同比数值未经季节性调整时出现，值为 true。此时顶层标志不出现。 |
| `quarter_over_quarter_not_seasonally_adjusted` | `true` | 否 | 仅当某国混用不同基准且其季度环比数值未经季节性调整时出现，值为 true。此时顶层标志不出现。 |
| `seasonally_adjusted` | `true` | 否 | 仅当两个数值均记录为经季节性调整时出现，值为 true。 |
| `year_over_year_seasonally_adjusted` | `true` | 否 | 仅当某国混用不同基准且其同比数值经季节性调整时出现，值为 true。此时顶层标志不出现。 |
| `quarter_over_quarter_seasonally_adjusted` | `true` | 否 | 仅当某国混用不同基准且其季度环比数值经季节性调整时出现，值为 true。此时顶层标志不出现。 |
| `released_on` | 日期 | 是 | 官方发布日期，而不是 Narwhal 的检索时间。 |
| `source` | 对象 | 否 | Who published the figure: the statistics office or central bank, for example `{"publisher": "Office for National Statistics"}`. Where the data reaches us through another body, `distributor` names that body too. If we cannot tell who published a figure, `source` is left out. On a newest figure read from the publisher's own release, `source` is `{"publisher": "..."}` with no distributor, and `released_on` is the publisher's local release day. |
| `stage` | 字符串 | 否 | Appears only on a newest figure read from the publisher's release. Which reading of the figure this is: `flash`, `advance`, `first`, `second`, `third`, `preliminary` or `final`. |
| `published_at` | RFC 3339 时间戳 | 否 | Appears only on a newest figure read from the publisher's release. When the publisher released the figure. |
| `provisional` | `true` | 否 | Present, as true, only when the figure read from the release is marked provisional. |
| `calculated` | array of strings | 否 | Present only when Narwhal calculated a figure from the publisher's own numbers because the publisher does not print it. Lists the calculated figures: `["year_over_year"]`, `["quarter_over_quarter"]` or both. A printed figure always wins over a calculated one. A stored answer can carry it too, not only an answer read from the release. |

### Newest figure read from the release

The newest answer can come from Narwhal's own read of the statistics office's release, before the stored series has it. Such an answer adds `source`、 `stage`、 `published_at` 和 `provisional` (only when true). An answer with none of these fields is the stored value. A stored answer can also carry `calculated`, which lists the figures Narwhal calculated from the publisher's own numbers.

For a country with a stored series, a read value is shown when it is for a later period than the stored one, or a later final reading of the same period.

Where a stored series reaches Narwhal through a distributor, the statistics office's own printed figure for the same period replaces it. The answer then names the office as the source and no distributor.

It also answers the newest figure for a country that has no stored series, from the release alone, with the same fields and the same charge: Cameroon, Chad, Comoros, Cyprus, Fiji, Guadeloupe, Hong Kong, Hungary, Iceland, Martinique, Morocco, New Caledonia, Niger, Papua New Guinea, Senegal and Taiwan。It has no history: a `period` 或 `version_id` request for such a country returns `404 series_not_found`。

For these countries GDP growth is answered only when the office's release or its own tables state whether each figure is seasonally adjusted. A year-over-year figure whose basis is not stated is a `404 series_not_found`, and a quarter-over-quarter figure whose basis is not stated, or that is annualised, is left out of the answer.

请求示例

```
curl --request GET \
  --url "https://api.narwhalapi.com/v1/economics/SEN/gdp-growth" \
  --header "Authorization: Bearer $NARWHAL_API_KEY"
```

响应示例

```
{
  "country": "SEN",
  "period": "2026-Q2",
  "year_over_year": "6.1",
  "quarter_over_quarter": "0.1",
  "released_on": "2026-10-02",
  "source": {
    "publisher": "Agence Nationale de la Statistique et de la Démographie"
  },
  "stage": "preliminary",
  "published_at": "2026-10-02T10:00:00Z"
}
```

请求示例

```
curl --request GET \
  --url "https://api.narwhalapi.com/v1/economics/GBR/gdp-growth" \
  --header "Authorization: Bearer $NARWHAL_API_KEY"
```

响应示例

```
{
  "country": "GBR",
  "period": "2026-Q3",
  "year_over_year": "1.9",
  "quarter_over_quarter": "0.7",
  "released_on": "2026-11-12",
  "source": {
    "publisher": "Office for National Statistics"
  },
  "stage": "preliminary",
  "published_at": "2026-11-12T07:00:00Z"
}
```

## API 错误码与额度

- `400 invalid_query` — 国家、期间或筛选格式无效。
- `401 invalid_api_key` — Bearer 密钥缺失或被拒绝。
- `404 series_not_found` — 没有已批准的观测值符合请求。
- `429 rate_limit_exceeded` — 已达到网络或账户的短时窗口限额；请按以下响应头指定的等待时间重试： `Retry-After`。
- `402 insufficient_credits` ，余额不足以支付该调用。
- `503 economics_unavailable` — Narwhal 无法安全提供已接受的发布版本。

Only a successful data response costs credit. 查看 [所有错误、响应头和重试规则](https://narwhalapi.com/zh/docs/errors.md)。

## 数据时效性

省略 `period` 返回 Narwhal 最新存储的已接受发布版本。API 调用读取 Narwhal 数据库，不会实时调用官方发布机构。

`released_on` 是官方发布日期。

The newest figure can be shown as soon as the publisher releases it, from Narwhal's read of the release. Until the stored series has the same period, the answer carries the read fields described above.

读取 [源检查、验证、已存储发布版本和失败检查的工作方式](https://narwhalapi.com/zh/docs/freshness.md)。

## 当前公开测试覆盖范围

44 国家

`ARG, AUS, AUT, BEL, BRA, CAN, CHL, CHN, COL, CZE, DEU, DNK, ESP, EST, FIN, FRA, GBR, HRV, IDN, IND, IRL, ISR, ITA, JPN, KOR, LTU, LUX, LVA, MEX, MYS, NLD, NOR, NZL, PAK, PHL, POL, PRT, QAT, SAU, SGP, SVN, SWE, USA, ZAF`

季度同比及环比增长率数据覆盖的国家见下方列表。可选字段 year_to_date 仅在官方来源发布相应数据时出现。

### 世界银行年度历史数据

165 国家

`ABW, AFG, AGO, ALB, AND, ARE, ARM, ASM, ATG, AZE, BDI, BEN, BFA, BGR, BHR, BHS, BIH, BLR, BLZ, BMU, BOL, BRB, BRN, BTN, BWA, CAF, CIV, CMR, COD, COG, COM, CPV, CRI, CUB, CUW, CYM, CYP, DJI, DMA, DOM, DZA, ECU, EGY, ERI, ETH, FJI, FRO, FSM, GAB, GEO, GHA, GIN, GMB, GNB, GNQ, GRC, GRD, GRL, GTM, GUM, GUY, HKG, HND, HTI, HUN, IMN, IRN, IRQ, ISL, JAM, JOR, KAZ, KEN, KGZ, KHM, KIR, KNA, KWT, LAO, LBN, LBR, LBY, LCA, LIE, LKA, LSO, MAC, MAF, MAR, MCO, MDA, MDG, MDV, MHL, MKD, MLI, MLT, MMR, MNE, MNG, MNP, MOZ, MRT, MUS, MWI, NAM, NCL, NER, NGA, NIC, NPL, NRU, OMN, PAN, PER, PLW, PNG, PRI, PRY, PSE, PYF, ROU, RUS, RWA, SDN, SEN, SLB, SLE, SLV, SMR, SOM, SRB, SSD, STP, SUR, SVK, SWZ, SXM, SYC, SYR, TCA, TCD, TGO, TJK, TKM, TLS, TON, TTO, TUN, TUR, TUV, TZA, UGA, UKR, URY, UZB, VCT, VEN, VIR, VNM, VUT, WSM, YEM, ZMB, ZWE`

这些国家没有最新值路由。向此路由发出的请求会返回 `404 series_not_found`，请改用历史路由。

日频外汇数据可通过以下 API 获取： [外汇 API](https://narwhalapi.com/zh/api/fx.md)。

返回 [所有经济数据操作](https://narwhalapi.com/zh/docs/api/economics.md)。

## 从免费密钥开始

每月赠送 10 美元免费额度，无需绑卡。每月 10 美元免费额度，无需绑卡。

[获取免费 API 密钥](https://narwhalapi.com/zh/signup)

此页面对你有帮助吗?
