example-data.com

countries

countries

Browse 50 countries records. Free mock data API by Draftbit — fetch over REST or browse paginated HTML.

United States

US

Capital: Washington, D.C. · Region: Americas

Canada

CA

Capital: Ottawa · Region: Americas

Mexico

MX

Capital: Mexico City · Region: Americas

Brazil

BR

Capital: Brasília · Region: Americas

Argentina

AR

Capital: Buenos Aires · Region: Americas

Chile

CL

Capital: Santiago · Region: Americas

Showing first 6 of 24 on this page.

curl -sS \
  "https://example-data.com/api/v1/countries?limit=25"
const res = await fetch(
  "https://example-data.com/api/v1/countries?limit=25"
);
const { data, meta } = await res.json();
import type { Countrie, ListEnvelope } from "https://example-data.com/types/countries.d.ts";

const res = await fetch(
  "https://example-data.com/api/v1/countries?limit=25"
);
const { data, meta } = (await res.json()) as ListEnvelope<Countrie>;
import requests

res = requests.get(
    "https://example-data.com/api/v1/countries",
    params={"limit": 25},
)
data = res.json()
{
  "data": [
    {
      "id": 1,
      "name": "United States",
      "alpha2": "US",
      "alpha3": "USA",
      "numericCode": "840",
      "capital": "Washington, D.C.",
      "region": "Americas",
      "subregion": "Northern America",
      "currencyCode": "USD",
      "callingCode": "+1",
      "flagEmoji": "🇺🇸"
    },
    {
      "id": 2,
      "name": "Canada",
      "alpha2": "CA",
      "alpha3": "CAN",
      "numericCode": "124",
      "capital": "Ottawa",
      "region": "Americas",
      "subregion": "Northern America",
      "currencyCode": "CAD",
      "callingCode": "+1",
      "flagEmoji": "🇨🇦"
    },
    {
      "id": 3,
      "name": "Mexico",
      "alpha2": "MX",
      "alpha3": "MEX",
      "numericCode": "484",
      "capital": "Mexico City",
      "region": "Americas",
      "subregion": "Central America",
      "currencyCode": "MXN",
      "callingCode": "+52",
      "flagEmoji": "🇲🇽"
    }
  ],
  "meta": {
    "page": 1,
    "limit": 25,
    "total": 50,
    "totalPages": 2
  },
  "links": {
    "self": "/api/v1/countries?page=1",
    "first": "/api/v1/countries?page=1",
    "last": "/api/v1/countries?page=2",
    "next": "/api/v1/countries?page=2",
    "prev": null
  }
}

View full response →

Draftbit