Open raegen opened 4 days ago
Hello, @raegen and thanks for opening this issue. While the signInDetails
are not supported when using Hosted UI or the signInWithRedirect
API (as noted here in docs), but we'll consider this issue a feature request to add that functionality into the signInWithRedirect
API calls.
Can you give us more details about the use case and context as to why you're looking to do this within your OAuth flow? For example, what kind of information are you looking to capture from the OAuth flow (i.e. provider, Auth flow type, or something else)?
Before opening, please confirm:
JavaScript Framework
React
Amplify APIs
Authentication
Amplify Version
v6
Amplify Categories
auth
Backend
Amplify CLI
Environment information
Describe the bug
getCurrentUser
does not return signInDetails if the user is signed in using OAuth (an IdentityProvider like google). The data for it is available in the idToken, and can be accessed directly through token payload, but is not returned bygetCurrentUser
.Expected behavior
getCurrentUser
returns consistent information regardless of how the user is signed in, especially if the data is actually available (meaning it's not a limitation related to the particular identity provider).Reproduction steps
There are no specific conditions for reproducing this other than using signInWithRedirect (we're using specifically google identity provider), but here it goes:
Code Snippet
Log output
aws-exports.js
Manual configuration
No response
Additional configuration
No response
Mobile Device
No response
Mobile Operating System
No response
Mobile Browser
No response
Mobile Browser Version
No response
Additional information and screenshots
No response