Dozor
Tracked Users

Online-status heartbeat

VIEWER+. Lightweight — `MAX(Session.endedAt)` keyed on the indexed `trackedUserId`, no `Event` table scan. Online flag flips when the most recent session ended within `ONLINE_THRESHOLD_MS`. `Cache-Control: no-store` so polling sees fresh values.

GET/api/tracked-users/{userId}/status

VIEWER+. Lightweight — MAX(Session.endedAt) keyed on the indexed trackedUserId, no Event table scan. Online flag flips when the most recent session ended within ONLINE_THRESHOLD_MS. Cache-Control: no-store so polling sees fresh values.

Path Parameters

userId*string

TrackedUser id (cuid)

Response Body

application/json

curl -X GET "https://loading/api/tracked-users/string/status"
{
  "online": true,
  "lastEventAt": "2026-04-26T10:33:04.320Z"
}
Empty
Empty
Empty