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

# Funding Rate Monitor

> Track funding across every Hyperliquid perp and catch rate divergences.

Funding is the carry cost of a perp position. Monitoring it across markets surfaces crowded trades and basis opportunities.

## Current rates across every market

```python theme={null}
import asyncio
from ironflow_sdk import Ironflow

THRESHOLD = 0.0005  # 0.05% per interval

async def scan():
    async with Ironflow("if_your_api_key") as client:
        markets = await client.markets(market_class="perp")
        for m in markets:
            page = await client.funding(m.display_symbol, limit=1)
            if not page.data:
                continue
            rate = float(page.data[0].rate)
            if abs(rate) > THRESHOLD:
                print(f"{m.display_symbol:24s} {rate:+.5f}")

asyncio.run(scan())
```

This sweeps native and HIP-3 builder perps in one pass — builder markets frequently carry the largest divergences.

## Historical analysis

Pull the full rate series for one market and study its regime:

```bash theme={null}
curl "https://api.ironflow.sh/v1/funding?source=hyperliquid&market=ETH-PERP&from=1751328000000&to=1754600000000" \
  -H "Authorization: Bearer $IRONFLOW_API_KEY"
```

## Funding statistics

`/v1/analytics/funding-stats` aggregates mean, extremes, and annualized rate per market server-side:

```bash theme={null}
curl "https://api.ironflow.sh/v1/analytics/funding-stats?source=hyperliquid&market=BTC-PERP&window=7d" \
  -H "Authorization: Bearer $IRONFLOW_API_KEY"
```


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