Clarifications regarding user_id (uniqueness and structure)


I have some questions regarding the user_id’s.

  1. I am using passwordless with email addresses. Let’s assume the user id is email|d25c3dd40b5361312a235cc6. What would happen if existing users switch to mobile numbers? Would the prefix before the | change?
  2. I guess that this part d25c3dd40b5361312a235cc6 is a hex string (looks like one but I am not sure if this is a coincidence). What is the hex encoded data (is it a number, random bytes or something else)? Is this hex string always of equal length? We are using value objects so knowing this would help to build in stronger validation.
  3. Is the user_id guaranteed to be unique? If so in which context (is it unique per tenant or in the whole auth0 system)?
  4. Is the part after the | (d25c3dd40b5361312a235cc6 e.g.) unique on it’s own (if so, in which context?) OR is it only unique in combination with the pre fix (like email).

Thank you :slight_smile:

Hey there!

Sorry for such huge delay in response! We’re doing our best in providing you with best developer support experience out there, but sometimes our bandwidth is not enough comparing to the number of incoming questions.

Wanted to reach out to know if you still require further assistance?