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

# Get apiv1orders

> Get single order details

Retrieve details of a specific order by order_id or client_order_id.

## Possible Details Field Values

| Details | Explanation |
|---------|-------------|
| PostOnlyViolation | Order would take liquidity but was marked post-only |
| IOCViolation | Immediate-or-cancel order could not be fully executed |
| PositionUpdateViolation | Order violates position update constraints |
| ReduceOnlyViolation | Reduce-only order would increase position size |
| ClearinghouseSettleViolation | Order conflicts with clearinghouse settlement |
| MaxFillLimitViolation | Order exceeds maximum fill limit |
| DuplicateClientOrderIdViolation | Client order ID already exists |
| OrderPreCancelled | Order was cancelled before execution |
| PlaceMakerOrderViolation | Maker order placement rules violated |
| DeadMansSwitchExpired | Dead man's switch timeout triggered |
| DisallowedSelfTrading | Self-trading is not permitted |
| OrderCancelledByUser | User manually cancelled the order |
| OrderCancelledBySystem | System automatically cancelled the order |
| OrderCancelledBySystemDueToError | System cancelled due to an error condition |



## OpenAPI

````yaml /api-reference/openapi.json get /api/v1/orders
openapi: 3.1.0
info:
  title: Decibel Trading API
  description: >-
    RESTful API for Decibel. Provides read-only endpoints for market data,
    trading operations, positions, and analytics.
  contact:
    name: Decibel Team
    url: https://decibel.trade/
  license:
    name: ''
  version: 1.0.0
servers:
  - url: https://api.mainnet.aptoslabs.com/decibel
    description: Mainnet
  - url: https://api.testnet.aptoslabs.com/decibel
    description: Testnet
security:
  - bearerAuth: []
tags:
  - name: Market Data
    description: Market information and real-time data endpoints
  - name: User
    description: User information and account management
  - name: Trades
    description: Trading operations and history
  - name: Positions
    description: User position management
  - name: Orders
    description: Order management and history
  - name: TWAP
    description: Time-weighted average price orders
  - name: Bulk Orders
    description: Bulk order management
  - name: Vaults
    description: Vault operations and management
  - name: Analytics
    description: Analytics and performance metrics
  - name: Predeposit Rewards
    description: Season 0 predeposit USDC rewards
  - name: Referrals
    description: Referral code management and tracking
paths:
  /api/v1/orders:
    get:
      tags:
        - User
      description: >-
        Get single order details


        Retrieve details of a specific order by order_id or client_order_id.


        ## Possible Details Field Values


        | Details | Explanation |

        |---------|-------------|

        | PostOnlyViolation | Order would take liquidity but was marked
        post-only |

        | IOCViolation | Immediate-or-cancel order could not be fully executed |

        | PositionUpdateViolation | Order violates position update constraints |

        | ReduceOnlyViolation | Reduce-only order would increase position size |

        | ClearinghouseSettleViolation | Order conflicts with clearinghouse
        settlement |

        | MaxFillLimitViolation | Order exceeds maximum fill limit |

        | DuplicateClientOrderIdViolation | Client order ID already exists |

        | OrderPreCancelled | Order was cancelled before execution |

        | PlaceMakerOrderViolation | Maker order placement rules violated |

        | DeadMansSwitchExpired | Dead man's switch timeout triggered |

        | DisallowedSelfTrading | Self-trading is not permitted |

        | OrderCancelledByUser | User manually cancelled the order |

        | OrderCancelledBySystem | System automatically cancelled the order |

        | OrderCancelledBySystemDueToError | System cancelled due to an error
        condition |
      operationId: handle_order
      parameters:
        - name: market
          in: query
          description: Market address
          required: true
          schema:
            type: string
          example: 0xmarket123...
        - name: account
          in: query
          description: Account address
          required: true
          schema:
            type: string
          example: 0x123...
        - name: order_id
          in: query
          description: Order ID (provide either this or client_order_id)
          required: false
          schema:
            type: string
          example: '12345'
        - name: client_order_id
          in: query
          description: Client order ID (provide either this or order_id)
          required: false
          schema:
            type: string
          example: client_order_abc
      responses:
        '200':
          description: Order details retrieved successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrderUpdate'
              examples:
                Cancelled:
                  summary: Cancelled order
                  value:
                    status: Cancelled
                    details: IOC Violation
                    order:
                      parent: >-
                        0x0000000000000000000000000000000000000000000000000000000000000000
                      market: >-
                        0xabcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890
                      client_order_id: ''
                      order_id: '45679'
                      status: Cancelled
                      order_type: Market
                      trigger_condition: None
                      order_direction: Close Short
                      orig_size: 2
                      remaining_size: 0
                      size_delta: null
                      price: 49500
                      is_buy: false
                      is_reduce_only: false
                      details: IOC Violation
                      tp_order_id: null
                      tp_trigger_price: null
                      tp_limit_price: null
                      sl_order_id: null
                      sl_trigger_price: null
                      sl_limit_price: null
                      transaction_version: 12345680
                      unix_ms: 1699565000000
                Filled:
                  summary: Filled order
                  value:
                    status: Filled
                    details: ''
                    order:
                      parent: >-
                        0x0000000000000000000000000000000000000000000000000000000000000000
                      market: >-
                        0xabcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890
                      client_order_id: ''
                      order_id: '45679'
                      status: Filled
                      order_type: Market
                      trigger_condition: None
                      order_direction: Close Short
                      orig_size: 2
                      remaining_size: 0
                      size_delta: null
                      price: 49500
                      is_buy: false
                      is_reduce_only: false
                      details: ''
                      tp_order_id: null
                      tp_trigger_price: null
                      tp_limit_price: null
                      sl_order_id: null
                      sl_trigger_price: null
                      sl_limit_price: null
                      transaction_version: 12345680
                      unix_ms: 1699565000000
                NotFound:
                  summary: Order not found
                  value:
                    status: notFound
                    message: 'Order with order_id: 123 not found'
components:
  schemas:
    OrderUpdate:
      type: object
      required:
        - status
        - details
        - order
      properties:
        details:
          type: string
        order:
          $ref: '#/components/schemas/OrderDto'
        status:
          type: string
    OrderDto:
      type: object
      required:
        - parent
        - market
        - client_order_id
        - order_id
        - status
        - order_type
        - trigger_condition
        - order_direction
        - is_buy
        - is_reduce_only
        - details
        - is_tpsl
        - cancellation_reason
        - transaction_version
        - unix_ms
      properties:
        cancellation_reason:
          type: string
        client_order_id:
          type: string
        details:
          type: string
        is_buy:
          type: boolean
        is_reduce_only:
          type: boolean
        is_tpsl:
          type: boolean
        market:
          type: string
        order_direction:
          type: string
        order_id:
          type: string
        order_type:
          type: string
        orig_size:
          type:
            - number
            - 'null'
          format: double
        parent:
          type: string
        price:
          type:
            - number
            - 'null'
          format: double
        remaining_size:
          type:
            - number
            - 'null'
          format: double
        size_delta:
          type:
            - number
            - 'null'
          format: double
        sl_limit_price:
          type:
            - number
            - 'null'
          format: double
        sl_trigger_price:
          type:
            - number
            - 'null'
          format: double
        status:
          type: string
        tp_limit_price:
          type:
            - number
            - 'null'
          format: double
        tp_trigger_price:
          type:
            - number
            - 'null'
          format: double
        transaction_version:
          type: integer
          format: int64
          minimum: 0
        trigger_condition:
          type: string
        unix_ms:
          type: integer
          format: int64
          minimum: 0
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Bearer token from Geomi. See
        [Authentication](/api-reference/rest/authentication) for setup
        instructions.

````