Skip to main content
POST
/
api
/
worldbank
/
countries
/worldbank/countries
curl --request POST \
  --url https://api.anysite.io/api/worldbank/countries \
  --header 'Content-Type: application/json' \
  --header 'access-token: <api-key>' \
  --data '
{
  "count": 2,
  "timeout": 300,
  "keyword": "united"
}
'
[
  {
    "id": "<string>",
    "@type": "@worldbank_country",
    "iso2_code": "<string>",
    "name": "<string>",
    "region": {
      "@type": "@worldbank_ref",
      "id": "<string>",
      "iso2_code": "<string>",
      "value": "<string>"
    },
    "adminregion": {
      "@type": "@worldbank_ref",
      "id": "<string>",
      "iso2_code": "<string>",
      "value": "<string>"
    },
    "income_level": {
      "@type": "@worldbank_ref",
      "id": "<string>",
      "iso2_code": "<string>",
      "value": "<string>"
    },
    "lending_type": {
      "@type": "@worldbank_ref",
      "id": "<string>",
      "iso2_code": "<string>",
      "value": "<string>"
    },
    "capital_city": "<string>",
    "longitude": 123,
    "latitude": 123
  }
]

Authorizations

access-token
string
header
required

API token from the dashboard

Headers

access-token
string
required

Body

application/json
count
integer
required

Max number of countries to return

Required range: x >= 1
timeout
integer
default:300

Max scrapping execution timeout (in seconds)

Required range: 20 <= x <= 1500
keyword
string | null

Filter countries whose name contains this text

Example:

"united"

region
enum<string> | null

Restrict to countries in this region

Available options:
AFE,
AFR,
AFW,
ARB,
CAA,
CEA,
CEB,
CEU,
CLA,
CME,
CSA,
CSS,
EAP,
EAR,
EAS,
ECA,
ECS,
EMU,
EUU,
FCS,
HPC,
LAC,
LCN,
LDC,
LTE,
MDE,
MEA,
MNA,
NAC,
NAF,
NRS,
OED,
OSS,
PRE,
PSS,
PST,
RRS,
SAS,
SSA,
SSF,
SST,
SXZ,
WLD,
XZN
income_level
enum<string> | null

Restrict to countries at this income level

Available options:
HIC,
INX,
LIC,
LMC,
LMY,
MIC,
UMC
lending_type
enum<string> | null

Restrict to countries with this World Bank lending type

Available options:
IBD,
IDB,
IDX,
LNX

Response

Successful Response

id
string
required
@type
string
default:@worldbank_country
iso2_code
string | null
name
string | null
region
WorldbankRef · object
adminregion
WorldbankRef · object
income_level
WorldbankRef · object
lending_type
WorldbankRef · object
capital_city
string | null
longitude
number | null
latitude
number | null