Realized P&L (Detail)
realizedGainsAndLoses
Input Parameters
| Parameter | Type | Meaning |
|---|---|---|
| account | Account | Account |
Result
| Parameter | Type | Meaning |
|---|---|---|
| isSuccess | bool | Whether successful |
| data | Object | Realized list is returned |
| message | string ? (optional) | Error message returned when isSuccess = false |
Realized Parameter
Return type : Object
| Parameter | Type | Meaning |
|---|---|---|
| date | string | Data date |
| branchNo | string | Branch number |
| account | string | Account |
| stockNo | string | Symbol |
| buySell | js:string / ts:BSAction | Buy/Sell Type : Buy, Sell |
| filledQty | number | Filled Quantity |
| filledPrice | number | Filled Price |
| orderType | js:string / ts:OrderType | Order Type : Stock, Margin, Short Short sale, DayTrade, SBL Securities borrowing and lending |
| realizedProfit | number | Realized profit |
| realizedLoss | number | Realized loss |
Request Example
sdk.accounting.realizedGainsAndLoses(account);
Response Example
{
isSuccess: true,
data:[
{
date: '2023/08/29',
branchNo: '6460',
account: '26',
stockNo: '1101',
buySell: Sell,
filledQty: 1000,
filledPrice: 35.3,
orderType: 0,
realizedProfit: 0,
realizedLoss: 906
},
...
]
}