It looks like you're new here. If you want to get involved, click one of these buttons!
my_api_key = "***"
my_request_token = "***"
my_secret_key = "***"
try:
kite = KiteConnect(api_key = my_api_key)
data = kite.request_access_token( request_token = my_request_token , secret= my_secret_key)
kite.set_access_token(data["access_token"])
print ("Access token: " + data["access_token"])
except Exception as e:
print("Connection could not be established...",str(e))
raise
Are you using Kite Connect API or Publisher..?
Can you check out this webinar and make sure you are doing the process correctly.
PS: The request token is valid for a couple of minutes and can be used only once whereas access token is valid for one day. Make sure you are not requesting for access token every time you run the script.