Returns historical bid-ask spread and order book imbalance data. Wide spreads indicate low liquidity and higher slippage risk. Imbalance shows whether buy or sell orders dominate the book.
Parameters
| Parameter | Type | Default | Description |
|---|
symbol | string | BTCUSDT | Trading pair |
hours | number | 24 | Lookback window in hours (max 168) |
Example Request
curl -X GET "https://krovn.io/api/v1/spread?symbol=BTCUSDT&hours=24" \
-H "X-API-Key: your_api_key"
Example Response
{
"symbol": "BTCUSDT",
"data": [
{
"timestamp": "2026-03-21T12:00:00.000Z",
"bidPrice": 87418.30,
"askPrice": 87422.10,
"spreadPct": 0.0043,
"imbalance": 0.125
},
{
"timestamp": "2026-03-21T12:05:00.000Z",
"bidPrice": 87430.50,
"askPrice": 87433.80,
"spreadPct": 0.0038,
"imbalance": -0.082
}
],
"dataPoints": 2,
"current": {
"timestamp": "2026-03-21T12:05:00.000Z",
"bidPrice": 87430.50,
"askPrice": 87433.80,
"spreadPct": 0.0038,
"imbalance": -0.082
},
"avgSpreadPct": 0.0041,
"signal": "NORMAL"
}
Signals: WIDE_SPREAD (current spread > 2x average), BID_HEAVY (imbalance > 0.3, buyers dominate), ASK_HEAVY (imbalance < -0.3, sellers dominate), NORMAL (balanced). Imbalance ranges from -1 to 1.