MCP server for persistent interactive terminal orchestration
Project description
i4z-terminal-mcp
MCP server that enables AI agents to manage multiple persistent terminal sessions concurrently.
Features
- Persistent PTY-backed bash shells
- 9 MCP tools for full terminal lifecycle management
- Concurrent terminals with isolated async background readers
- Incremental cursor-based output reads
- Pattern-based output waiting
- Signal support (SIGINT, SIGTERM, SIGKILL)
- Web UI — view terminals live at
http://127.0.0.1:9020, create/delete sessions, search output, browse dead sessions, filter history, and switch theme
Install
uv tool install i4z-terminal-mcp
# or
pip install i4z-terminal-mcp
# or from source
uv pip install -e .
Usage
With OpenCode, add to opencode.json:
{
"mcp": {
"terminal": {
"type": "local",
"command": ["uvx", "i4z-terminal-mcp"],
"enabled": true
}
}
}
Or directly:
i4z-terminal-mcp
Tools
| Tool | Description |
|---|---|
create_terminal |
Spawn a persistent bash shell |
list_terminals |
List all active sessions |
terminal_status |
Get PID, CWD, alive, timestamps |
send_input |
Write text/commands to stdin (newline optional) |
read_output |
Incremental read via cursor |
send_signal |
Send SIGINT/SIGTERM/SIGKILL |
kill_terminal |
Destroy session and free resources |
wait_for_output |
Block until pattern appears |
search_output |
Search output history buffer |
Requirements
- Python 3.11+
- Linux or macOS (pexpect PTY support)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
i4z_terminal_mcp-0.5.2.tar.gz
(15.4 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file i4z_terminal_mcp-0.5.2.tar.gz.
File metadata
- Download URL: i4z_terminal_mcp-0.5.2.tar.gz
- Upload date:
- Size: 15.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.30 {"installer":{"name":"uv","version":"0.9.30","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Arch Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
252a7673a9f5e424ccb4df483113fbcd329d9778ffb569d020e84718183f12bc
|
|
| MD5 |
c2fd0e0615bf383c24d7205480914237
|
|
| BLAKE2b-256 |
2fdc5403148350a1588b4e20d36cd282f65607e7ddb7cf7f70bbdbd65d4940b7
|
File details
Details for the file i4z_terminal_mcp-0.5.2-py3-none-any.whl.
File metadata
- Download URL: i4z_terminal_mcp-0.5.2-py3-none-any.whl
- Upload date:
- Size: 14.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.30 {"installer":{"name":"uv","version":"0.9.30","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Arch Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fd630efb1f806ca172ffbb176a93429f92fe0625cd4df4645a425592101c12fb
|
|
| MD5 |
185cde9cd53bc3f84c3e3fcbf0119904
|
|
| BLAKE2b-256 |
f5b18f34b9536557f0a046d64ea18f03f6f5ee943b2212cb9af4ec5e093e8ca8
|