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

# Get fills

> Returns historical fills for the authenticated user. Requires an explicit time range: both `start_timestamp_ns` and `end_timestamp_ns` must be provided and span no more than 7 days. Missing, inverted, or wider ranges are rejected with a 400.



## OpenAPI

````yaml openapi/api-gateway.json GET /fills
openapi: 3.1.0
info:
  title: ax-api-gateway
  description: ''
  license:
    name: ''
  version: 15.24.0
servers:
  - url: https://gateway.architect.exchange/api
security: []
tags:
  - name: api-gateway
    description: API gateway
paths:
  /fills:
    get:
      tags:
        - api-gateway
      description: >-
        Returns historical fills for the authenticated user. Requires an
        explicit time range: both `start_timestamp_ns` and `end_timestamp_ns`
        must be provided and span no more than 7 days. Missing, inverted, or
        wider ranges are rejected with a 400.
      operationId: get_fills
      parameters:
        - name: account_id
          in: query
          description: >-
            Optional account ID. If omitted, default (primary) user account is
            used.
          required: false
          schema:
            type:
              - string
              - 'null'
        - name: symbol
          in: query
          description: >-
            Optional symbol filter. If provided, only fills for this symbol will
            be returned.
          required: false
          schema:
            type:
              - string
              - 'null'
        - name: end_timestamp_ns
          in: query
          required: false
          schema:
            type:
              - integer
              - 'null'
            format: int64
            minimum: 0
        - name: start_timestamp_ns
          in: query
          required: false
          schema:
            type:
              - integer
              - 'null'
            format: int64
            minimum: 0
        - name: cursor
          in: query
          required: false
          schema:
            type:
              - string
              - 'null'
        - name: limit
          in: query
          required: false
          schema:
            type:
              - integer
              - 'null'
            format: int32
            minimum: 0
        - name: sort_ts
          in: query
          required: false
          schema:
            oneOf:
              - type: 'null'
              - $ref: '#/components/schemas/SortDirection'
                description: Timestamp sort direction (defaults to `desc`).
      responses:
        '200':
          description: List of fills
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetFillsResponse'
        '400':
          description: Time range missing or wider than the 7-day maximum
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - session_token: []
components:
  schemas:
    SortDirection:
      type: string
      description: >-
        Sort order/direction.


        - `asc`: ascending order per field type (e.g. lexicographic, numeric,
        etc.)

        - `desc`: descending order per field type
      enum:
        - asc
        - desc
    GetFillsResponse:
      allOf:
        - $ref: '#/components/schemas/CursorPage'
        - type: object
          required:
            - fills
          properties:
            fills:
              type: array
              items:
                $ref: '#/components/schemas/Fill'
    ErrorResponse:
      type: object
      description: Standard error response format
      required:
        - error
      properties:
        error:
          type: string
    CursorPage:
      type: object
      description: |-
        Page metadata for cursor-paged responses.

        This is intended for response bodies (not query params).
      properties:
        limit:
          type:
            - integer
            - 'null'
          format: int32
          minimum: 0
        next_cursor:
          type:
            - string
            - 'null'
        total_count:
          type:
            - integer
            - 'null'
          format: int64
          minimum: 0
    Fill:
      type: object
      required:
        - trade_id
        - account_id
        - timestamp
        - symbol
        - price
        - quantity
        - is_taker
        - fee
        - side
      properties:
        account_id:
          type: string
        fee:
          type: string
        is_block_trade:
          type: boolean
          description: |-
            True if this fill was generated by a block trade — a privately
            negotiated trade booked away from the order book.
        is_final_settlement:
          type: boolean
          description: >-
            True if this fill was generated by final settlement of a delisted or

            expired contract at the final settlement price; the counterparty is
            the

            exchange settlement account. Implies `is_block_trade`.
        is_taker:
          type: boolean
        order_id:
          type:
            - string
            - 'null'
        price:
          type: string
        quantity:
          type: integer
          format: int64
          minimum: 0
        realized_pnl:
          type:
            - string
            - 'null'
        side:
          $ref: '#/components/schemas/Side'
        symbol:
          type: string
        timestamp:
          type: string
          format: date-time
        trade_id:
          type: string
    Side:
      type: string
      enum:
        - B
        - S
  securitySchemes:
    session_token:
      type: http
      scheme: bearer
      description: User session token

````