Updates of orders from orderbook.
{
"action": "subscribe-public",
"module": "trading",
"path": "orderbook/{market_code}"
}
{
"action": "push",
"topic": "trading/orderbook/btc-pln",
"message": {
"changes": [
{
"marketCode": "BTC-PLN",
"entryType": "Buy",
"rate": "27601.35",
"action": "update",
"state": {
"ra": "27601.35",
"ca": "0.46205049",
"sa": "0.46205049",
"pa": "0.46205049",
"co": 4
}
}
],
"timestamp": "1576847016253"
},
"timestamp": "1576847016253",
"seqNo": 40018807
}
{
"requestId": "78539fe0-e9b0-4e4e-8c86-70b36aa93d4f",
"action": "proxy",
"module": "trading",
"path": "orderbook/{market_code}"
}
{
"action": "proxy-response",
"requestId": "78539fe0-e9b0-4e4e-8c86-70b36aa93d4f",
"statusCode": 200,
"body": {
"status": "Ok",
"sell": [
{
"ra": "27779.61",
"ca": "2.02",
"sa": "2.02",
"pa": "2.02",
"co": 1
}
],
"buy": [
{
"ra": "27300",
"ca": "0.0531304",
"sa": "0.0531304",
"pa": "0.0531304",
"co": 2
}
],
"timestamp": "1576847127883",
"seqNo": "40019280"
}
}
Response details
Key | Type | Description |
---|---|---|
changes | array | |
mmarketCode | string | Symbol of the market. |
entryType | string | Order type: buy / sell. |
rate | decimal | Price of the order. |
action | string | Type of change: remove / update. If update will occur you are going to get additional array of state. |
state | array | Optional array for active orders. |
* ra | decimal | Price of the order. |
* ca | decimal | Current amount of cryptocurrency in the order. |
* sa | decimal | Starting amount of cryptocurrency in the order. |
* pa | decimal | Amount of cryptocurrency before the last change. |
* co | decimal | Amount of orders in the order. |
timestamp | Unix Timestamp | Time of execute on server. For this time all above values are actual. |