CCM
/MCP
SkillsMCPMarketplacesDigestToolsAdvertise

This week in Claude

Every Monday: Claude Code, Agent SDK, MCP, and the Anthropic platform moves worth your time.

Skills by Category
Frontend DevelopmentBackend & APIsTesting & QASecurityDevOps & CI/CDGit & Pull RequestsDocumentationCode Review & QualityAI & Agent BuildingSkill Development
MCP Servers by Category
Sales & MarketingWeb & Browser AutomationDatabasesAI & LLM ToolsCloud & InfrastructureCommunication & MessagingDeveloper ToolsDesign & CreativeDocuments & KnowledgeSearch & Web Crawling
Marketplaces by Category
AI Agents & OrchestrationLLM IntegrationDevelopment ToolsFrontend & UIBackend & APIsDatabasesTesting & Code QualityDevOps & CloudSecurity & ComplianceGit & Version Control

Claude Code Marketplaces

Discover Claude Code plugins, extensions, and tools. Automatically updated directory of Anthropic Claude AI marketplaces with development tools, productivity plugins, and integrations.

Resources

  • Browse Skills
  • Browse MCP Servers
  • Browse Marketplaces
  • Skill index
  • MCP index
  • Marketplace index
  • Plugins Reference

Community

  • About
  • Tools
  • Feedback
  • Privacy Policy
  • Advertise

Built for the Claude Code community with Claude Code by mertbuilds.com

Independent project, not affiliated with Anthropic
mkpvishnu avatar

Terminal Mcp

mkpvishnu/terminal-mcp
79 toolsSTDIOregistry active
Summary

This server wraps persistent PTY sessions so Claude can interact with SSH connections, database CLIs, REPLs, and TUI applications that the built-in Bash tool can't handle. It exposes tools like session_create, session_send, session_read, and session_interact to manage long-lived processes across multiple tool calls. You get regex-triggered reads with session_wait_for, special key support for arrow keys and control characters, and four read modes including auto-detection of alternate screen buffers for tools like htop or vim. It includes a dangerous command gate that prompts before running destructive operations, OSC 133 shell integration for exit code detection, and configurable output truncation to manage token usage. Reach for this when you need Claude to maintain an interactive session that survives beyond a single command execution, whether that's a multi-line Python REPL or a live MySQL prompt.

CodeRabbit
CodeRabbit
AI writes the code. CodeRabbit catches the slop.
Try For Free →
inference shell
inference shell
create and run specialised agents in minutes
build now →
MCP-ready Email SendingMCP-ready Email Sending
MCP-ready Email Sending
Plug Mailtrap into your AI workflow and let it handle the email.
Connect Mailtrap MCP →
Make your agent a DeFi expert
Make your agent a DeFi expert
Agent, run crypto. Access onchain data & trade routes via 1inch.
Install now →
Capacitor - Shared memory for your team’s coding agents.
Capacitor - Shared memory for your team’s coding agents.
Make coding agent sessions - Searchable, Shareable, Vendor-neutral & Scored.
Try For Free →
CodeScene MCP ServerCodeScene MCP Server
CodeScene MCP Server
Your agent targets a perfect 10 Code Health score. Deterministic. Every commit.
Try For Free →
Give your AI the whole web as clean markdownGive your AI the whole web as clean markdown
Give your AI the whole web as clean markdown
Integrate web data into your AI product. One API to scrape website & brand data.
Get API Key Now →
belt - the only tool your agent needs
belt - the only tool your agent needs
belt cli automatically finds the best tools and skills for your agent. image, video, music, tts...
one prompt install →
CodeRabbit
CodeRabbit
AI writes the code. CodeRabbit catches the slop.
Try For Free →
inference shell
inference shell
create and run specialised agents in minutes
build now →
MCP-ready Email SendingMCP-ready Email Sending
MCP-ready Email Sending
Plug Mailtrap into your AI workflow and let it handle the email.
Connect Mailtrap MCP →
Make your agent a DeFi expert
Make your agent a DeFi expert
Agent, run crypto. Access onchain data & trade routes via 1inch.
Install now →
Capacitor - Shared memory for your team’s coding agents.
Capacitor - Shared memory for your team’s coding agents.
Make coding agent sessions - Searchable, Shareable, Vendor-neutral & Scored.
Try For Free →
CodeScene MCP ServerCodeScene MCP Server
CodeScene MCP Server
Your agent targets a perfect 10 Code Health score. Deterministic. Every commit.
Try For Free →
Give your AI the whole web as clean markdownGive your AI the whole web as clean markdown
Give your AI the whole web as clean markdown
Integrate web data into your AI product. One API to scrape website & brand data.
Get API Key Now →
belt - the only tool your agent needs
belt - the only tool your agent needs
belt cli automatically finds the best tools and skills for your agent. image, video, music, tts...
one prompt install →

Tools

Public tool metadata for what this MCP can expose to an agent.

9 tools
terminal_startStart a terminal session. Auto-detects shell if omitted.6 params

Start a terminal session. Auto-detects shell if omitted.

Parameters* required
colsinteger
default: 120
cwdstring
envobject
namestring
rowsinteger
default: 30
shellstring
terminal_execRun a command in a session and wait for completion.6 params

Run a command in a session and wait for completion.

Parameters* required
commandstring
maxLinesinteger
default: 200
minOutputBytesinteger
Min bytes before quiet exitdefault: 1
quietExitMsinteger
Exit if silent for N ms
sessionIdstring
timeoutinteger
default: 30000
terminal_runRun a binary directly. shell=true for built-ins/pipes/redirects.12 params

Run a binary directly. shell=true for built-ins/pipes/redirects.

Parameters* required
argsarray
cmdstring
cwdstring
maxOutputBytesinteger
default: 102400
parseboolean
Parse structured outputdefault: true
parseOnlyboolean
Omit raw when parseddefault: false
shellboolean
Run via system shelldefault: false
successExitCodevalue
null=anydefault: 0
successFilestring
successFilePatternstring
Regex
summaryboolean
default: false
timeoutinteger
default: 30000
terminal_writeWrite raw data to a terminal session.2 params

Write raw data to a terminal session.

Parameters* required
datastring
sessionIdstring
terminal_readRead new output from a terminal session.5 params

Read new output from a terminal session.

Parameters* required
idleTimeoutinteger
Must be < timeoutdefault: 500
maxLinesinteger
default: 200
sessionIdstring
sinceinteger
Byte position for inc. read
timeoutinteger
default: 30000
terminal_waitWait for a pattern to appear in terminal output.5 params

Wait for a pattern to appear in terminal output.

Parameters* required
patternstring
returnModestring
one of tail · full · match-onlydefault: tail
sessionIdstring
tailLinesinteger
default: 50
timeoutinteger
default: 30000
terminal_stopStop a terminal session.3 params

Stop a terminal session.

Parameters* required
sessionIdstring
snapshotLinesinteger
Return last N lines. 0 = none.default: 0
transcriptPathstring
Write history to this path
terminal_listList active terminal sessions.1 params

List active terminal sessions.

Parameters* required
verboseboolean
default: true
terminal_extra8 more tools: terminal_run_paged, terminal_get_history, terminal_resize, terminal_send_key, terminal_watch, terminal_retry, terminal_diff, terminal_write_file. list=true for full schemas, or pass tool + args to call.3 params

8 more tools: terminal_run_paged, terminal_get_history, terminal_resize, terminal_send_key, terminal_watch, terminal_retry, terminal_diff, terminal_write_file. list=true for full schemas, or pass tool + args to call.

Parameters* required
argsobject
listboolean
default: false
toolstring

terminal-mcp banner

Give your AI a real terminal. Persistent sessions. Interactive programs. Zero limitations.

PyPI Python 3.10+ License: MIT CI CodeQL

Install in VS Code Install in VS Code Insiders Install in Cursor Install in Claude Desktop

terminal-mcp demo


The Problem

Every AI coding tool hits the same wall: no real terminal access.

Claude Code's Bash tool, GitHub Copilot, and Codex all run commands in isolated subprocesses. Each command starts fresh. No state carries over. That means:

  • No SSH sessions - Can't connect to a remote server and run multiple commands
  • No REPLs - Can't use Python, Node, or Ruby interpreters interactively
  • No database CLIs - Can't maintain a psql, mysql, or redis-cli connection
  • No TUI apps - Can't navigate htop, vim, or fzf with arrow keys
  • No long-running processes - Can't monitor builds, watch logs, or run dev servers

The Solution

terminal-mcp gives AI agents a real terminal. Persistent PTY sessions that survive across tool calls. Send commands, read output, press keys, navigate TUIs - exactly like a human at a terminal.

uvx terminal-mcp

One command. Works with Claude Code, Claude Desktop, VS Code, Cursor, and Windsurf.


Quick Start

1. Install (30 seconds)

# No install needed - run directly
uvx terminal-mcp

# Or install globally
pip install terminal-mcp

2. Connect to Your AI Client

Claude Code

Add to ~/.claude.json or project .mcp.json:

{
  "mcpServers": {
    "terminal": {
      "command": "uvx",
      "args": ["terminal-mcp"]
    }
  }
}
Claude Desktop

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "terminal": {
      "command": "uvx",
      "args": ["terminal-mcp"]
    }
  }
}
VS Code / Cursor

Click the one-click install badge above, or add to .vscode/mcp.json:

{
  "servers": {
    "terminal-mcp": {
      "command": "uvx",
      "args": ["terminal-mcp"]
    }
  }
}
Windsurf

Add to ~/.codeium/windsurf/mcp_config.json:

{
  "mcpServers": {
    "terminal": {
      "command": "uvx",
      "args": ["terminal-mcp"]
    }
  }
}

3. Verify

session_exec  exec="echo hello from terminal-mcp"

What Can You Do With It?

SSH Into Remote Servers

session_create   command="ssh user@prod-server.com"   label="prod"
session_interact session_id="a1b2c3d4"  input="df -h"  wait_for="\$"
session_interact session_id="a1b2c3d4"  input="docker ps"  wait_for="\$"
session_close    session_id="a1b2c3d4"

Run Interactive REPLs

session_create   command="python3"  label="python"
session_interact session_id="e5f6g7h8"  input="import pandas as pd"  wait_for=">>>"
session_interact session_id="e5f6g7h8"  input="df = pd.read_csv('data.csv')"  wait_for=">>>"
session_interact session_id="e5f6g7h8"  input="df.describe()"  wait_for=">>>"
session_close    session_id="e5f6g7h8"

Query Databases

session_create   command="psql -U admin mydb"  label="db"
session_interact session_id="x1y2z3w4"  input="SELECT count(*) FROM users;"  wait_for="row"
session_interact session_id="x1y2z3w4"  input="\dt"  wait_for="#"
session_close    session_id="x1y2z3w4"

Navigate TUI Apps

session_create   command="htop"  label="monitor"
session_read     session_id="a1b2c3d4"
# Auto-detects TUI, returns screen snapshot

session_send     session_id="a1b2c3d4"  key="F6"
session_read     session_id="a1b2c3d4"  mode="diff"
# Returns only changed lines - saves tokens

session_send     session_id="a1b2c3d4"  key="F10"
session_close    session_id="a1b2c3d4"

Monitor Long-Running Builds

session_create   command="bash"  label="build"
session_send     session_id="a1b2c3d4"  input="npm run build"
session_wait_for session_id="a1b2c3d4"  pattern="Build complete|ERROR"  timeout=120

Run One-Off Commands

session_exec  exec="git log --oneline -10"
session_exec  exec="docker compose ps"  timeout=10

Features at a Glance

FeatureWhat It Does
Persistent SessionsReal PTY sessions that survive across tool calls
Send + Read in One Callsession_interact halves LLM round trips
Pattern-Based Readswait_for blocks until regex matches - no guessing timeouts
Auto TUI DetectionDetects htop, vim, etc. and auto-switches to screen snapshot mode
Output Diff ModeReturns only changed screen lines - minimizes tokens
Special KeysArrow keys, Tab, F1-F12, Home/End, Page Up/Down
Control CharactersCtrl-C, Ctrl-D, Ctrl-Z, Ctrl-L, telnet escape
Dangerous Command GateBlocks rm -rf, DROP TABLE, curl|sh - requires confirmation
OSC 133 Shell IntegrationAuto-detects command boundaries and exit codes
Smart TruncationFour strategies to prevent context overflow
Secret InputSend passwords without logging
Dynamic ResizeResize terminal on the fly with SIGWINCH
Idle CleanupAuto-closes idle sessions
Cross-PlatformLinux, macOS, and Windows support

Tools Reference

terminal-mcp exposes 9 MCP tools. Full details in docs/tools.md.

ToolPurpose
session_createSpawn a persistent terminal session
session_sendSend text, keys, or control characters
session_readRead output (stream, snapshot, auto, diff modes)
session_interactSend + read in one call
session_wait_forWait for regex pattern in output
session_execOne-shot command execution
session_closeClose a session gracefully
session_resizeResize terminal dimensions
session_listList active sessions

Architecture

flowchart LR
    Client[AI Client] -->|MCP JSON-RPC| Server[terminal-mcp]
    Server --> SM[Session Manager]
    SM --> S1[PTY 1: bash]
    SM --> S2[PTY 2: python3]
    SM --> S3[PTY 3: ssh user@host]
    S1 & S2 & S3 -.->|PTY output| Reader[Reader Thread]
    Reader -.->|buffer| Server

Each session is backed by a real PTY via pexpect.spawn (or PopenSpawn on Windows). For full architecture details, see docs/architecture.md.


Configuration

All settings configurable via TERMINAL_MCP_* environment variables. Full reference in docs/configuration.md.

SettingEnv VarDefault
Max sessionsTERMINAL_MCP_MAX_SESSIONS10
Idle timeoutTERMINAL_MCP_IDLE_TIMEOUT1800 (30 min)
Safety gateTERMINAL_MCP_SAFETY_GATEon
Buffer capTERMINAL_MCP_MAX_BUFFER_BYTES1000000 (1MB)
TruncationTERMINAL_MCP_TRUNCATION_MODEtail

Example with custom settings:

{
  "mcpServers": {
    "terminal": {
      "command": "uvx",
      "args": ["terminal-mcp"],
      "env": {
        "TERMINAL_MCP_MAX_SESSIONS": "20",
        "TERMINAL_MCP_IDLE_TIMEOUT": "3600",
        "TERMINAL_MCP_TRUNCATION_MODE": "head_tail"
      }
    }
  }
}

Documentation

DocumentDescription
Tools ReferenceComplete API for all 9 MCP tools
ArchitectureHow terminal-mcp works under the hood
ConfigurationAll settings and environment variables
Safety & SecurityDangerous command detection and safety gate
Use Cases & ExamplesReal-world recipes and patterns
ChangelogVersion history and release notes
ContributingHow to contribute

Supported Clients

ClientStatusInstall
Claude Code (CLI)Supported~/.claude.json or .mcp.json
Claude DesktopSupportedOne-click install
VS Code (Copilot Chat)SupportedOne-click install or .vscode/mcp.json
CursorSupportedOne-click install or Settings
WindsurfSupported~/.codeium/windsurf/mcp_config.json

Running Tests

pip install -e ".[dev]"
pytest tests/ -v

Contributing

Contributions welcome! See docs/contributing.md for guidelines.

License

MIT

Featured
CodeRabbit
CodeRabbit
AI writes the code. CodeRabbit catches the slop.
Try For Free →
inference shell
inference shell
create and run specialised agents in minutes
build now →
MCP-ready Email SendingMCP-ready Email Sending
MCP-ready Email Sending
Plug Mailtrap into your AI workflow and let it handle the email.
Connect Mailtrap MCP →
Make your agent a DeFi expert
Make your agent a DeFi expert
Agent, run crypto. Access onchain data & trade routes via 1inch.
Install now →
Capacitor - Shared memory for your team’s coding agents.
Capacitor - Shared memory for your team’s coding agents.
Make coding agent sessions - Searchable, Shareable, Vendor-neutral & Scored.
Try For Free →
CodeScene MCP ServerCodeScene MCP Server
CodeScene MCP Server
Your agent targets a perfect 10 Code Health score. Deterministic. Every commit.
Try For Free →
Give your AI the whole web as clean markdownGive your AI the whole web as clean markdown
Give your AI the whole web as clean markdown
Integrate web data into your AI product. One API to scrape website & brand data.
Get API Key Now →
belt - the only tool your agent needs
belt - the only tool your agent needs
belt cli automatically finds the best tools and skills for your agent. image, video, music, tts...
one prompt install →

Configuration

TERMINAL_MCP_MAX_SESSIONS

Maximum concurrent sessions

TERMINAL_MCP_IDLE_TIMEOUT

Seconds before auto-close (default 1800)

Categories
DatabasesDeveloper Tools
Registryactive
Packageterminal-mcp
TransportSTDIO
UpdatedFeb 28, 2026
View on GitHub

Related Databases MCP Servers

View all →
umitkavala avatar
Mindpm

umitkavala/mindpm

Persistent project memory for LLMs via SQLite. Never re-explain your project again.
7
florentine-ai avatar
Mcp

florentine-ai/mcp

MCP server for Florentine.ai - Natural language to MongoDB aggregations
6
alyiox avatar
Microsoft SQL Server

alyiox/mcp-mssql

Read-only MCP for Microsoft SQL Server: metadata discovery, parameterized SELECT, plans.
5
kiki830621 avatar
Che Apple Mail Mcp

kiki830621/che-apple-mail-mcp

Apple Mail MCP — 44 tools, SQLite millisecond search, .emlx parser, batch ops
5
krimto-labs avatar
Krimto

krimto-labs/krimto

Memory for AI coding agents — markdown in your own git, not a vendor database. Apache-2.0.
5
val-town avatar
Val Town

town.val/mcp

Deploy serverless TypeScript on Val Town: HTTP vals, cron, SQLite, email, OAuth.
5