Use Open Order Query to retrieve order information on orders still OPEN on the exchange.
Open Order Query
Request
Key | Type | Value | Required |
---|---|---|---|
type | string | openorderquery | Yes |
security | string | The trading pair to query. Use "*" to search for all open orders. | Optional |
refno | string | The reference order id to query | Optional |
Response
Key | Type | Value |
---|---|---|
type | string | openorderquery |
result | string | "OK" for successful queries. For unsuccessful queries, this field will be populated with the reason for the query rejection |
security | string | The trading pair used in the query |
total_rec | number | The number of records in the data block array |
data.refno | string | The reference order id |
data.updtime | string, POSIX | Time of the last order update in POSIX time |
data.tif | string | Order's Time In Force |
data.execamount | number | The amount of the order that has executed (FIAT) |
data.qty | number | The order's original quantity |
data.security | string | The trading pair of the order |
data.type | string | order |
data.clientorderid | string | |
data.liveqty | number | Remaining open quantity on the order |
data.category | string | |
data.refno | string | |
data.price | number | |
data.execqty | number | The executed order quantity |
data.side | string | The side of the Order |
# Request
{
"type":"openorderquery",
"security":"BTCUSD"
}
# Response - Success
{
"result":"OK",
"refno":"3XXF0329A0B0",
"data": {
"updtime":"1559505235085",
"tif":"GTC",
"execamount":"10000",
"qty":"1000",
"security":"BTCUSD",
"type":"order",
"clientorderid":"CLIENTID1",
"liveqty":"900",
"category":"CROX",
"refno":"3XXF0329A0B0",
"price":"100",
"execqty":"100",
"side":"S"
}
"security":"BTCUSD",
"type":"openorderquery"
}
# Response - Failure
{
"result":"order not found",
"refno":"3XXF0329A0B0",
"security":"BTCUSD",
"type":"openorderquery"
}