Postman collection of Kuna v4 API
Types of parameters you might need to use when interacting with Kuna v4 API
You may find our Postman collection useful for an easy start.
The Postman collection also includes documentation that you may find in our API references:
Using variables
You may see a common pattern in the examples, masking parameters behind variables, e.g. {{TRADED_ORDER_ID}}
.
This concept is used to save time and avoid errors when using API endpoints, which may use same parameters, output of one request may be a parameter of another one, etc.
The most common is {{baseURL}}
in every endpoint:
{{baseURL}}/v4/order/private/create
, which refers to the dev or production server's base URL that should be used for making the request,
or
{{OPEN_ORDER_ID}}
in the body of the request, which refers to a unique id of an open order:
{
"orderId": "{{OPEN_ORDER_ID}}"
}
Import collection into Postman
To import Postman collection, please open Postman >> create new or go to your Kuna workspace >> click Collections >> click Import >> click Raw text >> paste the code from below >> click Continue:
Postman collection
{
"info": {
"_postman_id": "8c31c0ad-17ff-4e67-8e8c-416bd0a9dfd1",
"name": "KUNA PRO REST API v4",
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
"_exporter_id": "4335195"
},
"item": [
{
"name": "v4",
"item": [
{
"name": "markets/public",
"item": [
{
"name": "Get all traded markets [Public]",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v4/markets/public/getAll",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"markets",
"public",
"getAll"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
},
"description": "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.\n\nThis is a `public` route, no need for authorization.\n\n### Data dictionary\n > 📘 This endpoint does not take any parameters. \n\n### Exemplary request\nPlease try sending this request: `{{baseURL}}/v4/markets/public/getAll`\n\n### Response structure\nYou will receive a JSON in the response with `data` object, filled with an array of `pairs` objects structured like this example:\n````\n{\n \"pair\": \"BCH_BTC\", // Traded pair of assets\n \"baseAsset\": { // The base asset of the traded pair, the one to sell or buy as a result of the trade\n \"code\": \"BCH\",\n \"precision\": 8 // Maximum amount of digits for the decimal part of a number\n },\n \"quoteAsset\": { // The quoted asset of the traded pair, the one to use to sell or buy the base asset \n \"code\": \"BTC\",\n \"precision\": 8 // Maximum amount of digits for the decimal part of a number\n },\n \"tickerPriceChange\": \"0\" // TBD\n}\n````\n### Errors\n> 📘 As there are no parameters for this endpoint, you may encounter only general errors while using it."
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "GET",
"header": [],
"url": {
"raw": "{{baseUrl}}/v4/markets/public/getAll",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"markets",
"public",
"getAll"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": [\n {\n \"pair\": \"enim sint\",\n \"baseAsset\": {\n \"code\": \"dolor est e\",\n \"precision\": -78207210.73378602\n },\n \"quoteAsset\": {\n \"code\": \"deserunt exercitation\",\n \"precision\": -404312.46770356596\n },\n \"tickerPriceChange\": 8687940.89879547\n },\n {\n \"pair\": \"cillum aliquip ullamco quis amet\",\n \"baseAsset\": {\n \"code\": \"minim eu dolor proident sit\",\n \"precision\": 88938424.75788409\n },\n \"quoteAsset\": {\n \"code\": \"eiusmod commodo\",\n \"precision\": 46607577.18143359\n },\n \"tickerPriceChange\": 50138793.33379546\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "GET",
"header": [],
"url": {
"raw": "{{baseUrl}}/v4/markets/public/getAll",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"markets",
"public",
"getAll"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"proident tempor\",\n \"code\": \"est dolor veniam\"\n },\n {\n \"message\": \"pariatur est anim velit quis\",\n \"code\": \"velit\"\n }\n ]\n}"
}
]
},
{
"name": "Get public market data by tickers [Public]",
"request": {
"auth": {
"type": "noauth"
},
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v4/markets/public/tickers?pairs={{TRADE_PAIR}},{{TRADE_PAIR_2}},{{TRADE_PAIR_3}},{{TRADE_PAIR_D_N}}",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"markets",
"public",
"tickers"
],
"query": [
{
"key": "pairs",
"value": "{{TRADE_PAIR}},{{TRADE_PAIR_2}},{{TRADE_PAIR_3}},{{TRADE_PAIR_D_N}}"
}
]
},
"description": "Get information on specific traded pairs. Returns an array of trading pairs objects.\n\nThis is a `public` route, no need for authorization.\n\n### Data dictionary\n| Name | Type | Parameter type | Required | Range | Description |\n|:-----:|:------:|:--------------:|:--------:|:-----:|:---------------------------------:|\n| pairs | string | QUERY | YES | - | A pair of tickers, e.g. BTC_USDT |\n> 📘 At least one trading pair should be sent. \n\n### Exemplary request\nPlease try this request for a start: `{{baseURL}}/v4/markets/public/tickers?pairs=BTC_USDT,ETH_BTC`\n\n### Response structure\nYou will receive a JSON in the response with `data` object, filled with an array of `pairs` objects structured like in this example:\n````\n[\n {\n \"pair\": \"BTC_USDT\", // Traded pair\n \"percentagePriceChange\": \"1\", // Relative price change, in percent \n \"price\": \"19999\", // Current median price\n \"equivalentPrice\": \"\", // TBD\n \"high\": \"20163\", // Highest price\n \"low\": \"19883\", // Lowest price\n \"baseVolume\": \"32.131491000001674\", // Traded volume as base \n \"quoteVolume\": \"642635.7276489848\", // Traded volume as quote\n \"bestBidPrice\": \"19975\", // The best bid price now\n \"bestAskPrice\": \"19976\", // The best ask price now\n \"priceChange\": \"19999\" // Absolute price change\n },\n {\n \"pair\": \"ETH_BTC\", // The following pair was not traded yesterday\n \"percentagePriceChange\": \"0\",\n \"price\": \"0\",\n \"equivalentPrice\": \"\",\n \"high\": \"0\",\n \"low\": \"0\",\n \"baseVolume\": \"0\",\n \"quoteVolume\": \"0\",\n \"bestBidPrice\": \"0\",\n \"bestAskPrice\": \"0\",\n \"priceChange\": \"0\"\n }\n]\n````\n### Errors\n| Error code | Message | Parameter | Description |\n|:-------------------:|:-------:|:-----------:|-----------------------------------------------------------------|\n| Empty \\`data\\` object | - | `pairs` | Have to send at least one pair to receive a meaningful response |"
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/markets/public/tickers?symbols=BCH_BTC",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"markets",
"public",
"tickers"
],
"query": [
{
"key": "symbols",
"value": "BCH_BTC"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": [\n {\n \"marketCode\": \"labore tempor esse eu\",\n \"baseVolume\": -75659516.21744928,\n \"bestAskPrice\": -2522528.3078294843,\n \"bestBidPrice\": -74708218.86268224,\n \"equivalentPrice\": -40613770.92977354,\n \"high\": 45296275.335223556,\n \"low\": 17138596.57962726,\n \"pair\": -74447402.40230829,\n \"percentagePriceChange\": 88350816.34157157,\n \"price\": -19876446.34740588,\n \"priceChange\": 24764511.884497777,\n \"quoteVolume\": -86956355.60091403\n },\n {\n \"marketCode\": \"ali\",\n \"baseVolume\": -19476406.889038205,\n \"bestAskPrice\": 76291555.44599718,\n \"bestBidPrice\": -9967912.558929637,\n \"equivalentPrice\": -77910184.75058697,\n \"high\": 17616028.70515415,\n \"low\": 53117871.3658745,\n \"pair\": -39091226.25047692,\n \"percentagePriceChange\": 23478891.66360098,\n \"price\": 18808572.20811571,\n \"priceChange\": 8165008.801359221,\n \"quoteVolume\": 30094159.151329964\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/markets/public/tickers?symbols=BCH_BTC",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"markets",
"public",
"tickers"
],
"query": [
{
"key": "symbols",
"value": "BCH_BTC"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
}
]
},
{
"name": "order",
"item": [
{
"name": "private",
"item": [
{
"name": "cancel",
"item": [
{
"name": "Cancel one client order [Private]",
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"orderId\": \"{{OPEN_ORDER_ID}}\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v4/order/private/cancel",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"cancel"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
},
"description": "Cancel an open order. Returns a success message if the target order was canceled as a result.\n\nThis is a `private` route, so the `api-key` parameter should be sent in the header.\n\n### Data dictionary\n| Name | Type | Parameter type | Required | Range | Description |\n|:-------:|:------:|:--------------:|:--------:|:-----:|:--------------------------------------------------------------------------------:|\n| orderId | string | BODY | YES | - | Should be a unique order id. For example, `c7fc5b2b-bd9d-48c1-a458-a83412669cf4` | \n\n### Exemplary request\nFirst you will need to create a new order using [Post a new order](#Post-a-new-order) endpoint. \nSend the uuid of the created order inside the body of the cancel request `{{baseURL}}/v4/order/private/cancel`:\n\n````\n{\n \"orderId\": \"{{OPEN_ORDER_ID}}\"\n}\n````\n\n### Response structure\nIn case the order is closed successfully, you should receive a JSON with `data` object, structured like this example:\n````\n{\n \"success\": true\n}\n````\n### Errors\n| Error code | Message | Parameter-related | Description |\n|:---------------------:|:--------------------------------------------:|:-----------------:|-------------------------------------------------------------------------------------------------------------------------------------------------|\n| WrongRequestException | orderId must be a UUID | orderId | The order id should match uuid pattern, for example, `c7fc5b2b-bd9d-48c1-a458-a83412669cf4` |\n| Internal Server Error | Invalid JSON | - | Expected a valid JSON in the body of request, but received something else. Recommend checking the structure, e.g. key-value pairs, quotes, etc. |\n| BAD_REQUEST | Order with status Closed can't be canceled | - | The order you tried to cancel has already been closed/traded |\n| BAD_REQUEST | Order with status Canceled can't be canceled | - | The order you tried to cancel has already been canceled |"
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "POST",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"orderId\": \"<number>\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v4/order/private/cancel",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"cancel"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": {\n \"success\": true\n }\n}"
},
{
"name": "When the request data is invalid.",
"originalRequest": {
"method": "POST",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"orderId\": \"<number>\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v4/order/private/cancel",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"cancel"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Bad Request",
"code": 400,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "POST",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"orderId\": \"<number>\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v4/order/private/cancel",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"cancel"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
},
{
"name": "Cancel multiple client orders [Private]",
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"orderIds\": [\n \"{{OPEN_ORDER_ID}}\",\n \"{{OPEN_ORDER_ID_2}}\",\n \"{{OPEN_ORDER_ID_3}}\"\n ]\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v4/order/private/cancel/multi",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"cancel",
"multi"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
},
"description": "Cancel several open orders at once. Returns confirmation upon success.\n\nThis is a `private` route, so the `api-key` parameter should be sent in the header.\n\n### Data dictionary\n| Name | Type | Parameter type | Required | Range | Description |\n|:--------:|:------:|:--------------:|:--------:|:-----:|:--------------------------------------------------------------------------------:|\n| orderIds | string | BODY | YES | - | Should be a unique order id. For example, `c7fc5b2b-bd9d-48c1-a458-a83412669cf4` |\n> 📘 If one or several orders from the batch have been traded or closed, the system will notify of this while still closing the remaining open orders. \n\n### Exemplary request\nPlease try this request for a start: `{{baseURL}}/v4/markets/public/getAll`\n\n### Response structure\nIf the whole orders batch was closed successfully, you should receive a JSON with `data` object, structured like this example:\n````\n{\n \"success\": true\n}\n````\n### Errors\n| Error code | Message | Parameter-related | Description |\n|:---------------------:|:--------------------------------------------:|:-----------------:|-------------------------------------------------------------------------------------------------------------------------------------------------|\n| Internal Server Error | Invalid JSON | - | Expected a valid JSON in the body of request, but received something else. Recommend checking the structure, e.g. key-value pairs, quotes, etc. |\n| BAD_REQUEST | Order with status Closed can't be canceled | - | One of the orders you asked to cancel has already been closed/traded. |\n| BAD_REQUEST | Order with status Canceled can't be canceled | - | One of the orders you asked to cancel has already been canceled. |\n| WrongRequestException | each value in orderIds must be a UUID | orderIds | One or several order ids did not match UUID pattern. All should look like `c7fc5b2b-bd9d-48c1-a458-a83412669cf4` |"
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "POST",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"orderIds\": [\n \"<number>\",\n \"<number>\"\n ]\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v4/order/private/cancel/multi",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"cancel",
"multi"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": {\n \"success\": true\n }\n}"
},
{
"name": "When the request data is invalid.",
"originalRequest": {
"method": "POST",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"orderIds\": [\n \"<number>\",\n \"<number>\"\n ]\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v4/order/private/cancel/multi",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"cancel",
"multi"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Bad Request",
"code": 400,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "POST",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"orderIds\": [\n \"<number>\",\n \"<number>\"\n ]\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v4/order/private/cancel/multi",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"cancel",
"multi"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
}
]
},
{
"name": "Get Order details by id [Private]",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/details/:id?withTrades=true",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"details",
":id"
],
"query": [
{
"key": "withTrades",
"value": "true"
}
],
"variable": [
{
"key": "id",
"value": "{{TRADED_ORDER_ID}}",
"description": "(Required) "
}
]
},
"description": "Get order details by order id (e.g. `4802bc23-45e9-4299-b878-48a41432ef17`). Returns an order object. Also, may include an array of trades if `withTrades = true`.\n\nThis is a `private` route, so the `api-key` parameter should be sent in the header.\n\n## Data dictionary\n| Name | Type | Parameter type | Required | Range | Description |\n|------------|--------|:--------------:|:--------:|:-------------:|--------------------------------------------------------------------------|\n| id | string | PATH | YES | - | The UUID of the order to show details. |\n| withTrades | bool | QUERY | NO | `true, false` | Specify if the response should include trades associated with the order. |\n\n## Exemplary request\nIf you do not have any orders created yet, please create a new order using [Create a new order](#Post-a-new-order) endpoint first. \nYou should receive an order id in the response, which should then be added to the path of this request: `{{baseURL}}/v4/order/private/details/{{ORDER_ID}}`\n\n## Response structure\nYou will receive a JSON in the response with `data` object, structured like this example:\n\n````JSON\nHTTP/1.1 200 OK\nContent-Type: application/json; charset=utf-8\n\n{\n \"id\": \"6ae80635-5434-4b85-a1c2-38856b50d295\", // Unique identifier of an order\n \"type\": \"Limit\", // Type of an order\n \"quantity\": \"0.01\", // Original order quantity\n \"executedQuantity\": \"0.00\", // Traded quantity is 0 if no trades \n \"pair\": \"BTC_USDT\", // Traded pair\n \"price\": \"16700\", // Price to trade\n \"status\": \"Open\", // The status of the order\n \"createdAt\": \"2022-10-01T12:08:55.444Z\", // Date-time of order creation, UTC\n \"startAt\": \"2022-10-01T12:08:55.444Z\", // Date-time of beginning order execution, UTC\n}\n````\n\nIf you also add `withTrades=true` and trades were executed for the order, then the `data` object will include `trades` array, for example: \n\n````JSON\nHTTP/1.1 200 OK\nContent-Type: application/json; charset=utf-8\n \n{\n \"id\": \"6ae80635-5434-4b85-a1c2-38856b50d295\", // Unique identifier of an order\n \"type\": \"Limit\", // Type of an order\n \"quantity\": \"0.01\", // Original order quantity\n \"executedQuantity\": \"0.01\", // Total traded quantity, if there were trades\n \"pair\": \"BTC_USDT\", // Traded pair\n \"price\": \"16700\", // Price to trade\n \"status\": \"Closed\", // The status of the order\n \"createdAt\": \"2022-10-01T12:08:55.444Z\", // Date-time of order creation, UTC\n \"startAt\": \"2022-10-01T12:08:55.444Z\", // Date-time of beginning order execution, UTC\n \"trades\": [\n {\n \"id\": \"73f4cf03-c79b-461f-9bbe-257c1c957073\", // Unique identifier of a trade\n \"orderId\": \"6ae80635-5434-4b85-a1c2-38856b50d295\", // Unique identifier of an associated order\n \"pair\": \"BTC_USDT\", // Traded pair\n \"quantity\": \"0.01\", // Traded quantity\n \"price\": \"19083\", // Traded price\n \"isTaker\": false, // ????????\n \"fee\": \"0.477075\", // Exchange commission fee\n \"feeCurrency\": \"0.477075\", // Currency of the commission !!! _Comment: bug reported_\n \"isBuyer\": false, // Buy or sell the base asset\n \"quoteQuantity\": \"190.83\", // Quote asset quantity\n \"createdAt\": \"2022-10-01T12:08:55.465Z\" // Date-time of trade execution, UTC\n }\n ]\n}\n````\n\n## Errors\n| Status | Error code | Message | Parameter | Description |\n|:------:|:----------------------:|:-----------------------------------:|:---------:|---------------------------------------------------------------------|\n| 404 | NotFoundException | Order with id: {SOME_ID} not found! | `id` | Order with such ID either does not exist or belongs to another user |\n| 500 | WrongRequestException | id must be a UUID | `id` | Incorrect order id received |\n| 500 | WrongRequestException | property uuid should not exist | `id` | Sent UUID as QUERY parameter, but should be sent as PATH |"
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/details/:id?withTrades=<boolean>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"details",
":id"
],
"query": [
{
"key": "withTrades",
"value": "<boolean>"
}
],
"variable": [
{
"key": "id",
"value": "<number>",
"description": "(Required) "
},
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": {\n \"type\": \"TakeProfitLimit\",\n \"status\": \"Open\",\n \"sn\": -77069031.83124804,\n \"quantity\": \"nulla reprehenderit ut labore\",\n \"executedQuantity\": \"mollit ullamco Lorem proident\",\n \"pair\": \"mollit\",\n \"price\": \"Duis cupidatat qui in non\",\n \"createdAt\": \"2003-12-17T23:46:45.823Z\",\n \"startAt\": \"2015-12-06T14:50:15.207Z\",\n \"quoteQuantity\": \"mollit ut officia ut\",\n \"stopPrice\": \"tempor aliqua veniam\",\n \"trades\": [\n {\n \"id\": \"incididu\",\n \"orderId\": -83303583.05296625,\n \"pair\": \"laboris officia\",\n \"createdAt\": 59078415.39173168,\n \"quantity\": \"veniam aute\",\n \"quoteQuantity\": \"eu ut quis\",\n \"price\": \"nulla Lorem laborum\",\n \"isTaker\": false,\n \"isBuyer\": true,\n \"fee\": \"adipisicing quis magna exercitation\",\n \"feeCurrency\": \"magna nulla laboris anim\"\n },\n {\n \"id\": \"anim ex culpa reprehenderit\",\n \"orderId\": -66052900.97978438,\n \"pair\": \"est eu qui\",\n \"createdAt\": 93730299.1231511,\n \"quantity\": \"proident pariatu\",\n \"quoteQuantity\": \"in amet consequat sed\",\n \"price\": \"aliqua eiusmod Excepteur Lorem\",\n \"isTaker\": true,\n \"isBuyer\": true,\n \"fee\": \"nisi incididunt in\",\n \"feeCurrency\": \"commodo cillum dolor aliqua\"\n }\n ]\n }\n}"
},
{
"name": "When the request data is invalid.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/details/:id?withTrades=<boolean>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"details",
":id"
],
"query": [
{
"key": "withTrades",
"value": "<boolean>"
}
],
"variable": [
{
"key": "id",
"value": "<number>",
"description": "(Required) "
},
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Bad Request",
"code": 400,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/details/:id?withTrades=<boolean>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"details",
":id"
],
"query": [
{
"key": "withTrades",
"value": "<boolean>"
}
],
"variable": [
{
"key": "id",
"value": "<number>",
"description": "(Required) "
},
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
},
{
"name": "Create client order [Private]",
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"type\": \"Limit\",\n \"orderSide\": \"{{ORDER_SIDE}}\",\n \"pair\": \"{{TRADE_PAIR}}\",\n \"quantity\": \"1\",\n \"price\": \"20000\",\n \"amount\": \"20000\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v4/order/private/create",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"create"
]
},
"description": "Create a new order. Returns an id of your newly created order.\n \n This is a `private` route, so the `api-key` parameter should be sent in the header.\n \n ### Data dictionary\n | Name | Type | Parameter type | Required | Range | Description |\n |---------------|--------|:--------------:|:--------:|:---------------------------------------------------------------------------------:|---------------------------------------------------------------------------------------------------------------------------------|\n | type | enum | BODY | YES | `Limit, LimitMaker, Market, StopLossLimit, StopLoss, TakeProfit, TakeProfitLimit` | Type of an order |\n | orderSide | enum | BODY | YES | `Bid, Ask` | `Bid` for buying base asset, `Ask` for selling base asset. FYI: `For BTC_USDT trading pair, BTC is the base asset` |\n | pair | string | BODY | YES | - | A trading pair as per the list from /v4/markets/public/getAll |\n | quantity | string | BODY | YES | - | Quantity of the base asset to buy/sell. Precision depends on the asset as per /v4/markets/public/getAll |\n | price | string | BODY | YES | - | Target exchange price to buy/sell the base asset. |\n | amount | string | BODY | YES | - | Amount of the quote asset to use. Precision depends on the asset as per /v4/markets/public/getAll |\n | quoteQuantity | string | BODY | YES* | - | The max quantity of the quote asset to use for selling/buying. Precision depends on the asset as per /v4/markets/public/getAll |\n | stopPrice | string | BODY | YES* | - | For Stop Loss orders, price threshold for stopping order execution |\n > 📘 For all price-, amount- and quantity-related parameters the precision depends on the asset as per /v4/markets/public/getAll \n \n ### Exemplary request\n Is there any dev env where users can create orders w/o worry about their wallets\n \n ````json\n {\n \"type\": \"Limit\",\n \"orderSide\": \"Ask\",\n \"pair\": \"DAY_NIGHT\",\n \"quantity\": \"1\",\n \"price\": \"1\",\n \"amount\": \"1\"\n }\n ````\n \n ### Response structure\n You will receive a JSON in the response with `data` object, structured like this example:\n ````\n {\n \"id\": \"3e5591ba-2778-4d85-8851-54284045ea44\", // Unique identifier of an order\n }\n ````\n ### Errors\n | Error code | Message | Parameter | Description |\n |:---------------------:|:------------------------------:|:----------:|--------------------------------------------------------|\n | REQUIRED:QUANTITY | Required quantity is missing | `quantity` | Required parameter is missing |\n | INVALID:MARKET | Invalid market pair | `pair` | Check the trading pair using /v4/markets/public/getAll |\n | WrongRequestException | amount must be a number string | `amount` | Required parameter is missing |"
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "POST",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"type\": \"<string>\",\n \"orderSide\": \"<string>\",\n \"pair\": \"<string>\",\n \"amount\": \"<string>\",\n \"price\": \"<string>\",\n \"quoteQuantity\": \"<string>\",\n \"quantity\": \"<string>\",\n \"stopPrice\": \"<string>\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v4/order/private/create",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"create"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Created",
"code": 201,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": {\n \"id\": 30738432.15039918\n }\n}"
},
{
"name": "When the request data is invalid.",
"originalRequest": {
"method": "POST",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"type\": \"<string>\",\n \"orderSide\": \"<string>\",\n \"pair\": \"<string>\",\n \"amount\": \"<string>\",\n \"price\": \"<string>\",\n \"quoteQuantity\": \"<string>\",\n \"quantity\": \"<string>\",\n \"stopPrice\": \"<string>\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v4/order/private/create",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"create"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Bad Request",
"code": 400,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "POST",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"type\": \"<string>\",\n \"orderSide\": \"<string>\",\n \"pair\": \"<string>\",\n \"amount\": \"<string>\",\n \"price\": \"<string>\",\n \"quoteQuantity\": \"<string>\",\n \"quantity\": \"<string>\",\n \"stopPrice\": \"<string>\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v4/order/private/create",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"create"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
},
{
"name": "Get client orders history [Private]",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/history?start={{UNIX_TIME_START}}&end={{UNIX_TIME_START}}&limit={{LIMIT}}&sort={{SORT_ASC}}&pairs={{TRADE_PAIR}},{{TRADE_PAIR_2}},{{TRADE_PAIR_3}}",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"history"
],
"query": [
{
"key": "start",
"value": "{{UNIX_TIME_START}}",
"description": "Start unix timestamp"
},
{
"key": "end",
"value": "{{UNIX_TIME_START}}",
"description": "End unix timestamp"
},
{
"key": "limit",
"value": "{{LIMIT}}",
"description": "Amount of items"
},
{
"key": "sort",
"value": "{{SORT_ASC}}",
"description": "Sort"
},
{
"key": "pairs",
"value": "{{TRADE_PAIR}},{{TRADE_PAIR_2}},{{TRADE_PAIR_3}}",
"description": "Currency Pairs separated by a comma"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
},
"description": "Get a list of client orders by pair/pairs (e.g. BTC_USDT, \"BTC_USDT,ETH_BTC\"). . Returns a list of order objects, newest first, 100 orders maximum, but not more than specified by the `limit` parameter.\n\nThis is a `private` route, so the `api-key` parameter should be sent in the header.\n\n### Data dictionary\n| Name | Type | Parameter type | Required | Range | Description |\n|-------|--------|:--------------:|:--------:|:-----------:|-------------------------------------------------------------------------|\n| pairs | string | QUERY | NO | - | A trading pair as per the list from /v4/markets/public/getAll |\n| limit | int | QUERY | NO | 1-100 | Maximum amount of results in a response |\n| sort | enum | QUERY | NO | `asc, desc` | Sort the resulting list newest-on-top (`desc`) or oldest-on-top (`asc`) |\n> 📘️ Parameter `pairs` may take several arguments separated by commas, e.g. `BTC_USDT,ETH_USDT,ETH_BTC`. If not provided, returns all pairs.\n> \n> 📘️ Parameter `limit` defaults to 100 if not provided.\n> \n> 📘️ Parameter `sort` defaults to `desc` if not provided.\n\n### Exemplary request\nFirst you will need to create a new order using [Create a new order](#Post-a-new-order) endpoint.\nOnce done, please try this request for a start: `{{baseURL}}/v4/order/private/history?limit=5`\n\n### Response structure\nYou will receive a JSON in the response with `data` object, structured like this example:\n````\n[\n {\n \"id\": \"aa6bcfe9-a8ed-4980-9102-69f6a8d1985d\", // Unique identifier of an order\n \"type\": \"Limit\", // Type of an order\n \"quantity\": \"0.325\", // Original order quantity\n \"executedQuantity\": \"0.325\", // Traded quantity (>0 if traded)\n \"pair\": \"BTC_USDT\", // Traded pair\n \"price\": \"19936\", // Price to trade\n \"status\": \"Closed\", // The status of the order\n \"createdAt\": \"2022-10-04T11:44:04.808Z\", // Date-time of order creation, UTC\n \"startAt\": \"2022-10-04T11:44:04.808Z\" // Date-time of beginning order execution, UTC\n },\n {\n \"id\": \"e05e70a5-133d-47f6-9c53-578e8b7b444a\",\n \"type\": \"Limit\",\n \"quantity\": \"44.35\",\n \"executedQuantity\": \"0\",\n \"pair\": \"ETH_USDT\",\n \"price\": \"1349.7\",\n \"status\": \"Closed\",\n \"createdAt\": \"2022-10-04T11:53:22.725Z\",\n \"startAt\": \"2022-10-04T11:53:22.725Z\"\n }\n]\n````\n### Errors\n| Error code | Message | Parameter-related | Description |\n|:-------------------------:|:---------------------------------:|:-----------------:|-----------------------------------------|\n| ARGUMENT_VALIDATION_ERROR | take must not be greater than 100 | `limit` | Ensure `limit` is less or equals 100 |\n| WrongRequestException | sort must be a valid enum value | `sort` | Only `asc` or `desc` values are allowed |\n"
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/history?start=<number>&end=<number>&limit=<number>&sort=<string>&pairs=<string>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"history"
],
"query": [
{
"key": "start",
"value": "<number>"
},
{
"key": "end",
"value": "<number>"
},
{
"key": "limit",
"value": "<number>"
},
{
"key": "sort",
"value": "<string>"
},
{
"key": "pairs",
"value": "<string>"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": [\n {\n \"type\": \"<string>\",\n \"status\": \"Open\",\n \"sn\": -32915706.574020967,\n \"quantity\": \"in in nostrud proident irure\",\n \"executedQuantity\": \"Ut ad\",\n \"pair\": \"dolor nulla\",\n \"price\": \"sint in\",\n \"createdAt\": \"1992-06-18T08:38:10.491Z\",\n \"startAt\": \"1943-09-04T23:33:59.643Z\",\n \"quoteQuantity\": \"in\",\n \"stopPrice\": \"dolore no\"\n },\n {\n \"type\": \"<string>\",\n \"status\": \"Expired\",\n \"sn\": -22040246.152549654,\n \"quantity\": \"tempor officia aliquip\",\n \"executedQuantity\": \"dolor sed\",\n \"pair\": \"exercitation mollit occaecat veni\",\n \"price\": \"aliqua\",\n \"createdAt\": \"1964-10-07T00:34:39.752Z\",\n \"startAt\": \"2001-03-14T02:42:09.820Z\",\n \"quoteQuantity\": \"commodo \",\n \"stopPrice\": \"consequat sint\"\n }\n ]\n}"
},
{
"name": "When the request data is invalid.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/history?start=<number>&end=<number>&limit=<number>&sort=<string>&pairs=<string>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"history"
],
"query": [
{
"key": "start",
"value": "<number>"
},
{
"key": "end",
"value": "<number>"
},
{
"key": "limit",
"value": "<number>"
},
{
"key": "sort",
"value": "<string>"
},
{
"key": "pairs",
"value": "<string>"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Bad Request",
"code": 400,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/history?start=<number>&end=<number>&limit=<number>&sort=<string>&pairs=<string>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"history"
],
"query": [
{
"key": "start",
"value": "<number>"
},
{
"key": "end",
"value": "<number>"
},
{
"key": "limit",
"value": "<number>"
},
{
"key": "sort",
"value": "<string>"
},
{
"key": "pairs",
"value": "<string>"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
},
{
"name": "Get trades by orderId [Private]",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/:id/trades",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
":id",
"trades"
],
"variable": [
{
"key": "id",
"value": "{{TRADED_ORDER_ID}}",
"description": "(Required) "
}
]
},
"description": "Get all the trades, associated with the order id. Returns an array of trades, if any were executed per the order.\n\nThis is a `private` route, so the `api-key` parameter should be sent in the header.\n\n### Data dictionary\n| Name | Type | Parameter type | Required | Range | Description |\n|------------|--------|:--------------:|:--------:|:-------------:|----------------------------------------|\n| id | string | PATH | YES | - | The UUID of the order to show details. |\n\n### Exemplary request\nTo fully utilize this endpoint, the checked order must have executed trades. You may trade with your open orders to accumulate enough data. \n\nPlease create a new order using [Create a new order](#Post-a-new-order) endpoint first and then create an opposing order (e.g. invert `type` to `Bid` if you created `Ask` first). \nThe trade should be executed within seconds.\n\nYou should receive an order id in the response when creating orders, please add it to the path of this request: `{{baseURL}}/v4/order/private/{{TRADED_ORDER_ID}}/trades`\n\n### Response structure\nYou will receive a JSON in the response with `data` object, structured like this example:\n\nURL: `{{baseURL}}/v4/order/private/e050c776-91e6-4c0d-b689-2415f2f74886/trades`\n````JSON\n[\n {\n \"id\": \"11de520f-6eeb-415f-a84f-1e6302962dcc\", // Unique identifier of a trade\n \"orderId\": \"e050c776-91e6-4c0d-b689-2415f2f74886\", // Unique identifier of an associated order\n \"pair\": \"BTC_USDT\", // Traded pair\n \"quantity\": \"0.6265\", // Traded quantity\n \"price\": \"20078\", // Traded price\n \"isTaker\": false, // ????????\n \"fee\": \"0.00156625\", // Exchange commission fee\n \"feeCurrency\": \"0.00156625\", // Curency of the commission !!!!!\n \"isBuyer\": true, // Buy or sell the base asset\n \"quoteQuantity\": \"12578.867\", // Quote asset quantity\n \"createdAt\": \"2022-10-04T15:33:10.046Z\" // Date-time of trade execution, UTC\n }\n]\n````\n\n### Errors\n| Error code | Message | Parameter-related | Description |\n|:-------------------------:|:-------------------------------:|:-----------------:|----------------------------------------------------------|\n| WrongRequestException | id must be a UUID | `uuid` | Incorrect order id received |\n"
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/:id/trades",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
":id",
"trades"
],
"variable": [
{
"key": "id",
"value": "<number>",
"description": "(Required) "
},
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": [\n {\n \"id\": \"voluptate magna elit\",\n \"orderId\": -67076125.0687923,\n \"pair\": \"reprehenderit\",\n \"createdAt\": 70336252.64876008,\n \"quantity\": \"laboris labore pariatur reprehenderit\",\n \"quoteQuantity\": \"eiusmod non consequat est ipsum\",\n \"price\": \"dolor\",\n \"isTaker\": true,\n \"isBuyer\": false,\n \"fee\": \"enim eiusmod pariatur culpa\",\n \"feeCurrency\": \"commodo\"\n },\n {\n \"id\": \"esse dolore\",\n \"orderId\": -19256864.66484566,\n \"pair\": \"ipsum\",\n \"createdAt\": 77839283.24538997,\n \"quantity\": \"cillum incididunt consequat\",\n \"quoteQuantity\": \"dolor ea amet\",\n \"price\": \"cillum est culpa in\",\n \"isTaker\": false,\n \"isBuyer\": true,\n \"fee\": \"enim deserunt\",\n \"feeCurrency\": \"reprehenderit deserunt\"\n }\n ]\n}"
},
{
"name": "When the request data is invalid.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/:id/trades",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
":id",
"trades"
],
"variable": [
{
"key": "id",
"value": "<number>",
"description": "(Required) "
},
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Bad Request",
"code": 400,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/:id/trades",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
":id",
"trades"
],
"variable": [
{
"key": "id",
"value": "<number>",
"description": "(Required) "
},
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
},
{
"name": "Get client active orders [Private]",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/active?start={{UNIX_TIME_START}}&end={{UNIX_TIME_START}}&limit={{LIMIT}}&sort={{SORT_ASC}}&pairs={{TRADE_PAIR}},{{TRADE_PAIR_2}},{{TRADE_PAIR_3}}",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"active"
],
"query": [
{
"key": "start",
"value": "{{UNIX_TIME_START}}",
"description": "Start unix timestamp"
},
{
"key": "end",
"value": "{{UNIX_TIME_START}}",
"description": "End unix timestamp"
},
{
"key": "limit",
"value": "{{LIMIT}}",
"description": "Amount of items"
},
{
"key": "sort",
"value": "{{SORT_ASC}}",
"description": "Sort"
},
{
"key": "pairs",
"value": "{{TRADE_PAIR}},{{TRADE_PAIR_2}},{{TRADE_PAIR_3}}",
"description": "Currency Pairs separated by a comma"
}
]
},
"description": "Api route for geting a list of active orders of an authorized user.\n Passing the authorization key in headers is required"
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/active?start=<number>&end=<number>&limit=<number>&sort=<string>&pairs=<string>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"active"
],
"query": [
{
"key": "start",
"value": "<number>"
},
{
"key": "end",
"value": "<number>"
},
{
"key": "limit",
"value": "<number>"
},
{
"key": "sort",
"value": "<string>"
},
{
"key": "pairs",
"value": "<string>"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": [\n {\n \"type\": \"<string>\",\n \"status\": \"Open\",\n \"sn\": -32915706.574020967,\n \"quantity\": \"in in nostrud proident irure\",\n \"executedQuantity\": \"Ut ad\",\n \"pair\": \"dolor nulla\",\n \"price\": \"sint in\",\n \"createdAt\": \"1992-06-18T08:38:10.491Z\",\n \"startAt\": \"1943-09-04T23:33:59.643Z\",\n \"quoteQuantity\": \"in\",\n \"stopPrice\": \"dolore no\"\n },\n {\n \"type\": \"<string>\",\n \"status\": \"Expired\",\n \"sn\": -22040246.152549654,\n \"quantity\": \"tempor officia aliquip\",\n \"executedQuantity\": \"dolor sed\",\n \"pair\": \"exercitation mollit occaecat veni\",\n \"price\": \"aliqua\",\n \"createdAt\": \"1964-10-07T00:34:39.752Z\",\n \"startAt\": \"2001-03-14T02:42:09.820Z\",\n \"quoteQuantity\": \"commodo \",\n \"stopPrice\": \"consequat sint\"\n }\n ]\n}"
},
{
"name": "When the request data is invalid.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/active?start=<number>&end=<number>&limit=<number>&sort=<string>&pairs=<string>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"active"
],
"query": [
{
"key": "start",
"value": "<number>"
},
{
"key": "end",
"value": "<number>"
},
{
"key": "limit",
"value": "<number>"
},
{
"key": "sort",
"value": "<string>"
},
{
"key": "pairs",
"value": "<string>"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Bad Request",
"code": 400,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/private/active?start=<number>&end=<number>&limit=<number>&sort=<string>&pairs=<string>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"private",
"active"
],
"query": [
{
"key": "start",
"value": "<number>"
},
{
"key": "end",
"value": "<number>"
},
{
"key": "limit",
"value": "<number>"
},
{
"key": "sort",
"value": "<string>"
},
{
"key": "pairs",
"value": "<string>"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
}
]
},
{
"name": "Get public Order book [Public]",
"request": {
"auth": {
"type": "noauth"
},
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v4/order/public/book/:pair?level={{LEVEL}}",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"public",
"book",
":pair"
],
"query": [
{
"key": "level",
"value": "{{LEVEL}}"
}
],
"variable": [
{
"key": "pair",
"value": "{{TRADE_PAIR}}",
"description": "(Required) "
}
]
},
"description": "Get a list of order prices by pair (e.g. BTC_USDT). Returns a list of order prices, 2 arrays for Bids and Asks; lowest first for Asks, highest first for Bids; leveled by order prices, but no more levels than specified by the `level` parameter.\n\nThis is a `public` route, no need for authorization.\n\n### Data dictionary\n| Name | Type | Parameter type | Required | Range | Description |\n|-------|--------|:--------------:|:--------:|:-----------------------------:|---------------------------------------------------------------|\n| pair | string | PATH | YES | - | A trading pair as per the list from /v4/markets/public/getAll |\n| level | int | QUERY | NO | 5, 10, 20, 50, 100, 500, 1000 | Amount of price levels for existing orders in the response |\n> 📘️ Parameter `level` defaults to 1000 if not provided.\n\n### Exemplary request\nPlease try this request for a start: `{{baseURL}}/v4/order/public/book/BTC_USDT?level=5`\n\n### Response structure\nYou will receive a JSON in the response with `data` object, structured like this example:\n````\n{\n \"asks\": [ // An array of sell orders\n [\n \"16950\", // Sell price, level 1\n \"0.001\" // Sell quantity, level 1\n ],\n [\n \"17000\", // Sell price, level 2\n \"0.01\" // Sell quantity, level 2\n ]\n ],\n \"bids\": [ // An array of buy orders\n [\n \"16700\", // Sell price, level 1\n \"0.01\" // Sell quantity, level 1\n ],\n [\n \"16000\", // Sell price, level 2\n \"0.001\" // Sell quantity, level 2\n ]\n ]\n }\n````\n### Errors\n| Error code | Message | Parameter | Description |\n|:----------------------:|:-----------------------------------------------------------------------------------------------:|:---------:|---------------------------------------------------------------------------------------------------------------------|\n| WrongRequestException | <font size=\"1\" level must be one of the following values: 5, 10, 20, 50, 100, 500, 1000 </font> | `level` | Ensure `limit` is within the provided range |\n| NotFoundException | Cannot GET /v4/trade/public/book?{pair} | `pair` | Sent `pair` as QUERY parameter, please send as PATH parameter instead. More info [here](#parameter-concepts-in-use) |"
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "GET",
"header": [],
"url": {
"raw": "{{baseUrl}}/v4/order/public/book/:pair?level=<string>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"public",
"book",
":pair"
],
"query": [
{
"key": "level",
"value": "<string>"
}
],
"variable": [
{
"key": "pair",
"value": "<string>",
"description": "(Required) "
},
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": {\n \"asks\": [\n [\n \"1950\",\n \"0.36\"\n ],\n [\n \"1950\",\n \"0.36\"\n ]\n ],\n \"bids\": [\n [\n \"1950\",\n \"0.36\"\n ],\n [\n \"1950\",\n \"0.36\"\n ]\n ]\n }\n}"
},
{
"name": "When the request data is invalid.",
"originalRequest": {
"method": "GET",
"header": [],
"url": {
"raw": "{{baseUrl}}/v4/order/public/book/:pair?level=<string>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"public",
"book",
":pair"
],
"query": [
{
"key": "level",
"value": "<string>"
}
],
"variable": [
{
"key": "pair",
"value": "<string>",
"description": "(Required) "
},
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Bad Request",
"code": 400,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "GET",
"header": [],
"url": {
"raw": "{{baseUrl}}/v4/order/public/book/:pair?level=<string>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"order",
"public",
"book",
":pair"
],
"query": [
{
"key": "level",
"value": "<string>"
}
],
"variable": [
{
"key": "pair",
"value": "<string>",
"description": "(Required) "
},
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
}
]
},
{
"name": "trade",
"item": [
{
"name": "private",
"item": [
{
"name": "Get client trades history by filter [Private]",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v4/trade/private/history?orderId={{TRADED_ORDER_ID}}",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"trade",
"private",
"history"
],
"query": [
{
"key": "pair",
"value": "{{TRADE_PAIR}}",
"disabled": true
},
{
"key": "orderId",
"value": "{{TRADED_ORDER_ID}}",
"description": "Better not provide both `pair` and `orderId`"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
},
"description": "Get a list of trades by pair (e.g. BTC_USDT). Returns a list of your trades with details on each trade, newest first.\n\nThis is a `private` route, so the `api-key` parameter should be sent in the header.\n\n### Data dictionary\n| Name | Type | Parameter type | Required | Range | Description |\n|---------|--------|:--------------:|:--------:|:-----:|---------------------------------------------------------------|\n| pair | string | QUERY | NO | - | A trading pair as per the list from /v4/markets/public/getAll |\n| orderId | string | QUERY | NO | - | UUID of an order, to receive trades for this order only |\n\n> 📘️ If `pair` and `orderId` were not specified, returns the latest 10 trades for any trade pair and any order.\n\n### Exemplary request\nTo properly test this endpoint, you need to have trades under your account. The easiest way is to create 2 alike order of different order side (Ask/Bid) and let them close each other. Once done, please use this endpoint: `{{baseURL}}/v4/trade/private/history`\n\n### Response structure\nIn return you should receive a JSON with `data` object, structured like this example:\n````\n{\n \"id\": \"edb17459-c9bf-4148-9ae6-7367d7f55d71\", // Unique identifier of a trade \n \"orderId\": \"a80bec3f-4ffa-45c1-9d78-f6301e9748fe\", // Unique identifier of an order associated with the trade\n \"pair\": \"BTC_USDT\", // Traded pair\n \"quantity\": \"1.5862\", // Traded quantity\n \"price\": \"19087\", // Price of the trade\n \"isTaker\": true, // ????????\n \"fee\": \"0.0039655\", // Exchange commission fee\n \"feeCurrency\": \"0.0039655\", // Curency of the commission !!!!!\n \"isBuyer\": true, // Buy or sell the base asset\n \"quoteQuantity\": \"30275.7994\", // Quote asset quantity\n \"createdAt\": \"2022-09-29T13:43:53.824Z\" // Date of trade execution\n}\n````\n### Errors\n| Error code | Message | Parameter-related | Description |\n|:-------------------------:|:---------------------------------------:|:-----------------:|----------------------------------------------------------------------------------------------------------------------|"
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/trade/private/history?pair=<string>&orderId=<number>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"trade",
"private",
"history"
],
"query": [
{
"key": "pair",
"value": "<string>"
},
{
"key": "orderId",
"value": "<number>"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": [\n {\n \"id\": \"voluptate magna elit\",\n \"orderId\": -67076125.0687923,\n \"pair\": \"reprehenderit\",\n \"createdAt\": 70336252.64876008,\n \"quantity\": \"laboris labore pariatur reprehenderit\",\n \"quoteQuantity\": \"eiusmod non consequat est ipsum\",\n \"price\": \"dolor\",\n \"isTaker\": true,\n \"isBuyer\": false,\n \"fee\": \"enim eiusmod pariatur culpa\",\n \"feeCurrency\": \"commodo\"\n },\n {\n \"id\": \"esse dolore\",\n \"orderId\": -19256864.66484566,\n \"pair\": \"ipsum\",\n \"createdAt\": 77839283.24538997,\n \"quantity\": \"cillum incididunt consequat\",\n \"quoteQuantity\": \"dolor ea amet\",\n \"price\": \"cillum est culpa in\",\n \"isTaker\": false,\n \"isBuyer\": true,\n \"fee\": \"enim deserunt\",\n \"feeCurrency\": \"reprehenderit deserunt\"\n }\n ]\n}"
},
{
"name": "When the request data is invalid.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/trade/private/history?pair=<string>&orderId=<number>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"trade",
"private",
"history"
],
"query": [
{
"key": "pair",
"value": "<string>"
},
{
"key": "orderId",
"value": "<number>"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Bad Request",
"code": 400,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/trade/private/history?pair=<string>&orderId=<number>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"trade",
"private",
"history"
],
"query": [
{
"key": "pair",
"value": "<string>"
},
{
"key": "orderId",
"value": "<number>"
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
}
]
},
{
"name": "Get public trades book [Public]",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v4/trade/public/book/:pair?limit={{LIMIT}}",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"trade",
"public",
"book",
":pair"
],
"query": [
{
"key": "limit",
"value": "{{LIMIT}}",
"description": "(Required) "
}
],
"variable": [
{
"key": "pair",
"value": "{{TRADE_PAIR_D_N}}",
"description": "(Required) "
}
]
},
"description": "Get a list of trades by pair (e.g. BTC_USDT). Returns a list of trades, newest first, 100 trades maximum, but not more than specified by the `limit` parameter.\n\nThis is a `public` route, no need for authorization.\n\n### Data dictionary\n| Name | Type | Parameter type | Required | Range | Description |\n|----------|--------|:--------------:|:--------:|:-----:|---------------------------------------------------------------|\n| pair | string | PATH | YES | - | A trading pair as per the list from /v4/markets/public/getAll |\n| limit | int | QUERY | NO | 1-100 | Maximum amount of results in a response |\n> 📘️ Parameter `limit` defaults to 25 if not provided.\n\n### Exemplary request\nPlease try this request for a start: `{{baseURL}}/v4/trade/public/book/BTC_USDT?limit=10`\n\n### Response structure\nIn return you should receive a JSON with `data` object, structured like this example:\n````\n{\n \"id\": \"3e5591ba-2778-4d85-8851-54284045ea44\", // Unique identifier of a trade\n \"sn\": \"2908\", // Serial number of the trade\n \"pair\": \"BTC_USDT\", // Market pair that is being traded\n \"quoteQuantity\": \"11528.8118\", // Qty of the quote asset, USDT in this example\n \"matchPrice\": \"18649\", // Exchange price at the moment of execution \n \"matchQuantity\": \"0.6182\", // Qty of the base asset, BTC in this example\n \"createdAt\": \"2022-09-23T14:30:41.486Z\", // Time of trade execution \n \"type\": \"Sell\" // Trade type: `Buy` or `Sell`\n}\n````\n### Errors\n| Error code | Message | Parameter-related | Description |\n|:-------------------------:|:---------------------------------------:|:-----------------:|----------------------------------------------------------------------------------------------------------------------|\n| ARGUMENT_VALIDATION_ERROR | take must not be greater than 100 | `limit` | Ensure `limit` is less or equals 100 |\n| NotFoundException | Cannot GET /v4/trade/public/book?{pair} | `pair` | Sent `pair` as QUERY parameter, please send as PATH parameter instead. More info [here](#parameter-concepts-in-use) |"
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "GET",
"header": [],
"url": {
"raw": "{{baseUrl}}/v4/trade/public/book/:pair?limit=<number>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"trade",
"public",
"book",
":pair"
],
"query": [
{
"key": "limit",
"value": "<number>"
}
],
"variable": [
{
"key": "pair",
"value": "<string>",
"description": "(Required) "
},
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": [\n {\n \"type\": \"Sell\",\n \"id\": \"consectetur fugiat sunt\",\n \"sn\": -68296993.87210946,\n \"pair\": \"veniam\",\n \"quoteQuantity\": \"officia esse culpa Duis ea\",\n \"matchPrice\": \"dolor\",\n \"matchQuantity\": \"exercitation cupidatat\",\n \"createdAt\": \"2005-03-13T00:04:40.698Z\"\n },\n {\n \"type\": \"Buy\",\n \"id\": \"id ut\",\n \"sn\": -79673857.86845087,\n \"pair\": \"irure\",\n \"quoteQuantity\": \"ipsum non cupidatat sunt\",\n \"matchPrice\": \"magna ea voluptate eu consequat\",\n \"matchQuantity\": \"fugiat veniam ea\",\n \"createdAt\": \"2017-08-28T07:44:21.134Z\"\n }\n ]\n}"
},
{
"name": "When the request data is invalid.",
"originalRequest": {
"method": "GET",
"header": [],
"url": {
"raw": "{{baseUrl}}/v4/trade/public/book/:pair?limit=<number>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"trade",
"public",
"book",
":pair"
],
"query": [
{
"key": "limit",
"value": "<number>"
}
],
"variable": [
{
"key": "pair",
"value": "<string>",
"description": "(Required) "
},
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Bad Request",
"code": 400,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "GET",
"header": [],
"url": {
"raw": "{{baseUrl}}/v4/trade/public/book/:pair?limit=<number>",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"trade",
"public",
"book",
":pair"
],
"query": [
{
"key": "limit",
"value": "<number>"
}
],
"variable": [
{
"key": "pair",
"value": "<string>",
"description": "(Required) "
},
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
}
]
},
{
"name": "client/private",
"item": [
{
"name": "Get client balance [Private]",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v4/private/getBalance",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"private",
"getBalance"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
},
"description": "Review account wallets balance. Returns an array of the balances of all your wallets. \n\nThis is a `private` route, so the `api-key` parameter should be sent in the header.\n\n### Data dictionary\n> 📘 This endpoint does not take any parameters. \n\n### Exemplary request\nPlease use this endpoint: `{{baseURL}}/v4/private/getBalance`\n\n### Response structure\nYou will receive a JSON in the response with `data` object, structured like this example:\n````JSON\n[\n {\n \"currency\": \"UAH\", // Wallet currency\n \"balance\": \"7134.6\", // Available balance, precision depends on the currency\n \"lockBalance\": \"100\" // Minimum amount locked on the balance\n },\n {\n \"currency\": \"ETH\", // Wallet currency\n \"balance\": \"10929514.7810025\", // Available balance, precision depends on the coin\n \"lockBalance\": \"69922.041\" // Minimum amount locked on the balance\n },\n {\n \"currency\": \"BTC\", // Wallet currency\n \"balance\": \"9994849.763209032\", // Available balance, precision depends on the coin\n \"lockBalance\": \"5110.24204168\" // Minimum amount locked on the balance\n }\n]\n````\n### Errors\n> 📘 As there are no parameters for this endpoint, you may encounter only general errors while using it."
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/private/getBalance",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"private",
"getBalance"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": [\n {\n \"currency\": \"minim incididunt eiusmod dolor\",\n \"balance\": \"quis\",\n \"lockBalance\": \"Duis pariatur\"\n },\n {\n \"currency\": \"ullamco ea sint dolor\",\n \"balance\": \"exercitation in incididunt dolor\",\n \"lockBalance\": \"commodo eiusmod\"\n }\n ]\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/private/getBalance",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"private",
"getBalance"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
},
{
"name": "Get client info [Private]",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v4/private/me",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"private",
"me"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
},
"description": "Review your account information. \n\nThis is a `private` route, so the `api-key` parameter should be sent in the header.\n\n### Data dictionary\n> 📘 This endpoint does not take any parameters. \n\n### Exemplary request\nPlease use this endpoint: `{{baseURL}}/v4/private/me`\n\n### Response structure\nYou will receive a JSON in the response with `data` object, structured like this example:\n````JSON\n{\n \"id\": \"93adcb31-a266-4c6e-98e8-5fc574cd230d\", // Unique identifier of the user\n \"fullName\": \"John Smith\", // Name of the user\n \"language\": \"en\", // Language preferences\n \"merchantId\": \"16324228-5ytc-5abc-4sra-c90259b21d4e\", // Unique merchant identifier\n \"referenceCurrency\": \"UAH\", // Reference currency for UI\n \"username\": \"john-smith-user\", // Username of the user\n \"verificationStatus\": \"accepted\", // User verification state\n \"confirmationSetting\": { // Indicates if a confirmation is sent in case of an action\n \"withdraw\": false // Confirmation of the withdrawal action (off in this case)\n },\n \"motificationSetting\": { // Indicates if a notification is sent in case of an event \n \"advertisement\": false, // Inform about new promos (off in this case)\n \"deposit\": false, // Inform about new deposits (off in this case)\n \"login\": false, // Inform about new login detection (off in this case)\n \"order\": false, // Inform about new order creation (off in this case)\n \"withdraw\": false // Inform about successful withdrawal (off in this case)\n }\n}\n````\n### Errors\n> 📘 As there are no parameters for this endpoint, you may encounter only general errors while using it."
},
"response": [
{
"name": "response",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/private/me",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"private",
"me"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"data\": {\n \"id\": \"non nisi\",\n \"fullName\": \"exercitation\",\n \"language\": \"quis nulla consequat\",\n \"merchantId\": \"non Lorem\",\n \"referenceCurrency\": \"Excepteur anim Ut consectetur\",\n \"username\": \"ex\",\n \"verificationStatus\": \"accepted\",\n \"confirmationSetting\": {\n \"withdraw\": false\n },\n \"motificationSetting\": {\n \"deposit\": false,\n \"order\": true,\n \"withdraw\": true,\n \"login\": false,\n \"advertisement\": false\n }\n }\n}"
},
{
"name": "When an internal error occurred.",
"originalRequest": {
"method": "GET",
"header": [
{
"description": "Added as a part of security scheme: apikey",
"key": "api-key",
"value": "<API Key>"
}
],
"url": {
"raw": "{{baseUrl}}/v4/private/me",
"host": [
"{{baseUrl}}"
],
"path": [
"v4",
"private",
"me"
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "{{BASE_URL_DEV}}",
"description": "Base url"
}
]
}
},
"status": "Internal Server Error",
"code": 500,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"cookie": [],
"body": "{\n \"errors\": [\n {\n \"message\": \"qui\",\n \"code\": \"su\"\n },\n {\n \"message\": \"sed Duis voluptate sint occaecat\",\n \"code\": \"minim velit\"\n }\n ]\n}"
}
]
}
]
}
]
}
],
"auth": {
"type": "apikey",
"apikey": [
{
"key": "value",
"value": "{{SINGLE_API_KEY}}",
"type": "string"
},
{
"key": "key",
"value": "api-key",
"type": "string"
}
]
},
"event": [
{
"listen": "prerequest",
"script": {
"type": "text/javascript",
"exec": [
""
]
}
},
{
"listen": "test",
"script": {
"type": "text/javascript",
"exec": [
""
]
}
}
],
"variable": [
{
"key": "BASE_URL_DEV",
"value": "rest-api-pro-dev.anuk.tech",
"type": "any"
},
{
"key": "baseUrl",
"value": "{{BASE_URL_DEV}}",
"type": "string"
}
]
}
Updated over 1 year ago