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

# Completed trades of one wallet: whole history, filters and sorts (hyperdash.com's Completed Trades tab)

> Every round trip (a position opened and fully closed) from hyperdash.com's completed-trades table, the source of the site's Completed Trades and Best Trades tabs and of GET /v1/accounts/{address}/stats: whole history, filtered by market, side, result and minimum notional (|size| × entry price), sorted by any of the site's columns (default: newest close first). `limit` trades per page; page with the cursor, pages start at offsets ≤ 10,000 (as the site), so one query reaches at most 10,000 + limit trades (meta.truncated = more exist: narrow with a filter or reverse the order). Pages are offsets into the live table, as on the site: trades that close while you page shift newest-first pages (a trade can repeat); order=asc walks stably. meta.total: matching trades when a filter is set (null without filters, and null on plans with limited history: the count would include trades outside it). Coverage: wallets Hyperdash has admitted to that table (every wallet trading since ~August 2025 and any wallet viewed on hyperdash.com; an older inactive wallet can have no rows), trades from the fills archive (2025-03). Your plan's history window applies (meta.history_from): older trades are not delivered, newest-first by close time ends at the window, other sorts leave them out of each page, and oldest-first by close time is refused on a limited window. Same round trips as GET /v1/accounts/{address}/trades, which pages a close-time range (≤ 90 days, ascending) from the node trade store instead. net_pnl = gross − signed fees (maker rebates add) + funding; fees = Σ |fee| (as /stats).

Pricing: base + per trade. Scope: `analytics:read`.



## OpenAPI

````yaml /data-api/openapi.json get /v1/accounts/{address}/completed-trades
openapi: 3.1.0
info:
  title: Hyperdash Data API
  version: v1
  description: >-
    Hyperliquid data from Hyperdash's own nodes. Every response reports the
    credits it cost.
servers:
  - url: https://data.hyperdash.com
security: []
tags:
  - name: Accounts
  - name: Async jobs
  - name: Builders
  - name: Cohorts
  - name: HIP-3 DEXs
  - name: Leaderboards
  - name: Lending
  - name: Liquidations
  - name: Markets
  - name: Network
  - name: Outcomes
  - name: Positions
  - name: Snapshots
  - name: Spot
  - name: Staking
  - name: Traders
paths:
  /v1/accounts/{address}/completed-trades:
    get:
      tags:
        - Accounts
      summary: >-
        Completed trades of one wallet: whole history, filters and sorts
        (hyperdash.com's Completed Trades tab)
      description: >-
        Every round trip (a position opened and fully closed) from
        hyperdash.com's completed-trades table, the source of the site's
        Completed Trades and Best Trades tabs and of GET
        /v1/accounts/{address}/stats: whole history, filtered by market, side,
        result and minimum notional (|size| × entry price), sorted by any of the
        site's columns (default: newest close first). `limit` trades per page;
        page with the cursor, pages start at offsets ≤ 10,000 (as the site), so
        one query reaches at most 10,000 + limit trades (meta.truncated = more
        exist: narrow with a filter or reverse the order). Pages are offsets
        into the live table, as on the site: trades that close while you page
        shift newest-first pages (a trade can repeat); order=asc walks stably.
        meta.total: matching trades when a filter is set (null without filters,
        and null on plans with limited history: the count would include trades
        outside it). Coverage: wallets Hyperdash has admitted to that table
        (every wallet trading since ~August 2025 and any wallet viewed on
        hyperdash.com; an older inactive wallet can have no rows), trades from
        the fills archive (2025-03). Your plan's history window applies
        (meta.history_from): older trades are not delivered, newest-first by
        close time ends at the window, other sorts leave them out of each page,
        and oldest-first by close time is refused on a limited window. Same
        round trips as GET /v1/accounts/{address}/trades, which pages a
        close-time range (≤ 90 days, ascending) from the node trade store
        instead. net_pnl = gross − signed fees (maker rebates add) + funding;
        fees = Σ |fee| (as /stats).


        Pricing: base + per trade. Scope: `analytics:read`.
      operationId: getWalletCompletedTrades
      parameters:
        - name: address
          in: path
          required: true
          description: Wallet, 0x + 40 hex.
          schema:
            type: string
            pattern: ^0x[0-9a-fA-F]{40}$
        - name: coin
          in: query
          required: false
          description: One market, e.g. BTC, xyz:TSLA (case-insensitive).
          schema:
            type: string
            pattern: ^[A-Za-z0-9:_\-/@.]{1,40}$
        - name: side
          in: query
          required: false
          description: long or short (omit for both).
          schema:
            type: string
            enum:
              - long
              - short
        - name: result
          in: query
          required: false
          description: win (net PnL > 0) or loss (net PnL < 0); omit for all.
          schema:
            type: string
            enum:
              - win
              - loss
        - name: min_notional
          in: query
          required: false
          description: >-
            Minimum notional (|size| × entry price, USD): 1000, 10000, 100000 or
            1000000.
          schema:
            type: string
            enum:
              - '1000'
              - '10000'
              - '100000'
              - '1000000'
        - name: sort
          in: query
          required: false
          description: 'Sort column (ties: newest close first).'
          schema:
            type: string
            default: close_time
            enum:
              - close_time
              - net_pnl
              - notional
              - duration
              - entry_px
              - exit_px
              - funding_pnl
              - coin
              - side
        - name: order
          in: query
          required: false
          description: Sort order.
          schema:
            type: string
            default: desc
            enum:
              - desc
              - asc
        - name: limit
          in: query
          required: false
          description: Trades per page.
          schema:
            type: integer
            minimum: 1
            maximum: 200
            default: 100
        - name: cursor
          in: query
          required: false
          description: Opaque cursor from next_cursor (same filters, sort and limit).
          schema:
            type: string
        - name: X-Max-Credits
          in: header
          required: false
          description: Refuse (free) if the request could cost more.
          schema:
            type: integer
        - name: X-Credit-Price-Version
          in: header
          required: false
          description: Expected price version; 409 price_changed if it differs.
          schema:
            type: integer
      responses:
        '200':
          description: OK
          headers:
            X-Credits-Charged:
              schema:
                type: integer
            X-Credit-Price-Version:
              schema:
                type: integer
            X-Request-Id:
              schema:
                type: string
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                  - has_more
                  - next_cursor
                  - meta
                properties:
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        coin:
                          type: string
                          description: Market
                        side:
                          type: string
                          description: long or short
                        open_time:
                          type: integer
                          description: Opened, epoch ms
                        close_time:
                          type: integer
                          description: Closed, epoch ms
                        duration_ms:
                          type: integer
                          description: Holding time (ms)
                        entry_px:
                          type: string
                          description: >-
                            Average entry price (decimal string; may carry extra
                            trailing zeros)
                        exit_px:
                          type: string
                          description: >-
                            Average exit price (decimal string; may carry extra
                            trailing zeros)
                        size:
                          type: string
                          description: >-
                            Size closed (base) (decimal string; may carry extra
                            trailing zeros)
                        max_size:
                          type: string
                          description: >-
                            Largest position size during the trade (decimal
                            string; may carry extra trailing zeros)
                        notional:
                          type:
                            - string
                            - 'null'
                          description: >-
                            |size| × entry price (USD): the min_notional /
                            sort=notional measure (decimal string; may carry
                            extra trailing zeros)
                        volume:
                          type: string
                          description: >-
                            Traded notional, entries + exits (USD) (decimal
                            string; may carry extra trailing zeros)
                        gross_pnl:
                          type: string
                          description: >-
                            PnL before fees and funding (decimal string; may
                            carry extra trailing zeros)
                        funding_pnl:
                          type: string
                          description: >-
                            Funding over the trade (decimal string; may carry
                            extra trailing zeros)
                        fees:
                          type: string
                          description: >-
                            Fees: Σ |fee| (rebates counted as fees) (decimal
                            string; may carry extra trailing zeros)
                        net_pnl:
                          type: string
                          description: >-
                            Net PnL: gross − signed fees + funding (decimal
                            string; may carry extra trailing zeros)
                        fills:
                          type: integer
                          description: Fills
                        maker_fills:
                          type: integer
                          description: Maker fills
                        leverage:
                          type:
                            - integer
                            - 'null'
                          description: Leverage (null when not recorded)
                        is_cross:
                          type:
                            - boolean
                            - 'null'
                          description: >-
                            Cross margin (null when the leverage is not
                            recorded)
                  has_more:
                    type: boolean
                  next_cursor:
                    type:
                      - string
                      - 'null'
                  meta:
                    type: object
        '400':
          description: Invalid parameter
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
        '401':
          description: Invalid, expired or revoked key
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
        '403':
          description: Scope, plan, history or credit limit
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
        '409':
          description: Price version changed
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
        '429':
          description: Rate limited (Retry-After)
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
        '503':
          description: Backend at capacity (Retry-After)
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
      security:
        - bearer: []
      x-codeSamples:
        - lang: curl
          source: >-
            curl -H 'Authorization: Bearer $HD_KEY'
            'https://data.hyperdash.com/v1/accounts/0x…/completed-trades?sort=net_pnl&limit=20'
components:
  schemas:
    Problem:
      type: object
      required:
        - type
        - title
        - status
        - code
        - request_id
      properties:
        type:
          type: string
        title:
          type: string
        status:
          type: integer
        code:
          type: string
        detail:
          type: string
        hint:
          type: string
        request_id:
          type: string
  securitySchemes:
    bearer:
      type: http
      scheme: bearer
      description: hdk_sk_live_v1_… or hdk_sk_test_v1_…

````

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