Not able to get the Futures and options data for expired tokens

murtuza91108112
Hello @everyone,
I hope you all are doing well.
  • I am a bit stuck and the validity of my subscription is going to end in the next 3 days and so I want a urgent help from you all.
  • I want the historical Futures and options data for expired tokens.
  • As mentioned in the documentation, we can download the data as I asked: DOCUMENTATION
  • But the issue is that it is giving me 'TokenError'
Can someone please help ASAP? Thank you for your time.

Regards
Murtuza
Tagged:
  • murtuza91108112
    murtuza91108112 edited April 2023
    Here is the request that I am making:
    response = requests.get(
    f'https://api.kite.trade/instruments/historical/{instrument_token}/minute?from={start_date_string}+00:01:00&to={end_date_string}+23:59:00&oi=1',
    headers=headers)

    headers = {
    'X-Kite-Version': '3',
    'Authorization': f'token {API_KEY}:{access_token}',
    }
  • ashwin_tay
    Sorry but thats not possible. Zerodha doesnt allow getting historical data for expired F&O contracts
  • murtuza91108112
    murtuza91108112 edited April 2023
    That is not correct. We can get it (I was able to get it) but the time interval for which we can get data is 'day'. Like we cannot get 'minute' data for the given time interval.
    I just want to know that if they have any other API for it.
    • rakeshr
      But the issue is that it is giving me 'TokenError'
      Are you getting InputException for the wrong instrument token or TokenException for an invalid api_key or access_token?
    Sign In or Register to comment.