Exchange Rate

Get live currency exchange rates and convert amounts between currencies. Rates are sourced from the European Central Bank via Frankfurter and cached for up to one hour.

Get API Key

Descripción general

Casos de uso

  • E-commerce multi-currency pricing
  • Fintech apps and payment processors
  • Travel and expense management tools
  • Financial dashboards and reporting
  • Invoice generation in foreign currencies

Funcionalidades

180+ currencies supported (ECB data via Frankfurter)
Rates cached for 1 hour — fast responses, minimal latency
Combined convert endpoint returns rate and converted amount in one call
ISO 4217 three-letter currency codes (USD, EUR, GBP, JPY, etc.)

Puntos finales de la API

Get Exchange Rate

Returns the current exchange rate between two currencies.

GET
https://requiems.xyz/v1/finance/exchange-rate

Parámetros

Nombre Tipo Obligatorio Descripción
from string Obligatorio ISO 4217 source currency code (3 letters, e.g. USD)
to string Obligatorio ISO 4217 target currency code (3 letters, e.g. EUR)

Pruébalo

Demostración en vivo
Solicitud

ISO 4217 source currency code (3 letters, e.g. USD)

ISO 4217 target currency code (3 letters, e.g. EUR)

Campos de respuesta

Campo Tipo Descripción
from string Source currency code (uppercased)
to string Target currency code (uppercased)
rate number Exchange rate — how many units of `to` equal 1 unit of `from`
timestamp string Date the rate was published by the ECB (ISO 8601)

Ejemplos de código

curl "https://requiems.xyz/v1/finance/exchange-rate?from=USD&to=EUR" \
  -H "requiems-api-key: YOUR_API_KEY"

Respuestas de error

bad_request

A required parameter is missing or the currency code is not exactly 3 alphabetic characters.

invalid_currency

One or both currency codes are not recognised by the upstream data source.

upstream_error

The exchange rate data source is temporarily unavailable.

Convert Currency

Converts an amount from one currency to another and returns the rate alongside the converted value.

GET
https://requiems.xyz/v1/finance/convert

Parámetros

Nombre Tipo Obligatorio Descripción
from string Obligatorio ISO 4217 source currency code (3 letters, e.g. USD)
to string Obligatorio ISO 4217 target currency code (3 letters, e.g. EUR)
amount number Obligatorio Amount to convert. Must be greater than 0.

Pruébalo

Demostración en vivo
Solicitud

ISO 4217 source currency code (3 letters, e.g. USD)

ISO 4217 target currency code (3 letters, e.g. EUR)

Amount to convert. Must be greater than 0.

Campos de respuesta

Campo Tipo Descripción
from string Source currency code (uppercased)
to string Target currency code (uppercased)
rate number Exchange rate used for the conversion
amount number The original amount passed in the request
converted number Result of amount × rate, rounded to 2 decimal places
timestamp string Date the rate was published by the ECB (ISO 8601)

Ejemplos de código

curl "https://requiems.xyz/v1/finance/convert?from=USD&to=EUR&amount=100" \
  -H "requiems-api-key: YOUR_API_KEY"

Respuestas de error

bad_request

A required parameter is missing, the currency code is not 3 alphabetic characters, or the amount is 0 or negative.

invalid_currency

One or both currency codes are not recognised by the upstream data source.

upstream_error

The exchange rate data source is temporarily unavailable.

Preguntas frecuentes