Sessions
Read, exchange and revoke the sessions of anonymous and signed-in users.
A session is the durable record of an anonymous or signed-in user. It holds the verified factors and the assurance levels they satisfy. A session lives for 24 hours after sign-in by default; the concepts page has the lifetimes.
A sign-in ends in a session: exchange the handoff token that an
authentication attempt returns.
From then on the browser holds the session cookie. Your app reads the session
with GET /sessions/me and signs the user out with DELETE /sessions/me.
Operators use the by-ID and query operations with a project secret.
| Method | Path | Summary |
|---|---|---|
POST | /sessions | Create an anonymous session |
POST | /sessions/query | Query sessions |
POST | /sessions/exchange | Exchange a handoff token for a session |
GET | /sessions/{session_id} | Get a session by ID |
DELETE | /sessions/{session_id} | Revoke a session |
GET | /sessions/me | Get my session |
DELETE | /sessions/me | Revoke my session |
GET | /sessions/me/csrf | Get my session's CSRF token |
Was this helpful?