> For the complete documentation index, see [llms.txt](https://docs.unix.market/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.unix.market/reference/enums.md).

# Enums

A consolidated reference of enumerated values used throughout the API. Each value is exactly what you send or receive in JSON.

## Order

| Field                                                             | Values                                                                                                                                   |
| ----------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------- |
| `order_type`                                                      | `limit`, `market`                                                                                                                        |
| `time_in_force`                                                   | `gtc`, `ioc`, `fok`                                                                                                                      |
| `algo_order_type`                                                 | `conditional`, `tpsl`, `attached_tpsl`                                                                                                   |
| `position_side`                                                   | `both`, `long`, `short`                                                                                                                  |
| `margin_mode`                                                     | `cross`, `isolated`                                                                                                                      |
| `market_order_type`                                               | `base`, `quote`                                                                                                                          |
| `price_match`                                                     | `queue_1`, `queue_5`, `counter_party_1`, `counter_party_5`                                                                               |
| `flags[]`                                                         | `post_only`, `reduce_only`                                                                                                               |
| `stp_mode`                                                        | `cancel_maker`, `cancel_taker`, `cancel_both`, `none`                                                                                    |
| `state`                                                           | `pending_new`, `new`, `partially_filled`, `filled`, `pending_cancel`, `canceled`, `rejected`, `inactive`, `pending_trigger`, `triggered` |
| `tpsl.tpsl_mode`                                                  | `full`, `partial`                                                                                                                        |
| `tpsl.tp_trigger_by` / `sl_trigger_by` / `conditional.trigger_by` | `last_price`, `mark_price`, `oracle_price`                                                                                               |
| `tpsl.tp_order_type` / `sl_order_type`                            | `market`, `limit`                                                                                                                        |

## Execution

| Field                         | Values                            |
| ----------------------------- | --------------------------------- |
| `is_buy`                      | `true`, `false`                   |
| `position_action` (perp only) | `open`, `close`, `reduce`, `flip` |

## Position

| Field           | Values                  |
| --------------- | ----------------------- |
| `position_side` | `both`, `long`, `short` |
| `margin_mode`   | `cross`, `isolated`     |
| `adl_level`     | `1`, `2`, `3`, `4`, `5` |

## Account

| Field           | Values              |
| --------------- | ------------------- |
| `position_mode` | `one_way`, `hedge`  |
| `auto_borrow`   | `true`, `false`     |
| Child `type`    | `sub`, `associated` |

## Symbols

| Field          | Values                                                                    |
| -------------- | ------------------------------------------------------------------------- |
| `status`       | `pre_launch`, `trading`, `suspended`, `delisted`                          |
| `trading_mode` | `normal`, `limit_only`, `post_only`, `reduce_only`, `cancel_only`, `null` |

## Klines

| Field      | Values                                                                          |
| ---------- | ------------------------------------------------------------------------------- |
| `interval` | `1m`, `5m`, `15m`, `30m`, `1h`, `2h`, `4h`, `6h`, `8h`, `12h`, `1d`, `1w`, `1M` |

## Order Book

| Field   | Values                                                                           |
| ------- | -------------------------------------------------------------------------------- |
| `depth` | `5`, `10`, `20`, `50`, `100`, `200`                                              |
| `merge` | Integer multiple of `tick_size`. See the symbol's `price_step_merge_multiplier`. |

## Withdrawal

| Field    | Values                         |
| -------- | ------------------------------ |
| `status` | `pending`, `success`, `failed` |

## Asset Flow

| Field                    | Numeric ID | Meaning                                    |
| ------------------------ | ---------- | ------------------------------------------ |
| `deposit`                | 1          | Deposit                                    |
| `withdraw`               | 2          | Withdrawal                                 |
| `pnl`                    | 3          | P\&L settlement                            |
| `spot_buy`               | 4          | Spot buy                                   |
| `spot_sell`              | 5          | Spot sell                                  |
| `fee`                    | 6          | Trading fee                                |
| `funding_fee`            | 7          | Funding payment                            |
| `liquidation`            | 8          | Liquidation                                |
| `transfer`               | 9          | Transfer                                   |
| `interest`               | 10         | Borrow interest                            |
| `isolated_open`          | 11         | Isolated open (balance → isolated margin)  |
| `isolated_close`         | 12         | Isolated close (isolated margin → balance) |
| `isolated_margin_change` | 13         | Isolated margin adjustment                 |
| `system_adjust`          | 99         | System adjustment                          |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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.unix.market/reference/enums.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.
