Issue: When I am trying to fetch margin required for a basket combination using basket_order_margins API, I observe that margin returned is inaccurate beyond 920AM and only for an expiry contract. I say inaccurate on the basis of margin shown for the same combination in kite console.
Pasting the relevant code used to fetch margin and the margin returned. Tested yesterday on BN contract(expiry) around 945AM
When checked the same in kite, margin is around 1.2lac. Refer Screenshot.
please look into this.
When I probed further into the contents of response, I observed that 'span_margin' is fixed at the same value for any combination of basket around the time and beyond. Whereas I see it different for different combinations when checked before 920AM or when checked for an non-expiry contract anytime during the day.