apyhub
Back
▣ VERIFICATION KIT

Currency, Crypto & Metals Rates API

What it does

The Convert Currency, Crypto & Metals API is a crypto and metals exchange rates API that also covers fiat money. Send a from code and one or more to codes, and get daily reference rates and converted amounts. It covers 340 codes: 154 fiat currencies, 4 metals (XAU, XAG, XPT, XPD) and 182 crypto assets.

Set to to one code or up to 20. from defaults to USD and amount defaults to 1. Add date for a past day. Crypto, metals and most currencies go back to 2024-03-02. About 30 major currencies go back to 1999-01-04. Use source to choose the rate set: auto (default), broad for all 340 codes, or ecb for the 30 major currencies.

For historical exchange rates over time, send startDate and endDate, up to 366 days apart. You get one row per working day and a high, low and percent change per currency. Ranges cover the 30 major currencies only. Set listCurrencies to true to get every supported code with its type and name.

Teams use it to convert order totals into a settlement currency and to show gold or bitcoin values next to local prices. It also helps chart currency exchange rates in reports and fill a currency picker.

As a crypto and metals exchange rates API it serves daily reference rates, so don't use it for trading or settlement.

To work out tax on a converted total, use the Calculate VAT and GST API or the US Sales Tax Calculator API.

POST
Get daily currency, crypto and metal rates
https://api.eu.apyhub.com/freedailypro/currency-crypto-metal-rates/converters/exchange-rates

QUICKSTART

GUIDE

Quickstart

Convert 250 USD to EUR and INR at the latest daily rates.

curl -X POST "https://api.eu.apyhub.com/freedailypro/currency-crypto-metal-rates/converters/exchange-rates" \
  -H "apy-token: $APY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"from": "USD", "to": ["EUR", "INR"], "amount": 250}'

What you'll get back

Returns a JSON object with a result object holding the rate for each target code, the converted amounts, the rate date and notes on the rates.

{
  "result": {
    "source": "Publicly available reference rates",
    "sourceId": "reference-broad",
    "note": "Daily reference rates, not live trading rates: they refresh about once a day, can differ from what a bank, card network or exchange charges, and for crypto and metals are not tradable prices. Do not use them for trading or settlement.",
    "live": false,
    "disclaimer": "Estimate for information only. Not financial, tax or legal advice; lenders, servicers and tax rules differ, so confirm the figures with the lender or a qualified adviser.",
    "from": "USD",
    "amount": 250,
    "date": "2026-11-18",
    "stale": false,
    "rates": {"EUR": 0.91080569, "INR": 93.326147},
    "converted": {"EUR": 227.7, "INR": 23331.54}
  }
}
TRY ITLIVE · 10 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
body*
Required unless listCurrencies is true. One currency, crypto or metal code, or a list of up to 20, to convert to. Not case-sensitive.
Past date, YYYY-MM-DD. Omit for the latest rates. ECB currencies start on 1999-01-04; crypto, metals and the broad set on 2024-03-02. Not allowed with startDate or endDate.
Currency, crypto or metal code to convert from. Not case-sensitive.

About this endpoint

What it does

Returns daily reference rates and converted amounts from one currency, crypto or metal code to up to 20 others, for the latest day or a past date. It can also return a daily history over a date range, or the list of supported codes.

Request Body

ParameterTypeDescription
toString / String ArrayRequired unless listCurrencies is true. One code, or a list of codes, to convert to. Not case-sensitive. Max 20 items.
fromStringCode to convert from: a currency, crypto or metal. Not case-sensitive. Default: USD.
amountNumberAmount to convert. Default: 1. Range: 0.000001 to 1000000000000 (1e12).
sourceENUMWhich rate set to use. Allowed values: auto, broad, ecb. Default: auto. auto uses the broad set and falls back to the ECB set. broad uses only the broad set (340 codes). ecb uses only the ECB set (about 30 fiat currencies).
dateStringPast date in YYYY-MM-DD format. Omit for the latest rates. ECB currencies start on 1999-01-04; crypto, metals and the broad set start on 2024-03-02. Can't be in the future. Not allowed with startDate or endDate.
startDateStringFirst day of a daily history, in YYYY-MM-DD format. Send together with endDate. History covers the ECB currencies only.
endDateStringLast day of the history, in YYYY-MM-DD format. Not before startDate. The range can be at most 366 days.
listCurrenciesBooleantrue returns the supported codes instead of rates. With source: ecb it returns the ECB codes only. Default: false.

Only these fields are accepted. Any other field returns a 400 error.

Response

Returns a JSON object with a result object. Its fields depend on the request: a rate lookup, a history range or a currency list. Every response has source, sourceId, live, note and disclaimer.

ParameterTypeDescription
result.sourceStringWhere the rates come from: Publicly available reference rates.
result.sourceIdENUMWhich rate set was used. Allowed values: reference-broad (broad set), reference-daily (ECB set).
result.liveBooleanAlways false: these are daily reference rates, not live prices.
result.noteStringExplains that the rates refresh about once a day and differ from bank, card or exchange prices.
result.disclaimerStringUse notice.
result.fromStringThe code you converted from, in uppercase. Rate lookups and history.
result.amountNumberThe amount used. Rate lookups and history.
result.dateStringDate of the rates used (YYYY-MM-DD). Rate lookups and currency lists.
result.requestedDateStringThe date you sent. Only when you sent date.
result.staleBooleantrue if older rates were used than expected. Present on most rate lookups and lists.
result.ratesObjectOne rate per target code: 1 unit of from in that code. Rate lookups.
result.convertedObjectamount converted into each target code. Rounded to 2 decimals, with more decimals for small values (for example 8 for BTC). Rate lookups.
result.typeNoteStringOnly when crypto or metal targets are included. Says these are reference values, not tradable prices.
result.crossRateNoteStringPresent on source: ecb rate lookups. Explains how rates between two non-base currencies are calculated.
result.fallbackBooleanOnly when auto fell back to the ECB set. Then true.
result.toString ArrayThe target codes. History only.
result.startDateStringFirst day of the range. History only.
result.endDateStringLast day of the range. History only.
result.observationsIntegerNumber of days in series. History only.
result.seriesObject ArrayOne row per working day with a published rate. History only.
result.series[].dateStringThe day (YYYY-MM-DD).
result.series[].ratesObjectThe rate for each target code that day.
result.series[].convertedObjectamount converted into each target code that day.
result.summaryObjectOne entry per target code with first, last, high, low and changePct (percent change from first to last). History only.
result.note2StringExtra note. For history: weekends and holidays have no row. For lists: what the type values mean.
result.currencyCountIntegerNumber of supported codes. Broad currency list only.
result.fiatCountIntegerNumber of fiat currencies. Broad currency list only.
result.metalCountIntegerNumber of metals. Broad currency list only.
result.otherCountIntegerNumber of crypto and other codes. Broad currency list only.
result.currenciesString ArrayAll supported codes. Currency lists only.
result.detailsObject ArrayOne row per code. Broad currency list only.
result.details[].codeStringThe code, for example BTC.
result.details[].typeENUMAllowed values: fiat, metal, other (crypto and codes outside ISO 4217).
result.details[].nameStringThe full name, for example Bitcoin.

Notes

  • Errors return 400 with error (a plain-language message) and code. Codes seen: invalid_input (missing to, more than 20 targets, unknown code, range over 366 days, date sent with a range, startDate without endDate, a future date, unknown field) and date_before_data_start (a crypto, metal or broad-set rate before 2024-03-02, or a crypto code in a history range). amount outside the range returns amount_out_of_range.
  • With source: auto, a weekend date returns that day's broad-set rate.
▣ COMMON ERRORS

Errors any endpoint can return

400bad_request

Required parameter missing or malformed body.

401unauthorized

API key missing, revoked, or not authorized for this service.

429rate_limited

Your plan's per-second rate exceeded. Retry with exponential backoff.

503upstream_busy

Backend temporarily unavailable. Try again in a few seconds.