I am trying to implement websockets in fastapi. I ...
# support-questions-legacy
d
I am trying to implement websockets in fastapi. I am sendihng the jwt token correctly. And also able to parse it using parse_jwt_without_signature_verification. The payload contains the session Handle. I could not fidn a way to get the session and the user form that. Any help would be appreicated.
r
hey @dekode the user ID is equal to the
sub
claim in the payload. If you want to get info about the session, you can use the sessionHandle and call Session.getSessionInformation on the backend. But note that this will call the core and is an expensive operation.
d
Yes, I saw that after experimenting. Thanks. I am using the sub
6 Views