Read terminal
tmux_readReads recent terminal pane output, including scrollback, and can wait for a regex match or command completion. Use it to inspect live command results and pane status.
Instructions
Return the pane's last lines lines (what the human sees, plus scrollback),
optionally waiting first. Last line: [at shell prompt] or [foreground: X],
plus [timeout: ...] if the wait gave up.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "tmux_read"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| lines | No | How many trailing lines to return, scrollback included. | |
| timeout | No | Max seconds to wait. | |
| wait_for | No | Python regex; first poll until it appears in output since the last tmux_send in this pane, e.g. '(?m)^BUILD OK'. Anchor it with ^ so the typed command line itself doesn't match. | |
| wait_done | No | First poll until the last tmux_send's command has finished (shell or REPL prompt back). | |
| target_pane | No | tmux target such as "0:1.0" (session:window.pane, from tmux_list_panes); empty = the agent session "agent" |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |