I am trying to figure out something related to “post login actions” and rules. Currently I have a custom rule. Within that rule, I access an id which exists on the user object as “_id” (not to be confused with user_id) .
here is a screenshot of the rule
here is the result of the log with the _id field
However, I noticed that when migrating to the post login action , the _id field does not exist on the user object anymore. ( i.e event.user, see Actions Triggers: post-login - Event Object (auth0.com) )
It is also not referred to anywhere in the docs. So I have the following questions please:
- Where does that _id come from ?
- Will that Id also be deprecated with the rules functionality ? as it is currently inaccessible via the user object in the post login actions.
- Is it safe to use the auth0 Id i.e (user_id) as a unique identifier in my application. I have seen a post here where it seemed like 2 users were able to have the same auth0 Id. ( Users with duplicate auth0 IDs - Auth0 Community