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

# Get onchain statistics for a specific pool

> Retrieve aggregated statistics including total open positions, input values, and unique users for a pool



## OpenAPI

````yaml /api-reference/openapi.json get /pools/{poolId}/onchain-stats
openapi: 3.0.0
info:
  title: LP Agent Open API
  version: 1.0.0
  description: |+
    Public API for LP Agent

    **Authentication**

    All endpoints require an API key passed via the `x-api-key` header.

servers:
  - url: https://api.lpagent.io/open-api/v1
    description: Production
security:
  - apiKeyAuth: []
tags: []
paths:
  /pools/{poolId}/onchain-stats:
    get:
      tags:
        - Pools
      summary: Get onchain statistics for a specific pool
      description: >-
        Retrieve aggregated statistics including total open positions, input
        values, and unique users for a pool
      parameters:
        - in: path
          name: poolId
          required: true
          schema:
            type: string
          description: The pool address
          example: 7d51qGEeAKiPakkxLoHda9egShXQLJcjFYpHEcX4d3EM
      responses:
        '200':
          description: Successfully retrieved pool onchain stats
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    example: success
                  data:
                    type: object
                    properties:
                      poolStats:
                        type: array
                        items:
                          type: object
                          properties:
                            pool:
                              type: string
                              description: Pool address
                              example: 7d51qGEeAKiPakkxLoHda9egShXQLJcjFYpHEcX4d3EM
                            total_open_positions:
                              type: number
                              description: Count of open positions
                              example: 42
                            unique_owners:
                              type: number
                              description: Count of distinct position owners
                              example: 15
                            total_input_value:
                              type: number
                              description: Total input value in USD
                              example: 0
                            total_input_native:
                              type: number
                              description: Total input value in native token
                              example: 0
        '404':
          description: No data found for the pool
        '500':
          description: Internal server error
components:
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: API key for authentication

````