API reference
Assemble backtest dataset
POST/backtests/atop/dataset
Bundle L2 orderbook windows + spot klines for a symbol and period into a single response ready for backtest replay.
10 requests / minute per key (write tier). Returns the {success, message, data} envelope.
Authorizations
Authorizationstringheaderrequired
Bearer token - an ito_* key (from Settings) holding the backtests:read scope.
Body
symbolstring
Example: "BTC"
intervalnumber
Example: 300
startstring
Example: "2026-02-01T00:00:00Z"
endstring
Example: "2026-02-08T00:00:00Z"
include_l2boolean
Example: false
Request
curl -X POST "https://itomarkets.com/api/v1/backtests/atop/dataset" \ -H "Authorization: Bearer $ITO_API_KEY" \ -H "Content-Type: application/json" \ -d ' { "symbol": "BTC", "interval": 300, "start": "2026-02-01T00:00:00Z", "end": "2026-02-08T00:00:00Z", "include_l2": false } 'ResponseJSON
{ "success": true, "message": "Success", "data": { "symbol": "BTC", "interval": 300, "period": { "start": "2026-02-01T00:00:00+00:00", "end": "2026-02-08T00:00:00+00:00" }, "windows": [ { "ts": "2026-02-01T00:05:00Z", "mid": 0.52, "spread": 0.04 } ], "spot_klines": [ { "ts": "2026-02-01T00:05:00Z", "open": 97200, "high": 97350, "low": 97100, "close": 97280 } ], "metadata": { "source": "ito-cloud-runtime/api/v1/backtests/atop", "clickhouse_table": "platform_orderbook_l2", "data_quality": "production_hot_storage" } }}