fx tool

Public

fx_convert

Convert one amount with ECB reference rates and explicit date resolution.

Description

Convert one amount with ECB reference rates and explicit date resolution.

EUR pairs use the published fixing directly (or its inverse); currency cross-rates triangulate through EUR and are flagged derived: true. The scalar envelope echoes amount/currencies/requested_date/rate_date, exact rate, six-decimal converted amount, units, currency, as_of, ECB attribution and derivation statement. Errors use bad_parameter or out_of_coverage. ECB reference rates are published for information purposes only; using them for transaction purposes is strongly discouraged. They are not transaction or execution prices.

Parameters

Input schema

NameTypeRequiredDefaultDescription
amountnumber | stringYesExact decimal amount to convert; never parsed as a float.
from_currencystringYesISO 4217 source currency.
to_currencystringYesISO 4217 destination currency.
datestring (date) | nullNonullRequested fixing date. A weekend or holiday resolves to the newest prior fixing and the payload echoes requested_date and rate_date. Omit for latest.

Provenance

Sources

  • ecbEuropean Central Bank

Dataset registry: fx_rates