Question: What’s the difference between Rules and Hooks and when to use them?
- Rules can be used in multiple ways enhancing your authentication and authorisation experience. Here’s the list of cases for which you can use them: LINK
- Hooks are secure, self-contained functions that allow you to customize the behavior of Auth0 when executed for selected extensibility points of the Auth0 platform. Auth0 invokes Hooks during runtime to execute your custom Node.js code.
- Example usage can be found here: LINK
Main difference is that rules are used for adding granularity to your login / signup experience while hooks are used for adding totally new mechanism to Auth0 extensibility points like:
- Pre User Registration
- Post User Registration