Skip to main content

Session endpoints

info

these are endpoints relating to sessions

info

sessions are active users
the users executor must also support websockets


Getting session info

GET /sessions/:session_id

Parameters

NameTypeDescription
session_idStringThe sessions id

Response

{
"success": true,
"session": {
"id": "SESSION_ID",
"user_key": "USER_KEY",
"script_id": "SCRIPT_ID",
"roblox_id": 10234711811,
"place_id": 606849621,
"job_id": "JOB_ID",
"created_at": 1770624500000,
}
}

Disconnecting a session

POST /sessions/:session_id/disconnect

Parameters

NameTypeDescription
session_idStringThe sessions id

Response

{ "success": true }

Messaging a session

POST /sessions/:session_id/message

tip

Check out session commands for how to handle messages

info

Request will wait up to 60 seconds for a response from the client

Parameters

NameTypeDescription
session_idStringThe sessions id

Body

NameTypeNullableDefaultDescription
keyStringId of function to execute
dataJson[]Data to send to client

Response

{
"success": true,
"processed": true,
"response": {
// data from client
}
}

Disconnecting multiple sessions

POST /sessions/disconnect

Body

NameTypeNullableDescription
session_idsString[]Array of ids to disconnect

Response

{ "success": true }

Messaging multiple sessions

POST /sessions/disconnect

tip

Check out session commands for how to handle messages

info

Request will wait up to 60 seconds for a response from the clients

Body

NameTypeNullableDefaultDescription
session_idsString[]Array of ids to message
keyStringId of function to execute
dataJson[]Data to send to client

Response

{
"success": true,
"responses": [{
"processed": true,
"response": {
// data from client
}
}, {
"processed": false,
"reason": "function errored, message: .." OR "invalid return data" OR "client never responded" OR "function doesnt exist"
}]}