Polymarket Get Orderbook logo

Catalog action Utility

Get the order book for one or more Polymarket tokens showing all bids and asks. Supports single token (tokenId) or batch mode (tokenIds array) for efficient multi-token lookup. Returns full depth of market with price levels, sizes, and spread information. Ideal for: market analysis, liquidity assessment, spread monitoring, trading strategy development.

At a Glance

FieldValue
Action IDpolymarket-get-orderbook
CategoryUtility
ConnectorNot required
Requires gasNo
Funds movementNone declared
Tagspolymarket, orderbook, market-data, read

Payload Schema

FieldTypeRequiredDescription
tokenIdstringNoThe token ID (condition token asset ID) to get the order book for. Use for single-token lookup.
tokenIdsarrayNoArray of token IDs to fetch order books for in a single batch call. More efficient than multiple single calls. Provide either tokenId or tokenIds, not both.

Result Schema

FieldTypeRequiredDescription
marketstringNoMarket condition ID
assetIdstringNoToken/asset ID
timestampstringNoOrder book timestamp
bidsarrayNoBid orders sorted ascending by price
asksarrayNoAsk orders sorted descending by price
bestBidnumber | nullNoBest (highest) bid price, null if no bids
bestAsknumber | nullNoBest (lowest) ask price, null if no asks
spreadnumber | nullNoSpread between best bid and ask, null if either side is empty
bidCountnumberNoNumber of bid levels
askCountnumberNoNumber of ask levels
minOrderSizenumberNoMinimum order size
tickSizenumberNoTick size for the market
negRiskbooleanNoWhether this is a neg-risk market
lastTradePricenumberNoLast trade price
orderbooksarrayNoArray of order book results when using batch mode (tokenIds input)

Examples

json
{ "type": "polymarket-get-orderbook", "payload": { "tokenId": "1", "tokenIds": "1" }, "children": []}

Payload fields can use workflow expressions such as {{$trigger.body.amount}}, {{$nodes.fetch.result.price}}, and {{$props.asset}} when the value should come from a trigger, prior node, or reusable workflow prop.