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

# TWAP statistics

> Global TWAP statistics over a time window, broken down by status.



## OpenAPI

````yaml /api-reference/openapi.json get /twaps/stats
openapi: 3.0.3
info:
  title: 'Hypedexer API: Indexed Data'
  version: 1.0.0
  description: >-
    API to query indexed Hyperliquid trading data.


    This API provides access to stored/indexed trading data:

    - **Fills**: Executed orders and fills (Spot-only or All = Spot + Perp)

    - **Analytics**: Aggregations and statistics based on indexed data

    - **Completed Trades**: Trade objects and their related fills

    - **Users**: User overviews, performance and activity

    - **Social Trading**: Per-trader equity curve, PnL calendar, account
    leverage and top trades

    - **Funding**: Funding rate history, user funding payments, predicted rates

    - **Liquidations**: Liquidation events with filters

    - **Overview**: Market dashboard metrics (volume, fees, traders, PnL)

    - **Spot**: Spot token metadata, pairs, and auctions

    - **TWAPs**: TWAP orders, execution stats and fills

    - **Vaults**: Vault details, summaries, equity, ledger


    > Note: No live streaming. Responses are computed from indexed data.
servers:
  - url: https://api.hypedexer.com
    description: Production, routed to the nearest region (EU or JP)
security:
  - ApiKeyAuth: []
tags:
  - name: Fills
    description: Fills endpoints.
  - name: Analytics
    description: Aggregations and stats.
  - name: Completed Trades
    description: Trades and fills.
  - name: Users
    description: User profiles.
  - name: Funding
    description: Funding rates and payments (HL-compatible).
  - name: Liquidations
    description: Liquidation events.
  - name: Overview
    description: Market dashboard metrics.
  - name: Spot
    description: Spot token metadata, pairs and auctions.
  - name: TWAPs
    description: TWAP orders, stats and fills.
  - name: Vaults
    description: Vault details, summaries, equity and ledger.
  - name: Social Trading
    description: >-
      Per-trader equity, PnL calendar, performance, account leverage and top
      trades.
paths:
  /twaps/stats:
    get:
      tags:
        - TWAPs
      summary: TWAP statistics
      description: Global TWAP statistics over a time window, broken down by status.
      parameters:
        - name: hours
          in: query
          required: false
          schema:
            type: integer
            maximum: 720
            minimum: 1
            description: Window in hours
            default: 24
            title: Hours
          description: Window in hours
        - name: coin
          in: query
          required: false
          schema:
            description: Filter by coin
            title: Coin
            type: string
            nullable: true
          description: Filter by coin
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                  message:
                    type: string
                  data:
                    type: object
                  total_count:
                    type: integer
                    nullable: true
                  next_cursor:
                    type: string
                    nullable: true
                  has_more:
                    type: boolean
                    nullable: true
              example:
                success: true
                message: TWAP stats for last 24h
                data:
                  hours: 24
                  totalTwaps: 4790
                  totalExecutedNtl: 489053597.97539616
                  byStatus:
                    - status: finished
                      count: 2556
                      totalSz: 1010399469.1056
                      executedSz: 1010272218.55743
                      executedNtl: 401841572.06814027
                      avgMinutes: 55.61306729264476
                      uniqueUsers: 704
                      uniqueCoins: 248
                    - status: terminated
                      count: 1283
                      totalSz: 465860034.07679987
                      executedSz: 58236980.65341003
                      executedNtl: 66365185.52414022
                      avgMinutes: 598.8324240062354
                      uniqueUsers: 399
                      uniqueCoins: 108
                    - status: 'error: Insufficient margin to place order.'
                      count: 422
                      totalSz: 23515513.93563
                      executedSz: 15761235.064529995
                      executedNtl: 7864243.939133
                      avgMinutes: 189.17061611374407
                      uniqueUsers: 45
                      uniqueCoins: 36
                    - status: activated
                      count: 385
                      totalSz: 66790807.68277
                      executedSz: 0
                      executedNtl: 0
                      avgMinutes: 3454.794805194805
                      uniqueUsers: 204
                      uniqueCoins: 86
                    - status: stopped
                      count: 42
                      totalSz: 1707885.9832100002
                      executedSz: 184663.94514999999
                      executedNtl: 1181121.741233
                      avgMinutes: 466.4761904761905
                      uniqueUsers: 20
                      uniqueCoins: 15
                    - status: 'error: Insufficient spot balance'
                      count: 37
                      totalSz: 908729.3951699999
                      executedSz: 390003.06493999995
                      executedNtl: 484046.30891868006
                      avgMinutes: 514.3243243243244
                      uniqueUsers: 21
                      uniqueCoins: 9
                    - status: 'error: Reduce only order would increase position.'
                      count: 33
                      totalSz: 650094.4760999999
                      executedSz: 40403.54060000001
                      executedNtl: 11317428.393831
                      avgMinutes: 139.84848484848484
                      uniqueUsers: 14
                      uniqueCoins: 12
                    - status: waitingForTrigger
                      count: 32
                      totalSz: 188826.32014
                      executedSz: 0
                      executedNtl: 0
                      avgMinutes: 777.03125
                      uniqueUsers: 19
                      uniqueCoins: 16
                  fills:
                    count: 704918
                    volume: 480650094.4882912
                    totalFees: 119737.81298800003
                    uniqueUsers: 850
                    uniqueTwaps: 4335
                total_count: null
                execution_time_ms: 1765
                next_cursor: null
                has_more: null
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
      description: >-
        Your Hypedexer API key. Create one in the console at
        https://app.hypedexer.com. `Authorization: Bearer <key>` and the
        `api_key` query parameter are accepted as well.

````