How to get exchange rates
Overview
Use Rate API to get exchange rates for cryptocurrency and fiat calculations.
Use these methods when you need to estimate conversion amounts, show fiat equivalent values, or validate pricing before creating payment, payout, invoice, or exchange flows.
Rate methods
| Method | Use case |
|---|---|
| [POST] rate | Get exchange rates between cryptocurrency pairs or supported currency pairs. |
| [POST] rate/fiat | Get rates between source currencies and fiat target currencies. |
Common request fields
Rate API methods use the standard request wrapper.
| Field | Type | Required | Description |
|---|---|---|---|
| timestamp | number | Yes | Current Unix UTC timestamp in milliseconds. The value must not be less than 3 minutes in the past or greater than 3 minutes in the future. |
| payload | object | Yes | Object with rate request parameters. |
Get exchange rates
Use [POST] rate.
| Payload field | Type | Required | Description |
|---|---|---|---|
| fromCurrencies | array | No | Source currencies. |
| toCurrencies | array | No | Target currencies. |
Request example
{
"timestamp": 1761650432438,
"payload": {
"fromCurrencies": [
"BTC",
"ETH"
],
"toCurrencies": [
"USDT_TRX"
]
}
}
Response fields
| Field | Type | Description |
|---|---|---|
| currencyRates | array | Exchange rates for requested currency pairs. |
currencyRates fields
| Field | Type | Description |
|---|---|---|
| fromCurrency | string | Source currency. |
| toCurrency | string | Target currency. |
| rates | number | Exchange rate. |
| ratesDate | string | Date and time when the rate was calculated. |
Get fiat exchange rates
Use [POST] rate/fiat.
| Payload field | Type | Required | Description |
|---|---|---|---|
| from | array | Yes | Source currencies. |
| to | array | Yes | Target fiat currencies. |
Request example
{
"timestamp": 1761650432438,
"payload": {
"from": [
"USDT_TRX",
"BTC"
],
"to": [
"USD",
"EUR"
]
}
}
Response fields
| Field | Type | Description |
|---|---|---|
| ratesMap | object | Nested object with rates grouped by source and target currency. |
Recommended handling
| Case | Recommendation |
|---|---|
| Showing estimated amounts | Treat rates as informational estimates and refresh them before important user actions. |
| Displaying fiat equivalents | Use rate/fiat when target currencies are fiat currencies. |
| Validating currency values | Use Currency API first to check supported currencies. |
Related docs
| Document | Link |
|---|---|
| Available currencies | How to get available currencies |
| Rate API reference | Rate API |