K
Kinde3mo ago
Samyam

How to get role of the current logged in user

the current getRole method is not working for next js, it is returning null kinde- 2.3.8
3 Replies
IkiTg07
IkiTg073mo ago
You're right. Let me tell the team about it Could you please tell me what your use case for getRoles is ?
IkiTg07
IkiTg073mo ago
Have you tried by switching this on?
No description
moggelitalanya
moggelitalanya3mo ago
Hello! Where did you find this option in the control-panel? Thank you in advance. @IkiTg07 EDIT: Found it, this solved my issue with not getting roles when calling "getRoles" from "getKindeServerSession". Found under: Kinde Settings > Application > Tokens >AccessToken > Roles switched on. For future reference. ‼️ Though, im still looking for getting the current role when fetching "getUser" .

Did you find this page helpful?