Skip to content

GET /v1/funding

GET https://api.hypquant.com/v1/funding

Returns hourly funding rates for a perpetual contract. Optionally includes the normalized z-score and the spot/perp premium. Requires an API key.


Parameters

Name Type Required Description
symbol string yes Trading pair, e.g. BTC-USDC
exchange string yes hyperliquid (Binance spot has no funding)
start string yes Start time — ISO8601 or Unix milliseconds
end string no End time. Defaults to now
normalized boolean no Include rate_normalized and premium. Default: false

Tier restriction

Free tier: max 365-day window per request. Pro/Scale: no cap.


Response

{
  "symbol": "BTC-USDC",
  "exchange": "hyperliquid",
  "count": 2,
  "data": [
    {
      "time": "2024-01-01T00:00:00+00:00",
      "rate": "0.00010000"
    },
    {
      "time": "2024-01-01T01:00:00+00:00",
      "rate": "0.00012500",
      "rate_normalized": "1.320000",
      "premium": "0.00050000"
    }
  ]
}

rate_normalized and premium are only present when normalized=true.

Field definitions

Field Description
rate Raw hourly funding rate as a decimal (0.0001 = 0.01%)
rate_normalized Z-score of rate vs. 30-day rolling window (720 periods). null during warm-up (first 719 hours) or when std ≈ 0
premium Spot/perp basis: (perp_price − spot_price) / spot_price. Positive = perp at premium

Examples

from hypquant import MarketData

with MarketData(api_key="qp_...") as md:
    # Raw rates
    df = md.funding("BTC-USDC", exchange="hyperliquid", start="2024-01-01")

    # With normalized z-score and premium
    df = md.funding(
        "BTC-USDC",
        exchange="hyperliquid",
        start="2024-01-01",
        normalized=True,
    )
    print(df.columns)
    # ['time', 'rate', 'rate_normalized', 'premium']
curl -H "X-API-Key: qp_..." \
  "https://api.hypquant.com/v1/funding?symbol=BTC-USDC&exchange=hyperliquid&start=2024-01-01T00:00:00Z&normalized=true"

Interpreting funding rates

Hyperliquid funding is paid every hour. A rate of 0.0001 means longs pay shorts 0.01% of their position every hour — roughly 0.73% per 30 days.

A rate_normalized of +2.0 means the current funding is 2 standard deviations above the recent 30-day average — historically elevated, often a signal of extreme long sentiment.

The premium field reflects the spot/perp basis including the USDC/USDT spread. See Data Cleaning Decisions for the exact formula.


Error responses

HTTP error code Cause
400 INVALID_TIMESTAMP start or end could not be parsed
400 INVALID_TIME_RANGE start is after end
401 UNAUTHORIZED Missing or invalid API key
403 TIER_LIMIT_EXCEEDED History window exceeds tier limit
429 RATE_LIMIT_EXCEEDED Daily or per-minute request quota reached