v2

latestOpenAPI 3.0.3Apache 2.02026-07-3149289180.2 KB

Set Auto-Cancel

Set a dead man's switch that cancels all your open orders at the chosen time. The time must be at least 5 seconds in the future. Send 0 to clear an active schedule without triggering it; posting a new time replaces the current one.

The switch fires once, then clears itself. It does not cover orders you place after it fires, so re-arm it if you still need protection.

An account can trigger auto-cancel up to 1000 times per UTC day. After that, the API rejects new schedules with the error auto_cancel_daily_limit_reached until the next UTC day. Clearing a schedule is always allowed. To check the active deadline and today's trigger count, call Get Auto-Cancel Status.

Requires proxy signature, see proxy signing.

patch/v1/trade/auto-cancel

Request body

sigstring required

Signature in hex format

saltinteger required

Salt

tsinteger required

Request timestamp. Unix milliseconds for most operations; Unix seconds for withdrawals (must match the on-chain EIP-712 struct verified against block.timestamp).

Example request

{
  "op": {
    "args": {
      "time": 1767225600000
    }
  },
  "sig": "0x1234567890...",
  "salt": 1234567890,
  "ts": 1767225600000
}

Response

The effective auto-cancel schedule after the update.

status'ok' required
deadlineinteger required

Deadline of the armed auto-cancel schedule, in Unix milliseconds. Zero means no schedule is armed. When the deadline passes, the exchange cancels every open order on the account and the schedule clears.

Example response

{
  "deadline": 1767000045000
}