3.0.0
Search…
⌃K
Links

Sessions

This object represents an active session for a user. Sessions are created when a user successfully goes through the sign in or sign up flows.

Available requests

  • GET/v1/sessions/:id
  • GET/v1/sessions
  • POST/v1/sessions/:id/revoke
  • POST/v1/sessions/:id/verify
  • POST /v1/sessions/:id/tokens/:templateName

Example session schema

{
"object": "session",
"id": "sess_1q8uCbeJSMgTJnTQMgpAK1Ff0ER",
"client_id": "client_1q8sn8pLHjqTU2g1UheJwJ7YWU6",
"user_id": "user_1n5BS00ns3t21GWIXiPJ0KcSe02",
"status": "active",
"last_active_organization_id": "org_21Ufcy98STcA11s3QckIwtwHIES",
"last_active_at": 1616473411,
"expire_at": 1617078211,
"abandon_at": 1619065411
}
get
https://api.clerk.dev
/v1/sessions/:id
Retrieve a session
get
https://api.clerk.dev
/v1/sessions
List all sessions
post
https://api.clerk.dev
/v1/sessions/:id/revoke
Revoke a session
post
https://api.clerk.dev
/v1/sessions/:id/verify
Verify a session
post
https://api.clerk.dev
/v1/sessions/:id/tokens/:templateName
Create a token based on a session and a template name