> ## Documentation Index
> Fetch the complete documentation index at: https://sure-917046f5-mintlify-docs-update-1787384258771.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# List balance history records



## OpenAPI

````yaml /openapi.yaml get /api/v1/balances
openapi: 3.0.3
info:
  title: Sure API
  version: v1
  description: OpenAPI documentation generated from executable request specs.
servers:
  - url: https://app.sure.am
    description: Production
  - url: http://localhost:3000
    description: Local development
security: []
paths:
  /api/v1/balances:
    get:
      tags:
        - Balances
      summary: List balance history records
      parameters:
        - name: page
          in: query
          required: false
          description: 'Page number (default: 1)'
          schema:
            type: integer
        - name: per_page
          in: query
          required: false
          description: 'Items per page (default: 25, max: 100)'
          schema:
            type: integer
        - name: account_id
          in: query
          required: false
          description: Filter by account ID
          schema:
            type: string
            format: uuid
        - name: currency
          in: query
          required: false
          description: Filter by currency code
          schema:
            type: string
        - name: start_date
          in: query
          required: false
          description: Filter balances from this date
          schema:
            type: string
            format: date
        - name: end_date
          in: query
          required: false
          description: Filter balances until this date
          schema:
            type: string
            format: date
      responses:
        '200':
          description: balances listed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BalanceCollection'
        '401':
          description: unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: insufficient scope
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: invalid filter
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - apiKeyAuth: []
components:
  schemas:
    BalanceCollection:
      type: object
      required:
        - balances
        - pagination
      properties:
        balances:
          type: array
          items:
            $ref: '#/components/schemas/Balance'
        pagination:
          $ref: '#/components/schemas/Pagination'
    ErrorResponse:
      type: object
      required:
        - error
      properties:
        error:
          type: string
        message:
          type: string
          nullable: true
        details:
          oneOf:
            - type: array
              items:
                type: string
            - type: object
          nullable: true
        errors:
          type: array
          items:
            type: string
          nullable: true
          description: >-
            Validation error messages (alternative to details used by trades,
            valuations, etc.)
    Balance:
      type: object
      required:
        - id
        - date
        - currency
        - flows_factor
        - balance
        - balance_cents
        - start_balance
        - start_balance_cents
        - end_balance
        - end_balance_cents
        - account
        - created_at
        - updated_at
      properties:
        id:
          type: string
          format: uuid
        date:
          type: string
          format: date
        currency:
          type: string
        flows_factor:
          type: number
          format: float
        balance:
          type: string
        balance_cents:
          type: integer
          description: Balance in currency minor units
        cash_balance:
          type: string
          nullable: true
        cash_balance_cents:
          type: integer
          nullable: true
          description: Cash balance in currency minor units
        start_cash_balance:
          type: string
        start_cash_balance_cents:
          type: integer
          description: Starting cash balance in currency minor units
        start_non_cash_balance:
          type: string
        start_non_cash_balance_cents:
          type: integer
          description: Starting non-cash balance in currency minor units
        start_balance:
          type: string
        start_balance_cents:
          type: integer
          description: Starting total balance in currency minor units
        cash_inflows:
          type: string
        cash_inflows_cents:
          type: integer
          description: Cash inflows in currency minor units
        cash_outflows:
          type: string
        cash_outflows_cents:
          type: integer
          description: Cash outflows in currency minor units
        non_cash_inflows:
          type: string
        non_cash_inflows_cents:
          type: integer
          description: Non-cash inflows in currency minor units
        non_cash_outflows:
          type: string
        non_cash_outflows_cents:
          type: integer
          description: Non-cash outflows in currency minor units
        net_market_flows:
          type: string
        net_market_flows_cents:
          type: integer
          description: Net market flows in currency minor units
        cash_adjustments:
          type: string
        cash_adjustments_cents:
          type: integer
          description: Cash adjustments in currency minor units
        non_cash_adjustments:
          type: string
        non_cash_adjustments_cents:
          type: integer
          description: Non-cash adjustments in currency minor units
        end_cash_balance:
          type: string
        end_cash_balance_cents:
          type: integer
          description: Ending cash balance in currency minor units
        end_non_cash_balance:
          type: string
        end_non_cash_balance_cents:
          type: integer
          description: Ending non-cash balance in currency minor units
        end_balance:
          type: string
        end_balance_cents:
          type: integer
          description: Ending total balance in currency minor units
        account:
          $ref: '#/components/schemas/BalanceAccount'
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
    Pagination:
      type: object
      required:
        - page
        - per_page
        - total_count
        - total_pages
      properties:
        page:
          type: integer
          minimum: 1
        per_page:
          type: integer
          minimum: 1
        total_count:
          type: integer
          minimum: 0
        total_pages:
          type: integer
          minimum: 0
    BalanceAccount:
      type: object
      required:
        - id
        - name
        - account_type
      properties:
        id:
          type: string
          format: uuid
        name:
          type: string
        account_type:
          type: string
          nullable: true
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      name: X-Api-Key
      in: header
      description: API key for authentication. Generate one from your account settings.

````