Navigation

    SmartAPI Forum
    • Register
    • Login
    • Search
    • Categories
    • Popular
    • Groups
    • FAQs
    • API Docs

    Historical data for Nifty and BankNifty

    Python SDK
    2
    4
    193
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • T
      TurboExpert last edited by

      Hello,

      I have tried the following code to get Historical data for Nifty and Bank nifty. Can you please tell me what is the correct symboltoken for the same ?

      # Historic api
      try:
          historicParam = {
              "exchange": "NSE",
              "symboltoken": "2",
              "interval": "FIVE_MINUTE",
              "fromdate": "2021-05-17 09:00",
              "todate": "2021-05-21 15:30"
          }
          candle = obj.getCandleData(historicParam)
          print(candle)
      except Exception as e:
          print("Historic Api failed: {}".format(e.message))
      

      I have tried using both "2" and "26009" which I got from instruments list for Nifty 50 and bank nifty indices. However there is no output, only an empty array is returned.

      Let me know what is the correct symbol token for NSE Nifty 50 and Bank nifty.

      Thank you.

      A 1 Reply Last reply Reply Quote 0
      • A
        admin @TurboExpert last edited by

        Hi @TurboExpert currently we provide data for NSE equity only.

        T 1 Reply Last reply Reply Quote 0
        • T
          TurboExpert @admin last edited by

          @admin thank you for the reply. Can you tell me from when will you support NSE indices historical data? Is there a planned release date?

          A 1 Reply Last reply Reply Quote 0
          • A
            admin @TurboExpert last edited by

            Hi @TurboExpert we are evaluating options for that we will keep you updated.

            1 Reply Last reply Reply Quote 0
            • First post
              Last post