Skip to main content

取得批次委託明細

batch_order_detail

輸入參數

參數類別說明
accountAccount帳號
batch_order_listBatchResult批次委託列表

Result 回傳

參數類別說明
is_successbool是否成功
dataList回傳委託資訊
messagestring當is_success = false 回傳錯誤訊息

委託資訊 FutOptOrderResult 欄位

Return type : Object

參數類別說明
function_typeint (Optional)功能別 : 0 新單 、10 新單執行、 15 改價、 20 改量、30刪單 、90失敗
datestring交易日期
seq_nostring委託單流水序號
branch_nostring分公司代號
accountstring帳號
order_nostring委託書號
asset_typeint資產類別 : 1 期貨 、2 選擇權
marketstring市場類型 : TAIMEX 期貨、選擇權
market_typeFutOptMarketType盤別種類 : Future 期貨日盤 、 Option 選擇權日盤 、 FutureNight 期貨夜盤 、 OptionNight 選擇權夜盤
unitint單位數
currencystring幣別
symbolstring商品代號
expiry_datestring到期日
strike_pricefloat履約價
call_putCallPut買賣權 : Call 買權、 Put 賣權
buy_sellBSAction買賣別 : Buy 買 、 Sell
symbol_leg2string商品代號 - 複式第二隻腳
expiry_date_leg2string到期日 - 複式第二隻腳
strike_price_leg2float履約價 - 複式第二隻腳
call_put_leg2CallPut買賣權 - 複式第二隻腳 : Call 買權、 Put 賣權
buy_sell_leg2BSAction買賣別 - 複式第二隻腳: Buy 買 、 Sell
price_typeFutOptPriceType原始委託價格別 : Limit 限價 、 Market 市價 、 RangeMarket 範圍市價、Reference 參考價
pricefloat價格
lotint原始委託股口數
time_in_forceTimeInforce委託條件別 : ROD ROD 、 FOK FOK 、 IOC IOC
order_typeFutOptOrderType委託單類型 : New 新倉 、 Close 平倉 、 Auto 自動 、 FdayTrade 當沖
is_pre_orderbool是否為預約單
statusint委託單狀態 : 0 預約單 、 4 中台收到委託 、 8 後台傳送中 、 9 後台連線逾時 、10 委託成功 、 30刪單成功 、 50 完全成交 、 90 失敗
after_price_typeFutOptPriceType有效委託價格別 : Limit 限價 、 Market 市價 、RangeMarket 範圍市價、 Reference 參考價
after_pricefloat有效委託價格
after_lotint有效委託口數
filled_lotint成交口數
filled_moneyfloat成交價金
before_lotint改單前有效口數
before_pricefloat改單前有效價
user_defstring自訂欄位
last_timestring最後異動時間
detaillist委託歷程 (查詢order_result_detail or order_history才有值)
error_messagestring錯誤訊息
caution

此功能僅供查詢批次送單執行結果,欲取得委託單最新狀態請使用單筆委託單查詢功能

請求範例

batch_results = sdk.futopt.batch_order_lists(account)
sdk.futopt.batch_order_detail(account, batch_results.data[0])

回傳範例

Result {
is_success: True,
message: None,
data : [FutOptOrderResult {
date: "2024/04/11", # 交易日期 (string)
seq_no: "00230177314", # 委託單流水序號 (string)
branch_no: "15000", # 分公司代號 (string)
account: "9974825", # 帳號 (string)
order_no: "C0020", # 委託書號 (string)
asset_type: 2, # 資產類別 : `1` 期貨 、`2` 選擇權 (int)
market: "TAIMEX", # 市場類型 : `TAIMEX` 期貨、選擇權 (string)
market_type: Option, # 盤別種類 : `Future` 期貨日盤 、 `Option` 選擇權日盤 、 `FutureNight` 期貨夜盤 、 `OptionNight` 選擇權夜盤 (MarketType)
unit: None, # 單位數 (int)
currency: None, # 幣別 (string)
symbol: "TXO", # 商品代號 (string)
expiry_date: "202404", # 到期日 (string)
strike_price: 18600, # 履約價 (float)
call_put: Call, # 買賣權 : `Call` 買權、 `Put` 賣權 (string)
buy_sell: Buy, # 買賣別 : `Buy` 買 、 `Sell` 賣 (BSAction)
symbol_leg2: None, # 商品代號 - 複式第二隻腳 (string)
expiry_date_leg2: None, # 到期日 - 複式第二隻腳 (string)
strike_price_leg2: None, # 履約價 - 複式第二隻腳 (float)
call_put_leg2: None, # 買賣權 - 複式第二隻腳 : `Call` 買權、 `Put` 賣權 (string)
buy_sell_leg2: None, # 買賣別 - 複式第二隻腳: `Buy` 買 、 `Sell` 賣 (BSAction)
price_type: Limit, # 原始委託價格別 : `Limit` 限價 、 `Market` 市價 、 `RangeMarket` 範圍市價、`Reference` 參考價 (PriceType)
price: 2100, # 價格 (float)
lot: 1, # 原始委託股口數 (int)
time_in_force: ROD, # 委託條件別 : `ROD` ROD 、 `FOK` FOK 、 `IOC` IOC (TimeInforce)
order_type: New, # 委託單類型 : `New` 新倉 、 `Close` 平倉 、 `Auto` 自動 、 `FdayTrade` 當沖 (OrderType)
is_pre_order: False, # 是否為預約單 (bool)
status: 50, # 委託單狀態 : `0` 預約單 、 `4` 中台收到委託 、`9` 後台連線逾時 、`10` 委託成功 、 `30`刪單成功 、 `50` 完全成交 、 `90` 失敗 (int)
after_price_type: None, # 有效委託價格別 : `Limit` 限價 、 `Market` 市價 、`RangeMarket` 範圍市價、 `Reference` 參考價 (PriceType)
after_price: 2100, # 有效委託價格 (float)
after_lot: 1, # 有效委託口數 (int)
filled_lot: 1, # 成交口數 (int)
filled_money: 2100, # 成交價金 (float)
before_lot: None, # 改單前有效口數 (int)
before_price: None, # 改單前有效價 (float)
user_def: None, # 自訂欄位 (string)
last_time: "10:41:46.760", # 最後異動時間 (string)
details: None, # 委託歷程 (list)
error_message: None # 錯誤訊息 (string)
},
FutOptOrderResult {
date: "2024/04/11", # 交易日期 (string)
seq_no: "00230177315", # 委託單流水序號 (string)
branch_no: "15000", # 分公司代號 (string)
account: "9974825", # 帳號 (string)
order_no: "C0021", # 委託書號 (string)
asset_type: 2, # 資產類別 : `1` 期貨 、`2` 選擇權 (int)
market: "TAIMEX", # 市場類型 : `TAIMEX` 期貨、選擇權 (string)
market_type: Option, # 盤別種類 : `Future` 期貨日盤 、 `Option` 選擇權日盤 、 `FutureNight` 期貨夜盤 、 `OptionNight` 選擇權夜盤 (MarketType)
unit: None, # 單位數 (int)
currency: None, # 幣別 (string)
symbol: "TXO", # 商品代號 (string)
expiry_date: "202404", # 到期日 (string)
strike_price: 18500, # 履約價 (float)
call_put: Call, # 買賣權 : `Call` 買權、 `Put` 賣權 (string)
buy_sell: Sell, # 買賣別 : `Buy` 買 、 `Sell` 賣 (BSAction)
symbol_leg2: None, # 商品代號 - 複式第二隻腳 (string)
expiry_date_leg2: None, # 到期日 - 複式第二隻腳 (string)
strike_price_leg2: None, # 履約價 - 複式第二隻腳 (float)
call_put_leg2: None, # 買賣權 - 複式第二隻腳 : `Call` 買權、 `Put` 賣權 (string)
buy_sell_leg2: None, # 買賣別 - 複式第二隻腳: `Buy` 買 、 `Sell` 賣 (BSAction)
price_type: Limit, # 原始委託價格別 : `Limit` 限價 、 `Market` 市價 、 `RangeMarket` 範圍市價、`Reference` 參考價 (PriceType)
price: 2230, # 價格 (float)
lot: 1, # 原始委託股口數 (int)
time_in_force: ROD, # 委託條件別 : `ROD` ROD 、 `FOK` FOK 、 `IOC` IOC (TimeInforce)
order_type: New, # 委託單類型 : `New` 新倉 、 `Close` 平倉 、 `Auto` 自動 、 `FdayTrade` 當沖 (OrderType)
is_pre_order: False, # 是否為預約單 (bool)
status: 50, # 委託單狀態 : `0` 預約單 、 `4` 中台收到委託 、`9` 後台連線逾時 、`10` 委託成功 、 `30`刪單成功 、 `50` 完全成交 、 `90` 失敗 (int)
after_price_type: None, # 有效委託價格別 : `Limit` 限價 、 `Market` 市價 、`RangeMarket` 範圍市價、 `Reference` 參考價 (PriceType)
after_price: 2230, # 有效委託價格 (float)
after_lot: 1, # 有效委託口數 (int)
filled_lot: 1, # 成交口數 (int)
filled_money: 2230, # 成交價金 (float)
before_lot: None, # 改單前有效口數 (int)
before_price: None, # 改單前有效價 (float)
user_def: None, # 自訂欄位 (string)
last_time: "10:41:46.760", # 最後異動時間 (string)
error_message: None # 錯誤訊息 (string)
}]}