Configure Cognito User Pool in Serverless

Link to chapter - https://serverless-stack.com/chapters/configure-cognito-user-pool-in-serverless.html

Please can you update the code snippet for create a UserPool with serverless, the email as UsernameAttributes was added recently.

Apologies for the delay. In past releases Cognito cloudformation added support for email address as username. Docs update are still in progress to reflect this change. You can use "UsernameAttributes" property to set it while creating user pool with cloud formation.

from: https://forums.aws.amazon.com/thread.jspa?threadID=259349&tstart=0

1 Like

Oh yeah we just rolled out an update for that - https://serverless-stack.com/chapters/changelog.html#v31-update-to-use-usernameattributes-current

Thanks for the heads up.

@jayair do you have any documentation showing a complete list of the available parameters for serverless.yml. Like if I wanted to require MFA or add custom attributes?

Found it, https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-cognito-userpool.html

2 Likes