Get all traded markets [Private]
Get the list of all the traded pairs on Kuna exchange. Returns an array of objects, each with the pair string, the tickers of both base and quoted asset alongside their precisions.
To call any private endpoint, headers should include authorization key(s).
You may use a single API key or a public-private key pair based on your current tasks. Here you may find typical Header configurations for both options.
Method name: | /v4/markets/private/getAll |
Request type: | GET |
Exemplary request
const apiKey = "YOUR_API_KEY"; // put here your Api key
const url = "https://api.kuna.io";
const path = "/v4/markets/private/getAll";
const options = {
headers: {
accept: "application/json",
"Content-Type": "application/json",
"api-key": apiKey,
},
};
fetch(url + path, options)
.then((response) => response.json())
.then((showResponse) => console.log(showResponse.data));
import requests
apiKey = "YOUR_API_KEY"; # put here your Api key
url = "https://api.kuna.io"
path = "/v4/markets/private/getAll"
headers = {
"accept": "application/json",
"Content-Type": "application/json",
"api-key": apiKey,
}
request = requests.get(url + path, headers=headers)
print(request.json())
How to call private endpoints here
Response
{
"pair": "BTC_USDT", // Traded pair of assets
"baseAsset": { // The base asset of the traded pair, the one to sell or buy as a result of the trade
"code": "BTC",
"precision": 6 // Maximum amount of digits for the decimal part of a number
},
"quoteAsset": { // The quoted asset of the traded pair, the one to use to sell or buy the base asset
"code": "USDT",
"precision": 2 // Maximum amount of digits for the decimal part of a number
},
"tickerPriceChange": "-0.07"// Relative change compared with the last tick
}
Updated over 1 year ago