Why market order is not allowed for sensex from API?
Can you let us know the complete trading symbol of the Sensex contract? Margin policy of contracts can change in the intraday as per the requirement from the RMS. This documentation explains more.
Market orders are now allowed for all index F&O contracts (Sensex, Midcpnifty and Finnifty) if the OI of the contract is more than 500 lots. Market orders will be automatically enabled as soon as the OI increase for liquid contracts on the expiry days.
Based on the above criteria, we recently started allowing market orders for all index F&O contracts. You might be looking at a strike which doesn't match this criteria
No @themohammedfaisal .. Today around 1PM I put sell order for Sensex 18th Aug 65200 CE.. but API did not allow market order. It threw KiteInputexception (Java). Same I triggered LIMIT order it got placed.
@mailboxofrafiq could you create a ticket and DM the ticket number. We could check what went happened here. This rule doesn't discriminate based on where the source of the order was.
I looked at your order logs. for the order where you got the Kite input exception, you had passed exchange as 'NFO' for a Sensex order, I have DM'ed you the log. No issue from our end.
Thanks @themohammedfaisal I fixed in my code.. However I would recommend you to throw an appropriate error message 'like incorrect exchange" so that we will know what is the issue clearly.
Margin policy of contracts can change in the intraday as per the requirement from the RMS. This documentation explains more.
No issue from our end.