stop_agent
Stop an agent to close its tab while keeping the session resumable. Optionally clean up its worktree and branch, refused if uncommitted or unmerged work exists unless forced.
Instructions
Stop an agent.
An agent started by start_agent has its tab closed; it can be resumed later with send_message. cleanup also removes its worktree and branch and forgets it. That is refused when the worktree has uncommitted files or commits not merged into the repository's current HEAD, unless force=True, which discards that work. An adopted session is only forgotten: its tab, directory, branch and transcript are left alone.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"name": "<name>"
},
"name": "stop_agent"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | ||
| force | No | ||
| cleanup | No |