Skip to main content
GET
/
partners
/
rates
Get Exchange Rate
curl --request GET \
  --url https://api.hyperrails.io/api/v1/partners/rates \
  --header 'Authorization: Bearer <token>'
import requests

url = "https://api.hyperrails.io/api/v1/partners/rates"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch('https://api.hyperrails.io/api/v1/partners/rates', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.hyperrails.io/api/v1/partners/rates",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://api.hyperrails.io/api/v1/partners/rates"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("Authorization", "Bearer <token>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.hyperrails.io/api/v1/partners/rates")
.header("Authorization", "Bearer <token>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.hyperrails.io/api/v1/partners/rates")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
{
  "from": "usdt",
  "to": "NGN",
  "rate": 0.0006,
  "source": "CONSENSUS",
  "timestamp": "2026-04-01T14:13:28.306083501Z",
  "chain": "ethereum"
}
{
"code": "INVALID_CURRENCY",
"message": "Invalid source currency. Supported: NGN, GHS",
"details": {}
}

Authorizations

Authorization
string
header
required

API key authentication using Bearer token

Query Parameters

base
string
required

The source currency code (e.g., NGN).

Example:

"NGN"

quote
string
required

The target currency code (e.g., GHS).

Example:

"GHS"

chain
string

The blockchain network (optional - only for crypto currencies)

Example:

"ETHEREUM"

Response

Successfully retrieved the exchange rate

Represents the current exchange rate and consensus metadata between two currencies.

from
string
required

The source currency code.

Example:

"usdt"

to
string
required

The target currency code.

Example:

"NGN"

rate
number<double>
required

The conversion rate/multiplier.

Example:

0.0006

source
string
required

The mechanism used to determine the rate (e.g., CONSENSUS, ADMIN_OVERRIDE, MARKET_MAKER, SPOT).

Example:

"CONSENSUS"

timestamp
string<date-time>
required

The UTC timestamp of the rate generation.

Example:

"2026-04-01T14:13:28.306083501Z"

chain
string

The blockchain network or settlement chain.

Example:

"ethereum"