opschain admin agent resume
packs:agents
opschain admin agent resume <agent-id> [--server <url>] [--auth-token <token>]
Lifts one agent's drain (v2 AgentService.SetAgentDraining): its declared
capabilities answer again and the fleet views read ready once the agent
is online. The inverse of opschain admin agent drain.
This lifts the drain only. A group-level drain still quiesces the agent
(quiesced (group)), and an emergency halt is lifted with
opschain admin agent halt-resume, not with this verb.
<agent-id> is the agent's member id — the ID column of
opschain admin agents list.
Flags
| Flag | Meaning |
|---|---|
--server <url> | Server base URL. Default: the active context, then OPSCHAIN_SERVER. |
--auth-token <token> | Admin bearer token override. Default: your opschain login session, then $OPSCHAIN_ADMIN_TOKEN, then the token stored by opschain admin login for that server. |
Output
Always a machine document (JSON unless -o yaml):
{
"draining": false,
"id": "01999a7e-…"
}
Exit codes
| Code | Meaning |
|---|---|
| 0 | The drain was lifted. |
| 1 | The server refused or failed the request (including a rejected admin token, or an unknown agent id). |
| 2 | Usage — wrong arguments, or no server / admin token resolvable. |
Named errors
a server is required — pass --server <url>, set OPSCHAIN_SERVER, or 'opschain context use <name>'— exit 2.this command needs a login or an admin token — run 'opschain login', pass --auth-token, set OPSCHAIN_ADMIN_TOKEN, or store one with 'opschain admin login'— exit 2.the server rejected the credential — run 'opschain login' again, or check the admin token— exit 1.agent <id> is not known to this estate — admin agent verbs take the ocr_ member id from 'opschain admin agents list' (a UUID is usually the identity-side service_account_id, not the member id)— the unknown, revoked or runner id 404, exit 1.- Any other server refusal is reported as
the server answered <code>: <message>— exit 1.
See also
opschain docs cli/admin-agent-drain— the verb this undoes.opschain docs cli/admin-agent-halt-resume— lifting an emergency halt instead.