home
docs
EconDash

Endpoints

API endpoints reference

Free trial and pay per call (AI agents, x402 / MPP)

The routes below answer free trial data directly. Outside the trial (another country or indicator, or over the free quota) they return 402 with x402 and MPP challenges; pay and retry the same request, or use an API key.

The same GET routes are also served under /api/v1/m2m/<same-path>, where every call is paid (the address EconDash is listed under in x402 catalogs). /api/proxy is an internal site endpoint, not for integrations — do not use /api/proxy?path=....

Details, token contracts, and examples: Agent payments.

Uptime and response times of the site, the data API and agent payments are public at status.econdash.org, checked every 5 minutes from outside our server. Target: availability of the site and API at least 99.5% per month.


Time Series

GET /api/v1/timeseries/{code}

Returns time series data for an indicator.

ParamTypeDescription
countrystringISO3 code (required for trial)
start_datedateYYYY-MM-DD
end_datedateYYYY-MM-DD
limitintMost recent points to return (default 10000, up to 100000; a longer series is cut from the oldest end; trial max 1000)

GET /api/v1/timeseries/{code}/top-countries

Returns top N countries by latest value.

ParamTypeDescription
limitint1–50 (trial max 10)

Metadata

  • GET /api/v1/indicators — List indicators
  • GET /api/v1/sources — List data sources for indicators (Data Sources)
  • GET /api/v1/news-sources — List RSS news sources (News Sources)
  • GET /api/v1/indicators/{code} — Indicator metadata
  • GET /api/v1/indicators/by-slug/{slug} — By URL slug
  • GET /api/v1/indicators/{code}/countries — Countries with data
  • GET /api/v1/countries — List countries
  • GET /api/v1/countries/{iso3} — Country data
  • GET /api/v1/countries/{iso3}/indicators — Indicators for country
  • GET /api/v1/categories — List categories
  • GET /api/v1/stats — Database stats

News

  • GET /api/v1/news — News with optional indicator, category, country filters
  • GET /api/v1/news/{news_id} — Single news item by ID

AI Citation

  • GET /api/v1/cite/{country}/{indicator} — AI-optimized citation data for one indicator: the latest value, trend, source, and pre-formatted citation strings (text, short, markdown). A single snapshot, not a full time series. Free inside the trial quota (300 requests/day and 30/minute per IP). After that quota the same URL answers 402, payable with x402/MPP or an API key. An unknown country or indicator is 404 and is not billed. Both path segments accept friendly aliases — country (us, eu, cn) and indicator (cpi, gdp, unemployment, …), e.g. /api/v1/cite/us/cpi, /api/v1/cite/eu/gdp, /api/v1/cite/us/unemployment.

M2M Discovery

  • GET /openapi.json (same file at /api/v1/m2m/openapi.json) — OpenAPI 3.1 spec for every route on both /api/v1 and /api/v1/m2m. Free, no payment required. Use for agent route discovery before paying.

OKF Knowledge Bundle

  • GET /okf/index.md — entry point to the Open Knowledge Format v0.1 bundle: a machine-readable Markdown knowledge graph for AI agents. Free, no payment required. Human-readable overview at econdash.org/okf.
  • Structure: /okf/metrics/index.md (indicator catalog), /okf/concepts/index.md (economic explainers), /okf/data-sources/index.md (providers).
  • Metadata only — names, descriptions, units, coverage ranges, observation counts, sources and chart links. No raw time-series values; full numeric data requires a subscription or per-query agent payment (x402 / MPP).
  • Regenerated weekly from the live database, so coverage (date ranges, observation counts, new indicators) stays current.

Chat

Not available via API. Chat is only available on econdash.org.