Skip to main content
GET
/
exchange-rates
Get exchange rate
curl --request GET \
  --url https://api.fernhq.com/exchange-rates \
  --header 'Authorization: Bearer <token>'
{
"exchangeRate": "1000.00",
"destinationAmount": "100",
"feeComponents": [
{
"feeType": "FLAT",
"feeCurrency": {
"label": "USDC",
"chain": "ETHEREUM",
"contractAddress": "0x123456789abcd123456789abcd123456789abcd",
"currencyDecimals": 18
},
"feeAmount": "5.45"
}
],
"fees": {
"feeCurrency": {
"label": "USDC",
"chain": "ETHEREUM",
"contractAddress": "0x123456789abcd123456789abcd123456789abcd",
"currencyDecimals": 18
},
"fernFee": {
"feeAmount": "5.45",
"feeUSDAmount": "5.45"
}
}
}

Authorizations

Authorization
string
header
required

To authenticate server-side requests

Query Parameters

sourceCurrency
string
required

Currency label or contract address.

sourcePaymentMethod
required

The payment method for the source exchangeRate The payment method for the source funds (fiat)

Available options:
ACH
sourceAmount
string

The amount to be sent. If provided fern fees and destination amount will be returned

destinationPaymentMethod
required

The payment method for the destination exchangeRate The payment method for the source funds (fiat)

Available options:
ACH
destinationCurrency
string
required

Currency label or contract address.

Response

Default Response

exchangeRate
string
required

The rate at which the source currency is multiplied to determine the equivalent amount in the destination currency

Example:

"1000.00"

feeComponents
Fees · object[]
required
destinationAmount
string

The amount that will be received excluding fern fees. Equivalent to setting developer fee to 0

Example:

"100"

fees
object

The estimated fees to be charged on this transaction