aws-cdk.aws-cognito
The CDK Construct Library for AWS::Cognito
What it is and what it does
This package provides a Python construct library for AWS CDK v1 that lets you define Amazon Cognito user pools and related authentication infrastructure declaratively. It wraps CloudFormation resources and higher-level abstractions for common Cognito patterns like sign-up, sign-in with multiple aliases (username, email, phone), multi-factor authentication, Lambda triggers, and identity providers.
The library is stable for CloudFormation resources and user pool constructs, but Identity Pool L2 constructs are not implemented here. Critically, AWS CDK v1 reached end-of-support on 2023-06-01 and is no longer maintained; AWS recommends migrating to CDK v2 for new projects and ongoing support.
Use it for:
- Define a user pool with self-sign-up and email verification in a CDK stack without writing CloudFormation directly.
- Configure sign-in options (username, email, phone) and multi-factor authentication for a web or mobile app.
- Set up Lambda triggers for custom authentication flows or user lifecycle events in Cognito.
- Grant IAM roles permissions to perform Cognito operations like admin user creation.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides AWS CDK constructs for defining Amazon Cognito user pools and identity management infrastructure as code in Python.
No, unless you are maintaining an existing CDK v1 project. AWS CDK v1 is end-of-support since 2023-06-01 and receives no updates. New projects should use aws-cdk.aws-cognito from AWS CDK v2 instead, which is actively maintained and has a migration guide available.
Install
aws-cdk-aws-cognito on PyPI
pip
pip install aws-cdk-aws-cognitouv
uv add aws-cdk-aws-cognitopoetry
poetry add aws-cdk-aws-cognitoInstalling aws-cdk.aws-cognito
Before you install
Low install friction with a wheel distribution. However, this is AWS CDK v1, which reached end-of-support on 2023-06-01 and is no longer being updated; users should migrate to AWS CDK v2 instead.
License in practice
Licensed under Apache-2.0 (permissive), allowing use in commercial and private projects with minimal restrictions.
Quickstart
pip install aws-cdk.aws-cognito
from aws_cdk import aws_cognito as cognito
user_pool = cognito.UserPool(self, "myuserpool",
user_pool_name="myawesomeapp-userpool"
)
AWS CDK v1 is end-of-support as of 2023-06-01; new projects should use AWS CDK v2 instead.
Verify before relying
- Whether Identity Pool L2 constructs are available in this v1 package or only in the v2 alpha module.
- Current adoption and migration timeline for projects still on CDK v1.
Package facts
| License | Apache-2.0 (permissive) |
| Python support | supports the current Python release (~=3.7) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 10 — aws-cdk.aws-certificatemanager, aws-cdk.aws-iam, aws-cdk.aws-kms, aws-cdk.aws-lambda, aws-cdk.core, aws-cdk.custom-resources, constructs, jsii, publication, typeguard |
| Maintenance | actively maintained — 1,152 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 150,356/month — #10,966 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: aws_cdk.aws_cognito-1.204.0-py3-none-any.whl
Tags
More Application Frameworks packages
FastAPI is a Python web framework for building…
permissive · top 100 on PyPI
annotated-docProvides a way to document function parameters,…
permissive · top 100 on PyPI
textualTextual is a Python framework for building…
permissive · top 100 on PyPI
typerTyper builds command-line applications from…
permissive · top 1,000 on PyPI
mcpBuild and connect to Model Context Protocol…
permissive · top 1,000 on PyPI
WerkzeugWerkzeug is a WSGI utility library providing…
permissive · top 1,000 on PyPI
aws-cdk.aws-location-alphaProvides AWS CDK constructs for building…
permissive · top 15,000 on PyPI
aws-cdk.aws-signerProvides AWS CDK constructs for defining…
permissive · top 15,000 on PyPI
pycognitoSimplifies AWS Cognito user authentication and…
permissive · top 5,000 on PyPI
warrantWarrant wraps AWS Cognito user management…
permissive · top 15,000 on PyPI
aws-cdk.aws-apigatewayProvides AWS CDK constructs for defining and…
permissive · top 15,000 on PyPI
aws-cdk.aws-imagebuilderProvides AWS CDK L1 constructs for defining and…
permissive · top 15,000 on PyPI
aws-cdk.aws-iamProvides Python constructs for defining AWS IAM…
permissive · top 15,000 on PyPI
aws-cdk.aws-acmpcaProvides AWS CDK constructs for working with…
permissive · top 15,000 on PyPI
aws-cdk.aws-codeguruprofilerProvides AWS CDK constructs for defining and…
permissive · top 15,000 on PyPI
aws-cdk.aws-sqsProvides AWS CDK constructs for defining Amazon…
permissive · top 15,000 on PyPI