← 地理与天气

国家详情

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": 386224.0,
    "borders": [
      "FIN",
      "SWE",
      "RUS"
    ],
    "capital": "Oslo",
    "code": "NO",
    "code_alpha3": "NOR",
    "continents": [
      "Europe"
    ],
    "currencies": {
      "NOK": {
        "name": "Norwegian krone",
        "symbol": "kr"
      }
    },
    "drives_on": "right",
    "flag_png": "https://flagcdn.com/w320/no.png",
    "flag_svg": "https://flagcdn.com/no.svg",
    "languages": {
      "nno": "Norwegian Nynorsk",
      "nob": "Norwegian Bokmål",
      "smi": "Sami"
    },
    "latitude": 62.0,
    "longitude": 10.0,
    "name": "Norway",
    "official_name": "Kingdom of Norway",
    "population": 5606944,
    "region": "Europe",
    "start_of_week": "monday",
    "subregion": "Northern Europe",
    "timezones": [
      "UTC+01:00"
    ]
  },
  "success": true
}