# Order

Push order state transitions for `address`.

{% hint style="info" %}
**No authentication required** — any address is publicly observable. This is by design; Lynx is on-chain.
{% endhint %}

## Subscribe

```json
{ "channel": "order", "address": "0xabc…def" }
```

## Push Timing

| Event                   | `e` value                                      |
| ----------------------- | ---------------------------------------------- |
| Order accepted          | `new` / `pending_trigger` / `inactive`         |
| Partial fill            | `partially_filled`                             |
| Full fill               | `filled`                                       |
| Cancellation            | `canceled`                                     |
| Rejection               | `rejected`                                     |
| Modify                  | Updated full Order object                      |
| Conditional triggered   | `triggered`, plus the child order's `new` push |
| Attached TPSL activated | `e`: `inactive` → `pending_trigger`            |

## Payload

See [Order Object](file:///1548985/reference/order-object.md) for full type definitions.

| Field | REST equivalent                               |
| :---: | --------------------------------------------- |
|  `i`  | `order_id`                                    |
|  `k`  | `client_order_id`                             |
|  `a`  | `address`                                     |
|  `b`  | `created_time`                                |
|  `u`  | `updated_time`                                |
|  `s`  | `symbol_id`                                   |
|  `d`  | `is_buy` (bool: `true` = buy, `false` = sell) |
|  `o`  | `order_type`                                  |
|  `g`  | `algo_order_type`                             |
|  `f`  | `time_in_force`                               |
|  `q`  | `quantity`                                    |
|  `p`  | `price`                                       |
|  `z`  | `price_match`                                 |
|  `j`  | `slippage`                                    |
|  `w`  | `position_side`                               |
|  `m`  | `margin_mode`                                 |
|  `y`  | `market_order_type`                           |
|  `n`  | `stp_mode`                                    |
|  `r`  | `flags`                                       |
|  `e`  | `state`                                       |
|  `E`  | `cum_filled_quantity`                         |
|  `D`  | `cum_filled_amount`                           |
|  `R`  | `remaining_quantity`                          |
|  `O`  | `original_quantity`                           |
|  `B`  | `cum_fee`                                     |
|  `S`  | `order_source`                                |
|  `C`  | `conditional`                                 |
|  `t`  | `tpsl`                                        |
|  `l`  | `parent_order_id`                             |
|  `x`  | `tx_hash`                                     |

## Example Push (Partial Fill)

```json
{
  "channel": "order",
  "address": "0xabc…def",
  "ts": 1719500000150,
  "finality": "final",
  "data": {
    "i": "144115188075855872",
    "k": "my-order-1",
    "s": 100001,
    "d": true,
    "e": "partially_filled",
    "E": "0.30",
    "D": "20250.00",
    "R": "0.70",
    "x": "0xt×_hash…",
    "u": 1719500000120
  }
}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.lynxtrade.world/websocket/user-channels/order.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
