shell-use
Provides tools to interact with tmux sessions, allowing AI agents to send keystrokes, capture terminal output, and scroll through history, enabling interaction with any CLI application.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@shell-useIn the dev session, open vim and insert 'foo' at line 3"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
shell-use
Let agents use the shell like a human.
Features
Interact with any CLI application (vim, htop, gdb, etc.)
Send special keys (Ctrl+C, Enter, arrow keys, etc.)
Dockerized for easy deployment
Available Tools
Tool | Description |
| Returns allowed session names |
| Captures terminal screen text |
| Sends key input (e.g., |
| Sends literal text ( |
| Scrolls through history |
| Exits copy-mode |
Setup
1. Build the Docker image
docker build -t shell-use:latest .2. Create a tmux session
tmux new-session -s dev2.1. Get the tmux socket path
SOCK="$(tmux display-message -p -F '#{socket_path}')"
[ -S "$SOCK" ] || { echo "tmux socket not found: $SOCK"; exit 1; }3. Configure your MCP client
Claude Code:
claude mcp add shell-use \
-- docker run -i --rm \
-v "$SOCK":/tmux/tmux.sock \
-e SHELL_USE_SOCKET=/tmux/tmux.sock \
-e SHELL_USE_SESSIONS=dev \
shell-use:latestClaude Desktop (claude_desktop_config.json):
{
"mcpServers": {
"shell-use": {
"command": "docker",
"args": [
"run", "-i", "--rm",
"-v", "/tmp/tmux-1000/default:/tmux/tmux.sock",
"-e", "SHELL_USE_SOCKET=/tmux/tmux.sock",
"-e", "SHELL_USE_SESSIONS=dev",
"shell-use:latest"
]
}
}
}Replace
/tmp/tmux-1000/defaultwith the path fromtmux display-message -p -F '#{socket_path}'.
Environment Variables
Variable | Description | Required |
| Comma-separated list of allowed session names | Yes |
| Path to tmux socket (default: | No |
Acknowledgments
Inspired by browser-use.
Available Tools
6 toolscaptureC
Captures current terminal screen text.
| Name | Required | Description | Default |
|---|---|---|---|
| session | Yes | ||
| scroll_back | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are present, so the description carries the full burden of behavioral disclosure. 'Captures current terminal screen text' implies a read operation but does not state side effects, whether scrollback is consumed, or whether terminal state is altered. This lack of detail leaves the agent uncertain about the tool's safety profile.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence that immediately conveys the tool's core purpose. It contains no filler, repetition, or irrelevant details, making it optimally concise while still informative at a high level.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The presence of an output schema reduces the need to explain return values, but the tool has two parameters and operates in a terminal context with sibling tools like scroll. The description does not explain how 'session' and 'scroll_back' affect behavior, nor whether capture requires a specific mode. With 0% schema coverage, this is insufficient for effective invocation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 0%, and the description does not mention either parameter. The required 'session' and optional 'scroll_back' remain unexplained, providing no semantic value beyond the bare names and types in the schema. The description fails to compensate for the lack of schema descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('captures') and the resource ('current terminal screen text'), providing a specific verb+resource definition. It doesn't explicitly mention sibling tools, but the action is distinct enough that no alternative is needed. Slight ambiguity in what 'capture' means (return text vs. save) prevents a 5.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is provided on when to use capture versus scrolling or sending keys. The description does not specify whether a session must be active, whether capture works in scroll mode, or any prerequisites. It gives no context for selecting this tool over alternatives.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
exit_scroll_modeA
Exits tmux copy-mode and returns to normal mode.
| Name | Required | Description | Default |
|---|---|---|---|
| session | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of explaining behavior. It accurately discloses the state transition without hidden side effects. However, it does not mention prerequisites (e.g., whether session must be in copy-mode) or error behavior, but for this simple tool the core behavior is transparent.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single clear sentence with no unnecessary words or repetition. It front-loads the action and is immediately understandable.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple state-transition tool with an output schema, the description covers the core action but lacks information about the required 'session' parameter and any prerequisite conditions. This makes it minimally viable but not fully complete for an agent to invoke correctly without additional context.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has one required parameter 'session' with 0% schema description coverage, and the description provides no explanation of what this parameter represents or how to determine its value. This is a significant gap, as the description adds no meaning beyond the parameter's name and type.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states a specific action ('Exits tmux copy-mode') and the resulting state ('returns to normal mode'). This distinguishes it from sibling tools like scroll or capture, which have different purposes.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage when the user is in tmux copy-mode and wants to return to normal mode, but it does not explicitly state when to use this tool versus alternatives like 'scroll'. There are no exclusions or alternative recommendations, so guidance is only implicit.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_sessionsA
Returns list of available tmux sessions.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
There are no annotations provided, so the description carries the full burden. It indicates a read-only operation by 'Returns list', but doesn't disclose additional traits such as whether the list is a snapshot or includes all session states.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence with no extraneous words. It is front-loaded and immediately conveys the tool's purpose.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a zero-parameter, read-only tool with an output schema, the description sufficiently conveys the tool's purpose and invocation. No additional context is necessary.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has zero parameters, so the schema fully covers parameter space. The description adds no parameter details, but none are needed given the baseline of 4 for zero-parameter tools.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb 'Returns list' and clearly identifies the resource 'available tmux sessions'. This clearly distinguishes it from sibling tools that send input or capture output.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description does not explicitly state when to use this tool versus alternatives, though the purpose is unambiguous. Usage is implied rather than stated, so the agent must infer when to list sessions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
scrollA
Navigates the scrollback buffer (half-pages by default).
| Name | Required | Description | Default |
|---|---|---|---|
| amount | No | ||
| session | Yes | ||
| direction | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It reveals only the default half-page behavior, but does not clarify whether the operation is view-only, what the effect on the session is, or any side effects. This is minimal for a tool without annotation support.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded, efficient sentence with no filler. Every word contributes to the meaning, making it highly concise and well-structured.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool has an output schema and relatively simple parameters, so the description need not cover return values. However, the lack of usage guidance and minimal behavioral detail leaves some contextual gaps for an AI agent, especially given no annotations.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description adds meaning to the 'amount' parameter by noting 'half-pages by default', which helps interpret the default value of 1. However, it does not explain 'session' or 'direction' explicitly, and with 0% schema coverage, it only partially compensates for the missing parameter documentation.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb ('navigates') and a specific resource ('scrollback buffer'), clearly distinguishing it from sibling tools like send_keys or capture. The parenthetical 'half-pages by default' adds useful scope.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies when to use the tool (when you need to navigate the scrollback buffer) but provides no explicit guidance on when not to use it or what alternatives exist. It does not mention relationships to siblings like exit_scroll_mode.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
send_keysC
Sends key input. Supports tmux key notation (Enter, C-c, etc.).
| Name | Required | Description | Default |
|---|---|---|---|
| keys | Yes | ||
| session | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden of behavioral disclosure. It mentions support for tmux key notation but does not disclose side effects, whether it requires an active session, or any error conditions. For a mutation-like tool, this is insufficient.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is extremely concise, two sentences with no filler. It front-loads the primary action and then adds the key notation detail. Every word earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool is simple, but the description is minimal. It lacks context about the session parameter, usage in workflows, and any behavioral nuances. While an output schema exists, the description alone does not adequately complete the picture for an agent deciding whether and how to invoke the tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must clarify parameters. It explains the 'keys' parameter via tmux notation, but entirely omits the 'session' parameter, leaving it undefined. The description adds partial meaning to one parameter but fails to cover the second.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states it sends key input and supports tmux key notation, which clearly defines the action and resource. It differentiates somewhat from siblings like send_text by emphasizing key notation, but it does not explicitly contrast with send_text.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is provided on when to use this tool versus alternatives like send_text. The description implies usage for key input operations but does not state exclusions or alternative scenarios, leaving the agent to infer context.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
send_textA
Sends literal text via tmux buffer. Supports multiline text with \n and \t.
Use enter=True for shell commands - automatically presses Enter after sending. Use enter=False (default) for editors - newlines are preserved as text.
Examples: - Shell: send_text(session, "ls -la", enter=True) -> executes command - Editor: send_text(session, "line1\nline2") -> pastes two lines
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes | ||
| enter | No | ||
| session | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations to rely on, the description carries the transparency burden and does well: it explains literal text handling, multiline support with \n and \t, and the Enter behavior. It does not mention return values or error conditions, but an output schema exists, so those are covered elsewhere.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-structured and concise: a single-sentence definition, followed by parameter-specific guidance, and two illustrative examples. Every line serves a purpose without redundant elaboration.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a relatively simple 3-parameter tool with an output schema, the description covers the essential behavior, parameter semantics, and practical examples. It lacks details about session validation or failure modes, but these are not necessary for basic selection and invocation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must compensate. It does for two of three parameters: text (literal multiline with escapes) and enter (boolean controlling Enter key press). The session parameter is not explicitly described, though its usage is shown in examples; given the low schema coverage, this is a minor gap.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with a specific verb+resource: 'Sends literal text via tmux buffer.' This clearly states the tool's core purpose and distinguishes it from sibling tools like send_keys by emphasizing 'literal text' rather than key sequences. The examples further reinforce what the tool does.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives explicit guidance for parameter usage: 'Use enter=True for shell commands' and 'Use enter=False (default) for editors.' This provides clear context for when to use which setting, though it does not explicitly compare against sibling tools like send_keys or list_sessions, so it stops short of a full when/when-not comparison.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
6 tool updates
v1.0.0- First observed
capture - First observed
exit_scroll_mode - First observed
list_sessions - First observed
scroll - First observed
send_keys - First observed
send_text
TDQS
Each tool has a clear, distinct purpose: listing sessions, capturing output, sending key input, sending text, scrolling, and exiting scroll mode. While send_keys and send_text both handle input, their descriptions clearly differentiate key notation from literal text, and scroll/exiting scroll are complementary rather than overlapping.
Most tools follow a consistent verb_noun pattern (list_sessions, send_keys, send_text, exit_scroll_mode), but capture and scroll are single verbs. This is a minor deviation; the naming remains predictable and readable.
With 6 tools, the server is well-scoped for its purpose of interacting with tmux sessions. Each tool covers a necessary operation—listing, capturing, sending, scrolling—without unnecessary redundancy.
The tool set covers the core lifecycle of terminal interaction: list sessions, send input, capture output, and navigate history. It lacks session creation or pane management, but these are outside the stated purpose of 'shell-use', so only minor gaps exist.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Operate Linux, macOS and Windows from your LLM. Every action runs through an auditable allowlist.
Docs for agent-manager, the terminal UI that runs AI coding agents as live tmux sessions.
Develop, manage, and debug Railway projects, services, and deployments from within agents.
Turns any agent into a full agentic application — branded, interactive screens generated at runtime.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to programmatically control interactive terminal applications through HT sessions, supporting session management, key sending, snapshots, and command execution.1MIT
- FlicenseAqualityDmaintenanceEnables AI agents to spawn, interact with, and orchestrate multiple concurrent terminal sessions via tmux.9-
- AlicenseNot gradedqualityBmaintenanceEnables AI agents to execute commands in a shared tmux session that is simultaneously visible to a human via a web-based terminal UI.1MIT
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to interact with interactive CLI processes via a real PTY, allowing them to send keystrokes, read screen output, and handle interactive prompts.61MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/kyuheon-kr/shell-use'
If you have feedback or need assistance with the MCP directory API, please join our Discord server