List crypto index candles
curl --request GET \
--url https://api.darvas.app/v1/crypto/index/prices \
--header 'X-API-KEY: <api-key>'import requests
url = "https://api.darvas.app/v1/crypto/index/prices"
headers = {"X-API-KEY": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-KEY': '<api-key>'}};
fetch('https://api.darvas.app/v1/crypto/index/prices', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"index": "BTC-USD",
"interval": "1H",
"prices": [
{
"open": 97401.2,
"high": 97990,
"low": 97302.6,
"close": 97811.4,
"confirmed": false,
"time": "2026-11-28T11:00:00.000Z",
"time_milliseconds": 1795863600000
}
]
}{
"error": "VALIDATION_ERROR",
"message": "Send ticker or cik"
}{
"error": "UNAUTHORIZED",
"message": "The API key is not valid"
}{
"error": "PLAN_REQUIRED",
"message": "The account of this key has no active data API plan"
}{
"error": "NOT_FOUND",
"message": "No company has this ticker or CIK"
}{
"error": "RATE_LIMITED",
"message": "Too many requests"
}{
"error": "INTERNAL_ERROR",
"message": "Something went wrong"
}{
"error": "UNAVAILABLE",
"message": "The data service is unavailable"
}Crypto Markets
Composite Crypto Spot Index Historical API
Query historical OHLC bars for composite crypto spot price indices such as BTC-USD and ETH-USD aggregated across major liquid spot exchanges.
List crypto index candles
curl --request GET \
--url https://api.darvas.app/v1/crypto/index/prices \
--header 'X-API-KEY: <api-key>'import requests
url = "https://api.darvas.app/v1/crypto/index/prices"
headers = {"X-API-KEY": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-KEY': '<api-key>'}};
fetch('https://api.darvas.app/v1/crypto/index/prices', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"index": "BTC-USD",
"interval": "1H",
"prices": [
{
"open": 97401.2,
"high": 97990,
"low": 97302.6,
"close": 97811.4,
"confirmed": false,
"time": "2026-11-28T11:00:00.000Z",
"time_milliseconds": 1795863600000
}
]
}{
"error": "VALIDATION_ERROR",
"message": "Send ticker or cik"
}{
"error": "UNAUTHORIZED",
"message": "The API key is not valid"
}{
"error": "PLAN_REQUIRED",
"message": "The account of this key has no active data API plan"
}{
"error": "NOT_FOUND",
"message": "No company has this ticker or CIK"
}{
"error": "RATE_LIMITED",
"message": "Too many requests"
}{
"error": "INTERNAL_ERROR",
"message": "Something went wrong"
}{
"error": "UNAVAILABLE",
"message": "The data service is unavailable"
}Overview
This endpoint returns OHLC candles for a composite crypto spot index, such asBTC-USD or ETH-USDT. Each composite index blends spot quotes from several major exchanges into a single reference series that perpetual swaps and futures contracts mark against. Candles return oldest first in prices, including the candle still in progress.
| Coverage | Details |
|---|---|
| Index format | index as BASE-QUOTE in any case (default BTC-USD); unknown index names return 404 |
| Intervals | 1m, 5m, 15m, 30m, 1H (default), 4H, 1D and 1W |
| Bucket alignment | Daily (1D) and weekly (1W) candles align to UTC boundaries (00:00:00Z) |
| Row limit | limit from 1 to 100 newest candles (default 100) |
| MCP tool | list_crypto_index_prices on the data API MCP server |
Candle fields and usage
Composite index candles carry price levels only (open, high, low, close) with no trade volume, because an index is a weighted spot composite rather than a single order book.
- Open versus closed bars. Each candle includes
confirmed(trueonce the bucket has closed,falsewhile the newest bar is still forming),time(ISO 8601 UTC open timestamp), andtime_milliseconds. - Comparing against derivatives. Pair index candles with perpetual swap candles at
/crypto/pricesor historical basis series at/crypto/derivatives(metric=basis) to measure contract premiums and discounts over time. - Related endpoints. For live spot index prices and 24-hour ranges across an entire quote currency, see
/crypto/index/snapshot. For live mark price, index price, and basis in basis points, see/crypto/derivatives/snapshot.
Examples
import os
import requests
headers = {"X-API-KEY": os.environ["DARVAS_API_KEY"]}
resp = requests.get(
"https://api.darvas.app/v1/crypto/index/prices",
headers=headers,
params={"index": "BTC-USD", "interval": "4H", "limit": 24},
).json()
print(resp["index"], resp["interval"], "bars:", len(resp["prices"]))
for bar in resp["prices"][-3:]:
print(bar["time"], "O/H/L/C:", bar["open"], bar["high"], bar["low"], bar["close"], "confirmed:", bar["confirmed"])
# Latest 30 daily UTC candles for the ETH-USD composite spot index
curl -H "X-API-KEY: $DARVAS_API_KEY" \
"https://api.darvas.app/v1/crypto/index/prices?index=ETH-USD&interval=1D&limit=30"
Authorizations
apiKeybearerKey
Query Parameters
Response
List crypto index candles: one page.
The answer of GET /crypto/index/prices.