Skip to main content

庫存與未實現損益查詢

inventories

輸入參數

參數類別說明
accountAccount帳號

PositionResponse 欄位

參數類別說明
nostring序號
prev_day_quantitystring昨日庫存股數
current_quantitystring即時庫存股數
today_quantitystring今日增減成交股數
today_buy_quantitystring今日買進成交數量
today_sell_quantitystring今日賣出成交數量
coststring付出成本
market_valuestring現值
unrealized_profit_lossstring未實現損益
unrealized_profit_loss_ratestring未實現損益率
securities_transaction_income_taxstring證券交易所得稅
health_insurance_feestring健保補充費
feestring手續費
taxstring交易稅
open_margin_amountstring未償還融資/券金額
open_guarantee_amountstring未償還融券保證金
open_short_collateralstring未償還擔保品
short_selling_feestring融券手續費
own_funds_amountstring自備款
other_coststring其他費用 ( 除手續費、交易稅外的費用項目 (資/券利息也包含在內) )
intereststring利息
unrealized_net_amountstring預估淨收付
total_profit_lossstring總損益
realized_profit_lossstring當日已實現損益
dividend_amountstring除息金額
account_summaryobject帳戶摘要
└─ margin_position_market_value_sumstring融資市值加總
└─ short_position_market_value_sumstring融券市值加總
└─ short_collateral_sumstring融券擔保品加總
└─ margin_limitstring融資限額
└─ short_limitstring融券限額
└─ guarantee_amount_sumstring擔保金總和
└─ margin_amount_sumstring融資金額總和
└─ short_amount_sumstring融券金額總和
└─ account_maintenance_ratestring帳戶維持率
└─ settlement_todaystring今日交割
└─ settlement_yesterdaystring昨日交割
└─ settlement_netstring淨交割金額
position_summariesarray持倉摘要清單
└─ branch_idstring分公司代號
└─ cust_idstring帳號
└─ nostring序號
└─ symbolstring股票代碼
└─ namestring用戶名
└─ symbol_namestring股票名稱
└─ stock_evaluationstring股票評價
└─ order_typestring交易類型 : 0 整股、1 , 3 融資、2 , 4 融券、9 現賣 ( 擔保品 )
└─ order_type_namestring交易類型名稱
└─ buy_sellstring買賣別 : BS
└─ prev_day_quantitystring昨日庫存股數
└─ current_quantitystring即時庫存股數
└─ total_quantitystring今日交易增減成交股數
└─ total_buy_quantitystring今日買進成交股數
└─ total_sell_quantitystring今日賣出成交股數
└─ coststring成本
└─ cost_before_dividendstring成本 (不扣除息金額)
└─ average_pricestring成交均價
└─ open_margin_amountstring未償還融資金額
└─ guarantee_amountstring保證金
└─ open_guarantee_amountstring未償還融券保證金
└─ short_collateralstring擔保品
└─ open_short_collateralstring未償還擔保品
└─ short_selling_feestring融券手續費
└─ own_funds_amountstring自備款
└─ guarantee_default_amountstring擔保金缺額
└─ current_pricestring現價
└─ market_valuestring市值
└─ unrealized_profit_lossstring未實現損益
└─ unrealized_profit_loss_ratestring未實現損益率
└─ feestring手續費
└─ taxstring稅金
└─ intereststring利息
└─ other_coststring其他費用 ( 除手續費、交易稅外的費用項目 (資/券利息也包含在內) )
└─ unrealized_net_amountstring預估淨收付金額
└─ target_pricestring標的股票現價
└─ portfolio_typestring權證種類 :1 認購權證、2認售權證、3牛證、4熊證、 空白 整股
└─ holding_percentstring持有比率
└─ securities_income_taxstring證券所得稅
└─ health_insurance_feestring健保補充費
└─ reference_pricestring參考價格
└─ total_profitstring總損益
└─ realized_profitstring當日已實現損益
└─ pledge_quantitystring質押數量
└─ amountstring會總成交價金
└─ average_filled_pricestring平均成交價格
└─ break_even_pricestring損益兩平價格
└─ dividend_amountstring股利金額
└─ position_detailsarray持倉明細
  └─ nostring序號
  └─ t_datestring成交日期
  └─ order_typestring交易類型 : 0 整股、1 , 3 融資、2 , 4 融券、9 現賣 ( 擔保品 )
  └─ order_type_namestring訂單類型名稱
  └─ buy_sellstring買賣別 : BS
  └─ delegate_sequencestring委託書號
  └─ filled_nostring成交序號
  └─ filled_quantitystring成交數量
  └─ prev_day_quantitystring昨日庫存股數
  └─ filled_pricestring成交價格
  └─ filled_amountstring成交金額
  └─ current_pricestring現價
  └─ market_valuestring市值
  └─ margin_amountstring融資金額
  └─ open_margin_amountstring未償還融資/券金額
  └─ short_collateralstring融券抵押品
  └─ open_short_collateralstring未償還擔保品
  └─ guarantee_amountstring保證金
  └─ open_guarantee_amountstring未償還融券保證金
  └─ securities_lending_feestring標借費
  └─ short_selling_feestring融券費手續費
  └─ feestring手續費
  └─ taxstring交易稅
  └─ intereststring利息
  └─ coststring收付金額
  └─ cost_before_dividendstring收付金額(不扣除息金額)
  └─ change_typestring異動別
  └─ own_funds_amountstring自備款
  └─ portfolio_typestring權證種類
  └─ cust_idstring帳號
  └─ namestring名稱
  └─ branch_idstring分行 ID
  └─ other_coststring其他費用 ( 除手續費、交易稅外的費用項目 (資/券利息也包含在內) )
  └─ is_adjustablestring是否可調整成本:Y開放、N不開放
  └─ securities_income_taxstring證券所得稅
  └─ health_insurance_feestring健康保險費
  └─ unrealized_profit_lossstring未實現損益
  └─ reference_pricestring參考價格
  └─ io_flagstring異動代碼
  └─ io_namestring異動名稱
  └─ break_even_pricestring損益兩平價格
  └─ dividend_amountstring股利金額
  └─ guarantee_default_amountstring擔保金缺額

請求範例

sdk.accounting.inventories(accounts)

回傳範例

PositionResponse {
no: "合計", # 序號 (string)
prev_day_quantity: "26796", # 昨日庫存股數 (string)
current_quantity: "26796", # 即時庫存股數 (string)
today_quantity: "0", # 今日增減成交股數 (string)
today_buy_quantity: "0", # 今日買進成交數量 (string)
today_sell_quantity: "0", # 今日賣出成交數量 (string)
cost: "348817", # 付出成本 (string)
market_value: "549957", # 現值 (string)
unrealized_profit_loss: "198916", # 未實現損益 (string)
unrealized_profit_loss_rate: "57.03%", # 未實現損益率 (string)
securities_transaction_income_tax: "0", # 證券交易所得稅 (string)
health_insurance_fee: "0", # 健保補充費 (string)
fee: "489", # 手續費 (string)
tax: "0", # 交易稅 (string)
open_margin_amount: "0", # 未償還融資/券金額 (string)
open_guarantee_amount: "0", # 未償還融券保證金 (string)
open_short_collateral: "0", # 未償還擔保品 (string)
short_selling_fee: "0", # 融券手續費 (string)
own_funds_amount: "0", # 自備款 (string)
other_cost: "0", # 其他費用 (string)
interest: "0", # 利息 (string)
unrealized_net_amount: "547733", # 預估淨收付 (string)
total_profit_loss: "198916.00", # 總損益 (string)
realized_profit_loss: "0", # 當日已實現損益 (string)
dividend_amount: "360.00", # 除息金額 (string)
account_summary: AccountSummary {
margin_position_market_value_sum: "0", # 融資市值加總 (string)
short_position_market_value_sum: "0", # 融券市值加總 (string)
short_collateral_sum: "0", # 融券擔保品加總 (string)
margin_limit: "0", # 融資限額 (string)
short_limit: "0", # 融券限額 (string)
guarantee_amount_sum: "0", # 擔保金總和 (string)
margin_amount_sum: "0", # 融資金額總和 (string)
short_amount_sum: "0", # 融券金額總和 (string)
account_maintenance_rate: "0%", # 帳戶維持率 (string)
settlement_today: "0", # 今日交割 (string)
settlement_yesterday: "0", # 昨日交割 (string)
settlement_net: "0", # 淨交割金額 (string)
},
position_summaries: [
PositionSummary {
branch_id: "5920", # 分公司代號 (string)
cust_id: "1234567", # 帳號 (string)
no: "1", # 序號 (string)
symbol: "00885", # 股票代碼 (string)
name: "許OO", # 用戶名 (string)
symbol_name: "富邦越南", # 股票名稱 (string)
stock_evaluation: "", # 股票評價 (string)
order_type: "0", # 交易類型 (string)
order_type_name: "現買", # 交易類型名稱 (string)
buy_sell: "B", # 買賣別 (string)
prev_day_quantity: "1000", # 昨日庫存股數 (string)
current_quantity: "1000", # 即時庫存股數 (string)
total_quantity: "0", # 今日交易增減成交股數 (string)
total_buy_quantity: "0", # 今日買進成交股數 (string)
total_sell_quantity: "0", # 今日賣出成交股數 (string)
cost: "16173", # 成本 (string)
cost_before_dividend: "16173.00", # 成本 (不扣除息金額) (string)
average_price: "16.17", # 成交均價 (string)
open_margin_amount: "0", # 未償還融資金額 (string)
guarantee_amount: "0", # 保證金 (string)
open_guarantee_amount: "0", # 未償還融券保證金 (string)
short_collateral: "0", # 擔保品 (string)
open_short_collateral: "0", # 未償還擔保品 (string)
short_selling_fee: "0", # 融券手續費 (string)
own_funds_amount: "0", # 自備款 (string)
guarantee_default_amount: "0", # 擔保金缺額 (string)
current_price: "11.7", # 現價 (string)
market_value: "11700", # 市值 (string)
unrealized_profit: None, # 未實現損益 (None)
unrealized_profit_loss_rate: "-27.85%", # 未實現損益率 (string)
fee: "23", # 手續費 (string)
tax: "0", # 稅金 (string)
interest: "0", # 利息 (string)
other_cost: "0", # 其他成本 (string)
unrealized_net_amount: "11669", # 預估淨收付金額 (string)
target_price: "0", # 標的股票現價 (string)
portfolio_type: "", # 權證種類 (string)
holding_percent: "2.13%", # 持有比率 (string)
securities_income_tax: "0", # 證券所得稅 (string)
health_insurance_fee: "0", # 健保補充費 (string)
reference_price: "0", # 參考價格 (string)
total_profit: "-4504.00", # 總損益 (string)
realized_profit: "0", # 當日已實現損益 (string)
pledge_quantity: "1000", # 質押數量 (string)
amount: "16150.00", # 會總成交價金 (string)
average_filled_price: "16.15", # 平均成交價格 (string)
break_even_price: "16.22", # 損益兩平價格 (string)
dividend_amount: "0", # 股利金額 (string)
position_details: [
PositionDetail {
no: "1", # 序號 (string)
t_date: "20210419", # 成交日期 (string)
order_type: "0", # 交易類型 (string)
order_type_name: "現買", # 訂單類型名稱 (string)
buy_sell: "B", # 買賣別 (string)
delegate_sequence: "i0317", # 委託書號 (string)
filled_no: "0000001", # 成交序號 (string)
filled_quantity: "1000", # 成交數量 (string)
prev_day_quantity: "1000", # 昨日庫存股數 (string)
filled_price: "16.15", # 成交價格 (string)
filled_amount: "16150.00", # 成交金額 (string)
current_price: "11.7", # 現價 (string)
market_value: "11700", # 市值 (string)
margin_amount: "0", # 融資金額 (string)
open_margin_amount: "0", # 未償還融資/券金額 (string)
short_collateral: "0", # 融券抵押品 (string)
open_short_collateral: "0", # 未償還擔保品 (string)
guarantee_amount: "0", # 保證金 (string)
open_guarantee_amount: "0", # 未償還融券保證金 (string)
securities_lending_fee: "0",# 標借費 (string)
short_selling_fee: "0", # 融券費手續費 (string)
fee: "23", # 手續費 (string)
tax: "0", # 交易稅 (string)
interest: "0", # 利息 (string)
cost: "16173", # 收付金額 (string)
cost_before_dividend: "16173", # 收付金額(不扣除息金額) (string)
change_type: "0", # 異動別 (string)
own_funds_amount: "0", # 自備款 (string)
portfolio_type: "", # 權證種類 (string)
cust_sequence: "1234567", # 帳號序號 (string)
name: "許OO", # 名稱 (string)
branch_id: "5920", # 分行 ID (string)
other_cost: "0", # 其他成本 (string)
is_adjusted: None, # 是否可調整 (None)
securities_income_tax: "0", # 證券所得稅 (string)
health_insurance_fee: "0", # 健康保險費 (string)
unrealized_profit_loss: "-4504", # 未實現損益 (string)
unrealized_profit_loss_rate: None, # 未實現損益率 (None)
reference_price: "0", # 參考價格 (string)
io_flag: "", # 異動代碼 (string)
io_name: "", # 異動名稱 (string)
break_even_price: "16.22", # 損益兩平價格 (string)
dividend_amount: "0", # 股利金額 (string)
guarantee_default_amount: "0" # 擔保金缺額 (string)
},
],
},
...
]
}