Incorrect instrument token returned by Kite.Orders()

bluenile
Hi - my program uses the instrument token as the KEY and entire program logic is dependent on matching the correct instrument token. However, for one particular (MIS, LIMIT, AMO) order that was pending, the instrument token retrieved came back as just the number '2'. I was using the instrument: 12181762/NIFTY18JAN10800CE. Please note, I was able to correctly place the AMO order. This happened on retrieving pending orders

I have two queries:
- Is this erroneous behaviour for Kite.Orders() or is this the expected behaviour for AMO orders?
- What is more reliable & consistent to be used as a logical KEY to track when trading multiple instruments - instrument_token or trading_symbol?
  • sujith
    Yes, it is a bug from OMS end because of which instrument token is returning the wrong value. We are following up with them to get a fix. This is observed only in AMOs only.

    You can use either tradingsymbol with exchange or instrument token as the logical key.
  • sujith
    sujith edited January 2018
    The instrument token can change. The instrument token can be assigned to some other contract once a contract expires. We use a combination of exchange and tradingsymbol like NSE:INFY.
  • bluenile
    Thanks Sujith. I understand instrument is re-cycled on contract expiry, my program logic takes care of that. But within an expiry cycle, will instrument token be a valid logical KEY. From your answer, it appears that this will hold true (except for AMO orders, which is being fixed).

    This is helpful.
  • sujith
    Yes, you can use it. I just told what we do.
    We are following up with OMS team to get it fixed.
Sign In or Register to comment.