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

# On-Fill

> Submit on-fill actions through signed POST /order.

Register one-shot consequents on the first fill of an embedded `m` or `l` order. Registration does not add a second status row. `pendingOnFill` exposes the unfired registration; consequent orders appear when they execute.

Consequents support `m`, `l`, `mod`, `cx`, `cxa`, `st`, `tp`, `rng`, `trig`, and `trl`. Nested orders control their own isolated routing and builder fees.

Use the current SDK to sign the complete transaction with a fresh nonce. See
[Transaction Signing](https://docs.bulk.trade/api-reference/signing.md) and the shared
[submission guide](https://docs.bulk.trade/api-reference/placeOrder.md#transaction-envelope). The request
example contains placeholder credentials and an illustrative nonce.

Inspect every [response status](https://docs.bulk.trade/api-reference/placeOrder.md#response-format),
including errors returned with HTTP 200. Later order and fill changes arrive
on the [account stream](https://docs.bulk.trade/api-reference/ws-account.md).

```json Signed request body theme={null}
{
  "actions": [
    {
      "of": {
        "trigger": {
          "l": {
            "c": "BTC-USD",
            "b": true,
            "px": 100000,
            "sz": 0.25,
            "tif": "GTC",
            "r": false,
            "i": false
          }
        },
        "actions": [
          {
            "st": {
              "c": "BTC-USD",
              "d": false,
              "sz": 0.25,
              "tr": 98000,
              "lim": null,
              "i": false
            }
          }
        ]
      }
    }
  ],
  "nonce": "1704067200000000016",
  "account": "FuueqefENiGEW6uMqZQgmwjzgpnb85EgUcZa5Em4PQh7",
  "signer": "FuueqefENiGEW6uMqZQgmwjzgpnb85EgUcZa5Em4PQh7",
  "signature": "5j7s...base58..."
}
```

```json Illustrative result theme={null}
{
  "status": "ok",
  "response": {
    "type": "order",
    "data": {
      "statuses": [
        {
          "resting": {
            "oid": "CqX7rUkKTmLJB1zRuEWlBsp4lusg30JlZhFE0Jr9VVm2"
          }
        }
      ]
    }
  }
}
```


## OpenAPI

````yaml api-reference/trading/openapi-on-fill.yaml POST /order
openapi: 3.0.3
info:
  title: Bulk Trading — On-Fill
  version: 1.0.0
servers:
  - url: https://mainnet-api1.bulk.trade/api/v1
    description: Mainnet (Primary)
  - url: https://exchange-api.bulk.trade/api/v1
    description: Testnet
security: []
paths:
  /order:
    post:
      tags:
        - Trading (Signed)
      summary: On-Fill
      description: >-
        Submit a signed transaction to the shared POST /order endpoint. Use the
        SDK and canonical signing guide; illustrative signatures and nonces are
        not executable.
      operationId: submitOnFill
      parameters:
        - in: header
          name: x-bulk-sig-mode
          required: false
          description: >
            Signature-mode hint. Raw tries only raw; omission tries raw then
            base58. Offchain and base58 hints try that mode first, then the
            other supported modes.

            Omit to use the default raw canonical-binary verification path. Set
            to `offchain` when the

            transaction was signed using the [v0 Solana offchain
            envelope](/api-reference/signing#offchain-signing-mode).
          schema:
            type: string
            enum:
              - raw
              - offchain
              - base58
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/FocusedTransaction'
            example:
              actions:
                - of:
                    trigger:
                      l:
                        c: BTC-USD
                        b: true
                        px: 100000
                        sz: 0.25
                        tif: GTC
                        r: false
                        i: false
                    actions:
                      - st:
                          c: BTC-USD
                          d: false
                          sz: 0.25
                          tr: 98000
                          lim: null
                          i: false
              nonce: '1704067200000000016'
              account: FuueqefENiGEW6uMqZQgmwjzgpnb85EgUcZa5Em4PQh7
              signer: FuueqefENiGEW6uMqZQgmwjzgpnb85EgUcZa5Em4PQh7
              signature: 5j7s...base58...
      responses:
        '200':
          description: >-
            Execution results. HTTP 200 alone is not success; inspect status and
            each statuses entry.
          content:
            application/json:
              schema:
                type: object
                required:
                  - status
                  - response
                description: >-
                  Signed transaction result. Status rows describe execution
                  events, not action-array positions.
                properties:
                  status:
                    type: string
                    enum:
                      - ok
                      - error
                    description: >-
                      Top-level status (ok when request was accepted; check each
                      item in statuses for per-action result)
                  response:
                    type: object
                    required:
                      - type
                      - data
                    properties:
                      type:
                        type: string
                        description: Always "order"
                      data:
                        type: object
                        required:
                          - statuses
                        properties:
                          statuses:
                            type: array
                            description: One status object per execution event
                            items:
                              oneOf:
                                - title: resting
                                  type: object
                                  description: >-
                                    Order placed and resting on book
                                    (non-terminal)
                                  properties:
                                    resting:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                - title: working
                                  type: object
                                  description: >-
                                    Order resting with partial fills
                                    (non-terminal)
                                  properties:
                                    working:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                        filledSz:
                                          type: number
                                          description: >-
                                            Filled size so far (signed; negative for
                                            sell-side)
                                        remainingSz:
                                          type: number
                                          description: >-
                                            Remaining size (signed; negative for
                                            sell-side)
                                        vwap:
                                          type: number
                                          description: Volume-weighted average price
                                - title: filled
                                  type: object
                                  description: Order fully filled (terminal)
                                  properties:
                                    filled:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                        totalSz:
                                          type: number
                                          description: >-
                                            Total filled size (signed; negative for
                                            sell-side)
                                        avgPx:
                                          type: number
                                          description: Average fill price (VWAP)
                                - title: partiallyFilled
                                  type: object
                                  description: Order partially filled and terminal
                                  properties:
                                    partiallyFilled:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                        totalSz:
                                          type: number
                                          description: >-
                                            Total filled size (signed; negative for
                                            sell-side)
                                        avgPx:
                                          type: number
                                          description: Average fill price (VWAP)
                                - title: cancelled
                                  type: object
                                  description: Order cancelled by user
                                  properties:
                                    cancelled:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                - title: cancelledRiskLimit
                                  type: object
                                  description: Cancelled due to risk limit violation
                                  properties:
                                    cancelledRiskLimit:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                        reason:
                                          type: string
                                          nullable: true
                                - title: cancelledSelfCrossing
                                  type: object
                                  description: Cancelled due to self-crossing (STP)
                                  properties:
                                    cancelledSelfCrossing:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                - title: cancelledReduceOnly
                                  type: object
                                  description: Cancelled - would not reduce position
                                  properties:
                                    cancelledReduceOnly:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                - title: cancelledIoc
                                  type: object
                                  description: IOC expired without full fill
                                  properties:
                                    cancelledIoc:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                        filledSz:
                                          type: number
                                          description: >-
                                            Size filled before expiry (signed;
                                            negative for sell-side)
                                - title: rejectedCrossing
                                  type: object
                                  description: Post-only rejected for crossing
                                  properties:
                                    rejectedCrossing:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                - title: rejectedDuplicate
                                  type: object
                                  description: Duplicate order ID
                                  properties:
                                    rejectedDuplicate:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                - title: rejectedRiskLimit
                                  type: object
                                  description: Rejected due to risk limit on submission
                                  properties:
                                    rejectedRiskLimit:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                        reason:
                                          type: string
                                          nullable: true
                                - title: rejectedInvalid
                                  type: object
                                  description: Invalid order parameters
                                  properties:
                                    rejectedInvalid:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                        reason:
                                          type: string
                                          nullable: true
                                - title: deposit
                                  type: object
                                  description: Faucet deposit succeeded
                                  properties:
                                    deposit:
                                      type: object
                                      properties:
                                        amount:
                                          type: number
                                - title: depositFailed
                                  type: object
                                  description: Faucet deposit failed
                                  properties:
                                    depositFailed:
                                      type: object
                                      properties:
                                        message:
                                          type: string
                                - title: agentWallet
                                  type: object
                                  description: Agent wallet registered
                                  properties:
                                    agentWallet:
                                      type: object
                                      properties:
                                        agent_wallet:
                                          type: string
                                - title: agentWalletFailed
                                  type: object
                                  description: Agent wallet operation failed
                                  properties:
                                    agentWalletFailed:
                                      type: object
                                      properties:
                                        message:
                                          type: string
                                - title: cancelOneRejected
                                  type: object
                                  description: Single cancel rejected
                                  properties:
                                    cancelOneRejected:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                        reason:
                                          type: string
                                - title: cancelAllRejected
                                  type: object
                                  description: Cancel-all rejected
                                  properties:
                                    cancelAllRejected:
                                      type: object
                                      properties:
                                        reason:
                                          type: string
                                - title: triggered
                                  type: object
                                  description: Conditional root fired (non-terminal)
                                  properties:
                                    triggered:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                - title: siblingCancelled
                                  type: object
                                  description: OCO sibling auto-cancelled
                                  properties:
                                    siblingCancelled:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                - title: triggerFailed
                                  type: object
                                  description: Trigger execution failed
                                  properties:
                                    triggerFailed:
                                      type: object
                                      properties:
                                        oid:
                                          type: string
                                          description: Order ID (base58)
                                        reason:
                                          type: string
                                          nullable: true
                                - title: transfer
                                  type: object
                                  description: Margin transfer succeeded
                                  properties:
                                    transfer:
                                      type: object
                                      properties:
                                        from:
                                          type: string
                                          description: Source account pubkey (base58)
                                        to:
                                          type: string
                                          description: Destination account pubkey (base58)
                                        symbol:
                                          type: string
                                          description: Margin asset symbol
                                        amount:
                                          type: number
                                - title: transferFailed
                                  type: object
                                  description: Margin transfer failed
                                  properties:
                                    transferFailed:
                                      type: object
                                      properties:
                                        message:
                                          type: string
                                - title: createSubAccount
                                  type: object
                                  description: Sub-account creation succeeded
                                  properties:
                                    createSubAccount:
                                      type: object
                                      properties:
                                        master:
                                          type: string
                                          description: Owning master account pubkey (base58)
                                        sub:
                                          type: string
                                          description: >-
                                            Newly created sub-account pubkey
                                            (base58)
                                        name:
                                          type: string
                                          description: Display name
                                        margin:
                                          type: number
                                          description: >-
                                            Initial margin transferred from master
                                            at creation (0 when none requested)
                                - title: createSubAccountFailed
                                  type: object
                                  description: Sub-account creation failed
                                  properties:
                                    createSubAccountFailed:
                                      type: object
                                      properties:
                                        message:
                                          type: string
                                - title: removeSubAccount
                                  type: object
                                  description: >-
                                    Sub-account removal succeeded; remaining
                                    margin is swept back to master
                                  properties:
                                    removeSubAccount:
                                      type: object
                                      properties:
                                        account:
                                          type: string
                                          description: Removed sub-account pubkey (base58)
                                        marginMoved:
                                          type: number
                                          description: >-
                                            Margin amount returned to the master
                                            account
                                - title: removeSubAccountFailed
                                  type: object
                                  description: Sub-account removal failed
                                  properties:
                                    removeSubAccountFailed:
                                      type: object
                                      properties:
                                        message:
                                          type: string
                                - title: renameSubAccount
                                  type: object
                                  description: Sub-account rename succeeded
                                  properties:
                                    renameSubAccount:
                                      type: object
                                      properties:
                                        master:
                                          type: string
                                          description: Owning master account pubkey (base58)
                                        account:
                                          type: string
                                          description: >-
                                            Sub-account pubkey that was renamed
                                            (base58)
                                        name:
                                          type: string
                                          description: New display name
                                - title: renameSubAccountFailed
                                  type: object
                                  description: Sub-account rename failed
                                  properties:
                                    renameSubAccountFailed:
                                      type: object
                                      properties:
                                        message:
                                          type: string
                                - title: error
                                  type: object
                                  description: Generic error
                                  properties:
                                    error:
                                      type: object
                                      properties:
                                        message:
                                          type: string
              examples:
                executionResult:
                  summary: Illustrative execution result
                  value:
                    status: ok
                    response:
                      type: order
                      data:
                        statuses:
                          - resting:
                              oid: CqX7rUkKTmLJB1zRuEWlBsp4lusg30JlZhFE0Jr9VVm2
                authBadSignature:
                  summary: 'Authentication failure: bad signature (HTTP 200)'
                  value:
                    status: error
                    response:
                      type: order
                      data:
                        statuses:
                          - error:
                              message: bad signature
                authUnauthorizedSigner:
                  summary: 'Authentication failure: unauthorized signer (HTTP 200)'
                  value:
                    status: error
                    response:
                      type: order
                      data:
                        statuses:
                          - error:
                              message: unauthorized signer
        '408':
          description: >-
            Response timeout (60 seconds for orders, 5 seconds for current-state
            snapshot requests). An order may still execute; reconcile before
            submitting a replacement.
        '429':
          description: >-
            Request or action rate limit reached. Back off before retrying; the
            body may be plain text or empty.
        '500':
          description: Internal endpoint error - Database or channel error
        '503':
          description: >-
            API disabled or required data/service unavailable. API_LOCKED uses
            the JSON example; other unavailable responses may be empty.
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: string
                  error:
                    type: string
              example:
                code: API_LOCKED
                error: api disabled until an admin enables it
components:
  schemas:
    FocusedTransaction:
      type: object
      required:
        - actions
        - nonce
        - account
        - signer
        - signature
      properties:
        actions:
          type: array
          description: >-
            This focused view shows on-fill actions. Use the batch reference for
            mixed trading actions.
          items:
            $ref: '#/components/schemas/FocusedAction'
        nonce:
          description: >-
            Fresh Unix nanosecond nonce; use a decimal string to preserve 64-bit
            precision
          oneOf:
            - type: string
              pattern: ^[0-9]+$
            - type: integer
              minimum: 0
        account:
          type: string
          description: >
            Account public key (base58) whose account is being acted on. Must be
            a master pubkey or a sub-account pubkey. Per-instrument isolated
            accounts are managed implicitly via the `i` flag on order actions
            and are never set as `account`.
          example: FuueqefENiGEW6uMqZQgmwjzgpnb85EgUcZa5Em4PQh7
        signer:
          type: string
          description: >
            Signer public key (base58); who is signing. One of:

            - the `account` itself;

            - when `account` is a sub-account: the parent master, or an [agent
            wallet](/api-reference/manageAgentWallet) registered on the parent
            master (automatically authorized for its sub-accounts);

            - an agent wallet registered directly on `account`.
          example: FuueqefENiGEW6uMqZQgmwjzgpnb85EgUcZa5Em4PQh7
        signature:
          type: string
          description: >-
            Base58 Ed25519 signature over canonical version-selected action
            bytes, nonce, account, and network domain. See Transaction Signing
            for raw, base58, and offchain modes.
          example: 5j7sVt3k2YxPqH4w...
    FocusedAction:
      title: On-fill (of)
      type: object
      description: >-
        Place an embedded market or limit order and register one-shot
        consequents for its first fill
      required:
        - of
      properties:
        of:
          type: object
          required:
            - trigger
            - actions
          properties:
            trigger:
              oneOf:
                - title: Limit order (l)
                  type: object
                  description: Place a resting limit order
                  required:
                    - l
                  properties:
                    l:
                      type: object
                      required:
                        - c
                        - b
                        - px
                        - sz
                        - tif
                        - r
                      properties:
                        c:
                          type: string
                          description: Symbol
                          example: BTC-USD
                        b:
                          type: boolean
                          description: true = buy, false = sell
                        px:
                          allOf:
                            - description: >-
                                Decimal quantity or price; canonical binary
                                encoding rounds value × 1e8 to an unsigned
                                64-bit integer
                              oneOf:
                                - type: number
                                - type: string
                          description: Limit price
                          example: 100000
                        sz:
                          allOf:
                            - 4400e9a8-6889-40d8-9582-15882e107463
                          description: Size / quantity
                          example: 0.1
                        tif:
                          type: string
                          enum:
                            - GTC
                            - IOC
                            - ALO
                            - ALO_SLIDE
                            - ALO_JOIN
                          description: >-
                            GTC may rest; IOC cancels the unfilled remainder;
                            ALO rejects crossing; ALO_SLIDE reprices crossing
                            orders to a non-crossing tick; ALO_JOIN joins the
                            same-side best quote, falling back to Slide
                        r:
                          type: boolean
                          description: Reduce only
                        i:
                          type: boolean
                          description: >
                            Optional, defaults to `false`. `true` routes the
                            order into the per-instrument isolated account under
                            the signing account; `false` keeps base-account
                            routing.

                            The boolean value is included in the signing bytes,
                            including the default `false` when omitted from
                            JSON.
                        builderCode:
                          type: object
                          description: >
                            Optional builder-code fee payload on market, limit,
                            stop, take-profit, range, or trailing orders,
                            including nested orders.

                            The fee is in basis points and must be pre-approved
                            by the account owner.

                            Omit the field when absent; null is rejected. A
                            builder fee anywhere in the action tree selects V3
                            signing for the whole transaction.
                          required:
                            - to
                            - fee
                          properties:
                            to:
                              type: string
                              description: Builder-code recipient public key (base58)
                            fee:
                              type: integer
                              format: int32
                              minimum: 1
                              maximum: 15
                              description: Builder-code fee in basis points
                - title: Market order (m)
                  type: object
                  description: Execute at market price immediately
                  required:
                    - m
                  properties:
                    m:
                      type: object
                      required:
                        - c
                        - b
                        - sz
                        - r
                      properties:
                        c:
                          type: string
                          description: Symbol
                          example: BTC-USD
                        b:
                          type: boolean
                          description: true = buy, false = sell
                        sz:
                          allOf:
                            - 4400e9a8-6889-40d8-9582-15882e107463
                          description: Size / quantity
                          example: 0.1
                        r:
                          type: boolean
                          description: Reduce only
                        i:
                          type: boolean
                          description: >
                            Optional, defaults to `false`. `true` routes the
                            order into the per-instrument isolated account under
                            the signing account; `false` keeps base-account
                            routing.

                            The boolean value is included in the signing bytes,
                            including the default `false` when omitted from
                            JSON.
                        builderCode: 1490099f-1a24-43c5-9c2f-32965e2a735b
                        slippage:
                          description: >-
                            Optional adverse execution bound from fair price in
                            basis points; uses the market's configured default
                            when omitted or null. Explicit values require
                            versioned signing.
                          allOf:
                            - oneOf:
                                - type: number
                                  nullable: true
                                - type: string
            actions:
              type: array
              description: >
                One-shot consequents executed on the trigger action's first
                fill.

                Allowed today: `m`, `l`, `mod`, `cx`, `cxa`, `st`, `tp`, `rng`,
                `trig`, `trl`.
              items:
                oneOf:
                  - f50db643-6892-4d79-8d32-edde9bccc28e
                  - 08ffb1f1-2829-4e78-824e-bed9a6643c4a
                  - title: Modify order (mod)
                    type: object
                    description: Modify the size of an existing resting order
                    required:
                      - mod
                    properties:
                      mod:
                        type: object
                        required:
                          - oid
                          - c
                          - sz
                        properties:
                          oid:
                            type: string
                            description: Order ID (base58 hash)
                            example: Fpa3oVuL3UzjNANAMZZdmrn6D1Zhk83GmBuJpuAWG51F
                          c:
                            type: string
                            description: Symbol
                            example: BTC-USD
                          sz:
                            allOf:
                              - 84ae3c27-600a-46d8-8d2b-5ee574dfbb78
                            description: New order size
                            example: 0.05
                  - title: Cancel order (cx)
                    type: object
                    description: Cancel a specific order by ID
                    required:
                      - cx
                    properties:
                      cx:
                        type: object
                        required:
                          - c
                          - oid
                        properties:
                          c:
                            type: string
                            description: Symbol
                            example: BTC-USD
                          oid:
                            type: string
                            description: Order ID (base58 hash)
                            example: Fpa3oVuL3UzjNANAMZZdmrn6D1Zhk83GmBuJpuAWG51F
                  - title: Cancel all (cxa)
                    type: object
                    description: Cancel all orders (optionally filtered by symbol)
                    required:
                      - cxa
                    properties:
                      cxa:
                        type: object
                        required:
                          - c
                        properties:
                          c:
                            type: array
                            description: >-
                              Symbols to cancel. Empty array `[]` cancels all
                              symbols.
                            items:
                              type: string
                            example:
                              - BTC-USD
                  - title: Stop (st)
                    type: object
                    description: Place a conditional stop order
                    required:
                      - st
                    properties:
                      st:
                        type: object
                        required:
                          - c
                          - d
                          - sz
                          - tr
                        properties:
                          c:
                            type: string
                            description: Symbol
                            example: BTC-USD
                          d:
                            type: boolean
                            description: >-
                              Trigger direction (`true` = trigger above/equal
                              threshold, `false` = below/equal)
                          sz:
                            allOf:
                              - f71f5f3a-b8dd-45b5-95eb-57c2b46ab366
                            description: Size to execute on trigger
                            example: 0.25
                          tr:
                            allOf:
                              - 5ef872ed-d008-4985-b54f-be718133fbc9
                            description: Trigger threshold
                            example: 98000
                          lim:
                            allOf:
                              - bfaa29b3-4fe8-4170-8406-d0d235184412
                            description: >-
                              Optional triggered limit price. Omit for
                              market-style trigger
                            example: 97950
                          i:
                            type: boolean
                            description: >
                              Optional, defaults to `false`. `true` routes the
                              triggered order into the per-instrument isolated
                              account under the signing account; `false` keeps
                              base-account routing.

                              The boolean value is included in the signing
                              bytes, including the default `false` when omitted
                              from JSON.
                          builderCode: e43b9795-acf3-4b12-951c-bce2b8559ab1
                          slippage:
                            type: number
                            nullable: true
                            description: >-
                              Optional slippage override in basis points for
                              market-style trigger execution
                  - title: Take profit (tp)
                    type: object
                    description: Place a conditional take-profit order
                    required:
                      - tp
                    properties:
                      tp:
                        type: object
                        required:
                          - c
                          - d
                          - sz
                          - tr
                        properties:
                          c:
                            type: string
                            description: Symbol
                            example: BTC-USD
                          d:
                            type: boolean
                            description: >-
                              Trigger direction (`true` = trigger above/equal
                              threshold, `false` = below/equal)
                          sz:
                            allOf:
                              - f71f5f3a-b8dd-45b5-95eb-57c2b46ab366
                            description: Size to execute on trigger
                            example: 0.25
                          tr:
                            allOf:
                              - ed78eb3b-d6b9-4ed2-932c-40e46c391b59
                            description: Trigger threshold
                            example: 104000
                          lim:
                            allOf:
                              - 023ce861-a41a-44ca-922e-8c0824cb1f10
                            description: >-
                              Optional triggered limit price. Omit for
                              market-style trigger
                            example: 103950
                          i:
                            type: boolean
                            description: >
                              Optional, defaults to `false`. `true` routes the
                              triggered order into the per-instrument isolated
                              account under the signing account; `false` keeps
                              base-account routing.

                              The boolean value is included in the signing
                              bytes, including the default `false` when omitted
                              from JSON.
                          builderCode: 370ac566-33de-4db4-bddc-08b953a20229
                          slippage:
                            type: number
                            nullable: true
                            description: >-
                              Optional slippage override in basis points for
                              market-style trigger execution
                  - title: Range / OCO (rng)
                    type: object
                    description: Place a range collar (OCO) conditional order
                    required:
                      - rng
                    properties:
                      rng:
                        type: object
                        required:
                          - c
                          - d
                          - sz
                          - pmin
                          - pmax
                        properties:
                          c:
                            type: string
                            description: Symbol
                            example: BTC-USD
                          d:
                            type: boolean
                            description: >-
                              Position direction (`true` = buy/long collar,
                              `false` = sell/short collar)
                          sz:
                            allOf:
                              - 98bd4329-ccb7-4a1a-995d-48cc8e3ba956
                            description: Size to protect/exit
                            example: 0.5
                          pmin:
                            allOf:
                              - 8a1e8918-4934-4f59-913f-0f685ec6ed90
                            description: Lower trigger threshold
                            example: 96000
                          pmax:
                            allOf:
                              - aba1dc62-4c00-4a77-92c7-612ea9cc1d30
                            description: Upper trigger threshold
                            example: 106000
                          lmin:
                            allOf:
                              - e6143ad7-b9d7-48b1-8904-52bfd77692be
                            description: Optional limit for the lower-trigger leg
                            example: 95950
                          lmax:
                            allOf:
                              - f84f35ea-84f6-469c-92de-5f2e40d20e55
                            description: Optional limit for the upper-trigger leg
                            example: 105950
                          i:
                            type: boolean
                            description: >
                              Optional, defaults to `false`. `true` routes the
                              triggered legs into the per-instrument isolated
                              account under the signing account; `false` keeps
                              base-account routing.

                              The boolean value is included in the signing
                              bytes, including the default `false` when omitted
                              from JSON.
                          builderCode: f993877d-b9fe-4173-9759-66fe3df87491
                          slSlippage:
                            type: number
                            nullable: true
                            description: >-
                              Optional stop-loss leg market-execution slippage
                              in basis points
                          tpSlippage:
                            type: number
                            nullable: true
                            description: >-
                              Optional take-profit leg market-execution slippage
                              in basis points
                  - title: Trigger basket (trig)
                    type: object
                    description: >-
                      Place a trigger basket order that executes nested actions
                      when threshold is crossed
                    required:
                      - trig
                    properties:
                      trig:
                        type: object
                        required:
                          - c
                          - d
                          - tr
                          - actions
                        properties:
                          c:
                            type: string
                            description: Symbol
                            example: BTC-USD
                          d:
                            type: boolean
                            description: >-
                              Trigger direction (`true` = trigger above/equal
                              threshold, `false` = below/equal)
                          tr:
                            allOf:
                              - 953d6db9-c224-451d-9fa4-1674fb15bbee
                            description: Trigger threshold
                            example: 105000
                          actions:
                            type: array
                            description: >
                              Nested actions executed when trigger fires.

                              Allowed today: `m`, `l`, `mod`, `cx`, `cxa`, `st`,
                              `tp`, `rng`, `trl`.
                            items:
                              type: object
                              description: >-
                                Nested action object using the same compact
                                action tags as top-level actions
                  - title: Trailing stop (trl)
                    type: object
                    description: Place a trailing-stop conditional root
                    required:
                      - trl
                    properties:
                      trl:
                        type: object
                        required:
                          - c
                          - b
                          - sz
                          - trb
                          - stb
                        properties:
                          c:
                            type: string
                            description: Symbol
                            example: BTC-USD
                          b:
                            type: boolean
                            description: >-
                              Protected position direction (`true` = long
                              protection, `false` = short protection)
                          sz:
                            allOf:
                              - 6c0cbe35-ca87-4afc-a870-4bf30550e37c
                            description: Size to protect/exit
                            example: 0.25
                          trb:
                            type: integer
                            format: int32
                            description: Trailing distance in bps
                            example: 100
                          stb:
                            type: integer
                            format: int32
                            description: Favorable reset step in bps
                            example: 10
                          lim:
                            allOf:
                              - 6e4ef7af-8235-4511-82f7-29293b0b5c55
                            description: >-
                              Optional triggered limit price. Omit for
                              market-style trigger
                            example: null
                          i:
                            type: boolean
                            description: >
                              Optional, defaults to `false`. `true` routes
                              trailing execution into the per-instrument
                              isolated account under the signing account;
                              `false` keeps base-account routing.

                              The boolean value is included in the signing
                              bytes, including the default `false` when omitted
                              from JSON.
                          builderCode: 936eae24-4aaf-4c81-b9e7-6f3d946fee81
                          slippage:
                            type: number
                            nullable: true
                            description: >-
                              Optional slippage override in basis points for
                              market-style trigger execution

````

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