Skip to Content
Clerk logo

Clerk Docs

Ctrl + K
Go to clerk.com

getSession()

Retrieves a single session by its ID, if the ID is valid. Throws an error otherwise.

const sessionId = 'my-session-id'; const session = await clerkClient.sessions.getSession(sessionId);

Required parameters

NameTypeDescription
sessionIdstringThe ID of the session to retrieve.

Last updated on August 16, 2023

What did you think of this content?

Clerk © 2024