GnistAI GnistAI
Log in

UN SDG

UN Sustainable Development Goals — 231 indicators across 17 goals covering poverty, health, education, climate, and inequality for 193 countries.

Overview   |   MCP   |   REST API   |   OpenAPI   |   CLI   |   Tutorial   |   Toolkits   |   Home
status: healthy status status healthy healthy tools: 8 tools tools 8 8 type: api wrapper type type api wrapper api wrapper lifecycle: maintained lifecycle lifecycle maintained maintained Economics

Data source: UN Stats SDG API v5

MCP Endpoint (Streamable HTTP) https://context.gnist.ai/mcp/unsdg/
Authentication

All requests require a Gnist-API-Key header (or api_key query parameter).

Free tier: 100 calls/day. Get your API key.

Tools (8)

list_sdg_goals

List all 17 UN Sustainable Development Goals.

Returns each goal's code (1-17), title, and description. Use the goal code
to explore targets and indicators via get_goal_targets.

Examples:
list_sdg_goals() → All 17 goals (poverty, hunger, health, education, etc.)

JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "list_sdg_goals",
    "arguments": {}
  }
}
get_goal_targets

Get targets and indicators for a specific SDG goal.

Returns the goal's targets (e.g. 1.1, 1.2) with their indicators and
data series codes. Use series codes with get_sdg_series_data for actual values.

Examples:
get_goal_targets(1) → Targets for 'No Poverty' (1.1 extreme poverty, 1.2 national poverty...)
get_goal_targets(13) → Targets for 'Climate Action'

ParameterTypeRequiredDescription
goal_codeintegerrequiredSDG goal number (1-17). E.g. 1 = No Poverty, 13 = Climate Action.
JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "get_goal_targets",
    "arguments": {
      "goal_code": 1
    }
  }
}
get_sdg_indicator_data

Get observation data for SDG indicators.

Returns time-series data for the specified indicators, optionally filtered
by country and time period. Each observation includes value, source,
geographic area, and any dimension breakdowns (age, sex, location, etc.).

Examples:
get_sdg_indicator_data(['1.1.1'], [156], 2010, 2023) → China poverty rate 2010-2023
get_sdg_indicator_data(['4.1.1'], [578]) → Norway education completion data
get_sdg_indicator_data(['13.2.2']) → All countries' greenhouse gas emissions

Returns:
Paginated observations with value, source, geo area, time period, and dimensions.

ParameterTypeRequiredDescription
indicator_codeslist[string]requiredIndicator code(s), e.g. ['1.1.1'] for extreme poverty rate.
area_codesanyoptionalGeo area code(s). E.g. [578] for Norway, [840] for USA. Use search_sdg_geo_areas to find codes.
time_startanyoptionalStart year (e.g. 2015).
time_endanyoptionalEnd year (e.g. 2023).
pageintegeroptionalPage number (default 1). (default: 1)
page_sizeintegeroptionalResults per page, max 200 (default 50). (default: 50)
JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "get_sdg_indicator_data",
    "arguments": {
      "indicator_codes": [
        "example"
      ]
    }
  }
}
get_sdg_series_data

Get observation data for specific SDG data series.

More granular than indicator data — a single indicator may have multiple series
with different measurement methodologies. Use get_goal_targets to discover
available series codes.

Examples:
get_sdg_series_data(['SI_POV_DAY1'], [840], 2000, 2023) → US $2.15/day poverty
get_sdg_series_data(['EN_ATM_GHGT_AIP'], [578]) → Norway greenhouse gas index

Returns:
Paginated observations with value, source, and disaggregation dimensions.

ParameterTypeRequiredDescription
series_codeslist[string]requiredSeries code(s), e.g. ['SI_POV_DAY1'] for poverty rate.
area_codesanyoptionalGeo area code(s). E.g. [578] for Norway.
time_startanyoptionalStart year.
time_endanyoptionalEnd year.
pageintegeroptionalPage number. (default: 1)
page_sizeintegeroptionalResults per page, max 200. (default: 50)
JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "get_sdg_series_data",
    "arguments": {
      "series_codes": [
        "example"
      ]
    }
  }
}
search_sdg_geo_areas

Search for SDG geo area codes by name.

Returns matching country and region codes that can be used with the
indicator and series data tools.

Examples:
search_sdg_geo_areas('Norway') → [{'code': '578', 'name': 'Norway'}]
search_sdg_geo_areas('Africa') → All African regions and sub-regions

ParameterTypeRequiredDescription
querystringrequiredSearch term for country or region name (e.g. 'Norway', 'Africa').
JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "search_sdg_geo_areas",
    "arguments": {
      "query": "NO"
    }
  }
}
get_sdg_series_dimensions

Get available dimensions (disaggregations) for a data series.

Shows what breakdowns are available — age groups, sex, location type,
reporting type, etc. Useful for understanding what granularity exists
before querying data.

Examples:
get_sdg_series_dimensions('SI_POV_DAY1') → Age, Sex, Reporting Type dimensions

ParameterTypeRequiredDescription
series_codestringrequiredSeries code, e.g. 'SI_POV_DAY1'.
JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "get_sdg_series_dimensions",
    "arguments": {
      "series_code": "example"
    }
  }
}
get_sdg_data_availability

Get which countries and regions have data for a specific series.

Useful for checking data coverage before querying — not all series
have data for all countries.

Examples:
get_sdg_data_availability('SI_POV_DAY1') → Countries with poverty data

ParameterTypeRequiredDescription
series_codestringrequiredSeries code, e.g. 'SI_POV_DAY1'.
JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "get_sdg_data_availability",
    "arguments": {
      "series_code": "example"
    }
  }
}
report_feedback

Report a bug, feature request, or general feedback for this data source.

Use this when something doesn't work as expected, when you'd like
a new feature, or when you have suggestions for improvement.

Args:
feedback: Describe the issue or suggestion.
feedback_type: One of 'bug', 'feature_request', or 'general'.

ParameterTypeRequiredDescription
feedbackstringrequired
feedback_typestringoptional (default: "general")
JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "report_feedback",
    "arguments": {
      "feedback": "example"
    }
  }
}

Quick Start

Shell
curl -X POST "https://context.gnist.ai/mcp/unsdg/" \
  -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_goal_targets", "arguments": {"goal_code": 1}}}'
Python
import httpx

resp = httpx.post(
    "https://context.gnist.ai/mcp/unsdg/",
    headers={"Gnist-API-Key": "YOUR_API_KEY", "Content-Type": "application/json"},
    json={
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "get_goal_targets",
    "arguments": {
      "goal_code": 1
    }
  }
},
)
print(resp.json())

Related Toolkits (Economics)

Resources