MCP server for debugging PTY/TTY/TUI programs. Enables Claude Code to control Claude Code, vim, and other TUI apps.
The PTY MCP server defines 6 tools with verb-based naming (spawn_session, send_input, get_snapshot, resize_terminal, list_sessions, close_session) and provides schemas for all. However, tool descriptions are generic (avg ~80 chars, baseline is 194), most parameter descriptions lack actionable details about constraints and formats, and output schemas are not documented. Error handling is minimal, no guidance on recovery steps or error categorization. The server demonstrates basic structural quality but falls short of production patterns around parameter guidance and output documentation.
Close a PTY session
Get current terminal screen state
List all active PTY sessions
Resize the terminal dimensions
Send keyboard input (text or special keys) to a PTY session
Spawn a TUI program in a new pseudo-terminal session
Parameter descriptions lack actionable constraint details. E.g., 'Command to execute' does not explain required format, acceptable programs, or failure modes. The 'specialKey' param lists examples (enter, tab, shift+tab, ctrl+c, alt+f, f1-f12, arrow keys with modifiers) but does not formalize them as an enum or pattern constraint, forcing LLMs to infer valid values.
Output schemas are not documented. Tools return snapshots, session lists, and resize confirmations, but the LLM has no formal specification of response fields (e.g., snapshot.text, snapshot.cursorPosition, snapshot.ansi). Without documented output schemas, LLMs cannot plan downstream operations or extract chaining IDs.
Error handling provides no recovery guidance. The server catches errors but does not categorize them as retryable, user-fixable, or fatal. E.g., if a sessionId is invalid, the error 'Session not found' gives no hint to retry with list_sessions() or check if the session was already closed.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-22 | D | 57 | 2026-07-28+ | v2 |
| 2026-03-09 | F | 48 | - | v1 |
Tool descriptions are brief (40 - 65 chars) and do not answer 'When should the LLM call this instead of a similar tool?' E.g., get_snapshot and send_input could both be used to observe state, but their descriptions do not clarify the distinction or recommended usage patterns.
The 'specialKey' parameter in send_input uses string type with examples rather than a constrained enum. Valid values are documented in the description but not machine-parseable. LLMs may attempt 'Enter', 'ENTER', 'enter', 'Return', or other variants not in the whitelist, causing silent failures.
No explicit confirmation or dry-run for destructive operations. close_session with SIGKILL is irreversible, but there is no confirmation step or preview. An agent could accidentally terminate the wrong session.