For Agents
Look up countries by name, capital, language, currency, region, regional bloc, calling code, or alpha code, and retrieve canonical country metadata. Returns JSON arrays of matching countries.
Install Jentic One Beta
Jentic One is a self-hosted execution layer for AI agents. It lets your agent call the Countrylayer API, or any other public or private API you need. You set the rules, the agent never sees your credentials, and every call is logged.
Two steps, two machines. Install the instance in a safe environment, then register your agent from wherever it runs.
Step 1: Jentic One Host machine
# On the machine that will host your Jentic One instance:
curl -fsSL "https://jentic.com/install.sh?src=apis&api=%2Fapis%2Fcountrylayer.com%2Fcountrylayer" | shStep 2: Agent machine
# On the machine where your agent runs (keep this separate from the instance):
curl -fsSL "https://jentic.com/install.sh?src=apis&api=%2Fapis%2Fcountrylayer.com%2Fcountrylayer" | sh
jentic register # connects your agent to your Jentic One instanceJentic One is in public beta. The setup above keeps your agent separate from the instance, which is what you want before using real credentials: an agent running as the same OS user as Jentic One can read its stored keys directly. Just evaluating? A single local install is fine to start. See the secure deployment guide for the tiers.
What an agent can do with Countrylayer API.
Retrieve a complete list of countries with metadata in one call
Search countries by full or partial name match
Resolve a capital city to its country record
Filter countries by official or spoken language
GET STARTED
Use for: I need to fetch a list of all countries with their currencies, Search for a country by its capital city, Find all countries that speak a given language, Get the calling code for a specific country
Not supported: Does not provide IP geolocation, state or city data, or live political news - use for static country reference metadata only.
The Countrylayer API is a REST service that returns rich country reference data - names, capitals, regions, languages, currencies, calling codes, regional blocs, and alpha codes - across 9 search and lookup endpoints. Authentication is via an `access_key` query parameter on the v2 base URL. It suits localisation, registration form dropdowns, shipping and tax rules, and any workflow that needs to resolve or validate country attributes without bundling a static dataset into the application.
Filter countries by currency code
Look up countries by ISO alpha-2 or alpha-3 code
Filter countries by region or regional bloc such as EU or ASEAN
Patterns agents use Countrylayer API for, with concrete tasks.
★ Localised Registration and Checkout
Populate country dropdowns, format phone numbers, and pick the right currency at signup or checkout by pulling fresh country data from the API rather than shipping a static list. The /all endpoint returns every country in one call which can be cached client-side, while /alpha/{code} resolves a stored ISO code back into a display name and calling code at runtime.
Call GET /all and cache the response, then on each checkout call GET /alpha/{code} to pull the calling code and currency for the user's stored country
Tax and Shipping Region Rules
Resolve a customer's country into the regional bloc, currency, and capital required for tax calculation or shipping zone selection. Use GET /regionalbloc/{regionalbloc} to enumerate the countries inside a bloc such as EU or NAFTA, or GET /currency/{currency} to list every country that uses a particular currency. Useful for e-commerce platforms applying VAT or duty rules.
Call GET /regionalbloc/EU and use the resulting list to apply VAT rules for orders shipping inside the European Union
Country Search and Autocomplete
Power a country search box that handles fuzzy name matches, capital city searches, and language filters. The API exposes /name/{name}, /capital/{capital}, and /language/{language} endpoints that all return JSON arrays of matching country records, so the front end can build a single autocomplete that pivots on whatever the user typed.
On each keystroke, call GET /name/{partial} and merge results with GET /capital/{partial} to rank country suggestions
AI Agent Country Enrichment
Let an AI agent enrich an unstructured 'country' string from a CRM record, support email, or scraped form into a canonical country record with currency, language, and calling code. Through Jentic, the agent searches by intent and the access_key is held in the encrypted vault so it never leaks into prompts or logs.
Use Jentic to search 'look up a country by name', load the schema for GET /name/{name}, and execute it with the user-supplied string
9 endpoints — the countrylayer api is a rest service that returns rich country reference data - names, capitals, regions, languages, currencies, calling codes, regional blocs, and alpha codes - across 9 search and lookup endpoints.
METHOD
PATH
DESCRIPTION
/all
Get all countries
/name/{name}
Search by country name
/capital/{capital}
Search by capital city
/language/{language}
Search by language
/currency/{currency}
Search by currency
/regionalbloc/{regionalbloc}
Search by regional bloc
/callingcode/{callingcode}
Search by calling code
/alpha/{code}
Search by ISO alpha code
/all
Get all countries
/name/{name}
Search by country name
/capital/{capital}
Search by capital city
/language/{language}
Search by language
/currency/{currency}
Search by currency
What agents get from Jentic-routed access to this vendor.
Setup
Wiring Countrylayer by hand means handling its access_key query-parameter auth, pinning the v2 host, and coding your own lookups by name, currency, or calling code. Through Jentic you install once, import Countrylayer from the API Directory, store the key once, and your agent calls it.
Permission scoping
Countrylayer is read-only country reference data where names and codes are lookup values in the path, not permissionable resources, so scope by operation: limit the agent to the operations it needs, such as looking up a country by name or currency. You choose the operations it may call, so it stays limited to those reads.
Credential isolation
Your Countrylayer access key is stored once, encrypted, by your own Jentic One instance and injected at execution time. It never enters the agent's prompt, logs, or context.
Intent-based discovery
Agents search Jentic by intent such as 'look up a country by name' or 'find countries using a currency', and Jentic returns the matching Countrylayer operation with its input schema so the agent calls the right endpoint without browsing the reference docs.
Alternatives and complements available in the Jentic catalogue.
Country State City API
Hierarchical country, state, and city dataset
Choose Country State City when you also need state and city data, not just country-level metadata
Specific to using Countrylayer API through Jentic.
What authentication does the Countrylayer API use?
Countrylayer uses an API access key passed as the `access_key` query parameter on every request. When called via Jentic, the key is stored encrypted in your Jentic One instance and the agent receives a scoped session token rather than the raw key.
Can I list every country in a single API call?
Yes. GET /all returns the full country dataset including names, capitals, regions, languages, currencies, calling codes, and alpha codes. Cache the response for 24 hours or longer because the underlying dataset changes rarely.
How do I find every country that uses the euro?
Call GET /currency/EUR. The response is a JSON array of country records, each containing the canonical name, capital, region, and other metadata. The same pattern works for any ISO 4217 currency code.
What are the rate limits for the Countrylayer API?
Rate limits and request quotas are determined by the Countrylayer subscription plan tied to the access_key. Free plans typically cap monthly requests in the low thousands while paid plans raise the cap; check the plan dashboard for exact numbers.
How do I look up a country by ISO code through Jentic?
Search Jentic for 'look up a country by alpha code', load the schema for GET /alpha/{code}, and execute it with the alpha-2 or alpha-3 code. Jentic supplies the access_key from the vault automatically.
Does Countrylayer return real-time political or border data?
No. The dataset reflects ISO and CIA World Factbook style reference data - names, capitals, currencies, languages, calling codes, and blocs. It is not a live news feed and does not track sanctions, conflicts, or border changes.
Can I limit what my agent is allowed to do with the Countrylayer API?
Yes. Countrylayer is read-only country reference data, so you scope the agent by operation from your own self-hosted Jentic One instance, where your rules decide which calls and credentials it may use. You can allow only the lookups the task needs, such as GET /name/{name} to search by country name or GET /currency/{currency} to list countries by currency, while withholding operations like GET /all or GET /regionalbloc/{regionalbloc}. The agent stays limited to the reads you permit.
/regionalbloc/{regionalbloc}
Search by regional bloc
/callingcode/{callingcode}
Search by calling code
/alpha/{code}
Search by ISO alpha code