Fiat FX rates and conversion
fx_rate[PAID $0.002 USDC per call via x402 on Base; errors are free] Foreign-exchange rates from one base currency (from, default USD) to a list of currencies (to, comma-separated, or "all"; default 14 majors incl. EUR, GBP, JPY, CNY, INR, KRW, VND), with amount converted. Live mode uses Coinbase public exchange rates (cached 15 s, updated about every minute, 160+ ISO 4217 currencies plus XAU/XAG), falling back to exchangerate-api daily rates. With date=YYYY-MM-DD it returns the ECB reference rates for that day (Frankfurter, ~30 major currencies, back to 1999-01-04). All params optional: with none it returns USD to 14 major currencies. Invalid codes = 400, never charged.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "fx_rate"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | No | Comma-separated target codes (max 50) or "all". Default: EUR,GBP,JPY,CNY,CHF,CAD,AUD,INR,KRW,SGD,HKD,MXN,BRL,VND. | |
| date | No | Optional YYYY-MM-DD for historical ECB reference rates (since 1999-01-04). Omit for live rates. | |
| from | No | Base currency, ISO 4217 code (default USD). | |
| amount | No | Amount in `from` to convert (default 1). |