Documentation Index
Fetch the complete documentation index at: https://docs.rails.xyz/llms.txt
Use this file to discover all available pages before exploring further.
On connection, it sends orderBook and completedOrders snapshots first, followed by orderBookDelta and completedOrdersDelta messages.
Message — Order Book
{
"resultType": "orderBook",
"data": {
"statusCode": 200,
"orders": [
{
"quantity": "1",
"price": "2000",
"orderType": "buy"
},
{
"quantity": "0.7",
"price": "2100",
"orderType": "sell"
}
]
}
}
| Field | Type | Required | Description |
|---|
resultType | string | Yes | orderBook |
data.statusCode | number | Yes | 200 |
data.orders | array | Yes | Full order book entries |
data.orders[].orderType | string | Yes | Order side: buy or sell |
data.orders[].price | string | Yes | Price level |
data.orders[].quantity | string | Yes | Total quantity at this price level |
Message — Order Book Delta
{
"resultType": "orderBookDelta",
"data": {
"statusCode": 200,
"orders": [
{
"quantity": "1",
"price": "2000",
"orderType": "buy"
},
{
"quantity": "0",
"price": "2100",
"orderType": "sell"
}
]
}
}
| Field | Type | Required | Description |
|---|
resultType | string | Yes | orderBookDelta |
data.statusCode | number | Yes | 200 |
data.orders | array | Yes | Incremental order book changes |
data.orders[].orderType | string | Yes | Order side: buy or sell |
data.orders[].price | string | Yes | Price level |
data.orders[].quantity | string | Yes | New total quantity at this price level |
Message — Completed Orders
{
"resultType": "completedOrders",
"data": {
"statusCode": 200,
"orders": [
{
"price": "2100",
"quantity": "0.1",
"matchId": "07e887c4-9b6f-4382-9947-d4fc6212b813",
"updatedAt": 1703710438931,
"orderType": "buy",
"executionType": "maker"
},
{
"price": "2100",
"quantity": "0.1",
"matchId": "17e887c4-9b6f-4382-9947-d4fc6212b813",
"updatedAt": 1703710438931,
"orderType": "sell",
"executionType": "taker"
},
{
"price": "2000",
"quantity": "1",
"matchId": "27e887c4-9b6f-4382-9947-d4fc6212b813",
"updatedAt": 1703703498217,
"orderType": "sell",
"executionType": "maker"
},
{
"price": "2000",
"quantity": "1",
"matchId": "37e887c4-9b6f-4382-9947-d4fc6212b813",
"updatedAt": 1703703498217,
"orderType": "buy",
"executionType": "taker"
}
]
}
}
| Field | Type | Required | Description |
|---|
resultType | string | Yes | completedOrders |
data.statusCode | number | Yes | 200 |
data.orders | array | Yes | Snapshot of recent trade executions |
data.orders[].executionType | string | Yes | Order execution role: taker or maker |
data.orders[].matchId | string | Yes | Unique identifier for the trade match |
data.orders[].orderType | string | Yes | Order side: buy or sell |
data.orders[].price | string | Yes | Execution price |
data.orders[].quantity | string | Yes | Execution quantity |
data.orders[].updatedAt | number | Yes | Execution timestamp (milliseconds since epoch) |
Message — Completed Orders Delta
{
"resultType": "completedOrdersDelta",
"data": {
"statusCode": 200,
"orders": [
{
"price": "2100",
"quantity": "0.1",
"matchId": "07e887c4-9b6f-4382-9947-d4fc6212b813",
"updatedAt": 1703710438931,
"orderType": "buy",
"executionType": "maker"
},
{
"price": "2100",
"quantity": "0.1",
"matchId": "07e887c4-9b6f-4382-9947-d4fc6212b813",
"updatedAt": 1703710438931,
"orderType": "sell",
"executionType": "taker"
}
]
}
}
| Field | Type | Required | Description |
|---|
resultType | string | Yes | completedOrdersDelta |
data.statusCode | number | Yes | 200 |
data.orders | array | Yes | New trade executions since last update |
data.orders[].executionType | string | Yes | Order execution role: taker or maker |
data.orders[].matchId | string | Yes | Unique identifier for the trade match |
data.orders[].orderType | string | Yes | Order side: buy or sell |
data.orders[].price | string | Yes | Execution price |
data.orders[].quantity | string | Yes | Execution quantity |
data.orders[].updatedAt | number | Yes | Execution timestamp (milliseconds since epoch) |