Skip to main content
Glama

Compare Countries

compare_countries
Read-onlyIdempotent

Compare a World Bank indicator across MULTIPLE countries in one call, returned ranked high→low. PREFER for "GDP per capita: US vs China vs Germany", "rank the G7 by CO2 emissions", "compare population of ". Pass 2+ ISO country codes. Defaults to each country's most-recent available value; pass a year for a specific year. Common indicators: NY.GDP.MKTP.CD (GDP), NY.GDP.PCAP.CD (GDP per capita), SP.POP.TOTL (population), EN.GHG.CO2.MT.CE.AR5 (CO2, Mt), FP.CPI.TOTL.ZG (inflation %). For CO2 rankings prefer country_co2_emissions, which knows the right series.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
yearNoOptional 4-digit year (e.g. "2023"). Omit for each country's most-recent available value.
indicatorYesWorld Bank indicator code (e.g. "NY.GDP.PCAP.CD", "SP.POP.TOTL", "EN.GHG.CO2.MT.CE.AR5").
country_codesYes2+ ISO country codes, comma- or semicolon-separated (e.g. "US,CN,DE" or "USA;CHN;DEU").

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / examples
      Previous value: -[
      -  {
      -    "country_codes": "US,CN,DE",
      -    "indicator": "NY.GDP.PCAP.CD"
      -  },
      -  {
      -    "country_codes": "GB;FR;JP;CA",
      -    "indicator": "EN.ATM.CO2E.PC",
      -    "year": "2022"
      -  }
      -]New value: +[
      +  {
      +    "country_codes": "US,CN,DE",
      +    "indicator": "NY.GDP.PCAP.CD"
      +  },
      +  {
      +    "country_codes": "GB;FR;JP;CA",
      +    "indicator": "SP.DYN.LE00.IN",
      +    "year": "2022"
      +  }
      +]
  2. Changed1 schema field changed
    • changedInput schema / properties / indicator / description
      Previous value: -"World Bank indicator code (e.g. \"NY.GDP.PCAP.CD\", \"SP.POP.TOTL\", \"EN.ATM.CO2E.PC\")."New value: +"World Bank indicator code (e.g. \"NY.GDP.PCAP.CD\", \"SP.POP.TOTL\", \"EN.GHG.CO2.MT.CE.AR5\")."
  3. Changed1 schema field changed
    • addedInput schema / examples
      Added value: +[
      +  {
      +    "country_codes": "US,CN,DE",
      +    "indicator": "NY.GDP.PCAP.CD"
      +  },
      +  {
      +    "country_codes": "GB;FR;JP;CA",
      +    "indicator": "EN.ATM.CO2E.PC",
      +    "year": "2022"
      +  }
      +]
  4. Changed1 schema field changed
    • changedInput schema / properties / indicator / description
      Previous value: -"World Bank indicator code (e.g. \"NY.GDP.PCAP.CD\", \"SP.POP.TOTL\", \"EN.GHG.CO2.PC.CE\")."New value: +"World Bank indicator code (e.g. \"NY.GDP.PCAP.CD\", \"SP.POP.TOTL\", \"EN.ATM.CO2E.PC\")."
  5. Changed1 schema field changed
    • changedInput schema / properties / indicator / description
      Previous value: -"World Bank indicator code (e.g. \"NY.GDP.PCAP.CD\", \"SP.POP.TOTL\", \"EN.ATM.CO2E.PC\")."New value: +"World Bank indicator code (e.g. \"NY.GDP.PCAP.CD\", \"SP.POP.TOTL\", \"EN.GHG.CO2.PC.CE\")."
  6. Added

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already convey safety (readOnly, idempotent, non-destructive, openWorld), so the description adds value by disclosing behavioral traits not obvious from annotations: results are 'returned ranked high→low', it 'Defaults to each country's most-recent available value', and a year can be passed for a specific year. It also points to an alternative tool for CO2 rankings, adding nuance. While it doesn't describe output format, it provides meaningful behavioral context beyond the annotations.

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?

The description is compact yet information-dense, front-loading the purpose in the first sentence. Every subsequent sentence earns its place: examples, parameter guidance, indicator list, and sibling-tool disambiguation. No filler or redundancy, and the structure flows logically from purpose to usage to parameters.

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 moderately complex tool with no output schema, the description is quite complete: it covers purpose, usage scenarios, parameter constraints, default behavior, and common indicators. The only minor gap is the lack of explicit return format details, but given the simple, ranked-list nature of the output, the description is sufficient for correct invocation.

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

Parameters4/5

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

Schema coverage is 100% with descriptions for all three parameters, so the baseline is 3. The description enriches this by listing common indicator codes with labels (NY.GDP.PCAP.CD for GDP per capita, SP.POP.TOTL for population, etc.), helping the agent select valid inputs. It also clarifies the year parameter's optionality and default behavior, adding meaning beyond the schema's basic description.

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?

The description clearly states the tool's purpose: 'Compare a World Bank indicator across MULTIPLE countries in one call, returned ranked high→low.' This specifies the verb (compare), resource (World Bank indicator), and unique behavior (ranking), distinguishing it from siblings like get_gdp or get_population. Examples further clarify typical use cases.

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

Usage Guidelines5/5

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

The description explicitly says 'PREFER for' with concrete query examples, and provides an exclusion: 'For CO2 rankings prefer country_co2_emissions, which knows the right series.' It also instructs to 'Pass 2+ ISO country codes' and explains the year default behavior, giving clear when-to-use and when-not-to-use guidance.

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.