-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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-cognito: Cannot customise "Verify email" string in emailBody of UserPool userVerification #23828
Comments
Thank you for your report. Can you provide a minimal CDK app so I can deploy in my account and reproduce this issue? |
@pahud You can use a stack like this to reproduce the issue:
|
Yes you are right. I think we have made it static here
And we should change the logic here: aws-cdk/packages/@aws-cdk/aws-cognito/lib/user-pool.ts Lines 1060 to 1062 in 64eb2bd
I am making it a p2. Any PR contribution would be welcome and appreciated! |
Hey @pahud, any update on this effort? |
I'm interested in this as well, any plan to fix this? |
Are you accepting PRs for this issue? |
Drafted a PR to fix this issue, included the bug fix and updating README with some more examples on |
When I change the text in the "{##Verify Email##}" placeholder, e.g. to "{##verify your email##}", cdk synth and cdk deploy commands yield the error, ``` Error: Verification email body must contain the template string '{##Verify Email##}' ``` This is incorrect as that documentation states that this string may be customised. https://docs.aws.amazon.com/cognito/latest/developerguide/cognito-user-pool-settings-email-verification-message-customization.html Help text in the AWS Cognito console reads: You can customize this message with HTML. "Verify email" is the text that will be displayed over the clickable link in the message. You can customize the "Verify email" string, but the variable - some text enclosed by "{##" and "##}" - must be kept in the message. Expected Behavior Be able to change the emailBody property of a UserPool to include the placeholder of format, "{##Verify Your Email##}" with any custom string allowed by AWS Cognito. Closes #23828 ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
|
When I change the text in the "{##Verify Email##}" placeholder, e.g. to "{##verify your email##}", cdk synth and cdk deploy commands yield the error, ``` Error: Verification email body must contain the template string '{##Verify Email##}' ``` This is incorrect as that documentation states that this string may be customised. https://docs.aws.amazon.com/cognito/latest/developerguide/cognito-user-pool-settings-email-verification-message-customization.html Help text in the AWS Cognito console reads: You can customize this message with HTML. "Verify email" is the text that will be displayed over the clickable link in the message. You can customize the "Verify email" string, but the variable - some text enclosed by "{##" and "##}" - must be kept in the message. Expected Behavior Be able to change the emailBody property of a UserPool to include the placeholder of format, "{##Verify Your Email##}" with any custom string allowed by AWS Cognito. Closes aws#23828 ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
When I change the text in the "{##Verify Email##}" placeholder, e.g. to "{##verify your email##}", cdk synth and cdk deploy commands yield the error, ``` Error: Verification email body must contain the template string '{##Verify Email##}' ``` This is incorrect as that documentation states that this string may be customised. https://docs.aws.amazon.com/cognito/latest/developerguide/cognito-user-pool-settings-email-verification-message-customization.html Help text in the AWS Cognito console reads: You can customize this message with HTML. "Verify email" is the text that will be displayed over the clickable link in the message. You can customize the "Verify email" string, but the variable - some text enclosed by "{##" and "##}" - must be kept in the message. Expected Behavior Be able to change the emailBody property of a UserPool to include the placeholder of format, "{##Verify Your Email##}" with any custom string allowed by AWS Cognito. Closes #23828 ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Describe the bug
When I change the text in the "{##Verify Email##}" placeholder, e.g. to "{##verify your email##}",
cdk synth
andcdk deploy
commands yield the error,This is incorrect as that documentation states that this string may be customised.
https://docs.aws.amazon.com/cognito/latest/developerguide/cognito-user-pool-settings-email-verification-message-customization.html
Help text in the AWS Cognito console reads:
Expected Behavior
I am able to change the
emailBody
property of a UserPool to include the placeholder of format, "{##Verify Your Email##}" with any custom string allowed by AWS Cognito.Current Behavior
cdk synth
andcdk deploy
commands yield the error,Reproduction Steps
Create a stack containing a cognito.UserPool resource with property,
Run
cdk synth
on the stack.Possible Solution
No response
Additional Information/Context
No response
CDK CLI Version
2.61.0 (build 34f4926)
Framework Version
No response
Node.js Version
v18.13.0
OS
Ubuntu 22.04.1 LTS
Language
Typescript
Language Version
No response
Other information
No response
The text was updated successfully, but these errors were encountered: