Skip to main content
Glama

Countries By Language

countries_by_language
Read-onlyIdempotent

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

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
languageYesLanguage name (e.g. "spanish", "french", "arabic")

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
countYesTotal number of countries speaking the language
languageYesLanguage name queried
countriesYesCountries where language is spoken, sorted by population descending

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / properties / countries / items / properties / population / type
      Previous value: -"integer"New value: +[
      +  "integer",
      +  "null"
      +]
  2. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "count": {
      +      "description": "Total number of countries speaking the language",
      +      "type": "integer"
      +    },
      +    "countries": {
      +      "description": "Countries where language is spoken, sorted by population descending",
      +      "items": {
      +        "properties": {
      +          "capital": {
      +            "description": "Capital city or N/A if not available",
      +            "type": "string"
      +          },
      +          "name": {
      +            "description": "Common country name",
      +            "type": "string"
      +          },
      +          "population": {
      +            "description": "Total population",
      +            "type": "integer"
      +          },
      +          "region": {
      +            "description": "Geographic region",
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "name",
      +          "capital",
      +          "region",
      +          "population"
      +        ],
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "language": {
      +      "description": "Language name queried",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "language",
      +    "count",
      +    "countries"
      +  ],
      +  "type": "object"
      +}
  3. Changed1 schema field changed
    • addedInput schema / examples
      Added value: +[
      +  {
      +    "language": "spanish"
      +  },
      +  {
      +    "language": "mandarin"
      +  }
      +]
  4. First observed

TDQS

A3.8/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint, idempotentHint, openWorldHint and destructiveHint=false, so the safety profile is fully covered without the description. The description adds the returned field list, but with an output schema present that information is largely redundant rather than new behavioral context.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two compact sentences, front-loaded with the action and scope, with no filler. Every clause carries information about the query domain or the result.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a one-parameter, annotated, read-only lookup with an output schema, the description covers purpose and scope adequately. The only mild gap is that it doesn't say how language names are matched (exact string, aliases, case sensitivity), which an agent might need when the user says 'Castilian' or 'Mandarín'.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% and the single parameter is fully documented in the schema, so the baseline is 3. The description's examples ('Spanish', 'Mandarin') echo what the schema already shows and add no new semantics such as exact-match vs fuzzy matching or case handling.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Find countries') plus the scoping dimension ('where a language is spoken'), which cleanly distinguishes it from siblings like countries_by_region and countries_by_currency. The inline examples ('Spanish', 'Mandarin') remove any ambiguity about the input domain.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is implied by the name and the phrase 'where a language is spoken,' but the description never states when to prefer this over search_countries, get_country_by_code, or the region/currency siblings. No exclusions, prerequisites, or routing guidance are given.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.