Cognito CustomMessage_AdminCreateUser mandatory use of {username} in template

0

I would like to use email or preferred_username in a template for CustomMessage_AdminCreateUser.

But it seems that Cognito requires that {username} must be present in a template, otherwise the default message is sent.

We cannot use "username" as we use this attribute to store uuid for a user. Including it in a message does not make sense.

Is there any way of preventing Cognito checking the presence of {username} in a template so the other attributes can be displayed as well?

1回答
1

Unfortunately, as you described, the username parameter is required. If it is missing, the default message template is used. A possible workaround is to use a HTML tags to hide the username value but this does not remove the username from the message. Again, a username parameter is required in the template.

AWS
Taka_M
回答済み 2年前
  • Thanks for the reply. Any plans to allow to use "alternative usernames/aliases" in templates any soon? HTML Workaround does not seem like a good option.

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ