> ## Documentation Index
> Fetch the complete documentation index at: https://docs.futuur.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Cancel order

> Cancel an open limit order by its ID.

Cancel an open limit order. Only an order with status `open` can be canceled, including a `gtc` order that is partly filled (it stays `open`). Canceling stops the unfilled remainder; shares already filled stay filled. Canceling needs HMAC only, not a wallet signature.

## Endpoint

```
PATCH https://api.futuur.com/v2.0/orders/{id}/cancel/
```

## Authentication

> [!NOTE]
>
> This endpoint requires HMAC authentication. Include the `Key`, `Timestamp`, and `HMAC` headers on every request. See the [authentication guide](https://docs.futuur.com/authentication.md) for signing instructions.

## Request

**id** `integer` *required*

The ID of the limit order to cancel.

This endpoint does not accept a request body.

## Response

Returns `204 No Content` on success. No response body is returned.

Otherwise:

| Order | Response |
| - | - |
| `processing` (being matched or settling) | `403` with code `LimitOrderBeingProcessing`. Retry shortly. |
| `filled`, `partial_filled`, `partial_filled_cancelled`, or `canceled` | `404` with code `not_found`. |
| Not yours, or does not exist | `404` with code `not_found`. |
| On an event that is no longer open | `404` with code `not_found`. |

> [!WARNING]
>
> A `404` does not tell you whether the order filled or was canceled. Read its final state from [List orders](https://docs.futuur.com/api-reference/orders/list.md) with the matching `status` filter.

## Example

```bash cURL theme={null}
curl --request PATCH \
  --url "https://api.futuur.com/v2.0/orders/10482/cancel/" \
  --header "Key: YOUR_PUBLIC_KEY" \
  --header "Timestamp: 1712534400" \
  --header "HMAC: YOUR_HMAC_SIGNATURE"
```

```
HTTP/1.1 204 No Content
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.