879 B
879 B
POST /agent/state
Protected. Requires a valid session cookie (credentials: 'include').
Post agent state
Authorized endpoint for the printer agent to report its operational status/telemetry.
Body (JSON)
| Field | Required | Type | Description |
|---|---|---|---|
state |
no | Status text or status object |
{
"state": "…"
}
Response 200
State recorded
{
"success": true,
"agent": {
"id": 1,
"companyId": 1,
"name": "…",
"token": "…",
"pairingpin": "…",
"pairedAt": "…",
"agentversion": "…",
"lastseenAt": "…",
"updatedAt": "…",
"sort": 1,
"enabled": true
}
}
Errors
| Status | Description |
|---|---|
| 401 | Unauthorized |
Generated from @openapi JSDoc. Do not edit by hand — run npm run docs:api.