← 地理与天气

国家详情

GET /countrydata/:code

按 ISO 3166-1 alpha-2 代码获取单个国家的完整资料。返回官方名称、首都、人口、面积、语言、货币、电话代码、边界、地区、亚地区等。当只需要一个国家时比获取全部 250 个国家更高效。适用于国家详情页和深度地理内容。

参数

code 必填

Country code

请求示例

基本用法
curl https://nordapi.ee/api/v1/countrydata/NO
Norway full profile
curl https://nordapi.ee/api/v1/countrydata/NO
Japan full profile
curl https://nordapi.ee/api/v1/countrydata/JP
Brazil full profile
curl https://nordapi.ee/api/v1/countrydata/BR

实时响应

{
  "data": {
    "area_km2": null,
    "borders": null,
    "capital": null,
    "code": null,
    "code_alpha3": null,
    "continents": null,
    "currencies": null,
    "drives_on": null,
    "flag_png": null,
    "flag_svg": null,
    "languages": null,
    "latitude": null,
    "longitude": null,
    "name": null,
    "official_name": null,
    "population": null,
    "region": null,
    "start_of_week": null,
    "subregion": null,
    "timezones": null
  },
  "success": true
}