Live FX rates API: on-chain stablecoin rates (EUR, GBP, MXN, BRL, CAD, SGD, ZAR, IDR) with ECB deviation

Updated 2026-10-24

Use when an agent needs live on-chain rates for EUR, GBP, MXN, BRL, CAD, SGD, ZAR or IDR versus USD, plus exchange quotes for EURUSD, GBPUSD, USDJPY, AUDUSD, USDCAD, USDCHF, EURGBP and EURJPY and matching on-chain gaps, not the ECB fix.

The European Central Bank fixes its euro reference rates once per working day. POST https://tanod.dev/v1/fx/live answers a different question: what do public stablecoin pools on Base say a currency is worth right now? Each pair is priced by asking the pool's own quoter, in both directions, what a USD 100 trade would fetch. The reply gives bid, ask and mid, the price impact of a larger trade, the pool, the block and its timestamp, and the ECB rate for the same pair with its date and the deviation between the two.

These are indicative on-chain prices, not dealable quotes. Chain data carries no licence restrictions; the ECB figure beside each mid is credited and free from the ECB website.

The same reply also carries exchange bid, ask, mid and spread for EURUSD, GBPUSD, USDJPY, AUDUSD, USDCAD, USDCHF, EURGBP and EURJPY only, plus the gap from matching EURUSD, GBPUSD and USDCAD on-chain mids when both sides have usable quotes (timestamps and limitations below).

An example

curl -s -X POST https://tanod.dev/v1/fx/live \
  -H "Content-Type: application/json" -H "X-Tanod-Free: 1" \
  -d '{"pairs": ["EURUSD", "USDMXN"], "amount_usd": 1000}'

{"pairs": [
  {"pair": "EURUSD", "bid": "1.1196564", "ask": "1.1198134", "mid": "1.1197349",
   "spread_pct": 0.014, "price_impact_pct": 0.0001,
   "stablecoin": {"symbol": "EURC", ...}, "venue": "aerodrome_slipstream",
   "pool": "0xf39B7c34BE147F5DC1bC374f27AF2E9f03AD3113", "fee_tier": 70,
   "ecb": {"rate": "1.1206", "date": "2026-10-09", "stale": false},
   "deviation_pct": -0.0772, "block": 52445369, "timestamp": "2026-10-11T00:54:45Z", ...},
  {"pair": "USDMXN", "bid": "18.433050", "ask": "18.451529", "mid": "18.442287", ...,
   "ecb": {"rate": "18.200071", "date": "2026-10-09"}, "deviation_pct": 1.3309, ...}],
 "thin": [...], "errors": [], "cached": false, "indicative": true, ...}

That sample was taken on a Sunday: the ECB date is Friday's fixing, so part of any deviation is the weekend, and part is the pool. Do not read the deviation as the pool's error alone.

What you send

pairs (optional, default all) in market convention: EURUSD is USD per EUR, USDMXN is MXN per USD. amount_usd (optional, 100 to 100000, default 1000) is the reference trade size for the price-impact measurement. USDJPY (JPY per USD), AUDUSD (USD per AUD), USDCHF (CHF per USD), EURGBP (GBP per EUR) and EURJPY (JPY per EUR) may be named too; they return exchange quotes only, with no configured on-chain pool. EURUSD, GBPUSD and USDCAD have both exchange quotes and configured on-chain pools. An unknown pair is a 422 that lists the supported pairs, and is not charged.

The pairs

PairStablecoin on BaseVenue
EURUSDEURC (Circle)Aerodrome Slipstream, Uniswap V3 (best of three pools)
GBPUSDtGBPAerodrome Slipstream
USDMXNMXNB (Bitso)Aerodrome Slipstream
USDBRLBRLAAerodrome Slipstream
USDCADCADCAerodrome Slipstream
USDSGDXSGDAerodrome Slipstream
USDZARZARPAerodrome Slipstream
USDIDRIDRXAerodrome Slipstream
USDJPYnone with a usable poolExchange quotes only
AUDUSDAUDD (too thin, listed under thin)Exchange quotes only
USDCHFno configured poolExchange quotes only
EURGBPno configured poolExchange quotes only
EURJPYno configured poolExchange quotes only

A stablecoin can trade away from its currency: the rate you get is the price of that token in USDC, which is what the pool offers, not the issuer's redemption rate.

How bid, ask and mid are worked out

The service calls the venue's QuoterV2 through one Multicall3 eth_call per round, the same path as the swap-quote route. Round one buys the stablecoin with USDC at USD 100 and at amount_usd. Round two sells exactly what was bought back for USDC. ask is the USDC paid per unit bought; bid is the USDC received per unit sold; for the USDxxx pairs both are inverted so they read as units per USD. mid is the geometric mean of bid and ask at USD 100. Each direction pays the pool fee once, so the geometric mean removes it. price_impact_pct is how much worse the average price at amount_usd is than at USD 100, the larger of buying and selling.

Thin pools are never rates

A pair is only given a rate when a quote at amount_usd moves the price by less than 1%. Otherwise it appears under thin with the measured impact. Stablecoins researched on 2026-10-11 that failed that test are listed there too with their depth: BRZ (about USD 3,100 of USDC in the pool), AUDD (about USD 260) and MXNe (about USD 120). Larger amount_usd values push more pairs into thin: the Indonesian rupiah pool, for one, holds under USD 5,000 of USDC, so its rate is only reliable for small sizes. No JPY stablecoin on Base had a usable pool when this was researched, so USDJPY, like AUDUSD, comes from exchange quotes instead.

Exchange quotes and the on-chain gap

Beside the pool pairs, exchange_quotes carries indicative quotes from a regulated exchange: bid, ask, arithmetic mid and spread_pct for EURUSD, GBPUSD, USDJPY, AUDUSD, USDCAD, USDCHF, EURGBP and EURJPY only. USDJPY, AUDUSD, USDCHF, EURGBP and EURJPY are exchange-only, with no configured usable on-chain pool. EURUSD, GBPUSD and USDCAD also have configured on-chain pools. All markets share one cache refreshed at most every 60 seconds. as_of is the fetch-window start and age_s is time since that fetch, not venue quote age. venue_timestamp is null because the ticker supplies no quote timestamp; even a newly fetched quote can reflect an inactive market. No order-book depth, trades or volume is returned. Spreads above 0.5% of mid are listed under exchange_omitted instead of quoted. Implausible quotes are omitted too: bid and ask must fall within 10% of an available ECB reference, or within a fixed pair-specific band when no reference is available.

If an exchange-only request has no usable quote (all omitted, unavailable or older than the retention limit), it returns 503 exchange_unavailable and is not charged; a free use is returned. Requests that include pool pairs keep the partial-result behavior, with exchange omissions or failures alongside the pool results.

On upstream failure, last good quotes may be retained up to 300 seconds from the original fetch, explicitly marked stale: true with increasing age_s and an errors entry. Older data is not served. The pool pairs are unaffected. For pairs present in both sets, exchange_gaps compares the geometric on-chain mid with the arithmetic exchange mid and reports gap_pct = (onchain_mid / exchange_mid - 1) * 100: positive means the on-chain mid is higher in the same market convention. Each comparison retains the on-chain timestamp, exchange fetch time, age and stale flag. These are unsynchronized indicative comparisons, not executable arbitrage, profit estimates or an oracle.

"exchange_quotes": [
  {"pair": "AUDUSD", "base": "AUD", "quote": "USD", "bid": "0.69574", "ask": "0.69589", "mid": "0.695815",
   "spread_pct": 0.0216, "source": "indicative quotes from a regulated exchange",
   "as_of": "2026-10-13T04:21:07Z", "age_s": 12.4, "venue_timestamp": null, "stale": false}, ...],
"exchange_omitted": [{"pair": "USDJPY", "code": "spread_too_wide", "spread_pct": 2.3519, ...}],
"exchange_gaps": [{"pair": "EURUSD", "onchain_mid": "1.1197349", "exchange_mid": "1.117225",
  "gap_pct": 0.2247, "onchain_timestamp": "2026-10-11T00:54:45Z",
  "exchange_as_of": "2026-10-13T04:21:07Z", "exchange_age_s": 12.4, "exchange_stale": false}]

The exchange example above is illustrative, not a synchronized capture with the pool sample.

Poll it on a schedule

Pool rates are cached for 15 seconds and exchange quotes for up to 60 seconds, so faster polling can return the same numbers. On exchange refresh failure, stale quotes can be retained up to 300 seconds with their age and stale flag. At USD 0.002 a call: every minute is 1,440 calls, about USD 2.88 a day; every 5 minutes is 288 calls, about USD 0.58 a day or 17.28 a month; hourly is about USD 1.44 a month. One call returns every pair, so poll the whole set, not each pair. For a daily fixing instead of a live rate, the ECB rates route costs USD 0.001 and changes once a working day.

Limits

Use it from Claude without writing code: in claude.ai or Claude Desktop, add https://tanod.dev/mcp/finance?via=live-fx-rates-api as a custom connector (steps), then ask in plain words, for example "What is 1,000 Japanese yen worth in US dollars right now?" The free daily allowance is applied automatically over MCP. Beyond it a call needs an x402 payment, which these clients can make.

Related guides: live FX API prices compared, ECB exchange rates API, Uniswap swap quote API. Updated 2026-10-24. All guides, or back to tanod.dev. Results are automated.