get_population

Pack: worldbank · Endpoint: https://gateway.pipeworx.io/worldbank/mcp

Get total population over time for a country. Shortcut for get_indicator with SP.POP.TOTL.

Parameters

NameTypeRequiredDescription
country_codestringyesISO country code (e.g., “US”, “GBR”, “CN”)

Example call

Arguments

{
  "country_code": "BR"
}

curl

curl -X POST https://gateway.pipeworx.io/worldbank/mcp \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"get_population","arguments":{"country_code":"BR"}}}'

TypeScript (@pipeworx/sdk)

import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();

const result = await pipeworx.call('get_population', {
  "country_code": "BR"
});

Response shape

Always returns: country, country_id, indicator_id, indicator_name, date_range, total_records, last_updated, data

FieldTypeDescription
countrystringCountry name or code
country_idstring | nullWorld Bank country ID
indicator_idstringWorld Bank indicator code
indicator_namestring | nullFull indicator name/description
date_rangestringRequested date range in start:end format
total_recordsnumberTotal number of records available
last_updatedstring | nullLast update timestamp from World Bank API
dataarrayTime-series population data sorted by year descending
Full JSON Schema
{
  "type": "object",
  "properties": {
    "country": {
      "type": "string",
      "description": "Country name or code"
    },
    "country_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "World Bank country ID"
    },
    "indicator_id": {
      "type": "string",
      "description": "World Bank indicator code"
    },
    "indicator_name": {
      "type": [
        "string",
        "null"
      ],
      "description": "Full indicator name/description"
    },
    "date_range": {
      "type": "string",
      "description": "Requested date range in start:end format"
    },
    "total_records": {
      "type": "number",
      "description": "Total number of records available"
    },
    "last_updated": {
      "type": [
        "string",
        "null"
      ],
      "description": "Last update timestamp from World Bank API"
    },
    "data": {
      "type": "array",
      "description": "Time-series population data sorted by year descending",
      "items": {
        "type": "object",
        "properties": {
          "year": {
            "type": [
              "string",
              "null"
            ],
            "description": "Year of the observation"
          },
          "value": {
            "type": [
              "number",
              "null"
            ],
            "description": "Total population value for the year"
          }
        }
      }
    }
  },
  "required": [
    "country",
    "country_id",
    "indicator_id",
    "indicator_name",
    "date_range",
    "total_records",
    "last_updated",
    "data"
  ]
}

Connect

Add this to your MCP client config, or use one-click install buttons:

{
  "mcpServers": {
    "worldbank": {
      "url": "https://gateway.pipeworx.io/worldbank/mcp"
    }
  }
}

See Getting Started for client-specific install steps.

Regenerated from source · build May 9, 2026