feat(cognito): add MfaSecondFactor support to CognitoUserPoolConstruct#64
feat(cognito): add MfaSecondFactor support to CognitoUserPoolConstruct#64ncipollina merged 1 commit intomainfrom
Conversation
Adds MfaSecondFactor property to ICognitoUserPoolConstructProps and CognitoUserPoolConstructProps, wired through to UserPoolProps, enabling callers to configure TOTP or SMS as a second factor when Mfa is OPTIONAL or REQUIRED. Bumps version to 2.3.0. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 25292a01ef
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| <Project> | ||
| <PropertyGroup> | ||
| <VersionPrefix>2.2.0</VersionPrefix> | ||
| <VersionPrefix>2.3.0</VersionPrefix> |
There was a problem hiding this comment.
Bump major version for public interface change
This release is tagged as 2.3.0, but the same commit adds MfaSecondFactor to the public ICognitoUserPoolConstructProps interface, which is a source-breaking API change for any downstream code that implements that interface. Consumers that auto-accept minor updates can hit compile failures after upgrading, so this should be shipped as a major version bump (or the interface change avoided) to preserve semantic-version expectations.
Useful? React with 👍 / 👎.
Summary
Adds
MfaSecondFactoras an optional property onICognitoUserPoolConstructPropsandCognitoUserPoolConstructProps. When set, it is passed directly to the CDKUserPoolProps, allowing callers to enable TOTP (Otp = true) or SMS (Sms = true) as a second authentication factor alongside the existingMfasetting. Bumps the package version to2.3.0.Changes
CognitoUserPoolConstructProps— added nullableMfaSecondFactor? MfaSecondFactorto both the interface and the concrete record (defaults tonull, fully backward compatible)CognitoUserPoolConstruct— wiresprops.MfaSecondFactorthrough toUserPoolProps.MfaSecondFactorDirectory.Build.props— version bumped from2.2.0to2.3.0Validation
cipollina-infrastructurestack withMfa = Mfa.REQUIREDandMfaSecondFactor = new MfaSecondFactor { Otp = true, Sms = false }Notes for Reviewers
Adding a property to the
ICognitoUserPoolConstructPropsinterface is technically a breaking change for external implementors, though in practice all consumers use the concreteCognitoUserPoolConstructPropsrecord. Treated as a minor bump accordingly.🤖 Generated with Claude Code