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

# Place BBO Order

> Place BBO Order.

Place BBO Order through the DexBuilder PerpDEX REST API.


## OpenAPI

````yaml openapi/perpdex-en.yaml POST /dex_futures/{settle}/bbo_orders
openapi: 3.0.3
info:
  title: DexBuilder PerpDEX API
  version: 1.0.0
  description: DexBuilder PerpDEX REST API。
servers:
  - url: https://api.dexbuilder.com/api/v1
    description: DexBuilder PerpDEX REST API
security:
  - DexBuilderKey: []
    DexBuilderTimestamp: []
    DexBuilderSignature: []
tags:
  - name: 行情
    description: 永續合約公開行情與市場資料
  - name: 風險資料
    description: 風險限額與市場強平資料
  - name: 帳戶
    description: 帳戶與費率
  - name: 持倉
    description: 持倉查詢與管理
  - name: 訂單
    description: 訂單、成交與批量交易
paths:
  /dex_futures/{settle}/bbo_orders:
    post:
      tags:
        - 訂單
      summary: 按檔位建立 BBO 訂單
      description: 按指定盤口檔位建立 BBO 永續合約訂單，支援 level 和 direction 參數。
      operationId: placePerpBBOOrder
      parameters:
        - $ref: '#/components/parameters/Settle'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DEXFuturesBBOOrder'
      responses:
        '200':
          description: 建立成功
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DEXFuturesBBOOrder'
components:
  parameters:
    Settle:
      name: settle
      in: path
      required: true
      description: 結算幣種
      schema:
        type: string
        enum:
          - usdt
      example: usdt
  schemas:
    DEXFuturesBBOOrder:
      type: object
      required:
        - contract
        - size
        - direction
        - level
      properties:
        contract:
          type: string
          description: 永續合約
        size:
          type: integer
          format: int64
          description: 交易數量；正數買入、負數賣出
        direction:
          type: string
          enum:
            - sell
            - buy
          description: sell 取得買盤檔位，buy 取得賣盤檔位
        iceberg:
          type: integer
          format: int64
          description: 冰山單顯示數量
        level:
          type: integer
          format: int64
          minimum: 1
          maximum: 20
          description: 盤口檔位，最大 20
        close:
          type: boolean
          description: 是否平倉
        reduce_only:
          type: boolean
          description: 是否只減倉
        tif:
          type: string
          description: 訂單有效方式
          enum:
            - gtc
            - ioc
            - poc
            - fok
        text:
          type: string
          description: 自定義訂單資訊
        auto_size:
          type: string
          description: 雙向持倉平倉方向
          enum:
            - close_long
            - close_short
        stp_act:
          type: string
          description: 自成交防護策略
          enum:
            - co
            - cn
            - cb
            - '-'
        default_leverage:
          type: string
          description: 預設槓桿
        limit_vip:
          type: integer
          format: int64
          description: 對手方 VIP 等級限制
        pid:
          type: integer
          format: int64
          description: Position ID
      additionalProperties: true
  securitySchemes:
    DexBuilderKey:
      type: apiKey
      in: header
      name: KEY
      description: DexBuilder API Key
    DexBuilderTimestamp:
      type: apiKey
      in: header
      name: Timestamp
      description: Unix 時間戳（秒），與目前時間差不得超過 60 秒
    DexBuilderSignature:
      type: apiKey
      in: header
      name: SIGN
      description: 使用 API Secret 對簽名字串執行 HMAC-SHA512 後的十六進制簽名

````

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