Sessions

Sessions

A session represents one running instance of your script. The bulk shutdown and message endpoints wait up to 25 seconds for running clients to acknowledge before they return, so the caller always knows the real outcome.

List a user's sessions

GET
https://api.envyauth.my.id/api/v3/projects/:project_uuid/users/:identifier/sessions

Active sessions for the resolved user.

Response

{  "success": true,  "data": {    "user_id": "uuid",    "sessions": [      {        "session_id":      "uuid",        "place_id":        "606849621",        "place_name":      "Adopt Me!",        "executor":        "Synapse X",        "script_id":       "uuid",        "script_name":     "main",        "script_version":  "1.4.2",        "roblox_uid":      "12345",        "roblox_username": "PlayerName",        "started":         true,        "executions":      1,        "expires_at":      1748430000,        "created_at":      "2026-05-24T16:14:46.000Z"      }    ]  },  "requestid": "uuid"}

The same data is also reachable via a query-string alias:

GET
https://api.envyauth.my.id/api/v3/projects/:project_uuid/users/get_sessions?discord_id=…

The alias accepts either ?discord_id= or ?identifier= and resolves the same three identifier shapes.

Shut down every session for a user

POST
https://api.envyauth.my.id/api/v3/projects/:project_uuid/users/:identifier/shutdown

Force-expire every active session for the resolved user. Optional ?message=... query string enqueues an in-game toast before the disconnect so the user sees a reason. The call blocks for up to 25 seconds while the server waits for each session to acknowledge.

Response

{  "success": true,  "data": {    "success":      true,    "message":      "All sessions terminated",    "terminated":   2,    "pending":      0,    "elapsed_time": 412  },  "requestid": "uuid"}

elapsed_time is in milliseconds. When the 25-second window passes before every session acknowledges, pending is non-zero; those sessions will still terminate on their next heartbeat because the server has already marked them expired.

Message every session for a user

POST
https://api.envyauth.my.id/api/v3/projects/:project_uuid/users/:identifier/message

Push the same in-game toast to every active session for the resolved user.

Query parameters:

NameRequiredNotes
messageyesToast body.
titlenoOptional title rendered as "{title}\n{message}". Combined text is truncated to 256 characters.

Response

{  "success": true,  "data": {    "success":      true,    "message":      "All toasts delivered",    "delivered":    2,    "pending":      0,    "elapsed_time": 314  },  "requestid": "uuid"}

Shut down one specific session

POST
https://api.envyauth.my.id/api/v3/projects/:project_uuid/sessions/:session_id/shutdown

Force-expire a single session by its ID. Use this when you already have a session_id from a GET /sessions call and want to kick exactly that one. No body required.

Response

{  "success": true,  "data": {    "shutdown":     true,    "transport":    "websocket",    "delivered":    true,    "elapsed_time": 87  },  "requestid": "uuid"}

Message one specific session

POST
https://api.envyauth.my.id/api/v3/projects/:project_uuid/sessions/:session_id/message

Push a single in-game toast to one session. Same ?title=&message= query parameters as the user-level message endpoint, scoped to one session.

Response

{  "success": true,  "data": {    "queued":       true,    "transport":    "websocket",    "delivered":    true,    "elapsed_time": 92  },  "requestid": "uuid"}