iterm2-mcp
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Capabilities
Features and capabilities supported by this server
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| list_sessionsA | List all iTerm2 windows, tabs, and sessions. Returns a tree with session IDs that can be passed to other tools. The
|
| get_active_sessionA | Return the ID and name of the currently focused iTerm2 session. |
| focus_sessionB | Bring a session to the foreground. :param session_id: The session UUID to activate. Its window is raised and its tab/pane is selected. |
| write_to_terminalA | Send text to an iTerm2 session. :param text: The characters to send.
:param session_id: Target session UUID. Defaults to the active session.
:param add_newline: If True (the default), appends |
| send_control_characterA | Send a control character to an iTerm2 session. Supported values: any single letter :param letter: The control key name; see above for accepted forms. :param session_id: Target session UUID. Defaults to the active session. |
| send_escape_sequenceA | Send a raw escape sequence to an iTerm2 session. Python string escapes in :param sequence: The escape sequence string. :param session_id: Target session UUID. Defaults to the active session. |
| read_screenA | Read the visible contents of an iTerm2 session as plain text. ANSI escape codes are stripped. Trailing blank lines are trimmed. :param session_id: Target session UUID. Defaults to the active session. :param max_lines: If set, return only the last N lines. |
| get_cursor_positionA | Return the cursor coordinates :param session_id: Target session UUID. Defaults to the active session. |
| run_commandA | Run a command and wait for it to finish, returning the resulting screen. Completion is detected via iTerm2's :param command: The command line to run.
:param session_id: Target session UUID. Defaults to the active session.
:param timeout_seconds: How long to wait for |
| create_windowA | Create a new iTerm2 window. :param command: Optional shell command to run in the new session. :param profile: Name of the iTerm2 profile to use. Defaults to the default profile. |
| create_tabB | Create a new tab in a window. :param window_id: Target window ID. Defaults to the current window. :param command: Optional shell command to run in the new tab's session. :param profile: Name of the iTerm2 profile to use. |
| split_paneA | Split an iTerm2 pane horizontally or vertically. :param session_id: Session UUID to split. Defaults to the active session. :param vertical: If True, split left/right; if False, split top/bottom. :param profile: Name of the iTerm2 profile to use for the new pane. :param command: Optional command to run in the new pane after the split. |
| close_sessionB | Close a specific session. :param session_id: The session UUID to close. :param force: If True, skip iTerm2's "running process" confirmation prompt. |
| set_session_nameB | Set the title/name of an iTerm2 session. :param name: The new session name. :param session_id: Target session UUID. Defaults to the active session. |
| set_badgeA | Set the iTerm2 session badge (translucent overlay text). The profile's Badge field must reference :param badge: Text to display as the badge. :param session_id: Target session UUID. Defaults to the active session. |
| clear_bufferA | Clear both the visible screen and the scrollback buffer. Uses the iTerm2-proprietary :param session_id: Target session UUID. Defaults to the active session. |
| list_profilesA | List all iTerm2 profiles with their names and GUIDs. |
| get_variableA | Read an iTerm2 session variable. Commonly useful names: :param name: The variable name to read. :param session_id: Target session UUID. Defaults to the active session. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/lorencarvalho/iterm2-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server