Returns a paginated list of countries with their ISO codes, region information, capital city, and geographic coordinates. Each country entry includes nested objects showing the region, administrative region, income level, and lending type classifications.
From spec: Retrieve all countries classified under a specific income level.
Usage Tips
- Supports pagination via per_page and page query parameters
- Common income levels: LIC (Low income), LMC (Lower middle income), UMC (Upper middle income), HIC (High income)
- Response includes country coordinates useful for mapping applications
import zingu_apis
api = zingu_apis.api("world-bank")
result = api.fetch("incomeLevel/{income_level_code}/country", format="json", per_page=3)
for item in result:
print(item)
const resp = await fetch("https://api.worldbank.org/v2/incomeLevel/LIC/country?format=json&per_page=3");
const data = await resp.json();