AuthSessionsResource
Lists and revokes the signed-in user's sessions.
- Stable unknown
- Release candidate since 0.1.0-rc.4
- Development since 0.1.0-dev.24+fa54770
public final class AuthSessionsResourceLists and revokes the signed-in user's sessions. Get it from AuthResource.sessions().
Methods
list
public List<JsonNode> list() throws IOException, InterruptedExceptionLists the user's sessions (GET /auth/session).
Returns: the sessions; empty when the response is not a list
Throws:
IOException: if the request cannot be sent or the response cannot be readInterruptedException: if the thread is interrupted while waiting for the response
revoke
public void revoke(String sessionId) throws IOException, InterruptedExceptionRevokes a session (DELETE /auth/session/{sessionId}). Revoking current also ends the local session.
Parameters:
sessionId: the session ID, orcurrent
Throws:
IOException: if the request cannot be sent or the response cannot be readInterruptedException: if the thread is interrupted while waiting for the response
Last updated on