Tried placing an Order with code - order_id = kite.place_order(variety= 'REGULAR', exchange=kite.EXCHANGE_NFO, tradingsymbol="NFO:NIFTY18JUNFUT", transaction_type=kite.TRANSACTION_TYPE_BUY, quantity=75, product=kite.PRODUCT_MIS, order_type=kite.ORDER_TYPE_SL, price=10605, validity='DAY', trigger_price=10600, ) Order ID is received but the Order gets rejected with an Error -RMS:Field Not Found 63002
Correct Trading Symbol NIFTY18JUNFUT is used in the Command.
In fact I have noticed an anomaly as can be seen from the previous command which got rejected and the following code which actually placed an SL Order. Both orders use the same Trading Symbol.
What I have observed is that SL order which requires Two Parameters Trigger_Price and Price gets successfully placed when ONLY THE Trigger_Price is given in the Place order function and Gets rejected when BOTH Trigger_Price and Price parameters are used. I checked in the Orders Tab in the account and found that SL order has been placed but Only the Trigger Price FIeld was filled and Price FIeld was absent.
I am unable to understand. I regularly place SL orders for Manual Trades (For BUY ABOVE a price giving Trigger and Price both values). Want to automate the same trading style using APIs. API function rejects the order when Both required parameters are given but accepts when Only one Parameter (trigger) is given.
There is no issue here when required parameters for the SL order have all been given. But it was observed that SL order gets placed even if the PRICE parameter is set to NONE as can be seen from below code ... I don't know whether this can be treated as an issue. this is like placing an SLM order...
@sujith : Was this looked into yet? To summarize the issue, a SL order placed without the "price" input degenerates into a SL-M order. Is this expected behavior? Thanks.
In fact I have noticed an anomaly as can be seen from the previous command which got rejected and the following code which actually placed an SL Order. Both orders use the same Trading Symbol.
>>> order_id=kite.place_order(variety='regular', exchange='NFO', tradingsymbol='NIFTY18JUNFUT',
transaction_type='BUY', quantity='75', product='NRML', order_type='SL', disclosed_quantity=None, trigger_price='10625', squareoff=None, stoploss=None, trailing_stoploss=None, tag=None)
>>> order_id
'180605001938705'
What I have observed is that SL order which requires Two Parameters Trigger_Price and Price gets successfully placed when ONLY THE Trigger_Price is given in the Place order function and Gets rejected when BOTH Trigger_Price and Price parameters are used. I checked in the Orders Tab in the account and found that SL order has been placed but Only the Trigger Price FIeld was filled and Price FIeld was absent.
I am unable to understand. I regularly place SL orders for Manual Trades (For BUY ABOVE a price giving Trigger and Price both values). Want to automate the same trading style using APIs.
API function rejects the order when Both required parameters are given but accepts when Only one Parameter (trigger) is given.
Request Guidance..
>>> order_id=kite.place_order(variety='regular', exchange='NFO', tradingsymbol='NIFTY18JUNFUT',
transaction_type='BUY', quantity='75', product='MIS', order_type='SL', disclosed_quantity=None, trigger_price='10850', price='10855', squareoff=None, stoploss=None, trailing_stoploss=None, tag=None)
>>> order_id
'180607000876987'
>>> order_list = kite.order_history(order_id=order_id)
>>> order_list
[{'placed_by': 'xxx', 'order_id': '180607000876987', 'exchange_order_id': None, 'parent_order_id': None, 'status': 'PUT ORDER REQ RECEIVED', 'status_message': None, 'order_timestamp': datetime.datetime(2018, 6, 7, 10, 56, 57), 'exchange_update_timestamp': None, 'exchange_timestamp': None, 'variety': 'regular', 'exchange': 'NFO', 'tradingsymbol': 'NIFTY18JUNFUT', 'instrument_token': 2, 'order_type': 'SL', 'transaction_type': 'BUY', 'validity': 'DAY', 'product': 'MIS', 'quantity': 75, 'disclosed_quantity': 0, 'price': 10855, 'trigger_price': 10850, 'average_price': 0, 'filled_quantity': 0, 'pending_quantity': 75, 'cancelled_quantity': 0, 'market_protection': 0, 'tag': None, 'guid': 'LmDCannUkvu7O51G'}, {'placed_by': 'xxx', 'order_id': '180607000876987', 'exchange_order_id': None, 'parent_order_id': None, 'status': 'VALIDATION PENDING', 'status_message': None, 'order_timestamp': datetime.datetime(2018, 6, 7, 10, 56, 57), 'exchange_update_timestamp': None, 'exchange_timestamp': None, 'variety': 'regular', 'exchange': 'NFO', 'tradingsymbol': 'NIFTY18JUNFUT', 'instrument_token': 12374274, 'order_type': 'SL', 'transaction_type': 'BUY', 'validity': 'DAY', 'product': 'MIS', 'quantity': 75, 'disclosed_quantity': 0, 'price': 10855, 'trigger_price': 10850, 'average_price': 0, 'filled_quantity': 0, 'pending_quantity': 75, 'cancelled_quantity': 0, 'market_protection': 0, 'tag': None, 'guid': 'LmDCannUkvu7O51G'}, {'placed_by': 'xxx', 'order_id': '180607000876987', 'exchange_order_id': None, 'parent_order_id': None, 'status': 'OPEN PENDING', 'status_message': None, 'order_timestamp': datetime.datetime(2018, 6, 7, 10, 56, 57), 'exchange_update_timestamp': None, 'exchange_timestamp': None, 'variety': 'regular', 'exchange': 'NFO', 'tradingsymbol': 'NIFTY18JUNFUT', 'instrument_token': 12374274, 'order_type': 'SL', 'transaction_type': 'BUY', 'validity': 'DAY', 'product': 'MIS', 'quantity': 75, 'disclosed_quantity': 0, 'price': 10855, 'trigger_price': 10850, 'average_price': 0, 'filled_quantity': 0, 'pending_quantity': 75, 'cancelled_quantity': 0, 'market_protection': 0, 'tag': None, 'guid': 'LmDCannUkvu7O51G'}, {'placed_by': 'xxxx', 'order_id': '180607000876987', 'exchange_order_id': '1100000000255085', 'parent_order_id': None, 'status': 'TRIGGER PENDING', 'status_message': None, 'order_timestamp': datetime.datetime(2018, 6, 7, 10, 56, 57), 'exchange_update_timestamp': None, 'exchange_timestamp': datetime.datetime(2018, 6, 7, 10, 56, 57), 'variety': 'regular', 'exchange': 'NFO', 'tradingsymbol': 'NIFTY18JUNFUT', 'instrument_token': 12374274, 'order_type': 'SL', 'transaction_type': 'BUY', 'validity': 'DAY', 'product': 'MIS', 'quantity': 75, 'disclosed_quantity': 0, 'price': 10855, 'trigger_price': 10850, 'average_price': 0, 'filled_quantity': 0, 'pending_quantity': 75, 'cancelled_quantity': 0, 'market_protection': 0, 'tag': None, 'guid': 'LmDCannUkvu7O51G'}]
>>>
But it was observed that SL order gets placed even if the PRICE parameter is set to NONE as can be seen from below code ...
I don't know whether this can be treated as an issue.
this is like placing an SLM order...
>>> order_id=kite.place_order(variety='regular', exchange='NFO', tradingsymbol='NIFTY18JUNFUT',
transaction_type='BUY', quantity='75', product='MIS', order_type='SL', disclosed_quantity=None, trigger_price='10850', price=None, squareoff=None, stoploss=None, trailing_stoploss=None, tag=None)
>>> order_id
'180607000821841'
>>> order_list = kite.order_history(order_id=order_id)
>>> order_list
[{'placed_by': 'xxx', 'order_id': '180607000821841', 'exchange_order_id': None, 'parent_order_id': None, 'status': 'PUT ORDER REQ RECEIVED', 'status_message': None, 'order_timestamp': datetime.datetime(2018, 6, 7, 10, 47, 25), 'exchange_update_timestamp': None, 'exchange_timestamp': None, 'variety': 'regular', 'exchange': 'NFO', 'tradingsymbol': 'NIFTY18JUNFUT', 'instrument_token': 2, 'order_type': 'SL', 'transaction_type': 'BUY', 'validity': 'DAY', 'product': 'MIS', 'quantity': 75, 'disclosed_quantity': 0, 'price': 0, 'trigger_price': 10850, 'average_price': 0, 'filled_quantity': 0, 'pending_quantity': 75, 'cancelled_quantity': 0, 'market_protection': 0, 'tag': None, 'guid': 's9avzKEHnm40j0jq'}, {'placed_by': 'xxxx', 'order_id': '180607000821841', 'exchange_order_id': None, 'parent_order_id': None, 'status': 'VALIDATION PENDING', 'status_message': None, 'order_timestamp': datetime.datetime(2018, 6, 7, 10, 47, 25), 'exchange_update_timestamp': None, 'exchange_timestamp': None, 'variety': 'regular', 'exchange': 'NFO', 'tradingsymbol': 'NIFTY18JUNFUT', 'instrument_token': 12374274, 'order_type': 'SL', 'transaction_type': 'BUY', 'validity': 'DAY', 'product': 'MIS', 'quantity': 75, 'disclosed_quantity': 0, 'price': 0, 'trigger_price': 10850, 'average_price': 0, 'filled_quantity': 0, 'pending_quantity': 75, 'cancelled_quantity': 0, 'market_protection': 0, 'tag': None, 'guid': 's9avzKEHnm40j0jq'}, {'placed_by': 'xxx', 'order_id': '180607000821841', 'exchange_order_id': None, 'parent_order_id': None, 'status': 'OPEN PENDING', 'status_message': None, 'order_timestamp': datetime.datetime(2018, 6, 7, 10, 47, 25), 'exchange_update_timestamp': None, 'exchange_timestamp': None, 'variety': 'regular', 'exchange': 'NFO', 'tradingsymbol': 'NIFTY18JUNFUT', 'instrument_token': 12374274, 'order_type': 'SL', 'transaction_type': 'BUY', 'validity': 'DAY', 'product': 'MIS', 'quantity': 75, 'disclosed_quantity': 0, 'price': 0, 'trigger_price': 10850, 'average_price': 0, 'filled_quantity': 0, 'pending_quantity': 75, 'cancelled_quantity': 0, 'market_protection': 0, 'tag': None, 'guid': 's9avzKEHnm40j0jq'}, {'placed_by': 'xxxx', 'order_id': '180607000821841', 'exchange_order_id': '1100000000235445', 'parent_order_id': None, 'status': 'TRIGGER PENDING', 'status_message': None, 'order_timestamp': datetime.datetime(2018, 6, 7, 10, 47, 25), 'exchange_update_timestamp': None, 'exchange_timestamp': datetime.datetime(2018, 6, 7, 10, 47, 25), 'variety': 'regular', 'exchange': 'NFO', 'tradingsymbol': 'NIFTY18JUNFUT', 'instrument_token': 12374274, 'order_type': 'SL', 'transaction_type': 'BUY', 'validity': 'DAY', 'product': 'MIS', 'quantity': 75, 'disclosed_quantity': 0, 'price': 0, 'trigger_price': 10850, 'average_price': 0, 'filled_quantity': 0, 'pending_quantity': 75, 'cancelled_quantity': 0, 'market_protection': 0, 'tag': None, 'guid': 's9avzKEHnm40j0jq'}]
>>>
Please don't post personal info or session tokens on the public threads. You can write a private message if you have to mention those.
To summarize the issue, a SL order placed without the "price" input degenerates into a SL-M order. Is this expected behavior?
Thanks.