Get market info by tickers [Private]
Get information on specific traded pairs. Returns an array of trading pairs objects.
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/tickers?pairs={pairs} |
Request type: | GET |
Data dictionary
Name | Type | Parameter type | Required | Range | Description |
---|---|---|---|---|---|
pairs | string | QUERY | YES | - | A pair of tickers, e.g. BTC_USDT |
At least one trading pair should be sent.
Exemplary request
Example path | Description |
---|---|
/v4/markets/private/tickers?pairs=BTC_UAH,BTC_USDT,ETH_UAH | Returns information about BTC_UAH , BTC_USDT and ETH_UAH markets |
/v4/markets/private/tickers?pairs=BTC_UAH | Returns information only about BTC_UAH market |
const apiKey = "YOUR_API_KEY"; // put here your Api key
const url = "https://api.kuna.io";
const path = "/v4/markets/private/tickers?pairs=BTC_UAH,BTC_USDT,ETH_UAH";
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/tickers?pairs=BTC_UAH,BTC_USDT,ETH_UAH"
headers = {
"accept": "application/json",
"Content-Type": "application/json",
"api-key": apiKey,
}
request = requests.get(url + path, headers=headers)
print(request.json())
How to call public endpoints here
Response
[
{
"pair": "BTC_USDT", // Traded pair
"percentagePriceChange": "-0.03490931899641581", // Relative price change, in percent
"price": "27900", // Current median price
"equivalentPrice": "", // TBD
"high": "29059.69", // Highest price
"low": "27900", // Lowest price
"baseVolume": "2.9008499999999993", // Traded volume as base
"quoteVolume": "82251.41477976", // Traded volume as quote
"bestBidPrice": "27926.91", // The best bid price now
"bestAskPrice": "27970.02", // The best ask price now
"priceChange": "-973.9700000000012" // Absolute price change
}
]
Updated over 1 year ago