Skip to main content

Query Stock Quote Information (Batch)

query_symbol_snapshot

info

For version >=2.2.5

tip

This feature is for querying product information such as daily upper and lower price limits and does not include real-time quote updates.

Input Parameters

ParameterAccountDescription
accountAccountAccount
market_typeMarketType (Optional)(default = Common)Market type: supports Common (regular lot), IntradayOdd (odd lot during trading hours), Fixing (closing auction)
stock_typesList StockType (Optional)(default = Stock)Product category: Stock (stocks), ConvertBond (convertible bonds), ETF_and_ETN (ETFs and ETNs)

Result

ParameterTypeDescription
isSuccessboolWhether the request was successful
dataList[SymbolQuote]Returned quote information
messagestringError message when isSuccess = false

Symbol Information (SymbolQuote Fields)

Return type : Object

ParameterTypeDescription
marketstrMarkets
symbolstrSymbol
istib_or_psbboolWhether it is TIB or PSB board
market_typestrMarket type
statusintStatus (bitmask sum) 0 :All forbidden, 1:Exempted from margin short selling price constraint,2: Exempted from SBL short selling price constraint, 4: Available sale after buy day trading, 8: Available buy after sale day trading
reference_pricefloatReference price
unitintTrading unit
update_timestrUpdate time
limitup_pricefloatUpper price limit
limitdown_pricefloatLower price limit
open_pricefloatOpening price
high_pricefloatHighest price
low_pricefloatLowest price
last_pricefloatLatest traded price
total_volumeintTotal traded volume
total_transactionintTotal number of trades (Reserved field, not currently in use)
total_valueintTotal traded value
last_sizeintLatest traded volume
last_transactionintLatest number of trades (Reserved field, not currently in use)
last_valueintLatest traded value
bid_pricefloatBest bid price
bid_volumeintBest bid volume
ask_pricefloatBest ask price
ask_volumeintBest ask volume
Supported Products

TAIEX and TAISDAQ securities

info

Status example: status 15 means all four capabilities are enabled (1 + 2 + 4 + 8). Status 12 means buy-first and sell-first day trading are enabled (4 + 8).

Request Example

from fubon_neo.constant import StockType

sdk.stock.query_symbol_snapshot(accounts.data[0]) #Default
sdk.stock.query_symbol_snapshot(accounts.data[0], MarketType.Common, [StockType.Stock])

Response Example

Result {
is_success: True,
message: None,
data: [ SymbolQuote {
market: "TAIEX", # str - Market
symbol: "2330", # str - Symbol
istib_or_psb: False, # bool - Whether it is TIB or PSB board
market_type: "IntradayOdd", # str - Market type
status: 1, # int - Status (bitmask sum)
reference_price: 780, # float - Reference price
unit: 1, # int - Trading Unit
update_time: "09:09:55.741", # str - Update time
limitup_price: 858, # float - Upper price limit
limitdown_price: 702, # float - Lower price limit
open_price: None, # float | None - Opening price
high_price: None, # float | None - Highest price
low_price: None, # float | None - Lowest price
last_price: None, # float | None - Latest traded price
total_volume: None, # int | None - Total traded volume
total_transaction: 0, # int - Total number of trades (Reserved field, not currently in use)
total_value: None, # float | None - Total traded value
last_size: None, # int | None - Latest traded volume
last_transaction: 0, # int - Latest number of trades (Reserved field, not currently in use)
last_value: 0, # int - Latest traded value
bid_price: 1140, # float - Best bid price
bid_volume: 47975, # int - Best bid volume
ask_price: 1145, # float - Best ask price
ask_volume: 23024, # int - Best ask volume
},
SymbolQuote{
market: "TAIEX", # str - Market
...
},
...
]
}