Navigation

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

    Not able to fetch BANKNIFTY data using HistoricalAPI

    Python SDK
    0
    3
    53
    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.
    • J
      jupyter last edited by jupyter

      Hi,

      I am not able to fetch BANKNIFTY data using HistoricalAPI.

      try:
        historicParam={
        "exchange": "NSE",
        "symboltoken": "26009",
        "interval": "ONE_MINUTE",
        "fromdate": "2022-02-30 09:15", 
        "todate": "2022-02-30 09:25"
        }
        print(obj.getCandleData(historicParam))
      except Exception as e:
        print("Historic Api failed: {}".format(e.message))
      

      OUTPUT:

      {'status': True, 'message': 'SUCCESS', 'errorcode': '', 'data': None}
      

      I am not sure why the 'data' is None. Do let me know if there is anything wrong in the code?

      Thanks in advance!!

      1 Reply Last reply Reply Quote 2
      • G
        greenhill last edited by

        Facing same issue with Nifty50

        Log
        DEBUG:urllib3.connectionpool:https://apiconnect.angelbroking.com:443 "POST /rest/secure/angelbroking/historical/v1/getCandleData HTTP/1.1" 200 62
        INFO:root:{'fromdate': '2022-09-30 04:41', 'todate': '2022-10-29 21:13', 'exchange': 'NSE', 'symboltoken': '2', 'interval': 'ONE_HOUR'}
        INFO:root:{'status': True, 'message': 'SUCCESS', 'errorcode': '', 'data': None}

        1 Reply Last reply Reply Quote 1
        • P
          P213417 last edited by

          No historical data of all NFO scripts.

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