bridge_apply_diff
Applies code changes from a worker’s isolated Git worktree branch into the main repository, then use the session cleanup tool to remove the temporary worktree.
Instructions
Apply the code changes generated by a worker in an isolated git worktree branch into the main repository. After applying, call bridge_close_session(session_id, cleanup_worktree=True) to clean up the temporary worktree.
Args: session_id: Session ID whose worktree branch should be applied. repo_root: Path to the target git repository (defaults to current directory).
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": {
"session_id": "<session_id>"
},
"name": "bridge_apply_diff"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| repo_root | No | ||
| session_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||