<@!714490410105438259> , If you want the email ID ...
# support-questions-legacy
r
@User , If you want the email ID on the backend, then you can do the following: - Get the user ID from the session using
req.session.getUserId()
- From the userId, you can get the email via:
Copy code
let {getUserById} = require("supertokens-node/recipe/emailpassword");

let user = getUserById(userId);
let email = user.email;
If you would like to get the email on the frontend, you should create an API which returns the email from the session, or you can even put the email in the JWT payload when creating a session.
3 Views