Country Lookup
ref_geo_lookupLook up a country by name, ISO alpha-2 code (2 letters), or ISO alpha-3 code (3 letters). Returns the full record: capital, region, official languages, currencies, calling codes, TLD, flag emoji, and IANA timezone IDs. Accepts fuzzy name matching โ "Brasil" and "Brazil" both resolve.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"query": "<query>"
},
"name": "ref_geo_lookup"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| by | No | Lookup strategy: auto tries alpha2, alpha3, then name in order. | auto |
| query | Yes | Country name (e.g., "Germany"), ISO alpha-2 code (e.g., "DE"), or ISO alpha-3 code (e.g., "DEU"). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tld | No | Country-code top-level domain (e.g., ".de"), or null if not applicable. | |
| flag | No | Flag emoji (e.g., ๐ฉ๐ช). | |
| name | No | Official English country name. | |
| error | No | Present when the call failed. Absent on success. | |
| alpha2 | No | ISO 3166-1 alpha-2 code (2 letters). | |
| alpha3 | No | ISO 3166-1 alpha-3 code (3 letters). | |
| notice | No | Present only when the country was resolved via fuzzy name matching (starts-with or contains), not an exact code or name hit. Echoes the query and the resolved country so the caller can normalize follow-up lookups. | |
| region | No | Continent-level region (Africa, Americas, Asia, Europe, Oceania, Antarctic). | |
| capital | No | Capital city name, or null if not applicable (e.g., Antarctica). | |
| languages | No | Official or widely spoken languages in the country. | |
| subregion | No | Subregion within the continent (e.g., "Western Europe"), or null if unavailable. | |
| timezones | No | IANA timezone IDs observed in this country (e.g., "America/New_York"). | |
| currencies | No | Currencies used in the country. | |
| native_name | No | Country name in the primary native language. | |
| calling_codes | No | International dialing codes with leading + (e.g., "+1", "+44"). |