Orderbook
A point-in-time order book.
import type { Orderbook } from "@symmio/trading-core";Fields
marketNamestringMarket name as SYMMIO names it.
bidsOrderbookLevel[]Resting buy orders, best (highest) price first.
asksOrderbookLevel[]Resting sell orders, best (lowest) price first.
lastUpdateIdnumberVenue sequence number this book is synchronized to. Monotonic per market — two books for the same market can be compared to tell which is newer. Meaningless across markets or across sources.
timestampnumberWhen the venue produced this book, unix ms. 0 when the venue omits it, which spot depth does.
Both sides are de-duplicated by price and carry no zero-size levels.
OrderbookLevel
pricenumberLimit price, quote-asset denominated.
sizenumberResting quantity at this price, base-asset denominated. The notional at this level is price * size.
OrderbookDepthLevel
Produced by accumulateOrderbook. Extends OrderbookLevel with:
totalnumberCumulative base-asset size from the best price through this level, inclusive.
totalQuotenumberCumulative notional through this level, inclusive.
Related
OrderbookSource— where a book comes from.getOrderbook— fetch one.