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

# Get Trade History



## OpenAPI

````yaml GET /api/v2/portfolio/history
openapi: 3.0.3
info:
  description: Multi-chain DEX trading API for developers
  license:
    name: ''
  title: Shuriken API v2
  version: 2.0.0
servers:
  - url: https://api.shuriken.trade
security: []
tags:
  - description: SplitNOW cross-chain split plan + execute
    name: V2 Splits
  - description: Wallet archive lifecycle (archive / unarchive / bulk-archive)
    name: Wallets
  - description: Token discovery, metadata, and pricing
    name: V2 Tokens
  - description: Quote and execute swaps
    name: V2 Swap
  - description: Limit orders and stop-loss
    name: V2 Trigger
  - description: Managed-agent invocation
    name: V2 Agents
  - description: Portfolio positions and PnL
    name: V2 Portfolio
  - description: User account management
    name: V2 Account
  - description: WebSocket stream discovery, session bootstrap, and channel authorization
    name: V2 WebSocket
  - description: Perpetual trading on Hyperliquid
    name: V2 Perps
  - description: Agent-proposed trade suggestions
    name: V2 Suggestions
paths:
  /api/v2/portfolio/history:
    get:
      tags:
        - V2 Portfolio
      summary: GET /api/v2/portfolio/history — Trade history
      operationId: get_portfolio_history
      parameters:
        - description: 'Filter by chain: solana, base, bsc'
          in: query
          name: chain
          required: false
          schema:
            type: string
        - description: Page number
          in: query
          name: page
          required: false
          schema:
            format: int32
            minimum: 0
            type: integer
        - description: Results per page (max 100)
          in: query
          name: limit
          required: false
          schema:
            format: int32
            minimum: 0
            type: integer
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiResponse_PortfolioHistoryResponse'
          description: Trade history
      security:
        - bearer_auth: []
components:
  schemas:
    ApiResponse_PortfolioHistoryResponse:
      description: V2 success response envelope
      properties:
        data:
          properties:
            trades:
              items:
                $ref: '#/components/schemas/PortfolioTrade'
              type: array
            warnings:
              items:
                type: string
              type: array
          required:
            - trades
          type: object
        pagination:
          $ref: '#/components/schemas/PaginationInfo'
          nullable: true
        requestId:
          type: string
      required:
        - data
        - requestId
      type: object
    PortfolioTrade:
      properties:
        chain:
          type: string
        inputAmount:
          nullable: true
          type: string
        inputToken:
          type: string
        isBuy:
          type: boolean
        outputAmount:
          nullable: true
          type: string
        outputToken:
          type: string
        priceUsd:
          type: string
        sizeUsd:
          type: string
        timestamp:
          format: int64
          type: integer
        token:
          type: string
        txHash:
          type: string
        walletAddress:
          type: string
      required:
        - chain
        - txHash
        - timestamp
        - walletAddress
        - inputToken
        - outputToken
        - token
        - sizeUsd
        - priceUsd
        - isBuy
      type: object
    PaginationInfo:
      description: Page-based pagination info (per RFC)
      properties:
        hasMore:
          type: boolean
        limit:
          format: int32
          minimum: 0
          type: integer
        page:
          format: int32
          minimum: 0
          type: integer
        total:
          format: int32
          minimum: 0
          nullable: true
          type: integer
      required:
        - page
        - limit
        - hasMore
      type: object
  securitySchemes:
    bearer_auth:
      bearerFormat: JWT or sk_{keyId}_{secret}
      description: >-
        Use `Authorization: Bearer <jwt>` for user auth or `Authorization:
        Bearer sk_{keyId}_{secret}` for API key auth.
      scheme: bearer
      type: http

````