This endpoint allows cancelling orders which are associated with a future's contract or a margin account. If no arguments are specified all open orders will be cancelled.
Authentication is required.
Endpoint |
Request Type | Permissible API Keys |
/api/v3/cancelallorders
|
POST | Read-write, Master |
Argument | Type | Required | Description |
symbol
|
string | No | A future product to cancel all open orders |
Sample Call |
https://www.cryptofacilities.com/derivatives/api/v3/cancelallorders https://www.cryptofacilities.com/derivatives/api/v3/cancelallorders?symbol=pi_xbtusd |
Sample Return if Successful |
{ ], "orderId":"2018bc94-643c-477e-9368-8a5688396c6a", "type":"CANCEL" |
Field |
Type | Description |
result
|
String | Always success |
serverTime
|
ISO8601 datetime | The server date and time |
cancelStatus
|
structure | A structure containing information on the cancellation request, see below |
receivedTime | ISO8601 datetime | The date and time the order cancellation was received |
cancelOnly | string | The symbol of the futures or all. |
status | string | The status of the order cancellation, either of:
|
cancelledOrders | list of structures | A list of structures containing all the successfully cancelled orders |
order_id | string | The cancelled order id |
cliOrdId | string | The client order id. Returned only if client specified one |
orderEvents | Structure | Order Events |
Sample Return if Unsuccessful |
{ "result":"error", "serverTime":"2016-02-25T09:45:53.818Z", "error":"apiLimitExceeded" } |
Field |
Type | Description |
result
|
String | Always error |
serverTime
|
ISO8601 datetime | The server date and time |
error
|
string |
The reason the API call failed, either of:
|