# Exotic Order Triggered


:::caution[]
You must be subscribed to the [ACCOUNT](https://docs.onetrading.com/introduction-374354m0.md) channel to receive take profit / stop loss messages.
:::

The `EXOTIC_ORDER_TRIGGERED` message is sent when the price reaches a level of an `ACTIVE` TP/SL, just before its close is placed. From here the TP/SL can no longer be updated or cancelled.

A futures close is planned as one or more reduce-only limit orders, each within the instrument's `max_order_value`, and all of them are listed in `close_orders`. They are sent one at a time, a short delay apart, and each appears on the [TRADING](https://docs.onetrading.com/websocket/trading/introduction.md) channel under its own `client_id`.

A spot close is a single sell order under the TP/SL's `tp_client_id` or `sl_client_id`: its message carries no `position_id`, `limit_price` or `close_orders`.

The message also carries a `message_id` next to `event_timestamp`. It can be delivered more than once with the same `message_id`: deduplicate on it.

```json
{
    "channel_name": "ACCOUNT",
    "type": "EXOTIC_ORDER",
    "time": "2026-11-16T12:30:41.512Z",
    "account_id": "726288e6-a463-4f88-9068-024ae8f97a34",
    "event_type": "EXOTIC_ORDER_TRIGGERED",
    "event_timestamp": "2026-11-16T12:30:41.000Z",
    "message_id": "54a0a5cf-bc22-4419-a2af-9038386916d3",
    "data": {
        "client_id": "0d0b1f0c-7f0e-4f55-9a53-6f6f3c1c2a10",
        "instrument_code": "BTC_USD_P",
        "status": "TRIGGERED",
        "trigger_source": "SL",
        "trigger_price": 65000,
        "actual_trigger_price": 64998.5,
        "close_amount": "1.5",
        "close_side": "SELL",
        "tp_client_id": "c2a7a1de-6d0b-11f0-8de9-0242ac120002",
        "sl_client_id": "1f06d0b6-a7a1-6e20-8de9-0242ac120002",
        "position_id": "1b0f6f5e-2a59-4f0a-9d0e-5f7f3f0f6a11",
        "limit_price": "61750",
        "close_orders": [
            {
                "client_id": "1f0c2f6a-5b7e-6d10-9c1e-0242ac120002",
                "amount": "0.70175"
            },
            {
                "client_id": "1f0c2f6a-5b7e-6d11-9c1e-0242ac120002",
                "amount": "0.70175"
            },
            {
                "client_id": "1f0c2f6a-5b7e-6d12-9c1e-0242ac120002",
                "amount": "0.0965"
            }
        ],
        "version": 2
    }
}
```

The envelope fields (`channel_name`, `type`, `time`, `account_id`, `event_type`, `event_timestamp`) are described in the [ACCOUNT introduction](https://docs.onetrading.com/introduction-374354m0.md).

### `data`

| Field | Type | Description |
|---|---|---|
| `client_id` | string | Identifier of the TP/SL. For one attached to an order, that order's `client_id`. |
| `instrument_code` | string | The instrument. |
| `status` | string | `TRIGGERED`. |
| `trigger_source` | string | The level that was reached: `TP` or `SL`. |
| `trigger_price` | number | The level the TP/SL was set with. |
| `actual_trigger_price` | number | The price that reached it. |
| `close_amount` | string | The amount the close sets out to close. |
| `close_side` | string | Side of the close orders: `BUY` or `SELL`. |
| `tp_client_id` | string or null | `client_id` of the close order placed when the take profit fires on a spot market. |
| `sl_client_id` | string or null | As `tp_client_id`, for the stop loss. |
| `position_id` | string or null | **Futures.** The position being closed. |
| `limit_price` | string | **Futures.** The limit price of every order of the close: the level less the TP/SL's slippage when selling, or plus it when buying. The close never fills at a worse price. |
| `close_orders` | array | **Futures.** Every order the close will send, in order. No other order is sent for this close, and their amounts add up to `close_amount`. |
| `close_orders[].client_id` | string | The `client_id` the order is placed under: its order and trade messages carry it. |
| `close_orders[].amount` | string | The most the order will send. |
| `version` | integer | Version of the message format: `2`. Not the TP/SL's own `version`. |