Economics
Data source: World Bank Open Data
MCP Protocol
Endpoint
https://context.gnist.ai/mcp/worldbank/
claude_desktop_config.json
{
"mcpServers": {
"gnist-worldbank": {
"url": "https://context.gnist.ai/mcp/worldbank/",
"headers": {
"Gnist-API-Key": "YOUR_API_KEY"
}
}
}
}
Shell
curl -X POST "https://context.gnist.ai/mcp/worldbank/" \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-H "Gnist-API-Key: YOUR_API_KEY" \
-d '{"jsonrpc": "2.0", "method": "tools/call", "id": 1, "params": {"name": "get_indicator", "arguments": {"country_code": "example", "indicator_code": "example"}}}'
REST API
API Root
https://context.gnist.ai/rest/worldbank/
5 endpoints available:
GET /rest/worldbank/get_indicatorGET /rest/worldbank/search_indicatorsGET /rest/worldbank/country_profileGET /rest/worldbank/compare_countriesGET /rest/worldbank/report_feedback
Shell
curl "https://context.gnist.ai/rest/worldbank/get_indicator?country_code=example&indicator_code=example" \ -H "Gnist-API-Key: YOUR_API_KEY"
Python
import httpx
resp = httpx.get(
"https://context.gnist.ai/rest/worldbank/get_indicator",
headers={"Gnist-API-Key": "YOUR_API_KEY"},
params={
"country_code": "example",
"indicator_code": "example"
},
)
print(resp.json())
Command Line
Command
gc worldbank
CLI documentation will be available when the GnistAI SDK is published.
Install
pip install gnistai
Available Tools (5)
get_indicatorFetch a time series for a World Bank indicator.
| Parameter | Type | Required | Description |
|---|---|---|---|
country_code | string | required | ISO 3166-1 alpha-2 or alpha-3 country code (e.g. "US", "USA", "NO"). Use "WLD" for global aggregates or "all" for every country. |
indicator_code | string | required | World Bank indicator ID (e.g. "NY.GDP.MKTP.CD" for GDP, "SP.POP.TOTL" for population). Use search_indicators to find codes. |
year_from | any | optional | Start year (inclusive). If omitted, uses mrv instead. |
year_to | any | optional | End year (inclusive). If omitted, uses year_from as single year. |
mrv | integer | optional | Most recent values to return (1–50, default 10). Used when year_from/year_to are not set. (default: 10) |
search_indicatorsSearch the World Bank indicator catalog by keyword.
| Parameter | Type | Required | Description |
|---|---|---|---|
query | string | required | Search term (e.g. "gdp", "literacy rate", "co2 emissions"). |
per_page | integer | optional | Number of results to return (1–50, default 20). (default: 20) |
country_profileGet a snapshot of key development indicators for a country.
| Parameter | Type | Required | Description |
|---|---|---|---|
country_code | string | required | ISO 3166-1 alpha-2 or alpha-3 country code (e.g. "NO", "USA", "DE"). |
year | any | optional | Specific year to retrieve. Defaults to most recent available data. |
compare_countriesCompare one indicator across multiple countries for a given year.
| Parameter | Type | Required | Description |
|---|---|---|---|
indicator_code | string | required | World Bank indicator ID (e.g. "NY.GDP.MKTP.CD"). Use search_indicators to find the right code. |
country_codes | list[string] | required | List of ISO 3166-1 alpha-2 or alpha-3 codes (e.g. ["US", "DE", "JP"]). Maximum 20 countries per request. |
year | integer | required | The year to compare (e.g. 2022). |
report_feedbackReport a bug, feature request, or general feedback for this data source.
| Parameter | Type | Required | Description |
|---|---|---|---|
feedback | string | required | |
feedback_type | string | optional | (default: "general") |