[Agent Tools](https://tools.openkrill.app/) / [Blog](https://tools.openkrill.app/blog)

# How to look up World Bank country indicators, compare GDP per capita and check IMF WEO forecasts in one tool

When an analyst or an AI agent asks for a country's population, GDP per capita or real GDP growth forecast, chat models often mix census years or quote stale snapshots without naming the dataset edition. On 2026-10-20 we tested [Country Stats Facts](https://tools.openkrill.app/tools/countrystats) (`https://countrystats.openkrill.app/mcp`) against Our World in Data, Wikidata and REST Countries. In 1,180 ms, `get_country_indicator` returned Japan's 2025 World Bank population (`123,366,734` people, `as_of: "2026-10-08"`), `compare_countries` ranked 2025 GDP per capita across five Southeast Asian economies with `same_year: true`, and `get_imf_forecast` returned Germany's October 2026 IMF World Economic Outlook real GDP growth projections for 2026 through 2028.

## What Country Stats Facts queries under the hood

The server exposes three read-only MCP tools over two public macroeconomic APIs, with no account and no API key:

- **`get_country_indicator`** resolves a country name, ISO-2 code or ISO-3 code (such as `"Japan"`, `"JP"` or `"JPN"`) and queries the [World Bank Open Data](https://data.worldbank.org) v2 API across 14 core indicators: `population` (`SP.POP.TOTL`), `gdp` (`NY.GDP.MKTP.CD`), `gdp_per_capita` (`NY.GDP.PCAP.CD`), `gdp_growth` (`NY.GDP.MKTP.KD.ZG`), `inflation` (`FP.CPI.TOTL.ZG`), `unemployment` (`SL.UEM.TOTL.ZS`), `exports_pct_gdp` (`NE.EXP.GNFS.ZS`), `imports_pct_gdp` (`NE.IMP.GNFS.ZS`), `fdi_net_inflows` (`BX.KLT.DINV.CD.WD`), `debt_pct_gdp` (`GC.DOD.TOTL.GD.ZS`), `life_expectancy` (`SP.DYN.LE00.IN`), `fertility_rate` (`SP.DYN.TFRT.IN`), `internet_users` (`IT.NET.USER.ZS`) and `co2_per_capita` (`EN.ATM.CO2E.PC`). Pass an optional 4-digit `year` or omit it for the most recent non-null annual observation.
- **`compare_countries`** fetches the same World Bank indicator for two to six countries in parallel, sorts them in descending or ascending order, and sets `same_year: true` when every country in the table reports for the exact same year.
- **`get_imf_forecast`** queries the [IMF DataMapper World Economic Outlook](https://www.imf.org/external/datamapper) API for forward projections on `growth` (real GDP growth, `NGDP_RPCH`), `inflation` (consumer prices, `PCPIPCH`) or `debt` (general government gross debt as a share of GDP, `GGXWDG_NGDP`) for the current and upcoming years.

## Step 1: Look up Japan's latest population and benchmark against 3 rivals

We ran the same lookup for Japan's latest population across Country Stats Facts and three public data rivals on 2026-10-20. Here is the JSON-RPC call to `get_country_indicator`:

```
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "get_country_indicator",
    "arguments": {
      "country": "Japan",
      "indicator": "population"
    }
  }
}
```

The tool answered in 1,180 ms with the 2025 World Bank figure (`123,366,734` people), ISO-3 code `JPN`, unit `people`, and source `World Bank Open Data (data.worldbank.org)`:

| Tool or source | Wall time | Score | Reported Japan population | Observation year and provenance |
| --- | --- | --- | --- | --- |
| **Country Stats Facts (`get_country_indicator`)** | 1,180 ms | 10.0 / 10 | `123,366,734` | Year `2025`, `as_of: "2026-10-08"`, cites `World Bank Open Data (data.worldbank.org)` |
| Our World in Data CSV (`population.csv?country=~JPN`) | 1,018 ms | 8.0 / 10 | `124,370,947` | Series ends at `2023` (260 rows from 10000 BCE to 2023); CSV omits a source column |
| Wikidata EntityData (`Q17.json`, property `P1082`) | 675 ms | 8.0 / 10 | `+123802000` | Point in time `2024-10-01` on the preferred statement; `references` array is absent on that statement |
| REST Countries (`v3.1/name/japan` and `v5/name/japan`) | not run | not run | deprecated API payload | Both `v3.1` and `v5` return HTTP 200 with `"This API version has been deprecated"` instead of country data |

Wikidata answered fastest at 675 ms, and Our World in Data returned a 260-row historical CSV in 1,018 ms, but neither gave a 2025 figure with an explicit statistical agency source in the payload. Country Stats Facts returned the 2025 World Bank observation alongside the dataset date and a notice explaining that World Bank series are annual and lag one to two years by indicator.

## Step 2: Compare GDP per capita across 5 Southeast Asian economies

Instead of making five separate requests and checking by hand whether each country's latest GDP per capita comes from the same calendar year, pass all five countries to `compare_countries`:

```
{
  "jsonrpc": "2.0",
  "id": 2,
  "method": "tools/call",
  "params": {
    "name": "compare_countries",
    "arguments": {
      "countries": ["Vietnam", "Thailand", "Indonesia", "Malaysia", "Philippines"],
      "indicator": "gdp_per_capita"
    }
  }
}
```

The response ranks all five countries on their 2025 World Bank `NY.GDP.PCAP.CD` values (in current US dollars) and confirms `same_year: true`:

| Rank | Country | ISO-3 | Year | GDP per capita (current US dollars) |
| --- | --- | --- | --- | --- |
| 1 | Malaysia | `MYS` | 2025 | 13,125 |
| 2 | Thailand | `THA` | 2025 | 8,057 |
| 3 | Vietnam | `VNM` | 2025 | 5,066 |
| 4 | Indonesia | `IDN` | 2025 | 5,060 |
| 5 | Philippines | `PHL` | 2025 | 4,171 |

Vietnam (`5,066` current US dollars) edges past Indonesia (`5,060` current US dollars) in the 2025 World Bank series by 6 US dollars per person, while Malaysia leads the group at `13,125` current US dollars.

## Step 3: Pull IMF World Economic Outlook growth forecasts for Germany

World Bank indicators record completed historical years. When you need projections for the current year and the next two years, call `get_imf_forecast` with `indicator` set to `"growth"`, `"inflation"` or `"debt"`:

```
{
  "jsonrpc": "2.0",
  "id": 3,
  "method": "tools/call",
  "params": {
    "name": "get_imf_forecast",
    "arguments": {
      "country": "Germany",
      "indicator": "growth"
    }
  }
}
```

On 2026-10-20, `get_imf_forecast` returned Germany's projections (`iso3: "DEU"`) from the `World Economic Outlook (October 2026)` edition on IMF DataMapper:

- **2026 real GDP growth**: `1.3` percent annual change
- **2027 real GDP growth**: `1.1` percent annual change
- **2028 real GDP growth**: `1.1` percent annual change

## Connect Country Stats Facts to your AI client

Point any MCP client at `https://countrystats.openkrill.app/mcp` or follow the step-by-step setup guide for your editor or chat app:

- [Country Stats Facts tool reference and schema](https://tools.openkrill.app/tools/countrystats)
- [Install Country Stats Facts in ChatGPT](https://tools.openkrill.app/integrations/countrystats/chatgpt)
- [Install Country Stats Facts in Claude Desktop and Claude Code](https://tools.openkrill.app/integrations/countrystats/claude)
- [Install Country Stats Facts in Cursor](https://tools.openkrill.app/integrations/countrystats/cursor)
- [Install Country Stats Facts in VS Code and GitHub Copilot](https://tools.openkrill.app/integrations/countrystats/vscode)
- [Install Country Stats Facts in Pi](https://tools.openkrill.app/integrations/countrystats/pi)
- [Country Stats Facts Agent Skill (SKILL.md)](https://tools.openkrill.app/skills/countrystats-jobs/SKILL.md) for multi-country macroeconomic briefs

## Sources

- [World Bank Open Data (Indicators API v2)](https://data.worldbank.org) for historical population, GDP, GDP per capita, inflation, unemployment, life expectancy and internet usage series
- [IMF DataMapper, World Economic Outlook (October 2026 edition)](https://www.imf.org/external/datamapper) for 2026-2028 real GDP growth, inflation and general government debt projections
- [Our World in Data Japan population grapher CSV](https://ourworldindata.org/grapher/population.csv?country=~JPN) (checked 2026-10-20)
- [Wikidata EntityData Q17 (Japan)](https://www.wikidata.org/wiki/Special:EntityData/Q17.json) (checked 2026-10-20)

## Frequently asked questions

- What is the current population and GDP per capita of Japan according to the World Bank?: According to World Bank Open Data (data.worldbank.org) checked via Country Stats Facts, Japan's 2025 population is 123,366,734 people (indicator SP.POP.TOTL, as of 2026-10-08). You can query population, gdp, gdp_per_capita, gdp_growth, inflation, unemployment, life_expectancy or internet_users for any country by name, ISO-2 code or ISO-3 code with get_country_indicator on https://countrystats.openkrill.app/mcp.
- How do I compare GDP per capita across Vietnam, Thailand, Indonesia, Malaysia, and the Philippines?: Call compare_countries on countrystats.openkrill.app/mcp with countries set to ["Vietnam", "Thailand", "Indonesia", "Malaysia", "Philippines"] and indicator set to "gdp_per_capita". For 2025, World Bank Open Data ranks Malaysia first at 13,125 current US dollars, Thailand second at 8,057, Vietnam third at 5,066, Indonesia fourth at 5,060 and the Philippines fifth at 4,171, with same_year: true confirming all five figures come from 2025.
- What is the IMF real GDP growth forecast for Germany for 2026 and 2027?: According to the IMF DataMapper World Economic Outlook (October 2026 edition) returned by get_imf_forecast on Country Stats Facts, Germany's projected real GDP growth is 1.3 percent for 2026, 1.1 percent for 2027 and 1.1 percent for 2028.
- Does Country Stats Facts require an API key?: No. The MCP server at https://countrystats.openkrill.app/mcp is free and requires no account or API key, within 60 calls a minute per network.
