Skip to main content

Historical API Reference

Metadata​

  • Owner: Origo Engineering
  • Last updated: 2026-03-26
  • Slice/version reference: S31 + S34 prep (API v0.1.28 branch state)

Purpose and scope​

  • Canonical end-user reference for all historical dataset interfaces.
  • Covers HTTP endpoints, Python method equivalents, mode support, and deferred scope.

Shared request contract​

  • mode
  • start_date
  • end_date
  • n_latest_rows
  • n_random_rows
  • fields
  • filters
  • strict

Route-specific additions:

  • spot trades routes: include_datetime_col
  • spot klines routes: kline_size

Modes:

  • native
  • aligned_1s

Window rules:

  • at most one of date-window, n_latest_rows, n_random_rows
  • no selector means full available history (earliest -> now)
  • dates are strict UTC YYYY-MM-DD

Historical availability rule:

  • full available history means full currently proved history for that dataset
  • see docs/backfill-status-reference.md

Historical dataset matrix​

DatasetHTTP endpointPython methodModes
binance_spot_tradesPOST /v1/historical/binance/spot/tradesget_binance_spot_tradesnative, aligned_1s
okx_spot_tradesPOST /v1/historical/okx/spot/tradesget_okx_spot_tradesnative, aligned_1s
bybit_spot_tradesPOST /v1/historical/bybit/spot/tradesget_bybit_spot_tradesnative, aligned_1s
etf_daily_metricsPOST /v1/historical/etf/daily_metricsget_etf_daily_metricsnative, aligned_1s
fred_series_metricsPOST /v1/historical/fred/series_metricsget_fred_series_metricsnative, aligned_1s
bitcoin_block_headersPOST /v1/historical/bitcoin/block_headersget_bitcoin_block_headersnative, aligned_1s
bitcoin_block_transactionsPOST /v1/historical/bitcoin/block_transactionsget_bitcoin_block_transactionsnative, aligned_1s
bitcoin_mempool_statePOST /v1/historical/bitcoin/mempool_stateget_bitcoin_mempool_statenative, aligned_1s
bitcoin_block_fee_totalsPOST /v1/historical/bitcoin/block_fee_totalsget_bitcoin_block_fee_totalsnative, aligned_1s
bitcoin_block_subsidy_schedulePOST /v1/historical/bitcoin/block_subsidy_scheduleget_bitcoin_block_subsidy_schedulenative, aligned_1s
bitcoin_network_hashrate_estimatePOST /v1/historical/bitcoin/network_hashrate_estimateget_bitcoin_network_hashrate_estimatenative, aligned_1s
bitcoin_circulating_supplyPOST /v1/historical/bitcoin/circulating_supplyget_bitcoin_circulating_supplynative, aligned_1s

Spot kline convenience routes:

  • POST /v1/historical/binance/spot/klines
  • POST /v1/historical/okx/spot/klines
  • POST /v1/historical/bybit/spot/klines

Deferred datasets​

  • none in current active historical scope

Response contract​

  • mode
  • source
  • sources
  • row_count
  • schema
  • warnings
  • rows
  • rights_state
  • rights_provisional

Status and error contract​

  • 200 success
  • 404 no rows for requested window
  • 409 contract/auth/strict warning failure
  • 503 runtime/backend failure