Skip to main content
Glama

Press a key

press

Send a keystroke to the focused browser element to submit forms, move focus, close dialogs, or navigate menus, while triggering the key's normal page effect.

Instructions

Press a key in the focused element, e.g. Enter to submit a form, Tab to move focus, Escape to close a dialog, ArrowDown in a menu, Shift+Tab, Control+a. Recordful also performs the key's usual effect (submitting, moving focus, deleting), since pages ignore synthetic keys otherwise.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
keyYesKey to press in the focused element, optionally with modifiers: Enter, Tab, Escape, Backspace, Delete, Space, ArrowUp, ArrowDown, ArrowLeft, ArrowRight, Home, End, PageUp, PageDown, F1–F12, or a single character, e.g. "Enter", "Shift+Tab", "Control+a".

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

A4.1/5.0
Behavior4/5

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

Annotations declare non-readonly, non-idempotent, open-world behavior, so the safety bar is partly covered. The description adds genuinely useful disclosure beyond that: the key press triggers the page's real effect (submitting, moving focus, deleting) because synthetic keys are otherwise ignored, which explains the non-idempotent side effects and warns of consequential actions.

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

Conciseness4/5

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

The capability and its examples are front-loaded in the first sentence, with the behavioral caveat following. It is dense but every clause carries information; only the double-embedding of examples and the parenthetical aside slightly dilute readability.

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

Completeness4/5

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

For a single-parameter tool with no output schema and rich annotations, the description covers purpose, valid inputs, and side-effect behavior. It omits edge cases such as pressing keys with no focused element or a missing target, but nothing essential to correct invocation is missing.

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% and the schema already enumerates valid keys, modifiers, and the regex pattern. The description's examples mirror that content rather than adding new semantics (e.g., no guidance on focus requirements, timing, or what happens when no element is focused), so baseline 3 applies.

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?

States a specific verb and resource ("Press a key in the focused element") and immediately grounds it in recognizable scenarios (submit, move focus, close dialog, menu navigation). It is trivially distinguishable from siblings like click, type, and scroll, which operate on different targets.

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 examples effectively communicate when to reach for this tool rather than type or click, and the modifier syntax (Shift+Tab, Control+a) tells the agent what shapes of input are expected. There is no explicit statement of when NOT to use it or a named alternative, so it stops short of a 5.

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