Auth0 Home Blog Docs

Management API V2 for .NET UpdateAsync fails with conflict errors.



I have recently been getting errors like the following, in various combinations.

Cannot update email_verified and phone_number simultaneously

It started when I tried updating the phone_number field. I have tried to solve the problem by calling GetAsync to get the full profile, then setting all of the possible properties of the UserUpdateRequest object. My thinking was the API was sending null properties and that ensuring all of the properties had their proper current values would help. But, it has not.

Has anyone run in to this problem, and more importantly found a solution?


I can technically reproduce that error by performing a PATCH request to /api/v2/users/{user_id}for a database connection user identifier and with the following payload:

“email_verified”: false,
“phone_number”: “+xxxxxxxxxx”

However, as the error message mentions it’s not possible to update those two fields together. In addition, to my knowledge the phone_number is for SMS passwordless end-users which to my knowledge would not have an email address associated. In conclusion, there’s nothing suspicious about the error message itself as it is expected if you send those two fields for update so you should clarify what exactly are your intents and what type of end-users are you updating (database connection, passwordless email, passwordless sms).