Fetch orderbooks batch
curl --request GET \
--url https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batchimport requests
url = "https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batch"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batch', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batch",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batch"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batch")
.asString();require 'uri'
require 'net/http'
url = URI("https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batch")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body[
{
"asks": [
{
"price": 123,
"size": 123
}
],
"asset_id": "<string>",
"bids": [
{
"price": 123,
"size": 123
}
],
"hash": "<string>",
"last_update_id": 1,
"timestamp": "2023-11-07T05:31:56Z"
}
]{
"kind": "Authentication",
"message": "<string>"
}Orderbook
fetch_orderbooks_batch
Fetch full-depth L2 orderbooks for multiple assets in one round-trip.
GET
/
v1
/
orderbook
/
fetch_orderbooks_batch
Fetch orderbooks batch
curl --request GET \
--url https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batchimport requests
url = "https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batch"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batch', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batch",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batch"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batch")
.asString();require 'uri'
require 'net/http'
url = URI("https://github.com/openpx-trade/openpx/v1/orderbook/fetch_orderbooks_batch")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body[
{
"asks": [
{
"price": 123,
"size": 123
}
],
"asset_id": "<string>",
"bids": [
{
"price": 123,
"size": 123
}
],
"hash": "<string>",
"last_update_id": 1,
"timestamp": "2023-11-07T05:31:56Z"
}
]{
"kind": "Authentication",
"message": "<string>"
}Fetch full-depth L2 orderbooks for multiple assets in one round-trip.
Query Parameters
Response
Success.
Ask levels, sorted ascending by price.
Show child attributes
Show child attributes
The orderable asset — Kalshi market ticker or Polymarket CTF token id (e.g. "KXBTCD-25APR1517").
Bid levels, sorted descending by price.
Show child attributes
Show child attributes
Polymarket book-state hash for replay integrity; null on Kalshi.
Monotonic sequence id from upstream; null when not provided.
Required range:
x >= 0Upstream snapshot time in UTC (e.g. "2026-04-25T12:00:00Z").

