Cancel Multiple Orders
Removes several orders from the book in a single call. Accepts up to 3000 order IDs per request.
Endpoint
Section titled “Endpoint”DELETE /orders
Base URL: https://api.openfish.fun
Authentication
Section titled “Authentication”L2 authentication required. All five OPENFISH_* headers must be present.
Request Body
Section titled “Request Body”A JSON array of order ID strings.
[ "a1b2c3d4-e5f6-7890-abcd-ef1234567890", "b2c3d4e5-f6a7-8901-bcde-f12345678901"]Response
Section titled “Response”{ "canceled": [ "a1b2c3d4-e5f6-7890-abcd-ef1234567890", "b2c3d4e5-f6a7-8901-bcde-f12345678901" ], "notCanceled": {}}| Field | Type | Description |
|---|---|---|
canceled | array of strings | IDs of orders that were removed |
notCanceled | object | Mapping from order ID to error string for any that could not be removed |
Partial failure example
Section titled “Partial failure example”{ "canceled": ["a1b2c3d4-e5f6-7890-abcd-ef1234567890"], "notCanceled": { "b2c3d4e5-f6a7-8901-bcde-f12345678901": "not found or already canceled" }}Example
Section titled “Example”curl -X DELETE https://api.openfish.fun/orders \ -H "Content-Type: application/json" \ -H "OPENFISH_ADDRESS: 0x..." \ -H "OPENFISH_SIGNATURE: ..." \ -H "OPENFISH_TIMESTAMP: 1700000000" \ -H "OPENFISH_API_KEY: ..." \ -H "OPENFISH_PASSPHRASE: ..." \ -d '["a1b2c3d4-...","b2c3d4e5-..."]'