Instrument csv dump

I am new to python and I want the list of instruments for BANKNIFTY. I have got the list in response object(as mentioned in documentation) but I am not able to read the data from response object. Also any leads for getting BANKNIFTY specific instruments?
  • rakeshr
    You need to send NFO param when requesting for instrument file, for python client:
    kite.instruments(exchange='NFO').Check documentation here.
  • AnujaJ
    I am not getting nifty/banknifty weekly options instrument token through the function mentioned above. Any leads for the same?
  • rakeshr
    rakeshr edited March 1
    Yeah, it will have all NFO scrip,you need to loop through whole response and then check for require trading symbol.Something as below for python client:
    for value in instrument_file:
    #Filter out required trading symbol
  • coolkoti
    Is there a way to get the old instrument tokens? For example, I want the token for ACC19FEBFUT or ACC19JANFUT. Where can I get them? The instrument csv only have the current, next and far month tokens.
  • sujith
    sujith edited March 5
    The exchange re-uses the tokens once expired so even though you store tokens for expired instruments. You won't be able to fetch data for expired instruments.
    You can use continuous data feature of the historical data API. You can refer documentation here.
  • sujith
    Please create a new thread for new queries. Please don't hijack threads.
This discussion has been closed.