close-terminal
Close a specific terminal
Open real iTerm2 sessions, run commands in a named one, and read the output back later.
LABSCO SUMMARY
Because every session has its own handle, an assistant can start something in one terminal, leave it running, and come back to read its output later — which is exactly what a single fire-and-forget shell call cannot do. It all happens in your own iTerm2, so you see it as it goes.
A bridge to iTerm2 on macOS. It opens terminal sessions, runs a command in a specific one, reads that session's output back, lists what is currently open, and closes a session when the work is done.
macOS with iTerm2 installed, since iTerm2 is macOS only, and Node to run the server. No account, no key. Input is schema-validated and each session is isolated from the others.
One command — npx iterm_mcp_server
USE CASES
Open a session, start the build in it, and read the output when you come back rather than waiting on one call.
Open a second session for the server while the first runs the tests, and keep track of which is which.
List what is still open and read the output of the one you left running.
Close the session you finished with, so the next question is not answered against a stale terminal.
Counted once with only startup setup. Other versions, modes or optional credentials may expose a different list.
close-terminalClose a specific terminal
execute-commandExecute a command in a specific terminal
list-terminalsList all active terminals and their information
open-terminalOpen a new terminal instance
read-outputRead the output from a specific terminal
BEFORE YOU INSTALL
5 tools when we connected.
CONTEXT COST
Rated by the size of the 5 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_server": {
"command": "npx",
"args": [
"iterm_mcp_server"
]
}
}
}npx iterm_mcp_server