Skip to Content
HomeLink Hub
Users & Profile

List the user's active sessions

GET
/api/v1/user/active-sessions

Access: Bearer token required.

Returns the sessions recorded at sign-in, newest first; at most 10 are kept per account. data is a bare array, not an object. id is the session ID embedded in that session's tokens, device is derived from the User-Agent (iPhone, iPad, Android Device, Mac, Windows PC, Linux Device or Unknown Device), and location is the IP address seen at sign-in rather than a place name. lastActive is the sign-in time: it is not refreshed as the session is used. The stored browser name and the current-session marker are not returned, and there is no endpoint to revoke a single session other than POST /auth/signout from that session.

Authorization

bearerAuth
headerAuthorizationBearer <JWT>

Access token returned by sign-in. Send it as Authorization: Bearer <token>.

Response Body

Sessions returned

application/json
  1. response
status*integer
success*boolean
message*string
data*array<>
Example Request
curl -X GET 'http://localhost:4000/api/v1/user/active-sessions'
Example Response
{  "status": 200,  "success": true,  "message": "Active sessions retrieved.",  "data": [    {      "id": "3f2b1c9e-7a4d-4e1b-9c2f-5d8a6b7c0e1f",      "device": "iPhone",      "location": "102.89.34.17",      "lastActive": "2026-11-24T18:42:09.000Z"    }  ]}