AWS Cognito User Migration Lambda in Python

We've been tasked with switching our login system from an in-app system to something leveraging AWS Cognito. Doing so requires a migration step which, when done fully through AWS requires some hoops (including an AWS Lambda where the example provided from AWS is a NodeJS Lambda (where we prefer Python Lambdas) so I spent some time rewriting it and thought I'd share for those that are interested.