Link Search Menu Expand Document

#+TITLE: nextjs api authentication #+ROAM_ALIAS:

  • tags:: authentication, auth0[auth0]]

    • Import the Auth0 lib file
import auth0 from '../../lib/auth0';
```
  * Add this wrapper around the route to be protected
``` javascript
export default auth0.requireAuthentication(
\\ function in here
)
```