Skip to main content
List crypto candles

Overview

This endpoint returns historical and live OHLCV candles from one minute to one month for Darvas aggregated pairs (exchange=darvas) and for single instruments across nine primary crypto exchanges. The open candle in progress arrives on the newest page.

Aggregated feeds and venues

Pass exchange=darvas to combine every exchange that lists a canonical pair: BASE-QUOTE for spot (BTC-USDT, BTC-ALLUSD) or BASE-QUOTE-SWAP for perpetuals (BTC-USDT-SWAP, BTC-ALLUSD-SWAP).
  • Price and volume math. Each aggregated candle takes the median open and close across reporting exchanges, drops closes more than 25% off the median and wicks more than 5% past the median high or low when three or more exchanges report, and sums base volume and quote_volume.
  • ALLUSD stablecoin guard. On ALLUSD pairs, if USDT or USDC strays more than 0.5% from fiat USD in a candle, Darvas drops that stablecoin from the bucket so a depeg cannot pull the series.
  • Venue filtering. Pass a comma-separated venues list (up to 16 exchanges, such as venues=binance,coinbase,okx) with exchange=darvas to aggregate only those exchanges. Sending venues with any single exchange returns 400.
  • Response scope. Answers for exchange=darvas include constituents (every exchange the pair combines) and venues (the filtered subset, or null when all constituents are combined). Both fields are absent for single-exchange requests.

Inverse, ratio and spread formulas

ticker also takes a formula over listed crypto instruments, written as in the chart’s pair search or in the canonical form an answer names it by:
  • Exchange. Send exchange=formula to read ticker as a formula. Without it, a ticker no exchange lists is read as a formula before it is refused, and a symbol without an EXCHANGE: prefix is looked up on the exchange sent first. market_type picks the market a symbol is read in first.
  • Resolution. A typed symbol resolves as the chart’s pair search resolves it: Darvas aggregated pairs first, then OKX, Binance, Bybit and the other exchanges, perpetuals before spot. USDTBTC with no exchange answers as 1 / [darvas:BTC-USDT-SWAP] while Darvas lists that pair. The canonical form names every leg’s exchange and id, so it always reads the same legs.
  • Answer. A formula answers with exchange formula, market_type synthetic, the canonical formula as ticker, the name Darvas shows as display_symbol (such as USDTBTC or BTC/NVDA) and its legs, each a listed instrument with exchange, ticker and market_type.
  • Candles. A formula’s candle is the formula of its legs’ candles at every time all legs hold one: open from the legs’ opens, close from their closes, and high and low the highest and lowest of the formula at the legs’ opens, highs, lows and closes. A one-leg formula such as an inverse keeps its leg’s volume; any other formula has volume 0.
  • Crypto only. Every leg is a listed instrument on a crypto exchange. A formula naming a CFD or partner broker symbol (such as 1 / [ctrader:EURUSD]) returns 400, one with a leg no exchange lists returns 404, and venues with a formula returns 400. /crypto/tickers resolves a formula query to the same canonical ticker.

Instrument IDs and pagination

Single-exchange IDs follow each venue: BTC-USDT or BTC-USDT-SWAP on OKX, ETH-USDC-SWAP on Hyperliquid, BTC-USD on Coinbase, and spot:BTCUSDT or perpetual:BTCUSDT on Binance and Bybit. A bare Binance or Bybit symbol such as BTCUSDT also works with market_type (spot or swap, defaulting to spot). Use /crypto/tickers to list every instrument and aggregated pair with its constituents. Pages walk back in time: the first page ends at end_date (today by default), each next_page_url continues before it, and the last page reaches start_date. Every page lists its candles oldest first. A formula’s pages work the same way, and each page reads its legs again, so every leg stays a listed crypto instrument. For the latest price alone, see /crypto/prices/snapshot. For precomputed moving averages, RSI, MACD, Bollinger Bands and ATR on these candles, see /crypto/indicators.

Examples

Authorizations

X-API-KEY
string
header
required

A Darvas data API key: dvk_ and 43 characters.

Query Parameters

ticker
string
required

The instrument id: BTC-USDT or BTC-USDT-SWAP on OKX, ETH-USDC-SWAP on Hyperliquid, BTC-USD on Coinbase, spot:BTCUSDT or perpetual:BTCUSDT on Binance and Bybit. A Binance or Bybit symbol such as BTCUSDT also works with market_type, spot without it. A Darvas aggregated pair is BASE-QUOTE or BASE-QUOTE-SWAP, such as BTC-USDT-SWAP, or BTC-ALLUSD for one combining its USD, USDT and USDC markets. A formula over listed crypto instruments is typed as in the chart's pair search, such as USDTBTC (the inverse of BTC-USDT), BTCUSDT*USDTETH, BTCUSDT/NVDAUSDT, BTC/NVDA, COINBASE:BTCUSD - BINANCE:BTCUSDT or (BTCUSDT + ETHUSDT) / 2, or sent in the canonical form an answer names it by, such as 1 / [okx:BTC-USDT-SWAP]. Every leg is a listed instrument on a crypto exchange. With exchange formula the ticker is read as a formula; without it, a ticker no exchange lists is read as one, its symbols looked up on the exchange sent first.

Maximum string length: 512
Pattern: ^[A-Za-z0-9 ._:@/()\[\]*+^-]{1,512}$
exchange
enum<string>
default:okx

The exchange, darvas for Darvas's aggregate of the pair across every exchange that lists it, or formula for a formula ticker; okx without it.

Available options:
darvas,
okx,
binance,
bybit,
hyperliquid,
coinbase,
kraken,
bitstamp,
deribit,
bitfinex,
formula
market_type
enum<string>

spot, swap, futures or option; without it, the type the id implies.

Available options:
spot,
swap,
futures,
option
venues
string

With exchange darvas: combine only these of the pair's exchanges, comma-separated. Any other exchange refuses it.

Maximum string length: 528
Pattern: ^[a-z0-9][a-z0-9-]{0,31}(,[a-z0-9][a-z0-9-]{0,31}){0,15}$
interval
enum<string>
default:day

minute, hour, day, week or month; day without it.

Available options:
minute,
hour,
day,
week,
month
interval_multiplier
integer<int32>
default:1

Candles of this many intervals: minute 1, 5, 15, 30; hour 1, 2, 4, 6, 12; otherwise 1.

Required range: 1 <= x <= 30
start_date
string<date>
required

The first UTC day to return.

Maximum string length: 10
end_date
string<date>

The last UTC day to return; today without it.

Maximum string length: 10
limit
integer<int32>
default:5000

Candles to return across all pages.

Required range: 1 <= x <= 50000
cursor
string

The cursor from a previous next_page_url. It replaces every other parameter.

Maximum string length: 4096
Pattern: ^[A-Za-z0-9_-]+$

Response

List crypto candles: one page.

The answer of GET /crypto/prices.

ticker
string
required

The instrument id of these candles, or with exchange formula the canonical formula, such as 1 / [okx:BTC-USDT-SWAP].

Maximum string length: 512
Pattern: ^[A-Za-z0-9 ._:@/()\[\]*+^-]{1,512}$
Example:

"BTC-USDT"

exchange
enum<string>
required

The exchange of these candles, or formula.

Available options:
darvas,
okx,
binance,
bybit,
hyperliquid,
coinbase,
kraken,
bitstamp,
deribit,
bitfinex,
formula
Example:

"okx"

market_type
enum<string>
required

The market of these candles; synthetic for a formula.

Available options:
spot,
swap,
futures,
option,
synthetic
Example:

"spot"

interval
enum<string>
required

The interval of the candles.

Available options:
minute,
hour,
day,
week,
month
Example:

"day"

interval_multiplier
integer<int32>
required

Intervals per candle.

Required range: 1 <= x <= 30
Example:

1

prices
object[]
required

This page of candles, oldest first.

Maximum array length: 500
constituents
string[]

With exchange darvas: every exchange contributing to these candles. Absent for one exchange.

Maximum array length: 16
Maximum string length: 32
Pattern: ^[a-z0-9][a-z0-9-]{0,31}$
Example:
venues
string[] | null

With exchange darvas: the exchanges feeding these candles when venues narrowed them, null when all are included. Absent for one exchange.

Maximum array length: 16
Maximum string length: 32
Pattern: ^[a-z0-9][a-z0-9-]{0,31}$
Example:
display_symbol
string

With exchange formula: the name Darvas shows for the formula of these candles, such as USDTBTC or BTC/NVDA. Absent otherwise.

Maximum string length: 512
Pattern: ^[^\x00-\x08\x0b\x0c\x0e-\x1f]*$
Example:

"USDTBTC"

legs
object[]

With exchange formula: the listed crypto instruments the formula of these candles reads. Absent otherwise.

Maximum array length: 10
next_page_url
string<uri>

The page before this one in time; absent on the first day asked for.

Maximum string length: 6000
Example:

"https://api.darvas.app/v1/crypto/prices?cursor=eyJleGNoYW5nZSI6Im9reCJ9"