# データのカバー範囲を確認する

Source: https://won.dev/ja/docs/trade/coverage-get

`GET https://api.won.dev/v1/trade/coverage`

お金を使う前に、ある国にどんなデータがあるかを確認します。輸入と輸出それぞれについて、その国で申告された通関記録があるか、記録に金額が入っているか、どの期間をカバーしているか、公式統計を照会できるかがわかります。無料です。自国の記録がない国（`records: false`）も検索結果には出てきますが、取引相手国の申告を通してだけなので、件数は不完全です。`country` を指定しなければ、自国の記録か公式統計がある国を一覧にし、それ以外の国の数は `notice` で示します。

- **課金：** 無料。
- **モード：** `proxy` ([各モードの意味](/ja/docs/trade#modes))

## パラメーター [#parameters]

パラメーターはクエリ文字列で渡し、リストはカンマ区切りにします。

| パラメーター | 型 | 必須 | 説明（APIの原文） |
| --- | --- | --- | --- |
| `country` | string | いいえ | The country to check. Leave it out to list all. An ISO code such as `US`, or an English name such as `United States`. |

## レスポンス [#response]

エラーについては[エラーコード](/ja/docs/errors)を参照してください。

| フィールド | 型 | 説明（APIの原文） |
| --- | --- | --- |
| `data` | object[] | One entry for each country. |
| `data[].country` | string | ISO 3166-1 alpha-2 country code, such as `US`. |
| `data[].imports` | object | Records of goods imported into the country. |
| `data[].imports.records` | boolean \| null | Whether shipment records declared in this country exist. Null when not known yet. |
| `data[].imports.values` | boolean \| null | Whether those records carry declared values. Null when not known yet. |
| `data[].imports.earliest` | string \| null | Date of the earliest record seen, `YYYY-MM-DD`. |
| `data[].imports.latest` | string \| null | Date of the latest record seen, `YYYY-MM-DD`. |
| `data[].imports.note` | string \| null | Something to know about these records, such as a gap or a late start. |
| `data[].exports` | object | Records of goods exported from the country. |
| `data[].exports.records` | boolean \| null | Whether shipment records declared in this country exist. Null when not known yet. |
| `data[].exports.values` | boolean \| null | Whether those records carry declared values. Null when not known yet. |
| `data[].exports.earliest` | string \| null | Date of the earliest record seen, `YYYY-MM-DD`. |
| `data[].exports.latest` | string \| null | Date of the latest record seen, `YYYY-MM-DD`. |
| `data[].exports.note` | string \| null | Something to know about these records, such as a gap or a late start. |
| `data[].official` | object | Official statistics with the country as importer or exporter. |
| `data[].official.available` | boolean | Whether official trade statistics can be queried. |
| `data[].official.latest_month` | string \| null | Latest month published, `YYYY-MM`, among the statistics fetched so far. They are fetched when first asked for, so it is null until a query has asked for this country's statistics. |
| `data[].official.mirror` | boolean | True when the country publishes no recent statistics of its own, and they are what its partners report about their trade with it. |
| `query` | object | The request as it was understood: country names as codes, the default dates filled in. |
| `notice` | string \| null | A plain sentence when there is something to know about this result: why a part is missing, or what to try next. Null otherwise. |
| `usage` | object | Nothing is charged here. The balance, for reference. |
| `usage.cost` | number | What this call cost, in US dollars. |
| `usage.balance` | number | The balance left after this call, in US dollars. |
| `usage.replayed` | boolean | True when this is a repeat of a request from the last 24 hours. Repeats are free. |

## 例 [#example]

```bash
curl "https://api.won.dev/v1/trade/coverage?country=United%20States" \
  -H "Authorization: Bearer $WON_API_KEY"
```

```json
{
  "data": [
    {
      "country": "US",
      "imports": {
        "records": true,
        "values": false,
        "earliest": "2021-01-01",
        "latest": "2026-11-13",
        "note": null
      },
      "exports": {
        "records": true,
        "values": false,
        "earliest": "2021-01-02",
        "latest": "2026-09-30",
        "note": null
      },
      "official": {
        "available": true,
        "latest_month": "2026-09"
      }
    }
  ],
  "query": {
    "country": "US"
  },
  "notice": null,
  "usage": {
    "cost": 0,
    "balance": 48.08,
    "replayed": false
  }
}
```