@Moderator_3 Please find the code :
obj = SmartConnect(api_key = apikey)
data = obj.generateSession(clientId, pwd, totp)
print(data)
AUTH_TOKEN = data ["data"]["jwtToken"]
refreshToken = data['data']['refreshToken']
FEED_TOKEN = feedtoken
res = obj.getProfile(refreshToken)
res["data"]["exchanges"]
print (res)
And also please find the error message. It is pointing at the jwtToken but I have been using the same since long and the system is also returning the same :
TypeError Traceback (most recent call last)
Cell In[4], line 5
3 data = obj.generateSession(clientId, pwd, totp)
4 print(data)
----> 5 AUTH_TOKEN = data ["data"]["jwtToken"]
6 refreshToken = data['data']['refreshToken']
7 FEED_TOKEN = feedtoken
TypeError: 'NoneType' object is not subscriptable