read_terminal_output
Reads the output from the active iTerm terminal
Let a model work in the iTerm session you already have open — the one that is mid-SSH, or sitting in a REPL.
LABSCO SUMMARY
Because the tools drive the active iTerm session, everything already true of it — the working directory, the environment, the SSH connection, the REPL you are in — is still true when the model types. send_control_character is what makes that survivable: a command that hangs gets interrupted instead of abandoning the session.
A local server with three tools against the active iTerm terminal: write to it, read what it printed, and send control characters.
iTerm on a Mac, with the session you want driven as the active one, and Node.js on the machine. MIT licensed.
One command — npx -y iterm-mcp
USE CASES
Have the command typed where your environment and directory already are, and read the result.
Work on the far side of a connection you set up by hand, without re-authenticating.
Interrupt the running process and check what state the shell is left in.
Read the tail of the output periodically instead of babysitting the window.
Counted once with only startup setup. Other versions, modes or optional credentials may expose a different list.
read_terminal_outputReads the output from the active iTerm terminal
send_control_characterSends a control character to the active iTerm terminal (e.g., Control-C, or special sequences like ']' for telnet escape)
write_to_terminalWrites text to the active iTerm terminal - often used to run a command in the terminal
BEFORE YOU INSTALL
3 tools when we connected.
CONTEXT COST
Rated by the size of the 3 tool definitions that ride along on every turn, not by how many there are
INSTALLATION
Add the block to your client, or run the command directly.
{
"mcpServers": {
"iterm-mcp": {
"command": "npx",
"args": [
"-y",
"iterm-mcp"
]
}
}
}npx -y iterm-mcp