Update an agent
update_agentUpdate a CI agent's name, labels, or organization, and drain it by enabling no_schedule to let it finish current work and accept no new jobs.
Instructions
Changes an agent. Admin only. no_schedule=true is the drain switch: the agent finishes its current work and takes nothing new.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Display name of the agent. | |
| org_id | No | Set for an organization-scoped agent when the account is an organization admin rather than an instance admin — that route is the only one they may use. | |
| agent_id | Yes | Numeric agent id. | |
| no_schedule | No | When true the agent finishes what it has and accepts no new work — how you drain an agent before taking its host down. | |
| custom_labels | No | Labels this agent advertises, as a flat string map. A pipeline selects agents with a matching "labels" block. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| truncated | No | Present only when the answer was shortened to fit the budget. |