wait_for_text
-
Read pane output; accepts no client-supplied executable input. Returned content may be sensitive or untrusted. Wait within one deadline for pane text. From tmux 3.7 it streams pane output over a control client; below 3.7 it reads the screen on a timer, so output that changes no row, such as blank-only output, is not seen. Ends as matched, stopped, timedOut, expiredWhileReading, paneClosed, or alternateScreen.
- MCP request method
tools/callSendwait_for_textas the tool name, with the arguments below.
Arguments#
-
Caller-controlled cursor.
- maxLength
16384
-
Caller-controlled maxLines.
- minimum
1- maximum
2000
-
Caller-controlled paneId.
-
Caller-controlled patterns.
- maxItems
32
-
Caller-controlled regex.
-
Caller-controlled stop.
- maxItems
32
-
Caller-controlled timeoutMs.
- minimum
100- maximum
600000
No other arguments are accepted.
Result#
Returns object
-
matchedIndex(integer | null) #
No other properties are accepted.
Annotations#
destructiveHinttrueidempotentHintfalseopenWorldHinttruereadOnlyHintfalsetitle"Wait for text"
Protocol data#
Use the complete advertised contract for validation and client integration.
Input schema
{"additionalProperties": false,"properties": {"cursor": {"description": "Caller-controlled cursor.","maxLength": 16384,"type": "string"},"maxLines": {"description": "Caller-controlled maxLines.","maximum": 2000,"minimum": 1,"type": "integer"},"paneId": {"description": "Caller-controlled paneId.","type": "string"},"patterns": {"description": "Caller-controlled patterns.","items": {"type": "string","x-libtmux-max-utf8-bytes": 4096},"maxItems": 32,"type": "array"},"regex": {"description": "Caller-controlled regex.","type": "boolean"},"stop": {"description": "Caller-controlled stop.","items": {"type": "string","x-libtmux-max-utf8-bytes": 4096},"maxItems": 32,"type": "array"},"timeoutMs": {"description": "Caller-controlled timeoutMs.","maximum": 600000,"minimum": 100,"type": "integer"}},"required": ["paneId","patterns"],"type": "object"}Output schema
{"additionalProperties": false,"properties": {"cursor": {"type": ["string","null"]},"effectiveTimeout": {"type": "number"},"matched": {"type": ["string","null"]},"matchedAtEntry": {"type": "boolean"},"matchedIndex": {"type": ["integer","null"]},"outcome": {"type": "string"},"paneRef": {"type": "string"},"sawNewOutput": {"type": "boolean"},"seconds": {"type": "number"},"tail": {"items": {"type": "string"},"type": "array"}},"required": ["cursor","effectiveTimeout","matched","matchedAtEntry","matchedIndex","outcome","paneRef","sawNewOutput","seconds","tail"],"type": "object"}