/load/sessions
0.2.17Unchanged since publicationStart a Load monitor session
settingsallStarts a session and returns 201. The server takes a reading every seconds as specified by every, for a total of readings readings. The interval must be a whole number from 2 to 60 seconds and defaults to 5. The number of readings must be a whole number from 1 to 720 and defaults to 100. The request body may contain every, readings, and keep. An invalid body returns 400.
The session runs as a single root process in the transient systemd unit urbestack-load-session. Only one session can run at a time. If a session is already running, the operation returns 409 and reports who started it and when it is due to end. Any administrator with a token that has the settings scope can watch or stop the running session.
The session ends after its last reading, when stopped through DELETE /load/sessions/{id}, or after one minute without a request for its readings. Set keep to true to save the readings when the session ends or to false to discard them. If keep is omitted, the session uses panel.load_keep_sessions. UrbeStack retains up to 50 kept sessions, keeping the newest.
As a command
Run as root on the servereveryinteger, 2 to 60keepbooleanreadingsinteger, 1 to 720Example
See the API overview for how to set $API and $TOKEN.curl -sS -X POST "$API/load/sessions" \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"every": 1,
"keep": true,
"readings": 1
}'201 Created{
"session": {
"ended_at": "text",
"ends_at": "text",
"every": 1,
"how": "done",
"id": 1,
"keep": true,
"readings": 1,
"started_at": "2026-09-09T10:15:01Z",
"started_by": "text",
"state": "running",
"stopped_by": "text",
"taken": 1,
"worst": {
"apache_busy_max": 1,
"apache_full": 1,
"blocked_max": 1,
"disk": {
"busy_pct": 1,
"name": "alice",
"wait_ms": 1
},
"iowait_max": 1,
"kernel_errors": 1,
"load_max": 1,
"mariadb_stuck": 1,
"pool": {
"domain": "example.com",
"hits": 1,
"kind": "domain",
"max": 1,
"name": "alice",
"peak": 1,
"php": "text",
"waiting_peak": 1
},
"query": {
"database": "alice_shop",
"seconds": 1,
"state": "text",
"user": "alice"
},
"running_max": 1,
"steal_max": 1,
"threads_running_max": 1
}
},
"started": true
}Errors
7 errors, each a status and a sentence400Invalid id400The body is an object: <words>400Unknown field400keep is true or false401Authentication required409A session is running, started by <cur.started_by> at <cur.started_at> and ending by <cur.ends_at>: 409A session named <id> exists already; start again in a secondurbestack.com/docs/api/post-load-sessions/