Options · Order flow
Options flow by trade type
/v1/options/flow/by-trade-typeoptionsFlowByTradeTypeFor each bucket, the premium in US dollars of call prints and of put prints, split into sweeps, blocks and other prints, with the total, and the totals over the window. All sides count and multi-leg orders are excluded. Sweeps and blocks are groupings the platform infers from the prints, not exchange-confirmed order types; other is the total minus sweeps and blocks. Buckets that have not started yet are not returned.
Example request
curl -sS --get "https://api.ordermap.si/v1/options/flow/by-trade-type" \
-H "Authorization: Bearer $ORDERMAP_API_KEY" \
--data-urlencode underlying_symbol=SPXWconst params = new URLSearchParams({
underlying_symbol: "SPXW",
});
const res = await fetch(`https://api.ordermap.si/v1/options/flow/by-trade-type?${params}`, {
headers: { Authorization: `Bearer ${process.env.ORDERMAP_API_KEY}` },
});
if (!res.ok) throw new Error(`${res.status} ${await res.text()}`);
const { data, meta } = await res.json();
console.log(data, meta.coverage);Set ORDERMAP_API_KEY to your key. Replace the dates with a recent trading date.
Parameters
6 parameters, 1 required.
| Parameter | Type and limits | Description |
|---|---|---|
underlying_queryrequired | stringat most 8 characterspattern ^[A-Za-z][A-Za-z0-9.]{0,7}$ | Option root or family: SPX covers the SPX and SPXW roots, SPXW only the weekly root, QQQ, NDXP, RUTW, XSP ... |
datequeryoptional | stringdate | Trading date (YYYY-MM-DD). Default: the current session, else the most recent completed one. Overnight prints belong to the next trading date. |
sessionqueryoptional | stringrthgthalldefault rth | Trading session: rth is the regular session, gth the overnight (global trading hours) session before the trading date, all both. Overnight data requires the Pro plan and exists only for underlyings with an overnight session; GET /v1/options/sessions shows which. |
start_queryoptional | integerunix-msmin 946684800000max 4102444800000 | Start of the window (inclusive). The window must lie within one trading session; combine with date to name that session. |
end_queryoptional | integerunix-msmin 946684800000max 4102444800000 | End of the window (exclusive). |
intervalqueryoptional | string1m5m15m30m1hdefault 5m | Bucket length: 1m, 5m, 15m, 30m or 1h. |
Response
| Status | Meaning | Body |
|---|---|---|
200 | Successful response. | Schema below |
400 | Invalid, unknown or repeated parameters, or an invalid cursor. | Error object |
401 | Missing or invalid API key. | Error object |
403 | The plan, dataset release or account state does not allow this request. | Error object |
422 | The request is valid but no data exists for it. | Error object |
429 | Rate limit, burst limit or cooldown; wait Retry-After seconds.Retry-After | Error object |
500 | Internal error. | Error object |
503 | Data temporarily unavailable; retry after Retry-After seconds.Retry-After | Error object |
504 | The request timed out. | Error object |
Authenticated responses carry the X-RateLimit-* headers (see rate limits); 429 and 503 add Retry-After.
200 response body
dataobjectrequiredPremium by trade type.26 fields insidebucketsarray<object>requiredOne entry per bucket that has started.11 fields insidecallobjectrequiredCall premium of the bucket.4 fields insideblocknumber | nullrequiredPremium of blocks.othernumber | nullrequiredPremium of the other prints.sweepnumber | nullrequiredPremium of sweeps, US dollars.totalnumber | nullrequiredPremium of all prints.
putobjectrequiredPut premium of the bucket.4 fields insideblocknumber | nullrequiredPremium of blocks.othernumber | nullrequiredPremium of the other prints.sweepnumber | nullrequiredPremium of sweeps, US dollars.totalnumber | nullrequiredPremium of all prints.
timestampintegerunix-msrequiredStart of the bucket. Unix epoch milliseconds (UTC).
callobjectrequiredCall totals over the window.4 fields insideblocknumber | nullrequiredPremium of blocks.othernumber | nullrequiredPremium of the other prints.sweepnumber | nullrequiredPremium of sweeps, US dollars.totalnumber | nullrequiredPremium of all prints.
intervalstringrequiredBucket length.putobjectrequiredPut totals over the window.4 fields insideblocknumber | nullrequiredPremium of blocks.othernumber | nullrequiredPremium of the other prints.sweepnumber | nullrequiredPremium of sweeps, US dollars.totalnumber | nullrequiredPremium of all prints.
sessionstringrequiredSession.rthgthalltrading_datestringdaterequiredTrading date.underlying_symbolstringrequiredThe requested underlying.
metaobjectrequiredMeta object
Example response
{
"data": {
"buckets": [
{
"call": {
"block": 0,
"other": 320000,
"sweep": 100000,
"total": 420000
},
"put": {
"block": 200000,
"other": 110000,
"sweep": 0,
"total": 310000
},
"timestamp": 1792161000000
}
],
"call": {
"block": 9000000,
"other": 22000000,
"sweep": 4100000,
"total": 35100000
},
"interval": "5m",
"put": {
"block": 9000000,
"other": 22000000,
"sweep": 4100000,
"total": 35100000
},
"session": "rth",
"trading_date": "2026-10-16",
"underlying_symbol": "SPX"
},
"meta": {
"as_of": 1760659200123,
"coverage": {
"complete": true
},
"delay_ms": 0,
"delayed": false,
"request_id": "0199f0c2-5a1e-7c3b-9d4e-2b6f8a1c3d5e",
"source": "opra"
}
}Values are illustrative. Missing values are null, never 0.
