I have a query regarding the carryForwardBuyValue and carryForwardSellValue columns coming from self.get_positions() api request. In the following example, I have 1 lot BN option carried forward. e.g. for first position, costPrice was 774.55 and quantity is 15 thus the carryForwardBuyValue should be 15*774.55 = 11618.25 which is not matching with carryForwardBuyValue.
Over here, costPrice is your actual Buy Price or Sell Price of the instrument. When it comes to carry forward positions, the system also maintains Mark-to-Market prices, which is displayed as buyAvg and sellAvg in the API response.
carryForwardBuyValue and carryForwardSellValue is computed as: