hi, How to get user email in react frontend
# support-questions-legacy
r
hi, How to get user email in react frontend
r
hey @rajubai11 you need to add the email to the access token payload yourself with the createNewSession override
r
so i need to store email to my db and then retrieve and use as payload
anyway to get from session data
r
you don't need to store email in your db. You can get the email of the user using our functions for the recipe on the backend like EmailPassword.getUserById.
then in the createNewSession override, add the email to the access token payload and read it on the frontend
r
Thanks
14 Views