Supported Fiat Currencies
This endpoint allows you to retrieve a list of supported fiat currencies, with details including currency code (e.g., USD, AUD), symbol, name, price, and display precision. Merchants can use this data to create invoices in fiat currencies.
GET
https://api.oxapay.com/v1/common/fiats
{
"data": {
[key: string]:
{
"symbol": string,
"name": string,
"price": decimal,
"display_precision": decimal,
} // Represents dynamic keys (currency symbol) with object values.
},
"message": string, // A message containing additional information about the result of the request.
"error": {
"type": string,
"key": string,
"message": string
} || {}, // An object that provides details about any errors that occurred.
"status": integer, // The status of the request response. Typically provided as a numeric code (e.g., 200 for success or other codes for errors).
"version": string // The version of the API being used.
}
API Request Sample Codes
curl -X GET https://api.oxapay.com/v1/common/fiats
<?php
$url = 'https://api.oxapay.com/v1/common/fiats';
$options = array(
'http' => array(
'method' => 'GET'
),
);
$context = stream_context_create($options);
$response = file_get_contents($url, false, $context);
if ($response === FALSE) {
die('Error occurred');
}
$result = json_decode($response, true);
var_dump($result);
?>
const axios = require('axios');
const url = 'https://api.oxapay.com/v1/common/fiats';
axios.get(url)
.then((response) => {
console.log(response.data);
})
.catch((error) => {
console.error(error);
});
import requests
url = 'https://api.oxapay.com/v1/common/fiats'
response = requests.get(url)
result = response.json()
print(result)
These example code snippets demonstrate how to request the "Supported Fiat Currencies" endpoint using different programming languages. You can customize the data parameters according to your specific requirements.
API Response Example
{
"data": {
"USD": {
"symbol": "USD",
"name": "United States Dollar",
"price": 1.0000000000,
"display_precision": 0.00100000
},
"AMD": {
"symbol": "AMD",
"name": "Armenian Dram",
"price": 0.0025214600,
"display_precision": 0.10000000
},
"AUD": {
"symbol": "AUD",
"name": "Australian Dollar",
"price": 0.6441713400,
"display_precision": 0.00100000
},
"AZN": {
"symbol": "AZN",
"name": "Azerbaijani Manat",
"price": 0.5882352900,
"display_precision": 0.00100000
},
"BRL": {
"symbol": "BRL",
"name": "Brazilian Real",
"price": 0.1929038700,
"display_precision": 0.00100000
},
"CAD": {
"symbol": "CAD",
"name": "Canadian Dollar",
"price": 0.7252846500,
"display_precision": 0.00100000
},
"CHF": {
"symbol": "CHF",
"name": "Swiss Franc",
"price": 1.0969049700,
"display_precision": 0.00010000
},
"CNH": {
"symbol": "CNH",
"name": "Chinese Yuan (Offshore)",
"price": 0.1377564900,
"display_precision": 0.01000000
},
"CNY": {
"symbol": "CNY",
"name": "Chinese Yuan",
"price": 0.1381584300,
"display_precision": 0.00100000
},
"CZK": {
"symbol": "CZK",
"name": "Czech Republic Koruna",
"price": 0.0420012800,
"display_precision": 0.01000000
},
"DKK": {
"symbol": "DKK",
"name": "Danish Krone",
"price": 0.1424081900,
"display_precision": 0.00100000
},
"EUR": {
"symbol": "EUR",
"name": "Euro",
"price": 1.0624553700,
"display_precision": 0.00010000
},
"GBP": {
"symbol": "GBP",
"name": "British Pound Sterling",
"price": 1.2445643600,
"display_precision": 0.00010000
},
"GHS": {
"symbol": "GHS",
"name": "Ghanaian Cedi",
"price": 0.0743720600,
"display_precision": 0.01000000
},
"HKD": {
"symbol": "HKD",
"name": "Hong Kong Dollar",
"price": 0.1277318100,
"display_precision": 0.01000000
},
"HUF": {
"symbol": "HUF",
"name": "Hungarian Forint",
"price": 0.0026962900,
"display_precision": 0.10000000
},
"IDR": {
"symbol": "IDR",
"name": "Indonesian Rupiah",
"price": 0.0000621600,
"display_precision": 1.00000000
},
"ILS": {
"symbol": "ILS",
"name": "Israeli New Sheqel",
"price": 0.2663094500,
"display_precision": 0.00100000
},
"INR": {
"symbol": "INR",
"name": "Indian Rupee",
"price": 0.0119749500,
"display_precision": 0.01000000
},
"ISK": {
"symbol": "ISK",
"name": "Icelandic Króna",
"price": 0.0070613100,
"display_precision": 0.10000000
},
"JPY": {
"symbol": "JPY",
"name": "Japanese Yen",
"price": 0.0064821000,
"display_precision": 0.10000000
},
"KRW": {
"symbol": "KRW",
"name": "South Korean Won",
"price": 0.0007204800,
"display_precision": 1.00000000
},
"KZT": {
"symbol": "KZT",
"name": "Kazakhstani Tenge",
"price": 0.0022311200,
"display_precision": 0.10000000
},
"MXN": {
"symbol": "MXN",
"name": "Mexican Peso",
"price": 0.0598135800,
"display_precision": 0.01000000
},
"MYR": {
"symbol": "MYR",
"name": "Malaysian Ringgit",
"price": 0.2094855000,
"display_precision": 0.00100000
},
"NOK": {
"symbol": "NOK",
"name": "Norwegian Krone",
"price": 0.0914139400,
"display_precision": 0.01000000
},
"NZD": {
"symbol": "NZD",
"name": "New Zealand Dollar",
"price": 0.5903546600,
"display_precision": 0.00100000
},
"PHP": {
"symbol": "PHP",
"name": "Philippine Peso",
"price": 0.0175658300,
"display_precision": 0.01000000
},
"PKR": {
"symbol": "PKR",
"name": "Pakistani Rupee",
"price": 0.0035969100,
"display_precision": 0.10000000
},
"PLN": {
"symbol": "PLN",
"name": "Polish Zloty",
"price": 0.2468242900,
"display_precision": 0.00100000
},
"RUB": {
"symbol": "RUB",
"name": "Russian Ruble",
"price": 0.0107071300,
"display_precision": 0.01000000
},
"SEK": {
"symbol": "SEK",
"name": "Swedish Krona",
"price": 0.0919065000,
"display_precision": 0.01000000
},
"SGD": {
"symbol": "SGD",
"name": "Singapore Dollar",
"price": 0.7338081500,
"display_precision": 0.00100000
},
"THB": {
"symbol": "THB",
"name": "Thai Baht",
"price": 0.0272183500,
"display_precision": 0.01000000
},
"TMT": {
"symbol": "TMT",
"name": "Turkmenistani Manat",
"price": 0.2857142800,
"display_precision": 0.00100000
},
"TRY": {
"symbol": "TRY",
"name": "Turkish Lira",
"price": 0.0308383100,
"display_precision": 0.01000000
},
"UAH": {
"symbol": "UAH",
"name": "Ukrainian Hryvnia",
"price": 0.0252792700,
"display_precision": 0.01000000
},
"UZS": {
"symbol": "UZS",
"name": "Uzbekistan Som",
"price": 0.0000789200,
"display_precision": 0.10000000
},
"VND": {
"symbol": "VND",
"name": "Vietnamese Dong",
"price": 0.0000397200,
"display_precision": 1.00000000
},
"ZAR": {
"symbol": "ZAR",
"name": "South African Rand",
"price": 0.0525925600,
"display_precision": 0.01000000
}
},
"message": "Operation completed successfully!",
"error": {},
"status": 200,
"version": "1.0.0"
}
The response example above is provided to help you understand the format and structure of the response. If you have any further questions or need assistance, please feel free to contact to your account manager.
Last updated