Book
Resting limit orders in the order book for the active symbol. The script re-runs on every book update while running.
book.bid / book.ask
Two arrays of price levels, best-first.
book.bid[0]/book.ask[0]are best bid / best ask.priceis a real price.sizeis resting quantity at that level.- Zero-size levels are removed.
API
book.bid // BookLevel[] - resting buy orders, highest price first
book.ask // BookLevel[] - resting sell orders, lowest price first
interface BookLevel { price: number; size: number }