countries_by_language

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

Find countries where a language is spoken (e.g., “Spanish”, “Mandarin”). Returns name, capital, region, population, and official language status.

Parameters

NameTypeRequiredDescription
languagestringyesLanguage name (e.g. “spanish”, “french”, “arabic”)

Example call

Arguments

{
  "language": "spanish"
}

curl

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

TypeScript (@pipeworx/sdk)

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

const result = await pipeworx.call('countries_by_language', {
  "language": "spanish"
});

More examples

{
  "language": "mandarin"
}

Response shape

Always returns: language, count, countries

FieldTypeDescription
languagestringLanguage name queried
countintegerTotal number of countries speaking the language
countriesarrayCountries where language is spoken, sorted by population descending
Full JSON Schema
{
  "type": "object",
  "properties": {
    "language": {
      "type": "string",
      "description": "Language name queried"
    },
    "count": {
      "type": "integer",
      "description": "Total number of countries speaking the language"
    },
    "countries": {
      "type": "array",
      "description": "Countries where language is spoken, sorted by population descending",
      "items": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "Common country name"
          },
          "capital": {
            "type": "string",
            "description": "Capital city or N/A if not available"
          },
          "region": {
            "type": "string",
            "description": "Geographic region"
          },
          "population": {
            "type": "integer",
            "description": "Total population"
          }
        },
        "required": [
          "name",
          "capital",
          "region",
          "population"
        ]
      }
    }
  },
  "required": [
    "language",
    "count",
    "countries"
  ]
}

Connect

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

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

See Getting Started for client-specific install steps.

Regenerated from source · build May 9, 2026