POST /agents/:id/pause ignores request body — custom pauseReason cannot be set via API
Symptom
services/agents.js pause() accepts a custom reason (pause(id, reason = "manual")") and stores it in agents.pauseReason, but the route handler calls svc.pause(id)without forwarding the request body. Every API pause is therefore recorded asmanual`.
Impact
Fleet automation needs machine-readable pause reasons (we use namespaced reasons like pcfleet:mirror / pcfleet:retired to distinguish reconciler state from operator action). With the route dropping the body, tooling cannot mark WHY an agent was paused, and other automation cannot distinguish 'paused by operator' from 'paused by fleet tooling'.
Suggested fix
router.post("/agents/:id/pause") should forward an optional reason, e.g. svc.pause(id, req.body?.pauseReason ?? req.body?.reason) (defaulting to "manual"), with the field documented in CreateAgent/pause validation.
Workaround
Direct DB writes (fragile) or dist patch that forwards the body.
Source: paperclipai/paperclip