GET /v1/features¶
GET https://api.hypquant.com/v1/features
Returns pre-computed feature values in wide format (one column per feature). Requires an API key.
See also: GET /v1/features/available to discover the full catalogue.
Parameters¶
| Name | Type | Required | Description |
|---|---|---|---|
symbol | string | yes | Trading pair, e.g. BTC-USDC |
exchange | string | yes | hyperliquid or binance |
timeframe | string | yes | 1m, 5m, 15m, 1h, 4h, 1d, or funding |
features | string | yes | Comma-separated feature names, e.g. rsi_14,macd,bb_upper |
start | string | yes | Start time — ISO8601 or Unix milliseconds |
end | string | no | End time. Defaults to now |
The funding timeframe
Funding features (funding_norm, funding_cumulative_24h, funding_cumulative_7d, premium_pct, premium_zscore) live in timeframe = "funding" — one row per hour aligned to the funding event. Tier restrictions on timeframe granularity do not apply to funding.
Tier restriction
For non-funding timeframes: Free = 1h+ and ≤ 365-day window. Pro/Scale = unrestricted.
Response¶
{
"symbol": "BTC-USDC",
"exchange": "hyperliquid",
"timeframe": "1h",
"features": ["rsi_14", "macd"],
"count": 2,
"data": [
{
"time": "2024-01-01T00:00:00+00:00",
"rsi_14": "58.432100",
"macd": "145.230000"
},
{
"time": "2024-01-01T01:00:00+00:00",
"rsi_14": "61.120000",
"macd": "162.450000"
}
]
}
Examples¶
from hypquant import MarketData
with MarketData(api_key="qp_...") as md:
# Technical features on 1h candles
df = md.features(
"BTC-USDC",
exchange="hyperliquid",
timeframe="1h",
features=["rsi_14", "macd", "macd_signal", "bb_upper", "bb_lower", "atr_14"],
start="2024-01-01",
end="2024-03-31",
)
# Funding features
df_funding = md.features(
"BTC-USDC",
exchange="hyperliquid",
timeframe="funding",
features=["funding_norm", "funding_cumulative_7d", "premium_pct"],
start="2024-01-01",
)
GET /v1/features/available¶
GET https://api.hypquant.com/v1/features/available
Returns the complete feature catalogue with name, description, and category.
{
"features": [
{"name": "rsi_9", "description": "RSI period 9 (Wilder smoothing)", "category": "momentum"},
{"name": "rsi_14", "description": "RSI period 14 (Wilder smoothing)", "category": "momentum"},
{"name": "rsi_21", "description": "RSI period 21 (Wilder smoothing)", "category": "momentum"},
{"name": "macd", "description": "MACD line (12,26,9)", "category": "trend"},
{"name": "macd_signal", "description": "MACD signal line (9-period EMA)", "category": "trend"},
{"name": "macd_histogram", "description": "MACD histogram (MACD − signal)", "category": "trend"},
{"name": "bb_upper", "description": "Bollinger Bands upper (20, 2σ)", "category": "volatility"},
{"name": "bb_middle", "description": "Bollinger Bands middle — 20-period SMA", "category": "volatility"},
{"name": "bb_lower", "description": "Bollinger Bands lower (20, 2σ)", "category": "volatility"},
{"name": "bb_width", "description": "Bollinger Band width (upper−lower)/mid", "category": "volatility"},
{"name": "bb_pct", "description": "Bollinger %B — position within bands", "category": "volatility"},
{"name": "atr_14", "description": "ATR period 14 (Wilder smoothing)", "category": "volatility"},
{"name": "vwap_20", "description": "20-period rolling VWAP", "category": "volume"},
{"name": "twap_20", "description": "20-period rolling TWAP", "category": "volume"},
{"name": "price_vs_vwap_20", "description": "Price deviation from VWAP (%)", "category": "volume"},
{"name": "funding_norm", "description": "Funding z-score vs 30-day rolling window", "category": "funding"},
{"name": "funding_cumulative_24h", "description": "Cumulative funding over 24h", "category": "funding"},
{"name": "funding_cumulative_7d", "description": "Cumulative funding over 7 days", "category": "funding"},
{"name": "premium_pct", "description": "Spot/perp basis percentage (basis × 100)", "category": "premium"},
{"name": "premium_zscore", "description": "Premium z-score vs 30-day rolling window", "category": "premium"}
]
}
See the full Features Catalogue for computation details.
Error responses¶
| HTTP | error code | Cause |
|---|---|---|
| 400 | MISSING_FEATURES | features parameter is empty |
| 400 | UNKNOWN_FEATURES | One or more names not in the catalogue |
| 400 | INVALID_TIMEFRAME | Timeframe not in allowed set |
| 400 | INVALID_TIMESTAMP | start or end could not be parsed |
| 401 | UNAUTHORIZED | Missing or invalid API key |
| 403 | TIER_LIMIT_EXCEEDED | Timeframe or history window requires upgrade |
| 429 | RATE_LIMIT_EXCEEDED | Daily or per-minute request quota reached |