!!! info "[ApiCancelOrderRequest](/../../schemas/api_cancel_order_request)" Cancel an order on the orderbook for this trading account. Either `order_id` or `client_order_id` must be provided.
|Name
`Lite`|Type|Required
`Default`| Description | |-|-|-|-| |sub_account_id
`sa` |string|True|The subaccount ID cancelling the order| |order_id
`oi` |string|False
`0`|Cancel the order with this `order_id`| |client_order_id
`co` |string|False
`0`|Cancel the order with this `client_order_id`| |time_to_live_ms
`tt` |string|False
`100`|Specifies the time-to-live (in milliseconds) for this cancellation.
During this period, any order creation with a matching `client_order_id` will be cancelled and not be added to the GRVT matching engine.
This mechanism helps mitigate time-of-flight issues where cancellations might arrive before the corresponding orders.
Hence, cancellation by `order_id` ignores this field as the exchange can only assign `order_id`s to already-processed order creations.
The duration cannot be negative, is rounded down to the nearest 100ms (e.g., `'670'` -> `'600'`, `'30'` -> `'0'`) and capped at 5 seconds (i.e., `'5000'`).
Value of `'0'` or omission results in the default time-to-live value being applied.
If the caller requests multiple successive cancellations for a given order, such that the time-to-live windows overlap, only the first request will be considered.
|