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

# Uniswap wallet positions

> Returns Uniswap position NFTs for a wallet.

```bash theme={null}
curl "https://staging-api.struct.to/v1/uniswap/wallets/{wallet_address}/positions?chain=base&chain_id=8453&protocol=v4&status=open&fields=short" \
  -H "X-API-Key: YOUR_API_KEY"
```

```json Response (Long) theme={null}
{
  "count": 1,
  "positions": [
    {
      "token_id": "42",
      "pool_id": "0x1111111111111111111111111111111111111111111111111111111111111111",
      "currency0": "0x0000000000000000000000000000000000000000",
      "currency1": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
      "currency0_decimals": 18,
      "currency1_decimals": 6,
      "currency0_price_usd": "2474.05",
      "currency1_price_usd": "1.00",
      "fee": 3000,
      "tick_spacing": 60,
      "hooks": "0x0000000000000000000000000000000000000000",
      "tick_lower": -180,
      "tick_upper": 60,
      "liquidity_raw": "250000000",
      "token_amounts": {
        "amount0_raw": "1500000000000000000",
        "amount1_raw": "3700000000",
        "amount0": "1.5",
        "amount1": "3700",
        "amount0_usd": "3711.08",
        "amount1_usd": "3700",
        "amounts_usd": "7411.08"
      },
      "in_range": true,
      "current_tick": -120,
      "sqrt_price_x96": "12345678901234567890",
      "active_liquidity_raw": "1000000000",
      "claimable_fees": {
        "currency0": "0x0000000000000000000000000000000000000000",
        "currency1": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
        "currency0_decimals": 18,
        "currency1_decimals": 6,
        "currency0_price_usd": "2474.05",
        "currency1_price_usd": "1.00",
        "amount0_raw": "1200000000000000",
        "amount1_raw": "2800000",
        "amount0": "0.0012",
        "amount1": "2.8",
        "amount0_usd": "2.97",
        "amount1_usd": "2.8",
        "amounts_usd": "5.77"
      },
      "minted_block": 22095000,
      "minted_timestamp": 1709995000000,
      "updated_block": 22100000,
      "updated_timestamp": 1710000000000
    }
  ]
}
```

```jsonc Response (Short) theme={null}
{
  "c": 1,
  "ps": [
    {
      "id": "42",
      "p": "0x1111111111111111111111111111111111111111111111111111111111111111",
      "c0": "0x0000000000000000000000000000000000000000",
      "c1": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
      "cd0": 18,
      "cd1": 6,
      "p0": "2474.05",
      "p1": "1.00",
      "f": 3000,
      "ts": 60,
      "h": "0x0000000000000000000000000000000000000000",
      "tl": -180,
      "tu": 60,
      "lq": "250000000",
      "ta": {
        "a0r": "1500000000000000000",
        "a1r": "3700000000",
        "a0": "1.5",
        "a1": "3700",
        "a0u": "3711.08",
        "a1u": "3700",
        "au": "7411.08"
      },
      "ir": true,
      "ctk": -120,
      "sp": "12345678901234567890",
      "al": "1000000000",
      "cf": {
        "c0": "0x0000000000000000000000000000000000000000",
        "c1": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
        "cd0": 18,
        "cd1": 6,
        "p0": "2474.05",
        "p1": "1.00",
        "a0r": "1200000000000000",
        "a1r": "2800000",
        "a0": "0.0012",
        "a1": "2.8",
        "a0u": "2.97",
        "a1u": "2.8",
        "au": "5.77"
      },
      "mb": 22095000,
      "mt": 1709995000000,
      "ub": 22100000,
      "ut": 1710000000000
    }
  ]
}
```


## OpenAPI

````yaml onchain-openapi.json GET /uniswap/wallets/{wallet_address}/positions
openapi: 3.1.0
info:
  title: Struct On-chain API
  description: >-
    RESTful API for token market data, discovery, holders, audits, and trader
    analytics across supported chains. Pass `fields=short` or header
    `x-field-names: short` for abbreviated keys. HTTP defaults to `long`. Token
    candlesticks, token trades and wallet batch trades also support
    `fields=array` for typed positional rows.
  version: 1.0.0
servers:
  - url: https://staging-api.struct.to/v1
    description: Staging
security:
  - ApiKey: []
paths:
  /uniswap/wallets/{wallet_address}/positions:
    get:
      tags:
        - Uniswap
      summary: Uniswap wallet positions
      description: Returns Uniswap position NFTs for a wallet.
      operationId: get_uniswap_wallet_positions
      parameters:
        - name: chain
          in: query
          description: Chain name. Required unless `chain_id` is provided.
          required: false
          schema:
            type: string
          example: base
        - name: chain_id
          in: query
          description: Chain id. Required unless `chain` is provided. Use `-1` for Solana.
          required: false
          schema:
            type: integer
            format: int64
          example: 8453
        - name: wallet_address
          in: path
          description: EVM wallet address.
          required: true
          schema:
            type: string
        - name: protocol
          in: query
          description: 'Uniswap version: v3 or v4. Omit to query both versions.'
          required: false
          schema:
            $ref: '#/components/schemas/UniswapProtocol'
          example: v4
        - name: limit
          in: query
          description: Maximum positions to return. Defaults to 100, maximum 1000.
          required: false
          schema:
            type: integer
            minimum: 0
        - name: pagination_key
          in: query
          description: Opaque cursor from a previous response.
          required: false
          schema:
            type: string
        - name: pool_id
          in: query
          description: 'Pool identifier: a Uniswap V3 pool address or a 32-byte V4 pool id.'
          required: false
          schema:
            type: string
        - name: status
          in: query
          description: Position status. `open` or `closed`. Defaults to `open`.
          required: false
          schema:
            $ref: '#/components/schemas/UniswapPositionStatus'
          example: open
        - name: include_fees
          in: query
          description: Whether to include claimable fee amounts. Defaults to true.
          required: false
          schema:
            type: boolean
        - name: sort_by
          in: query
          description: Sort field. Defaults to token_id.
          required: false
          schema:
            $ref: '#/components/schemas/V4PositionSortBy'
        - name: sort_order
          in: query
          description: Sort order. Defaults to asc.
          required: false
          schema:
            $ref: '#/components/schemas/V4PositionSortOrder'
        - name: min_tick_lower
          in: query
          description: Minimum lower tick.
          required: false
          schema:
            type: integer
            format: int32
        - name: max_tick_upper
          in: query
          description: Maximum upper tick.
          required: false
          schema:
            type: integer
            format: int32
        - name: active_at_tick
          in: query
          description: Return positions whose range contains this tick.
          required: false
          schema:
            type: integer
            format: int32
        - name: min_liquidity
          in: query
          description: Minimum raw liquidity.
          required: false
          schema:
            type: string
        - name: has_claimable_fees
          in: query
          description: Filter by whether a position has claimable fees.
          required: false
          schema:
            type: boolean
        - name: x-field-names
          in: header
          required: false
          description: >-
            Select long (full) or short (abbreviated) field names. HTTP defaults
            to `long`. Takes precedence over `fields`. See [Response
            Format](/api-reference/response-format#long-and-short-field-names).
          schema:
            type: string
            enum:
              - long
              - short
            default: long
          example: short
        - name: fields
          in: query
          required: false
          description: >-
            Same as `x-field-names`. Use `long` or `short`. HTTP defaults to
            `long`. Ignored when the header is set. `field_names` is accepted as
            an alias.
          schema:
            type: string
            enum:
              - long
              - short
            default: long
          example: short
      responses:
        '200':
          description: Uniswap positions for a wallet
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V4WalletPositionsResponse'
              examples:
                long:
                  summary: Response (Long)
                  value:
                    count: 1
                    positions:
                      - token_id: '42'
                        pool_id: >-
                          0x1111111111111111111111111111111111111111111111111111111111111111
                        currency0: '0x0000000000000000000000000000000000000000'
                        currency1: '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913'
                        currency0_decimals: 18
                        currency1_decimals: 6
                        currency0_price_usd: '2474.05'
                        currency1_price_usd: '1.00'
                        fee: 3000
                        tick_spacing: 60
                        hooks: '0x0000000000000000000000000000000000000000'
                        tick_lower: -180
                        tick_upper: 60
                        liquidity_raw: '250000000'
                        token_amounts:
                          amount0_raw: '1500000000000000000'
                          amount1_raw: '3700000000'
                          amount0: '1.5'
                          amount1: '3700'
                          amount0_usd: '3711.08'
                          amount1_usd: '3700'
                          amounts_usd: '7411.08'
                        in_range: true
                        current_tick: -120
                        sqrt_price_x96: '12345678901234567890'
                        active_liquidity_raw: '1000000000'
                        claimable_fees:
                          currency0: '0x0000000000000000000000000000000000000000'
                          currency1: '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913'
                          currency0_decimals: 18
                          currency1_decimals: 6
                          currency0_price_usd: '2474.05'
                          currency1_price_usd: '1.00'
                          amount0_raw: '1200000000000000'
                          amount1_raw: '2800000'
                          amount0: '0.0012'
                          amount1: '2.8'
                          amount0_usd: '2.97'
                          amount1_usd: '2.8'
                          amounts_usd: '5.77'
                        minted_block: 22095000
                        minted_timestamp: 1709995000000
                        updated_block: 22100000
                        updated_timestamp: 1710000000000
                short:
                  summary: Response (Short)
                  value:
                    c: 1
                    ps:
                      - id: '42'
                        p: >-
                          0x1111111111111111111111111111111111111111111111111111111111111111
                        c0: '0x0000000000000000000000000000000000000000'
                        c1: '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913'
                        cd0: 18
                        cd1: 6
                        p0: '2474.05'
                        p1: '1.00'
                        f: 3000
                        ts: 60
                        h: '0x0000000000000000000000000000000000000000'
                        tl: -180
                        tu: 60
                        lq: '250000000'
                        ta:
                          a0r: '1500000000000000000'
                          a1r: '3700000000'
                          a0: '1.5'
                          a1: '3700'
                          a0u: '3711.08'
                          a1u: '3700'
                          au: '7411.08'
                        ir: true
                        ctk: -120
                        sp: '12345678901234567890'
                        al: '1000000000'
                        cf:
                          c0: '0x0000000000000000000000000000000000000000'
                          c1: '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913'
                          cd0: 18
                          cd1: 6
                          p0: '2474.05'
                          p1: '1.00'
                          a0r: '1200000000000000'
                          a1r: '2800000'
                          a0: '0.0012'
                          a1: '2.8'
                          a0u: '2.97'
                          a1u: '2.8'
                          au: '5.77'
                        mb: 22095000
                        mt: 1709995000000
                        ub: 22100000
                        ut: 1710000000000
        '400':
          description: Validation error, usually invalid chain or wallet_address.
        '503':
          description: Uniswap wallet position data is unavailable for the requested chain.
components:
  schemas:
    UniswapProtocol:
      type: string
      description: 'Uniswap version: v3 or v4.'
      enum:
        - v3
        - v4
    UniswapPositionStatus:
      type: string
      enum:
        - open
        - closed
    V4PositionSortBy:
      type: string
      enum:
        - token_id
        - liquidity
        - token_amount0
        - token_amount1
        - token_amount0_usd
        - token_amount1_usd
        - token_amounts_usd
        - claimable_fee0
        - claimable_fee1
        - claimable_fee0_usd
        - claimable_fee1_usd
        - claimable_fees_usd
        - updated_block
        - updated_timestamp
        - minted_block
        - minted_timestamp
        - tick_lower
        - tick_upper
        - range_width
        - current_tick
        - in_range
    V4PositionSortOrder:
      type: string
      enum:
        - asc
        - desc
    V4WalletPositionsResponse:
      type: object
      required:
        - count
        - positions
      properties:
        count:
          type: integer
          description: Total matching positions.
          minimum: 0
        positions:
          type: array
          items:
            $ref: '#/components/schemas/V4WalletPositionData'
    V4WalletPositionData:
      type: object
      required:
        - token_id
        - pool_id
        - currency0
        - currency1
        - fee
        - tick_spacing
        - hooks
        - tick_lower
        - tick_upper
        - liquidity_raw
        - token_amounts
        - in_range
        - current_tick
        - sqrt_price_x96
        - active_liquidity_raw
        - minted_block
        - minted_timestamp
        - updated_block
        - updated_timestamp
      properties:
        token_id:
          type: string
        pool_id:
          type: string
        currency0:
          type: string
        currency1:
          type: string
        currency0_decimals:
          type:
            - integer
            - 'null'
          format: int32
          minimum: 0
        currency1_decimals:
          type:
            - integer
            - 'null'
          format: int32
          minimum: 0
        currency0_price_usd:
          type:
            - string
            - 'null'
        currency1_price_usd:
          type:
            - string
            - 'null'
        fee:
          type: integer
          format: int32
          minimum: 0
        tick_spacing:
          type: integer
          format: int32
        hooks:
          type: string
        tick_lower:
          type: integer
          format: int32
        tick_upper:
          type: integer
          format: int32
        liquidity_raw:
          type: string
        token_amounts:
          $ref: '#/components/schemas/V4PositionTokenAmounts'
        in_range:
          type: boolean
        current_tick:
          type: integer
          format: int32
        sqrt_price_x96:
          type: string
        active_liquidity_raw:
          type: string
        claimable_fees:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/V4ClaimableFeesData'
        minted_block:
          type: integer
          format: int64
          minimum: 0
        minted_timestamp:
          type: integer
          format: int64
          description: Mint block time, in Unix milliseconds.
          minimum: 0
        updated_block:
          type: integer
          format: int64
          minimum: 0
        updated_timestamp:
          type: integer
          format: int64
          description: Last update block time, in Unix milliseconds.
          minimum: 0
    V4PositionTokenAmounts:
      type: object
      required:
        - amount0_raw
        - amount1_raw
      properties:
        amount0_raw:
          type: string
        amount1_raw:
          type: string
        amount0:
          type:
            - string
            - 'null'
        amount1:
          type:
            - string
            - 'null'
        amount0_usd:
          type:
            - string
            - 'null'
        amount1_usd:
          type:
            - string
            - 'null'
        amounts_usd:
          type:
            - string
            - 'null'
    V4ClaimableFeesData:
      type: object
      required:
        - currency0
        - currency1
        - amount0_raw
        - amount1_raw
      properties:
        currency0:
          type: string
        currency1:
          type: string
        currency0_decimals:
          type:
            - integer
            - 'null'
          format: int32
          minimum: 0
        currency1_decimals:
          type:
            - integer
            - 'null'
          format: int32
          minimum: 0
        currency0_price_usd:
          type:
            - string
            - 'null'
        currency1_price_usd:
          type:
            - string
            - 'null'
        amount0_raw:
          type: string
        amount1_raw:
          type: string
        amount0:
          type:
            - string
            - 'null'
        amount1:
          type:
            - string
            - 'null'
        amount0_usd:
          type:
            - string
            - 'null'
        amount1_usd:
          type:
            - string
            - 'null'
        amounts_usd:
          type:
            - string
            - 'null'
  securitySchemes:
    ApiKey:
      type: apiKey
      in: header
      name: X-API-Key
      description: Secret API key (`sk_*`) or JWT public key (`pk_jwt_*`).

````

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