Skip to main content
GET
/
v1
/
exchange
/
rates
/
{base}
/
{target}
Get exchange rate
curl --request GET \
  --url https://api.light.inc/v1/exchange/rates/{base}/{target} \
  --header 'Authorization: <api-key>'
{
  "base": "USD",
  "target": "USD",
  "rate": 123,
  "effectiveDate": "2023-12-25",
  "requestedDate": "2023-12-25"
}

Authorizations

Authorization
string
header
required

Basic authentication header of the form Basic <api_key>, where <api_key> is your api key.

Path Parameters

base
string
required

Base currency of the exchange rate

target
string
required

Target currency of the exchange rate

Query Parameters

date
object

Date the exchange rate is requested for. If omitted, defaults to today

Response

default - application/json;charset=UTF-8

default response

base
string
Example:

"USD"

target
string
Example:

"USD"

rate
number

Exchange rate between base and target currency

effectiveDate
string<date>

Effective date of the exchange rate. E.g., rate requested on Saturday will have the effective date Friday

requestedDate
string<date>

Date the exchange rate is requested for