Cannot update user's phone number if that number is already assigned to another user

Hello!

We are currently trying to update a new users phone number to one that is already assigned to an existing user and we get the following error. We have not been able to find a setting/config that specifies phone number should be unique between user profiles.

Any help would be greatly appreiated!

Hi @rowen,

Welcome back to the Auth0 Community!

The error that you have encountered - “Error! The specified new phone_number already exists” is expected in this scenario, where the phone number is already assigned to a current user of your database.

A phone number can be considered an Identifier, which help for uniquely identifying users, therefore they must be unique. This is also mentioned in our Flexible Identifiers and Attributes documentation, which also points that:

  • Each user must be assigned a unique username, email address, and phone number regardless of connection type. The phone number is unique even if not added as an attribute.

I hope this helps, so if you have further questions please let me know!
Best regards,
Remus

Thanks for that @remus.ivan
That does provide some direction, what I was after was where can this be configured/changed?

I have had a look at the database connection > attributes and only email address is listed as an attribute so not sure where and how phone number is being used as an identifier.

To give you a little more context, we are trying to facilitate testing in our non-production environments by preventing the need of having multiple unique phone numbers for testing.

Thanks!

Hi @rowen,

Thank you for the additional input.

I understand the need of your current use-case, however at this moment there is no option to change/configure this to non-unique phone numbers. Even though only the email address is set as an Identifier, the phone number could also perceived as a potential Identifier, so:

  • phone numbers need to be unique per connection, across all users in that connection

If you would be interested in having this type of feature in future, I would highly recommend submitting a Feature Request, since others might consider it useful as well and our product team is constantly reviewing this category for potential implementations.

Thank you!
Best regards,
Remus