I'm receiving an error from Cognito that a user exists after deleting them, they don't show in the console or list-user in the cli

0

The user in question did exist as an EXTERNAL_PROVIDER using Google. I deleted the account through the console, and was attempting to create a new user using aws cognito-idp admin-create-user

The error is: (UsernameExistsException) when calling the AdminCreateUser operation: An account with the given email already exists.

If I search in the console or using aws cognito-idp list-users the user and email doesn't show up.

Not sure where else to post this, it seems like a bug in Cognito. Hoping it will resolve itself somehow!

Carl
已提问 1 年前478 查看次数
1 回答
0

Hi!

For finding entities with the attribute EMAIL we will have to use the --filter option for the command that you used (aws cognito-idp list-users) and you can read more about the same here.

Now, for UsernameExistsException there is a document published and it has the following explanation under the subheading:

Preventing UsernameExistsException errors for email addresses and phone numbers on sign-up

When you configure alias attributes in your user pool, you can keep duplicate email addresses and phone numbers from generating UsernameExistsException errors in response to SignUp API requests. You must have created your user pool with email address or phone number as an alias attribute.

Does this help?

AWS
ART
已回答 1 年前
  • Please inform me if my answer was satusfactory by accepting my response with an up-vote.

  • Hi Carl, I am aspiring to become a Security committee member and your upvote helps in reaching my goal. If my answer was satidfactory, please do upvote.

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则