API operation · load group
PATCH
/load/sessions/{id}
First published 26 Oct 2026
0.2.17Unchanged since publicationSet whether the running Load monitor session keeps its readings
Who may call it
AdministratorResellerCustomer
Token scope, any of
settingsallAnswers200 OK
The request body must be an object containing only the required boolean field keep. Set keep to true to save the readings when the session ends or to false to discard them.
An invalid session ID format or request body returns 400. If the session has ended, the operation returns 409.
As a command
Run as root on the serverParameters
idpath ·string, matching ^[0-9]{8}-[0-9]{6}$RequiredSession ID derived from the UTC start time, in YYYYMMDD-HHMMSS format. Example ID 20261025-171203.
keepbooleanRequiredWhether to retain the readings after the session ends.
Example
See the API overview for how to set $API and $TOKEN.Request
curl -sS -X PATCH "$API/load/sessions/1" \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"keep": true
}'Response ·
200 OK{
"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
11 errors, each a status and a sentence400--id is required400--keep or --no-keep is required400A session ID is the moment it started, like 20261025-171203400Invalid id400The body is an object: <words>400Unknown field400keep is required400keep is true or false401Authentication required404No session <id>409Session <id> has ended; only the running session's Keep switch can changeNo error of this operation matches.
Generated from release 0.2.35 (current) · the API’s own descriptionThis entry has been unchanged since it was first published in release 0.2.17 on 26 Oct 2026.
urbestack.com/docs/api/patch-load-sessions-id/