I'm trying to figure out how to proceed after receiving confirmation email from AWS after signing up using the code below:
import { Auth } from 'Amplify'
const auth() => {
return Auth.signUp({
username: email,
password,
attributes: {
birthdate,
email,
given_name: firstName,
family_name: lastName,
},
})
}
I tried to search for this but didn't find anything helpful so far. Did anyone have experience using Amplify and confirming email address (which is also username in my Cognito configuration)?
The code above works, I get the email, but when click on it I get redirected to /my-callback-url?username=643663f9-e36b-4333-9222-1118338abf04
. Something like this - what is this username parameter here, how do I decode it?
Best,
Marko
It depends on cognito settings. I set up cognito to return code (not the link like in your case). You need to confirm sign up with return Auth.confirmSignUp(username, code);
docs are here https://docs.amplify.aws/lib/auth/emailpassword/q/platform/js
I tought that user is confirmed by simply visiting that link in your case. 643663f9-e36b-4333-9222-1118338abf0 is one time verification code.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With