Skip to content

List the signed-in person’s open sessions

GET
/v1/auth/sessions
curl --request GET \
--url https://api.emite.cr/v1/auth/sessions

Browser and system are derived from the user agent; ip is the address of the latest use. The session of this request is marked current.

The open sessions of the person, this one first.

Media typeapplication/json
object
sessions
required

The sessions a token can still use: this one first, then by most recent use. A person keeps at most 20; a sign-in past that closes the least recently used.

Array<object>
object
id
required

Id of the session: what DELETE /v1/auth/sessions/{id} closes.

string format: uuid
current
required

true for the session of this request, listed first. It is not closed from the list: sign out instead (POST /v1/auth/logout).

boolean
browser
required

Browser, derived from the user agent when listing: Chrome, Edge, Firefox, Safari, Opera or Samsung Internet; null when it cannot be told.

string
nullable
os
required

Operating system, derived from the user agent when listing: Windows, macOS, iOS, iPadOS, Android, ChromeOS or Linux; null when it cannot be told.

string
nullable
ip
required

IP address the session was last used from; null when unknown.

string
nullable
lastSeenAt
required

When the session was last used. Updated at most every 5 minutes.

string format: date-time
authenticatedAt
required

When the person signed in to open it.

string format: date-time
via
required

How the person signed in: password alone; the second factor after it (totp, email_otp or recovery_code); verifying a new account (signup); resetting the password (password_reset); accepting an invitation (invitation); or starting a demo (demo).

string
Allowed values: password totp email_otp recovery_code signup password_reset invitation demo
expiresAt
required

When it ends at the latest: its maximum, counted from the sign-in. It can end earlier — signed out, closed, or under a company inactivity rule.

string format: date-time
Example
{
"sessions": [
{
"browser": "Chrome",
"os": "Windows",
"ip": "201.192.10.4",
"via": "password"
}
]
}