Thank you for posting this! I am working on an application that will use a very similar stack :D Good timing!
Why do this yourself? Just use AWS Cognito. You should never use that sort of DIY stuff really. Use this as a learning tool instead.
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.