Nuxt.js
Server-side Authentication State
Learn how to access and manage the user authentication state on the server-side in your Nuxt.js application.
Prerequisites
Install the Corbado Node.js SDK:
Generate an API secret in the developer panel to allow the SDK to access the Corbado BackendAPI.
Example
To gain access to authentication state on the server-side we utilize the Corbdo Node.js SDK.
We might use it in a server-side event handler function to verify the user is authenticated and retrieve some data in this case:
server/api/user-info.ts
Find more info on the Corbdo Node.js SDK in the backend integration section.
Was this page helpful?