Skip to main content
Glama

Press a key

browser_press
Destructive

Presses a specified key, such as Enter or Control+A, on the currently focused browser element using a session ID.

Instructions

Press a key on whatever has focus: 'Enter', 'Escape', 'Tab', 'ArrowDown', 'Control+A'.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "session_id": "<session_id>",
      "key": "<key>"
    },
    "name": "browser_press"
  }
}

Input Schema

NameRequiredDescriptionDefault
keyYesA key name, pressed on whatever has focus: 'Enter', 'Escape', 'ArrowDown', 'Control+A'.
session_idYesThe session_id `browser_open` returned.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.14.0

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already declare destructiveHint=true, openWorldHint=true and idempotentHint=false, so accuracy of the safety profile is not the description's burden. The description does add meaningful behavior — keys are sent to the focused element rather than a selector-targeted one — but it never mentions that key presses can trigger destructive page actions (form submits, navigation) despite the destructive annotation.

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?

A single short sentence with the key examples front-loaded and the focus constraint stated immediately; nothing extraneous.

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?

For a two-parameter key-press tool the description covers the essentials — what it presses and that it targets current focus — and annotations plus a fully described schema carry the rest. However, it omits any note that an agent should establish focus (e.g. via click or snapshot) before pressing, which is the main failure mode for this tool.

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

Parameters3/5

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

Schema description coverage is 100%, so both parameters are already documented and the description's key examples duplicate the schema's key field text. It adds no syntax detail (modifier ordering, case sensitivity) beyond what the schema provides, so baseline 3 applies.

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

Purpose4/5

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

States a specific verb and resource ("Press a key") plus the key examples, which is unambiguous about the operation. It does not distinguish itself from siblings like browser_type (text entry) or browser_click, leaving an agent to infer the boundary.

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

Usage Guidelines3/5

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

The phrase "on whatever has focus" implicitly tells the agent focus must be established first, which is a real usage prerequisite, but there is no explicit when-to-use versus browser_type or when-not guidance.

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