I’m attempting to retrieve user information to automatically fill out a fields in a form in a react application when the app is opened.
The user will be clicking on a call to action button in the original app (where they are logged in) to reach the new react app, which will be in a new tab under a new url.
Is it possible to retrieve the user information without asking the user to login again?
I’ve successfully added login following this guide and I’ve made use of the user object to fill out the fields. But I would like to avoid forcing the user to log in again if possible.
Thank you for any help you might be able to offer.
Yes! You could call the Authentication API’s Get user info endpoint using the access token generated from the user’s initial login to populate the fields in your form.
Alternatively, you could call the Management API’s Get a user endpoint or the Search users by email endpoint to get the user’s information. However, this will require you to know the user’s user_id or email.