I am trying to add AWS Cognito to my iOS application using AWS Amplify. The docs suggest to use amplify add auth
on the CLI, but this does not seem to work with an existing User Pool (i.e. you have to create a new one). Is it possible to integrate AWS Cognito into my iOS (Swift) project using an existing User Pool?
Import existing Amazon Cognito resources into your Amplify project. Get started by running amplify import auth command to search for & import an existing Cognito User Pool & Identity Pool in your account. The amplify import auth command will: automatically populate your Amplify Library configuration files (aws-exports.
Amplify uses Amazon Cognito as the main authentication provider. Amazon Cognito is a robust user directory service that handles user registration, authentication, account recovery & other operations.
IT pros typically use a third-party IdP for this function. However, a Cognito user pool is its own IdP. If an identity pool is configured correctly, it can use the app's user pools as an IdP. This way, users authenticate via user pools and are assigned IAM roles via identity pools.
Update: Since 2020 Amplify allows you to use existing User Pools (yeah!). Just run:
amplify import auth
Source: https://aws.amazon.com/de/about-aws/whats-new/2020/10/use-existing-cognito-user-pools-identity-pools-for-amplify-project/
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