Hello, we had a user who needed their email changed. I tried to do it in the dashboard, but saw an error. I tried to patch the user instead with the Management API and saw the same error. Finally, I recognized the error as coming from the Get User custom database script, and the problem is the organization ID is not set through the dashboard.
This was my path:
- PATCH ~/api/v2/users/:id
- Run into error because custom database Get User script expects organization ID
- Hard-coded the organization ID into the Get User script (temporarily!)
- Ran PATCH again
- Get auth0_idp_error 400 Bad Request “The specified new email already exists”
At this point I don’t know what to do. The email does not exist. That’s the main issue. But if someone knows a fix to get organization id included in the Change Email button on the dashboard, that would be nice.
Our workaround is to delete the user through the dashboard and have them login again to hit our initialization code.