# Cancel Order Channel

### Description

1.Rate limit will be shared with Rest API <br/>
2.Please connect to V2 Websocket domain: wss://ws.bitget.com/v2/ws/private <br/>
3.So far websocket trading doesn't support canceling batch orders<br/>

<div className="api-aligning">

```json title="Request Example"
{
   "op":"trade",
   "args":[
      {
         "id":"xxxxx-xxx-xxx-xxxx-xxxxxx",
         "instType":"SPOT",
         "instId":"BTCUSDT",
         "channel":"cancel-order",
         "params":{
            "orderId":"xxxxxxxxx",
            "clientOid":"xxxxx-xxx-xxx-xxxx-xxxxxx"
         }
      }
   ]
}
```

### Request Parameters

| Parameter          | Type               | Required | Description                                                                                              | 
|:-------------------|:-------------------|:---------|:---------------------------------------------------------------------------------------------------------|
| op                 | String             | Yes      | "trade"                                                                                                  |
| args               | List&lt;Object&gt; | Yes      | List of channels to request subscription                                                                 |
| &gt; id            | String             | Yes      | Unique Identifier<br/>Length&lt;= 40<br/>("^[0-9A-Za-z_:#\\-+\\s]*$");                                      |
| &gt; instType      | String             | Yes      | Product line type `SPOT`                                                                                 |
| &gt; instId        | String             | Yes      | Product ID, e.g. `ETHUSDT`                                                                               |
| &gt; channel       | String             | Yes      | Channel name, `cancel-order`                                                                             |
| &gt; params        | Object             | Yes      |                                                                                                          |
| &gt;&gt; orderId   | String             | No       | Order ID <br/> Either `orderId` or `clientOid` is required.If both are present, orderId prevails.        |
| &gt;&gt; clientOid | String             | No       | Custom order ID <br/> Either `orderId` or `clientOid` is required.If both are present, orderId prevails. |

</div>

<div className="api-br-10"></div>

<div className="api-aligning">

```json title="Response Example"
{
  "event":"trade",
  "arg":[
    {
      "id":"xxxxx-xxx-xxx-xxxx-xxxxxx",
      "instType":"SPOT",
      "channel":"cancel-order",
      "instId":"BTCUSDT",
      "params":{
        "orderId":"xxxxxxxxxxx",
        "clientOid":"xxxxx-xxx-xxx-xxxx-xxxxxx"
      }
    }
  ],
  "code":0,
  "msg":"Success"
}
```

### Response Parameters

| Parameter          | Type         | Description                                                                                              | 
|:-------------------|:-------------|:---------------------------------------------------------------------------------------------------------|
| event              | String       | Event<br/>`trade` <br/>`error`                                                                           |
| arg                | Object       | Channel                                                                                                  |
| &gt; id            | String       | Unique Identifier<br/>Length&lt;= 40<br/>("^[0-9A-Za-z_:#\\-+\\s]*$");                                      |
| &gt; instType      | String       | Product line type `SPOT`                                                                                 |
| &gt; instId        | String       | Product ID, e.g. `ETHUSDT`                                                                               |
| &gt; channel       | String       | Channel name, `cancel-order`                                                                             |
| &gt; params        | Object       |                                                                                                          |
| &gt;&gt; orderId   | String       | Order ID <br/> Either `orderId` or `clientOid` is required.If both are present, orderId prevails.        |
| &gt;&gt; clientOid | String       | Custom order ID <br/> Either `orderId` or `clientOid` is required.If both are present, orderId prevails. |
| code               | String       | code                                                                                                     |
| msg                | String       | msg                                                                                                      |

</div>
