Skip to main content
DELETE
/
orderbooks
/
stocks
/
api
/
offchain
/
orders
/
{orderId}
{
  "customerRef": "cust_12345"
}
{
  "success": true,
  "data": {
    "id": "ord_oc_001",
    "status": "CANCELLED",
    "cancelledAt": "2025-01-15T10:35:00.000Z"
  },
  "metadata": {
    "requestId": "550e8400-e29b-41d4-a716-446655440000",
    "timestamp": "2025-01-15T10:35:00.000Z",
    "instanceId": "inst_abc"
  }
}
Cancels an open off-chain order. The customerRef in the request body must match the original order’s customer reference.

Authentication

Requires an instance API key with the trading service enabled.

Path Parameters

orderId
string
required
The order identifier. Max 100 characters.

Request Body

customerRef
string
required
The customer reference that placed the order. 1-256 characters.
{
  "customerRef": "cust_12345"
}
{
  "success": true,
  "data": {
    "id": "ord_oc_001",
    "status": "CANCELLED",
    "cancelledAt": "2025-01-15T10:35:00.000Z"
  },
  "metadata": {
    "requestId": "550e8400-e29b-41d4-a716-446655440000",
    "timestamp": "2025-01-15T10:35:00.000Z",
    "instanceId": "inst_abc"
  }
}

Error Codes

CodeStatusDescription
ORDER_NOT_FOUND404Order does not exist or does not belong to this instance