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

# Solana Wallet Trades for One Token and Pool

> Deprecated. Use Get Wallet Pool Trades in Trades V2 for a wallet's trades in one pool. Liquidity events stay on this route.

**Deprecated.** Switch to [`GET /v2/trades/{token}/{pool}/{wallet}`](https://docs.solanatracker.io/data-api/trades-v2/token/get-wallet-pool-trades) instead. With the SDK, use `client.getWalletPoolTradesV2(token, pool, wallet)`. Liquidity events (`events=liquidity` and `events=all`) are only on this route.

`wallet` is the trader: the owner of the swap, or the fee payer when the owner is a program vault. A page can come back short or empty with `hasNextPage: true`: keep following `nextCursor`.

Retrieve token activity within this route’s token, pool and wallet scope. Use `events=all` to combine swaps with liquidity additions/removals, or `events=liquidity` for liquidity only. Omit `events` for the existing trades-only response. Add `enrich=identity` to identify wallets on either event type.

Liquidity rows use `type: add_liquidity | remove_liquidity`, a single `pool`, and exact string amounts in `tokens[]`; they do not contain swap prices, volume or PnL. See the [liquidity guide](https://docs.solanatracker.io/guides/liquidity.md) for REST examples, pagination and live rooms.

## SDK Example

```typescript
import { Client } from '@solana-tracker/data-api';

const client = new Client({ apiKey: 'YOUR_API_KEY' });

const data = await client.getUserPoolTradeHistory('6p6xgHyF7AeE6TZkSmFsko444wqoP15icUSqi2jfGiPN', '9d9mb8kooFfaD3SctgZtkxQypkshx6ezhbKio89ixyy2', 'FbMxP3GVq8TQ36nbYgx4NP9iygMpwAwFWJwW81ioCiSF', {
  events: 'all', // Use 'liquidity' for LP adds/removes only, or 'trades' for swaps.
  enrich: 'identity',
  currency: 'usd', // Adds a per-token price to each swap: 'usd', 'eur' or 'sol'.
  marketCap: true,
  limit: 100,
  sortDirection: 'DESC',
});
```


## OpenAPI

````yaml /data-api/openapi.json get /trades/{tokenAddress}/{poolAddress}/{owner}
openapi: 3.1.0
info:
  title: Solana Tracker Data API
  description: >-
    Solana Tracker Data API for token prices, holders, trades, charts, wallet
    data, risk signals, and market analytics.
  version: 1.0.0
  contact:
    email: contact@solanatracker.io
servers:
  - url: https://data.solanatracker.io
    description: Production server
security:
  - apiKey: []
paths:
  /trades/{tokenAddress}/{poolAddress}/{owner}:
    get:
      tags:
        - Trades
      summary: Get User-Specific Pool Trades
      description: >-
        **Deprecated.** Switch to [`GET
        /v2/trades/{token}/{pool}/{wallet}`](/data-api/trades-v2/token/get-wallet-pool-trades)
        instead. With the SDK, use `client.getWalletPoolTradesV2(token, pool,
        wallet)`. Liquidity events (`events=liquidity` and `events=all`) are
        only on this route.


        Retrieve token activity within this route’s token, pool and wallet
        scope. Use `events=all` to combine swaps with liquidity
        additions/removals, or `events=liquidity` for liquidity only. Omit
        `events` for the existing trades-only response. Add `enrich=identity` to
        identify wallets on either event type.


        Liquidity rows use `type: add_liquidity | remove_liquidity`, a single
        `pool`, and exact string amounts in `tokens[]`; they do not contain swap
        prices, volume or PnL. See the [liquidity guide](/guides/liquidity) for
        REST examples, pagination and live rooms.
      parameters:
        - name: tokenAddress
          in: path
          required: true
          schema:
            type: string
        - name: poolAddress
          in: path
          required: true
          schema:
            type: string
        - name: owner
          in: path
          required: true
          schema:
            type: string
        - name: events
          in: query
          schema:
            type: string
            enum:
              - trades
              - all
              - liquidity
            default: trades
          description: >-
            Choose trades (default), all (swaps plus liquidity), or liquidity
            (add/remove actions only). All modes return a trades array. Invalid
            values return HTTP 400.
        - name: enrich
          in: query
          schema:
            type: string
          example: identity
          description: >-
            Pass identity to attach wallet identity to every returned trade or
            liquidity event, using the same enrichment as token holders.
            Includes available KOL profiles, tags, trading platforms and
            profiles, developer/pool labels, curated labels, and SNS names.
            Unknown wallets return identity: null. Omit for unchanged responses
            and no identity lookups. all and * also enable identity; pool and
            developer are compatibility aliases.
        - name: cursor
          in: query
          schema:
            type: string
          description: >-
            `nextCursor` from the previous page, unchanged. Keep the other
            filters the same between pages.
        - name: limit
          in: query
          schema:
            type: integer
            minimum: 1
            maximum: 500
            default: 250
          description: >-
            Number of results, default 250, maximum 500. With events=all or
            events=liquidity the range is 1–500.
        - name: sortDirection
          in: query
          schema:
            type: string
            enum:
              - ASC
              - DESC
            default: DESC
          description: >-
            Chronological order: DESC (newest first) or ASC (oldest first).
            Invalid values return HTTP 400.
        - name: showMeta
          in: query
          schema:
            type: boolean
          description: >-
            Set to true to add from/to token metadata to swaps. Liquidity rows
            retain their tokens array without swap metadata.
        - name: hideArb
          in: query
          schema:
            type: boolean
          description: >-
            Set to true to keep swap legs involving the requested token.
            Liquidity actions are retained.
        - name: currency
          in: query
          description: >-
            Adds `price` (per token) to every swap, in this currency at the time
            of the trade. `sol`: trades against SOL use the swap's own SOL and
            token amounts; other trades divide the USD price by the SOL/USD rate
            at that second. `eur`: the USD price divided by the EUR/USD rate at
            the time of the trade. `price` is `null` when the trade has no USD
            price or no rate is available. Liquidity rows are unchanged. Invalid
            values return HTTP 400.
          schema:
            type: string
            enum:
              - usd
              - eur
              - sol
        - name: marketCap
          in: query
          description: >-
            Set to true to add `marketCap` to every swap: `price` (in
            `currency`, USD by default) times the supply of the token's main
            pool. Uses the current supply, so a token that burned or minted
            since the trade is valued at today's supply.
          schema:
            type: boolean
            default: false
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TokenTradesResponse'
              examples:
                trades:
                  summary: 'Default: swaps only'
                  value:
                    trades:
                      - tx: >-
                          5V4apVkgHf49J5acYPiuh5rB89EGsF8ocSysgnD9vFfZsTtDamhN3MFDKJSq7Dn7Z6Y5XhjghuVYuvvYWnSFpnvW
                        amount: 90
                        priceUsd: 6
                        volume: 540
                        volumeSol: 3
                        type: sell
                        wallet: F7R61te4Ac8xZ4pfkJUdF6iaaHy9tnM8nVRUPv8H8EMi
                        time: 1789722000000
                        program: pumpfun-amm
                        pools:
                          - 9d9mb8kooFfaD3SctgZtkxQypkshx6ezhbKio89ixyy2
                    nextCursor: null
                    hasNextPage: false
                    sortDirection: DESC
                liquidity:
                  summary: 'events=liquidity: exact token amounts'
                  value:
                    trades:
                      - tx: >-
                          5V4apVkgHf49J5acYPiuh5rB89EGsF8ocSysgnD9vFfZsTtDamhN3MFDKJSq7Dn7Z6Y5XhjghuVYuvvYWnSFpnvW
                        type: add_liquidity
                        program: pumpfun-amm
                        programId: pAMMBay6oceH9fJKBRHGP5D4bD4sWpmSwMn52FMfXEA
                        instruction: deposit
                        pool: 9d9mb8kooFfaD3SctgZtkxQypkshx6ezhbKio89ixyy2
                        wallet: F7R61te4Ac8xZ4pfkJUdF6iaaHy9tnM8nVRUPv8H8EMi
                        time: 1789722000000
                        slot: 370000000
                        amountBasis: transfer
                        tokens:
                          - address: 6p6xgHyF7AeE6TZkSmFsko444wqoP15icUSqi2jfGiPN
                            amount: '123.000001'
                            amountRaw: '123000001'
                            decimals: 6
                          - address: So11111111111111111111111111111111111111112
                            amount: '9.000000001'
                            amountRaw: '9000000001'
                            decimals: 9
                    nextCursor: null
                    hasNextPage: false
                    sortDirection: DESC
        '400':
          description: Invalid token, pool, wallet, events, sort direction or event cursor.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '503':
          description: >-
            Trades are temporarily unavailable. Retry after `Retry-After`
            seconds.
          headers:
            Retry-After:
              description: Seconds to wait before retrying.
              schema:
                type: integer
                example: 1
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Error fetching trade data
      deprecated: true
      x-codeSamples:
        - lang: shell
          label: Liquidity events
          source: >-
            curl --get
            "https://data.solanatracker.io/trades/{tokenAddress}/{poolAddress}/{owner}"
            \
              --header "x-api-key: YOUR_API_KEY" \
              --data-urlencode "events=liquidity" \
              --data-urlencode "enrich=identity" \
              --data-urlencode "limit=50"
        - lang: typescript
          label: SDK
          source: >
            import { Client } from '@solana-tracker/data-api';


            const client = new Client({ apiKey: 'YOUR_API_KEY' });


            const data = await
            client.getUserPoolTradeHistory('6p6xgHyF7AeE6TZkSmFsko444wqoP15icUSqi2jfGiPN',
            '9d9mb8kooFfaD3SctgZtkxQypkshx6ezhbKio89ixyy2',
            'FbMxP3GVq8TQ36nbYgx4NP9iygMpwAwFWJwW81ioCiSF', {
              events: 'all', // Use 'liquidity' for LP adds/removes only, or 'trades' for swaps.
              enrich: 'identity',
              currency: 'usd', // Adds a per-token price to each swap: 'usd', 'eur' or 'sol'.
              marketCap: true,
              limit: 100,
              sortDirection: 'DESC',
            });
      x-code-samples:
        - lang: shell
          label: Liquidity events
          source: >-
            curl --get
            "https://data.solanatracker.io/trades/{tokenAddress}/{poolAddress}/{owner}"
            \
              --header "x-api-key: YOUR_API_KEY" \
              --data-urlencode "events=liquidity" \
              --data-urlencode "enrich=identity" \
              --data-urlencode "limit=50"
        - lang: typescript
          label: SDK
          source: >
            import { Client } from '@solana-tracker/data-api';


            const client = new Client({ apiKey: 'YOUR_API_KEY' });


            const data = await
            client.getUserPoolTradeHistory('6p6xgHyF7AeE6TZkSmFsko444wqoP15icUSqi2jfGiPN',
            '9d9mb8kooFfaD3SctgZtkxQypkshx6ezhbKio89ixyy2',
            'FbMxP3GVq8TQ36nbYgx4NP9iygMpwAwFWJwW81ioCiSF', {
              events: 'all', // Use 'liquidity' for LP adds/removes only, or 'trades' for swaps.
              enrich: 'identity',
              currency: 'usd', // Adds a per-token price to each swap: 'usd', 'eur' or 'sol'.
              marketCap: true,
              limit: 100,
              sortDirection: 'DESC',
            });
components:
  schemas:
    TokenTradesResponse:
      type: object
      properties:
        trades:
          type: array
          items:
            oneOf:
              - $ref: '#/components/schemas/TokenTrade'
              - $ref: '#/components/schemas/LiquidityEvent'
        nextCursor:
          type:
            - integer
            - string
            - 'null'
          description: >-
            A number for trades-only requests, a string for
            events=all/liquidity. Pass back unchanged with the same filters.
            Null at the end.
        hasNextPage:
          type: boolean
        sortDirection:
          type: string
          enum:
            - ASC
            - DESC
        currency:
          type: string
          enum:
            - usd
            - eur
            - sol
          description: >-
            Currency of `price` and `marketCap`. Present when `currency` or
            `marketCap` is set.
    ErrorResponse:
      type: object
      properties:
        error:
          type: string
          description: Error message
      required:
        - error
    TokenTrade:
      type: object
      properties:
        tx:
          type: string
        amount:
          type: number
        priceUsd:
          type: number
        volume:
          type: number
        volumeSol:
          type: number
        type:
          type: string
          enum:
            - buy
            - sell
        wallet:
          type: string
        time:
          type: integer
        program:
          type: string
        pools:
          type: array
          items:
            type: string
        identity:
          description: >-
            Present only with enrich=identity. Current wallet labels, including
            available KOL, platform, developer/pool and SNS identity. Null when
            no identity is known.
          anyOf:
            - $ref: '#/components/schemas/EnrichedIdentity'
            - type: 'null'
        price:
          type:
            - number
            - 'null'
          description: >-
            Price per token in the requested `currency` at the time of the
            trade. Only present when `currency` or `marketCap` is set.
        marketCap:
          type:
            - number
            - 'null'
          description: >-
            Market cap in the requested `currency` at the trade's price, using
            the current supply. Only present when `marketCap=true`.
      required:
        - tx
        - type
        - wallet
        - time
    LiquidityEvent:
      type: object
      required:
        - tx
        - type
        - program
        - programId
        - instruction
        - pool
        - wallet
        - time
        - slot
        - amountBasis
        - tokens
      properties:
        tx:
          type: string
        type:
          type: string
          enum:
            - add_liquidity
            - remove_liquidity
        program:
          type: string
        programId:
          type: string
        instruction:
          type: string
        pool:
          type: string
        wallet:
          type: string
        time:
          type: integer
          description: Unix milliseconds
        slot:
          type: integer
        amountBasis:
          type: string
          enum:
            - transfer
            - principal
          description: >-
            Transfer amounts are gross, before Token-2022 withholding. Principal
            separates CLMM fees and DLMM/Orca rebalancing.
        tokens:
          type: array
          minItems: 1
          items:
            type: object
            required:
              - address
              - amount
              - amountRaw
              - decimals
            properties:
              address:
                type: string
              amount:
                type: string
                description: Exact decimal amount
              amountRaw:
                type: string
                pattern: ^[0-9]+$
              decimals:
                type: integer
                minimum: 0
                maximum: 255
              feeAmountRaw:
                type: string
              transferredAmountRaw:
                type: string
        identity:
          description: >-
            Present only with enrich=identity. Current wallet labels, including
            available KOL, platform, developer/pool and SNS identity. Null when
            no identity is known.
          anyOf:
            - $ref: '#/components/schemas/EnrichedIdentity'
            - type: 'null'
    EnrichedIdentity:
      type: object
      description: >-
        Optional token-context identity enrichment for a holder wallet. Only
        known fields are returned. Common `type` values include `pool`, `bot`,
        `kol`, `developer`, and platform tags.
      properties:
        name:
          type: string
        twitter:
          type: string
        avatar:
          type: string
        type:
          type: string
          description: >-
            Primary label for single-badge UIs, such as `pool`, `bot`, `kol`,
            `developer`, or a platform tag.
        tags:
          type: array
          items:
            type: string
        platforms:
          type: array
          items:
            type: string
        pool:
          type: object
          properties:
            program:
              type: string
            poolAddress:
              type: string
        developer:
          type: object
          properties:
            token:
              type: string
            via:
              type: array
              items:
                type: string
            pools:
              type: array
              items:
                type: string
            creationTx:
              type: string
            createdAt:
              type: integer
        bot:
          type: object
          properties:
            name:
              type:
                - string
                - 'null'
            avatar:
              type:
                - string
                - 'null'
              format: uri
  securitySchemes:
    apiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: API Key for authentication

````

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