Skip to main content

平倉查詢

close_position_record

輸入參數

參數類別說明
accountAccount帳號
start_datestring查詢起日
end_datestring查詢迄日

Result 回傳

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

已實現彙總 CloseRecord 欄位

Return type : Object

參數類別說明
datestring資料日期
branch_nostring分公司代號
position_kindint部位種類 : 1 期貨 、2 選擇權
accountstring帳號
order_nostring委託書號
marketstring市場別 : TAIMEX 期貨、選擇權
symbolstring商品代號
expiry_datestring履約日
strike_pricefloat履約價
call_putCallPut權利別 : Call Call 、Put Put
buy_sellBSAction買賣別 : Buy 買、Sell
order_typeFutOptOrderType委託單類型 : New 新倉 、 Close 平倉 、 Auto 自動 、 FdayTrade 當沖
pricefloat成交價
orig_lotsint原始口數
transaction_feefloat交易手續費
taxfloat交易稅

請求範例

sdk.futopt_accounting.close_position_record(accounts,"20240310","20240410")

回傳範例

Result {
is_success: True,
message: None,
data : [
CloseRecord {
date: "2024/04/10", # 資料日期(string)
branch_no: "15000", # 分公司代號(string)
account: "9974825", # 帳號 (string)
position_kind: 1, # 部位種類: `1` 期貨, `2` 選擇權 (int)
order_no: "15001-0000", # 委託書號 (string)
market: "TAIMEX", # 市場別 : `TAIMEX` (string)
symbol: "FITX", # 商品代號 (string)
expiry_date: "202404", # 履約日 (string)
strike_price: None, # 履約價 (float)
call_put: None, # Call/Put Type : `Call` Call, `Put` Put (CallPut)
buy_sell: Buy, # Buy/Sell Type : `Buy`, `Sell` (BSAction)
price: 20847.0, # 成交價 (float)
orig_lots: 1, # 原始口數 (int)
transaction_fee: 40.0, # 交易手續費 (float)
tax: 83.0, # 交易稅 (float)
},
CloseRecord {
date: "2024/04/10", # 資料日期 (string)
branch_no: "15000", # 分公司代號 (string)
account: "9974825", # 帳號 (string)
position_kind: 1, # 部位種類d : `1` 期貨, `2` 選擇權 (int)
order_no: "C0005-0000", # 委託書號 (string)
market: "TAIMEX", # 市場別 : `TAIMEX` 期貨, 選擇權 (string)
symbol: "FITX", # 商品代號 (string)
expiry_date: "202405", # 履約日 (string)
strike_price: None, # 履約價 (float)
call_put: None, # Call/Put Type : `Call` Call, `Put` Put (CallPut)
buy_sell: Buy, # Buy/Sell Type : `Buy`, `Sell` (BSAction)
price: 20890.0, # 成交價 (float)
orig_lots: 1, # 原始口數 (int)
transaction_fee: 40.0, # 交易手續費 (float)
tax: 84.0, # 交易稅 (float)
}
]
}