-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
aws-cdk-lib/aws-cognito: Cannot use the .addTrigger() method on an existing userpool #33350
Comments
I think you should use const cognitoUserPool = new UserPool(this, 'UserPool', {
selfSignUpEnabled: true,
accountRecovery: AccountRecovery.PHONE_AND_EMAIL,
userVerification: {
emailStyle: VerificationEmailStyle.CODE,
},
autoVerify: {
email: true,
},
standardAttributes: {
email: {
required: true,
mutable: true,
},
},
});
// This does not work, even if the correct props are provided
cognitoUserPool.addTrigger() |
Hey Pahud, please see the bottom of my inline code. I'm attempting to use .addTrigger() and it does not currently work. |
Hey Pahud, typo in my example, if you see the TypeScript error output it's showing what does not currently work. The function is missing from the interface.
|
Hey Pahud, we have to make a decision on whether or not to try and tackle this with L1 constructs or when this would be fixed for L2. Do you know what an approximate timeframe would be? |
Describe the bug
I am currently unable to use the addTrigger() method on UserPool created in CDK.
Regression Issue
Last Known Working CDK Version
No response
Expected Behavior
userPool.addTrigger() should be a valid method for adding a trigger to a cognito user pool. Type hints should be available and working in any modern IDE.
Current Behavior
When attempting to call the addTrigger() method on a userpool, CDK fails to compile and states the method does not exist.
Reproduction Steps
Possible Solution
No response
Additional Information/Context
I've attempted updating version, invalidating caches, removing node_modules and reinstalling.
CDK CLI Version
2.178.1
Framework Version
No response
Node.js Version
v18.19.1
OS
Ubuntu 24
Language
TypeScript
Language Version
No response
Other information
No response
The text was updated successfully, but these errors were encountered: