v1
latestOpenAPI 3.0.32026-07-26172157253.6 KBClient
Get current session
Returns the currently authenticated user's basic info from the access token. Project admin tokens return a projectAdmin session object instead of an auth.users row.
This endpoint does not refresh expired access tokens by itself. For browser apps using the TypeScript SDK, call auth.getCurrentUser() during startup. The SDK will use the httpOnly refresh cookie automatically when it can refresh the session. Server, mobile, and other non-browser clients should call /api/auth/refresh explicitly.
get/api/auth/sessions/current
Response
Current session info
Example response
{
"projectAdmin": {
"subject": "local:admin",
"username": "admin"
}
}