AWS Cognito is not sending verification emails

Viewed 43

I'm using AWS Cognito and requiring email verification for users. However, when I get to this page:

Email verification page

Nothing happens. I have waited several hours and no verification email has appeared.

I can see that the user has been created in the cognito user pool and I can manually confirm users which show up there.

User created in cognito user pool

Browing some other posts previously I have added the domain name in AWS Cognito but emails are still not being sent.

Domain name added

I have included my registration code below, is there something I'm missing which is causing this issue?

return (
    <Authenticator
    // Default to Sign Up screen
    initialState="signUp"
    // Customize `Authenticator.SignUp.FormFields`
    signUpAttributes={[
      'address',
      'email',
      'name',
      'phone_number',
      'custom:business_name',
      'custom:type',
      'custom:abn',
    ]}
    components={{
      SignUp: {
        FormFields() {
          const { validationErrors } = useAuthenticator();

          return (
            <>
              {/* Re-use default `Authenticator.SignUp.FormFields` */}
              <Authenticator.SignUp.FormFields />
              <TextField
                name="custom:business_name"
                placeholder='Business Name'
              />
              <TextField
                name="address"
                placeholder='Address of Business'
              />
              <TextField
                name='custom:abn'
                placeholder='ABN'
              />
              <SelectField
                name='custom:type'
                placeholder='Select Type of Business'
              >
                <option value="Donor">Donor</option>
                <option value="Collector">Collector</option>
              </SelectField>
            </>
          );
        },
      },
    }}
  >
    {({ signOut, user }) => (
      <div className="App">
      <header className="App-header">
        <>
      {component}
      {showNav == "True" &&
      <Navbar/> }
      </>
      </header>
      <button onClick={signOut}>Sign out</button>
    </div>
    )}
  </Authenticator>
  );
0 Answers
Related