Get Fiat Rates
curl --request GET \
--url https://api.obiex.finance/v1/currencies/fiat-ratesimport requests
url = "https://api.obiex.finance/v1/currencies/fiat-rates"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.obiex.finance/v1/currencies/fiat-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.obiex.finance/v1/currencies/fiat-rates",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.obiex.finance/v1/currencies/fiat-rates"
req, _ := http.NewRequest("GET", url, nil)
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.obiex.finance/v1/currencies/fiat-rates")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.obiex.finance/v1/currencies/fiat-rates")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"message": "Ok",
"data": [
{
"currency": "NGNX",
"base": "USDT",
"buyRate": 1600,
"sellRate": 1580
},
{
"currency": "GHS",
"base": "USDT",
"buyRate": 15.5,
"sellRate": 15.1
}
]
}Trades
Get Fiat Rates
Returns the current buy and sell rates between USDT and supported fiat currencies. Currently supports NGNX and GHS.
Use this endpoint to show live fiat/USDT rates to your users. Don’t use Create Quote to check rates — Create Quote is only for trades you intend to execute, and it’s limited to 100 requests per hour per API key.
buyRate: how much fiat you pay for 1 USDT (aBUYof USDT).sellRate: how much fiat you receive for 1 USDT (aSELLof USDT).
Rates are cached for up to 60 seconds.
GET
/
currencies
/
fiat-rates
Get Fiat Rates
curl --request GET \
--url https://api.obiex.finance/v1/currencies/fiat-ratesimport requests
url = "https://api.obiex.finance/v1/currencies/fiat-rates"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.obiex.finance/v1/currencies/fiat-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.obiex.finance/v1/currencies/fiat-rates",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.obiex.finance/v1/currencies/fiat-rates"
req, _ := http.NewRequest("GET", url, nil)
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.obiex.finance/v1/currencies/fiat-rates")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.obiex.finance/v1/currencies/fiat-rates")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"message": "Ok",
"data": [
{
"currency": "NGNX",
"base": "USDT",
"buyRate": 1600,
"sellRate": 1580
},
{
"currency": "GHS",
"base": "USDT",
"buyRate": 15.5,
"sellRate": 15.1
}
]
}Was this page helpful?