Ledga
GET/fx/rates/{from}/{to}

Get the current resolved rate for a pair

The current resolved rate for a pair (manual override → live provider → DB fallback, per the stale-rate policy).

Parameters

NameInTypeDescription
fromrequired path string Base currency.
torequired path string Quote currency.

Responses

200Successful operation
{
  "success": true,
  "data": {
    "base_currency": "EUR",
    "quote_currency": "USD",
    "rate": "1.081000000000000000",
    "inverse_rate": "0.925069380203515263",
    "source": "ecb",
    "effective_at": "2026-01-15T10:30:00Z",
    "stale": false
  }
}
401Unauthenticated
{
  "success": false,
  "message": "Validation failed",
  "code": "VALIDATION_ERROR"
}
422Invalid currency, or no rate available / rate stale
{
  "success": false,
  "message": "Validation failed",
  "code": "VALIDATION_ERROR"
}

Examples

curl https://ledga.io/api/v1/fx/rates/{from}/{to} \
  -H "Authorization: Bearer sk_xxxxxxxx_your_secret"

← All endpoints