Skip to main content
GET
/
wallet
/
rates
Get Exchange Rates
curl --request GET \
  --url https://api.rolla.xyz/api/v1/external/wallet/rates \
  --header 'X-API-Key: <api-key>'
{
  "status": 200,
  "success": true,
  "message": "Exchange rates retrieved successfully",
  "rates": [
    {
      "fromCurrency": "USD",
      "toCurrency": "NGN",
      "rate": 1550,
      "rateToken": "<string>"
    }
  ]
}
Retrieve current exchange rates for all supported currency pairs. Use the rateToken from the response to lock in a rate when performing a swap.

Example Request

curl -X GET "https://api.rolla.xyz/api/v1/external/wallet/rates" \
  -H "X-API-Key: your_api_key_here"

Example Response

{
  "status": 200,
  "success": true,
  "message": "Exchange rates retrieved successfully",
  "data": {
    "rates": [
      {
        "fromCurrency": "NGN",
        "toCurrency": "USD",
        "rate": 0.0006292157,
        "rateToken": "eyJhbGci..."
      },
      {
        "fromCurrency": "XAF",
        "toCurrency": "USD",
        "rate": 0.0017606254,
        "rateToken": "eyJhbGci..."
      },
      {
        "fromCurrency": "USD",
        "toCurrency": "NGN",
        "rate": 1405.3992,
        "rateToken": "eyJhbGci..."
      },
      {
        "fromCurrency": "USD",
        "toCurrency": "XAF",
        "rate": 556,
        "rateToken": "eyJhbGci..."
      }
    ]
  }
}
Exchange rates are live and may change between the time you fetch them and when you execute a swap. Pass the rateToken to the /wallet/swap endpoint to lock in the quoted rate.

Authorizations

X-API-Key
string
header
required

Your Rolla API key

Response

Rates retrieved successfully

status
integer
Example:

200

success
boolean
Example:

true

message
string
Example:

"Exchange rates retrieved successfully"

rates
object[]