CEX
Batch fetch CEX OHLCV candles
post
/cex/ohlcv/batch
operationId: cex-historyBatch

POST batch variant of /cex/ohlcv. Body: { pairs: [{asset, base}], interval, startTime, endTime, limit } (max 50 pairs). Returns one row per requested pair as { asset, base, candles: [...] } — pairs with no data in the window surface as candles: []. Time-window / interval / limit are shared across the batch.

Unlock protected endpoints

Enter your Bearer token once to enable every protected route in this API reference.

HTTP bearer

Saved for this browser tab only. The credential is never sent until you test an endpoint.

Authorizations
NameLocationDetails
BearerAuthAuthorization header · bearerJWT issued by the Honeycluster auth service for the `oracle` audience. Present as `Authorization: Bearer <token>`.
Request Body
application/json
required
FieldTypeDefaultDescription
pairs
required
object[]
Up to 50 (asset, base) pairs to fetch candles for.
pairs[].asset
required
string
Asset symbol to query (e.g. `XRP`).
pairs[].base
string"USD"
Base currency. Defaults to `USD`.
interval
enum<string>"1h"
OHLCV candle interval. Defaults to `1h`.
Available
1m3m5m15m30m1h2h4h
startTime
integer
Inclusive lower bound for candle time, Unix-seconds. Defaults to `endTime − (interval × limit)`.
endTime
integer
Exclusive upper bound for candle time, Unix-seconds. Defaults to the current server time.
limit
integer500
Per-pair maximum number of candles to return (1–1000). Defaults to 500.
Example
Json
{
  "pairs": [
    {
      "asset": "XRP",
      "base": "USD"
    }
  ],
  "interval": "1h",
  "startTime": 1745798400,
  "endTime": 1745798400,
  "limit": 500
}
Responses
200
application/json
Successful response
FieldTypeDescription
items
object[]
One entry per requested pair, in request order.
items[].asset
string
Echoed asset symbol.
items[].base
string
Echoed base currency.
items[].candles
object[]
OHLCV candles for the pair, ascending bucket order. Empty when no data exists in the window.
items[].candles[].asset
string
Asset symbol.
items[].candles[].base
string
Base currency.
items[].candles[].bucket
integer
Candle start time, Unix-seconds.
items[].candles[].open
object
Opening price (decimal string), or `null` when only ticker-derived close is available.
items[].candles[].high
object
Highest price (decimal string), or `null` when only ticker-derived close is available.
items[].candles[].low
object
Lowest price (decimal string), or `null` when only ticker-derived close is available.
items[].candles[].close
string
Closing price (decimal string).
items[].candles[].volume
object
Total volume in the interval, or `null` when only ticker-derived close is available.
items[].candles[].vwap
object
Volume-weighted average price.
items[].candles[].tradeCount
number
Number of trades aggregated into the candle.
Example
Json
{
  "items": [
    {
      "asset": "string",
      "base": "string",
      "candles": [
        {
          "asset": "XRP",
          "base": "USD",
          "bucket": 1745712000,
          "open": "0.512",
          "high": "0.518",
          "low": "0.509",
          "close": "0.514",
          "volume": "128450.32",
          "vwap": 0.5135,
          "tradeCount": 312
        }
      ]
    }
  ]
}
400
application/json
Invalid input data
FieldTypeDescription
message
string
The error message
code
string
The error code
issues
object[]
An array of issues that were responsible for the error
issues[].message
string
Example
Json
{
  "code": "BAD_REQUEST",
  "message": "Invalid input data",
  "issues": []
}
401
application/json
Authorization not provided
FieldTypeDescription
message
string
The error message
code
string
The error code
issues
object[]
An array of issues that were responsible for the error
issues[].message
string
Example
Json
{
  "code": "UNAUTHORIZED",
  "message": "Authorization not provided",
  "issues": []
}
403
application/json
Insufficient access
FieldTypeDescription
message
string
The error message
code
string
The error code
issues
object[]
An array of issues that were responsible for the error
issues[].message
string
Example
Json
{
  "code": "FORBIDDEN",
  "message": "Insufficient access",
  "issues": []
}
500
application/json
Internal server error
FieldTypeDescription
message
string
The error message
code
string
The error code
issues
object[]
An array of issues that were responsible for the error
issues[].message
string
Example
Json
{
  "code": "INTERNAL_SERVER_ERROR",
  "message": "Internal server error",
  "issues": []
}