Learn how Auth for GenAI enables AI agents to seamlessly authenticate users.
Create an Auth0 Account and a Dev Tenant
Create an Auth0 Application
Regular Web
http://localhost:3000/auth/callback
http://localhost:3000
.env.local
file and add the following variables. You can find your Auth0 domain and client ID in the application you created in the Auth0 Dashboard.src/lib/auth0.ts
and instantiate a new Auth0 client:src/middleware.ts
:src/app/page.tsx
file to display content based on the user session:http://localhost:3000
in your browser.You will see: