Cancel batch of orders by order IDs or client order IDs

Queues cancellation for multiple orders by providing identifiers in a batch.

The request body can contain either or both of:

  • order_ids: Array of order IDs assigned by Paradex
  • client_order_ids: Array of client-assigned order IDs
1{
2 "order_ids": ["order-id-1", "order-id-2"],
3 "client_order_ids": ["client-id-1", "client-id-2"]
4}

Returns a 200 OK status code with detailed results for each order:

1{
2 "results": [
3 {
4 "id": "order-id-1",
5 "client_id": "client-id-X",
6 "account": "account-1",
7 "market": "BTC-USD-PERP",
8 "status": "QUEUED_FOR_CANCELLATION"
9 },
10 {
11 "id": "order-id-2",
12 "client_id": "client-id-Y",
13 "account": "account-1",
14 "market": "ETH-USD-PERP",
15 "status": "ALREADY_CLOSED"
16 },
17 {
18 "id": "order-id-3",
19 "client_id": "client-id-1",
20 "account": "account-1",
21 "market": "BTC-USD-PERP",
22 "status": "QUEUED_FOR_CANCELLATION"
23 },
24 {
25 "client_id": "client-id-2",
26 "status": "NOT_FOUND"
27 }
28 ]
29}

Each result includes:

  • id: Order ID (if the order was found)
  • client_id: Client order ID (if available)
  • account: Account that owns the order
  • market: Market of the order
  • status: One of:
    • QUEUED_FOR_CANCELLATION: Order was successfully queued for cancellation
    • ALREADY_CLOSED: Order was already in a closed state
    • NOT_FOUND: The order with the provided ID/client ID was not found

Confirmation of cancellation will be sent via websocket or can be verified from GET /orders/:id endpoint.

Orders that are already in a CLOSED state will be included in the response with status “ALREADY_CLOSED”.

Headers

AuthorizationstringRequired

Request

This endpoint expects an object.
client_order_idslist of stringsOptional

List of client order IDs to cancel

order_idslist of stringsOptional

List of order IDs to cancel

Response

List of cancellation results

resultslist of objectsOptional

List of cancellation results

Errors