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

# Get Analytics

> Get time-series analytics

Returns TVL and volume time-series, grouped by total, stock, or issuer.

```bash theme={null}
curl "https://rwapulse.xyz/api/v0/liquidity/analytics?days=30&groupBy=total" \
  -H "Authorization: Bearer rwa_your_key"
```

## Parameters

| Name        | Required | Default | Description                              |
| ----------- | -------- | ------- | ---------------------------------------- |
| `groupBy`   | No       | `total` | `total`, `stock`, or `issuer`            |
| `days`      | No       | 90      | Days of history (clamped to 365)         |
| `assetType` | No       | `stock` | `stock` or `commodity`                   |
| `symbol`    | No       | -       | Filter by symbol (when `groupBy=stock`)  |
| `issuer`    | No       | -       | Filter by issuer (when `groupBy=issuer`) |

## Response (groupBy=total)

```json theme={null}
{
  "groupBy": "total",
  "days": 30,
  "series": [
    {
      "date": "2024-01-15",
      "tvl": 150000,
      "volume": 12000,
      "poolCount": 25
    }
  ]
}
```

## Response (groupBy=stock)

```json theme={null}
{
  "groupBy": "stock",
  "days": 30,
  "data": [
    {
      "symbol": "TSLA",
      "series": [
        { "date": "2024-01-15", "tvl": 50000, "volume": 4000 }
      ]
    }
  ]
}
```

## Common Mistake

`days` must be an integer >= 1. `groupBy=stock` without `symbol` returns all stocks.
