For Users to SignIn to the App using Social SignIn & Email,Phone password, we need to setup AWS social signin User Pool.
Refer to the Steps below to add the Auth User pool for your App.
STEP 1: #
- Sign in to the AWS Console, Navigate/Search for Amazon Cognito, Click on “User pools“
- Select the “Server Location/Region” where your App Database is/will be hosted.
- Click on “Create user pool“
STEP 2: #
- Select “Federated Identity Providers” as Provider types
- Select “Email“, “Phone number” as Sign in options
- Select “Facebook“, “Google“, “Login with Amazon“, “Signin with apple” as federated signin options.
- Click Next
STEP 3: #
Select all the options as shown below:
STEP 4: #
Select all the options as shown below:
STEP 5: #
- Select “Send email with Amazon SES” as Email Provider
- Select “SES Region“
- Select “FROM email address” from which Verification Emails will be sent
- Select “Create a new IAM Role“
- Set SocialSignInAuthRole as IAM role name
- Select the SNS Region (the region where your app database is/will be hosted. SNS will only work if it is migrated to Production mode from Sandbox mode in the same region)
Click Next
STEP 6: #
Select “Skip for now” for all the Federated Sign-In options as shown below:
Click Next
STEP 7: (Important: Generate Cognito Domain) #
- Set “SocialSignInAuthPool” As User Pool name
- Select Use a Cognito Domain
- Set your ApppName in the URL to generate the Cognito Domain (Copy & Store this URL for all future needs)
STEP 8: #
- Select “Public Client” as App type
- Set SocialSignInAppClient as client name
- Select “Don’t generate client secret“
- Add these allowed callback URLs : 1. http://localhost:9753/ (For flutter web, run using this port 9753 only), 2. myapp//:
STEP 9: #
Click Create user pool
STEP 10: (Copy Credentials) #
Social SignIn User pool will be created successfully. You can find this in:
AWS Console –> Amazon cognito –> User pools –> select Region > “SocialSignInAuthPool“, (NOTE: You should be in the same AWS region from the top right region selector)
Copy the “User Pool ID” and paste it inside the source code for the field: AWS_AUTH_POOL_ID