Token is invalid or has expired

AutoTrade
Hi I am getting the following exception after data = kite.generate_session("sessID", api_secret="api_secret")

Please help me , i am frustrated in setting up python cient.

DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): api.kite.trade:443
DEBUG:urllib3.connectionpool:https://api.kite.trade:443 "POST /session/token HTTP/1.1" 403 None
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\Admin\AppData\Local\Programs\Python\Python37\lib\site-packages\kiteconnect-3.7.7-py3.7.egg\kiteconnect\connect.py", line 232, in generate_session
File "C:\Users\Admin\AppData\Local\Programs\Python\Python37\lib\site-packages\kiteconnect-3.7.7-py3.7.egg\kiteconnect\connect.py", line 701, in _post
File "C:\Users\Admin\AppData\Local\Programs\Python\Python37\lib\site-packages\kiteconnect-3.7.7-py3.7.egg\kiteconnect\connect.py", line 766, in _request
kiteconnect.exceptions.TokenException: Token is invalid or has expired.
Sign In or Register to comment.