DELETE /api/v1/orders/{order_id}
Cancel an order
Cancel an order.
operationId: cancelOrderV1 · CCXT method: cancelOrder · Rate-limit class: trading
Declared server differs from the callable one. This path declares its own
serversbase ofhttps://exchange.nexus.xyz, without the/api/exchangemount the document default carries. Measured 2026-09-02, the override is not routed —https://exchange.nexus.xyz/api/v1/orders/{order_id}returns404while the gateway form in the sample below is routed. A client generated from this contract will aim at the override; pin the gateway base until the per-network hosts are live. See Networks.
Authentication: hmacAuth.
Charged to the cancel budget, which is separate from the order budget that submission and amend draw on (x-nexus-rate-limit-class: trading names the class both belong to, not the bucket). A key that has spent its entire submission allowance can still cancel: exhausting one never refuses the other. It is a separate bucket rather than an exemption, so cancelling in a tight loop can still 429 — with bucket: cancel, the only refusal that means your cancel channel itself is saturated. See "Rate limits" for the full model.
Parameters
order_id
path
string
Yes
—
—
market_id
query
string
Yes
—
Market the order rests on (required for routing).
Responses
200
— (no schema declared)
Cancelled order returned
401
— (no schema declared)
—
404
— (no schema declared)
Order not found
Example
curl -X DELETE 'https://exchange.nexus.xyz/api/exchange/api/v1/orders/{order_id}' \
-H 'X-API-Key: nx_7f3a1b...' \
-H 'X-Timestamp: 1776033911836' \
-H 'X-Signature: <hmac-sha256>'import requests
headers = {
"X-API-Key": "nx_7f3a1b...",
"X-Timestamp": "1776033911836",
"X-Signature": "<hmac-sha256>"
}
response = requests.delete("https://exchange.nexus.xyz/api/exchange/api/v1/orders/{order_id}", headers=headers)
response.raise_for_status()
print(response.json())const response = await fetch("https://exchange.nexus.xyz/api/exchange/api/v1/orders/{order_id}", {
method: "DELETE",
headers: {
"X-API-Key": "nx_7f3a1b...",
"X-Timestamp": "1776033911836",
"X-Signature": "<hmac-sha256>"
},
});
if (!response.ok) throw new Error(`${response.status} ${await response.text()}`);
console.log(await response.json());X-Signature is a placeholder: it is derived from this specific request. See Authentication for the canonical string and the HMAC rule.
Generated from eng/apps/exchange/api/openapi.json (spec 0.9.36). Do not edit by hand — regenerate with python3 product/docs/tools/api-reference/generate.py. Hand-authored context lives in the Guides pages.
Last updated

