Skip to main content
Glama
HLH2023
by HLH2023

terminal.press

Input key combinations into a terminal session to control interactive programs.

Instructions

Press a key or key combination in the terminal. Supports arbitrary key expressions: basic keys (enter, tab, escape, up, down, f1-f12), ctrl combos (ctrl+a through ctrl+z), alt combos (alt+enter), shift combos (shift+tab), and multi-modifier combos (ctrl+shift+f). Legacy hyphenated format (ctrl-c) still works.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sessionIdYesSession ID from terminal.start — use exact value
keyYesKey expression. Examples: "enter", "ctrl+a", "ctrl+p", "alt+enter", "shift+tab", "f1", "ctrl+f1". Legacy format "ctrl-c" also works. Use terminal.keys to see common key names.
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It does not mention side effects (e.g., if the key press triggers actions), error conditions (invalid key, dead session), or whether the press is synchronous or returns after the key is processed. This lack of transparency is a significant gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single paragraph that front-loads the core purpose and then details supported key expressions efficiently. Every sentence contributes useful information without redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool is simple with 2 parameters and no output schema. The description adequately explains the input but does not cover return values, error handling, or what happens after pressing the key. Given the simplicity, this is a minor gap; more could be said about expected behavior.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% with descriptions for both parameters. The description adds value beyond the schema by providing a comprehensive list of supported key formats, examples, and mentioning legacy format and the terminal.keys tool. This helps the agent understand the range of valid key expressions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states 'Press a key or key combination in the terminal.' It provides extensive examples and supported formats, distinguishing it from related tools like terminal.type and terminal.mouse_click. The verb 'press' and resource 'key in terminal' are specific and unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implicitly indicates usage for pressing keys but does not explicitly state when to use this tool versus alternatives. It references terminal.keys for discovering key names, which helps with correct invocation. However, no exclusions or when-not-to-use guidance is provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/HLH2023/terminal-use-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server