Skip to main content

交割款查詢

querySettlement

輸入參數

參數類別說明
accountAccount帳號
rangestring時間區間,目前有效值為"0d"(當日)、"3d"

Result 回傳

參數類別說明
isSuccessbool是否成功
dataObject回傳交割款資訊
messagestring ? (optional)當isSuccess = false 回傳錯誤訊息

交割款 SettlementData 欄位

Return type : Object

參數類別說明
> AccountReslistObject
>> accountstring帳號
>> branchNostring分公司代號
> detailslistObject
>> datestring查詢日
>> settlementDatestring?交割日
>> buyValueint?買進金額
>> buyFeeint?買進手續費
>> buySettlementint?買進應收付款
>> buyTaxint?買進交易稅
>> sellValueint?賣出金額
>> sellFeeint?賣出手續費
>> sellSettlementint?賣出應收付款
>> sellTaxint?賣出交易稅
>> totalBsValueint?合計買賣金額
>> totalFeeint?合計手續費
>> totalTaxint?合計交易稅
>> totalSettlementAmountint?合計交割金額
>> currencystring?幣別

請求範例

sdk.accounting.querySettlement(target_user,"3d");

回傳範例

{
isSuccess: true,
data:{
account: { branchNo: '6460', account: '26' },
details:[
{
date: "2024/03/04",
settlementDate: "2024/03/06",
buyValue: 735500,
buyFee: 313,
buySettlement: -1429513,
buyTax: 0,
sellValue: 770500,
sellFee: 320,
sellSettlement: 0,
sellTax: 2309,
totalBsValue: 1506000,
totalFee: 633,
totalSettlementAmount: -1429513,
totalTax: 2309,
currency: "TWD"
},
{
date: "2024/03/05",
settlementDate: "2024/03/07",
buyValue: 2261470,
buyFee: 1065,
buySettlement: -3895335,
buyTax: 0,
sellValue: 2488170,
sellFee: 1137,
sellSettlement: 677626,
sellTax: 7412,
totalBsValue: 4749640,
totalFee: 2202,
totalSettlementAmount: -3217709,
totalTax: 7412,
currency: "TWD"
},
{
date: "2024/03/06"
}
]
}
}