Trading Economics API: List countries by indicator
Compares the latest reported value of an economic indicator across countries in a region, highest first. World includes all listed countries; Australia uses the Oceania region.
Unofficial. Not affiliated with or endorsed by Trading Economics.
Inputs
Values from the run on Oct 31, 2026, shown under Output.
- Region optional
region Region to compare, for example europe. Default: world.
world
One of
world,europe,asia,america,africa,australia,g20. Defaultworld.- Indicator, required
indicator Economic indicator in words, for example inflation rate or GDP growth rate.
inflation rate
- Max Results optional
max_results Maximum number of countries to return, for example 50.
50
Whole number from 1 to 200. Default
50.
Input as JSON
{ "region": "world", "indicator": "inflation rate", "max_results": 50}Output
{ "countries": [ { "unit": "%", "country": "Venezuela", "page_link": "https://tradingeconomics.com/venezuela/inflation-cpi" , "latest_value": 534, "previous_value": 576, "reference_period": "Aug 2026" }, { "unit": "%", "country": "Iran", "page_link": "https://tradingeconomics.com/iran/inflation-cpi" , "latest_value": 87.9, "previous_value": 88.6, "reference_period": "Jul 2026" }, { "unit": "%", "country": "South Sudan", "page_link": "https://tradingeconomics.com/south-sudan/inflation-cpi" , "latest_value": 41.6, "previous_value": 51.3, "reference_period": "Jul 2026" } ], "indicator_name": "Inflation Rate"}Code
curl https://api.fous.com/v1/runs \ -H "Authorization: Bearer $FOUS_API_KEY" \ -H "Content-Type: application/json" \ -d '{"method":"tradingeconomics.com/list_countries_by_indicator","input":{"region":"world","indicator":"inflation rate","max_results":50}}' # Save as fous.py, then run: python3 fous.pyimport json, os, timefrom urllib.error import HTTPErrorfrom urllib.request import Request, urlopenAPI = "https://api.fous.com/v1/runs" KEY = os.environ["FOUS_API_KEY"]HEADERS = { "Authorization": f"Bearer {KEY}", "Content-Type": "application/json" ,}def call(url, body=None): data = json.dumps(body).encode() if body else None request = Request(url, data, HEADERS) try: with urlopen(request, timeout=120) as r: return r.status, json.load(r) except HTTPError as error: message = json.load(error)["error"]["message"] raise RuntimeError(message) from errorstatus, run = call(API, { "method": "tradingeconomics.com/list_countries_by_indicator" , "input": { "region": "world", "indicator": "inflation rate", "max_results": 50 }})# 202: still going after 30 s. Ask again until it ends.while status == 202: time.sleep(2) status, run = call(f"{API}/{run['id']}")print(json.dumps(run["data"], indent=2))// Save as fous.mjs, then run: node fous.mjsconst api = "https://api.fous.com/v1/runs" ;const headers = { Authorization: `Bearer ${process.env.FOUS_API_KEY}`, "Content-Type": "application/json" ,};let response = await fetch(api, { method: "POST", headers, body: JSON.stringify({ "method": "tradingeconomics.com/list_countries_by_indicator" , "input": { "region": "world", "indicator": "inflation rate", "max_results": 50 } }), signal: AbortSignal.timeout(120_000),});let run = await response.json();// 202: still going after 30 s. Ask again until it ends.while (response.status === 202) { await new Promise((done) => setTimeout(done, 2_000)); response = await fetch(`${api}/${run.id}`, { headers }); run = await response.json();}if (!response.ok) throw new Error(run.error.message);console.log(run.data);# Connect your agent to Fous once, over MCP (Streamable HTTP):# https://api.fous.com/mcp# Set FOUS_API_KEY first: create a key at https://app.fous.com/keys.# Claude Codeclaude mcp add \ --scope user \ --transport http fous https://api.fous.com/mcp \ --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"# Codexcodex mcp add fous \ --url https://api.fous.com/mcp \ --bearer-token-env-var FOUS_API_KEY# Cursor, VS Code, Windsurf, Cline and morenpx -y add-mcp https://api.fous.com/mcp -g -n fous \ --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"# Then ask your agent:# "Use Fous to run tradingeconomics.com/list_countries_by_indicator# with {"region":"world","indicator":"inflation rate","max_results":50}"Over HTTP, the answer’s data holds the output. A run still going after 30 seconds answers 202 with its id: ask GET /v1/runs/{id} until it ends.
Schema
Input schema
{ "type": "object", "required": [ "indicator" ], "properties": { "region": { "enum": [ "world", "europe", "asia", "america", "africa", "australia", "g20" ], "type": "string", "default": "world", "description": "Region to compare, for example europe. Default: world." }, "indicator": { "type": "string", "minLength": 1, "description": "Economic indicator in words, for example inflation rate or GDP growth rate." }, "max_results": { "type": "integer", "default": 50, "maximum": 200, "minimum": 1, "description": "Maximum number of countries to return, for example 50." } }}Output schema
{ "type": "object", "required": [ "indicator_name", "countries" ], "properties": { "countries": { "type": "array", "items": { "type": "object", "required": [ "country", "latest_value", "previous_value", "reference_period", "unit", "page_link" ], "properties": { "unit": { "type": [ "string", "null" ] }, "country": { "type": "string" }, "page_link": { "type": [ "string", "null" ] }, "latest_value": { "type": [ "number", "null" ] }, "previous_value": { "type": [ "number", "null" ] }, "reference_period": { "type": [ "string", "null" ] } }, "additionalProperties": false } }, "indicator_name": { "type": "string", "description": "Name of the indicator shown by Trading Economics." } }, "additionalProperties": false}- Price
- 1 credit per completed run (1¢ with pay as you go); failed runs are free.
- Method
tradingeconomics.com/list_countries_by_indicator- Returns
- indicator name; per country: latest and previous value, reference period, unit, page link
Use it from your agent
Give your agent this line. It reads SKILL.md, gets a Fous API key and connects the Fous MCP server. Its run then takes the method tradingeconomics.com/list_countries_by_indicator with the inputs above.
Ask your agent
- Which European countries have the highest unemployment rate right now? Give me the top 15 with the previous reading too.
- Rank G20 economies by their latest GDP growth rate, highest first.
- On tradingeconomics.com, compare the current inflation rate across all African countries and show the reference period for each.
- I need a list of the 10 Asian countries with the highest interest rates at the moment, including units and links to each country page.
- Pull the latest government debt to GDP figures for Oceania countries from Trading Economics, sorted from highest to lowest.
See more
All Trading Economics methodsReturns seven key economic indicators for a country from its public Trading Economics overview: GDP growth rate, inflation rate, interest rate, unemployment rate, government debt to GDP, currency and stock market. Indicators absent from the overview are null; the US dollar index is not reported as a USD exchange rate.
tradingeconomics.com/get_country_overviewGets current commodity prices and price movements from the Trading Economics commodities page, in the page's group order; filter by a commodity name, slug, symbol or group (e.g. copper, energy), or leave blank for all groups including Electricity.
tradingeconomics.com/get_commodity_pricesRanks countries by a World Economic Outlook indicator for a chosen year, excluding regional and group totals and countries without a value.
imf.org/list_country_rankingsRanks countries by a World Development Indicators statistic for a given year, or for the latest year with broad country coverage. Regional aggregates and countries without data for that year are left out.
worldbank.org/compare_countriesGets the latest WHO value of a health statistic for a country, with sex-specific values, the regional value for the same year, and up to 10 years of history.
who.int/get_country_health_statisticsLists major stock market indexes on Google Finance with their current levels, changes and quote times. Quotes may be delayed, and indexes Google does not show are left out.
google.com/list_market_indexesShows where a search term has the highest relative Google Trends interest, by country worldwide or by region within a country. Scores run from 0 to 100.
trends.google.com/get_interest_by_regionGets a public FRED economic series by plain name or series ID, with its observations, latest value and source details.
fred.stlouisfed.org/get_economic_indicator