Skip to content

stock_snapshot_quote

Latest NBBO (National Best Bid and Offer) quote snapshot for one or more stocks.

FreeValueStandardPro

Code Example

rust
let data = tdx.stock_snapshot_quote(&["SPY", "MSFT", "GOOGL"]).await?;
for t in &data {
    println!("date={} ms_of_day={} bid={:.2} bid_size={} ask={:.2} ask_size={} midpoint={:.2}",
        t.date, t.ms_of_day, t.bid, t.bid_size, t.ask, t.ask_size, t.midpoint);
}
python
data = tdx.stock_snapshot_quote(["SPY", "MSFT", "GOOGL"])
for t in data:
    print(f"date={t.date} ms_of_day={t.ms_of_day} bid={t.bid:.2f} "
          f"bid_size={t.bid_size} ask={t.ask:.2f} ask_size={t.ask_size} midpoint={t.midpoint:.2f}")
typescript
const data = tdx.stockSnapshotQuote(['SPY', 'MSFT', 'GOOGL']);
for (const t of data) {
    console.log(`date=${t.date} ms_of_day=${t.ms_of_day} bid=${t.bid} bid_size=${t.bid_size} ask=${t.ask} ask_size=${t.ask_size}`);
}
cpp
auto data = client.stock_snapshot_quote({"SPY", "MSFT", "GOOGL"});
for (const auto& t : data) {
    printf("date=%d ms_of_day=%d bid=%.2f bid_size=%d ask=%.2f ask_size=%d midpoint=%.2f\n",
        t.date, t.ms_of_day, t.bid, t.bid_size, t.ask, t.ask_size, t.midpoint);
}

Parameters

symbolsstring[]required
One or more ticker symbols
venuestringoptional
Data venue filter
min_timestringoptional
Minimum time of day as milliseconds from midnight ET

Response Fields (QuoteTick)

ms_of_dayi32
Milliseconds since midnight ET
bid_size / ask_sizei32
Quote sizes
bid_exchange / ask_exchangei32
Exchange codes
bid / askf64
Bid/ask prices (decoded at parse time). midpoint is pre-computed.
bid_condition / ask_conditioni32
Condition codes
datei32
Date as YYYYMMDD integer

Sample Response

json
[
  {"date": 20260402, "ms_of_day": 72000220, "bid": 250.30, "bid_size": 51, "ask": 255.38, "ask_size": 201, "midpoint": 252.84},
  {"date": 20260402, "ms_of_day": 72000000, "bid": 655.61, "bid_size": 200, "ask": 656.41, "ask_size": 200, "midpoint": 656.01}
]

Notes

  • Accepts multiple symbols in a single call. Batch requests to reduce round-trips.
  • The NBBO represents the best bid and ask across all exchanges.
  • The midpoint field is pre-computed from bid and ask.

Released under the Apache-2.0 License.