Skip to main content
Glama

press_key

Send Android key events such as home, back, enter, delete, power, volume, and KEYCODE_* names to control a device through ADB.

Instructions

Press a key: home, back, enter, delete, recent, power, volume_up, volume_down, tab, wake, notifications, quick_settings, or any KEYCODE_* name.

Input Schema

NameRequiredDescriptionDefault
keyYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.9/5.0
Behavior3/5

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

With no annotations, the description must carry the behavioral burden. It discloses the supported key values and KEYCODE_* flexibility, but it does not state device-targeting expectations, whether a device must be selected or unlocked, or what the tool returns or blocks on.

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 front-loaded sentence with a compact, necessary enumeration of supported values. There is no filler or redundant wording.

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 one-parameter action tool with no output schema, the description gives enough to invoke it correctly by specifying valid keys. It could be more complete by mentioning the current selected device or any required device state, but the core invocation details are present.

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

Parameters5/5

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

Schema description coverage is 0%, so the description must define the single parameter. It does so well by listing concrete accepted key names and allowing any KEYCODE_* name, which adds substantial meaning beyond the bare string schema.

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?

The description states a specific verb and resource, 'Press a key,' and enumerates the supported key names. It is clear what the tool does, but it does not explicitly distinguish itself from siblings such as type_text, tap, or adb_shell.

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 list of valid keys implies when the tool is appropriate, but there is no explicit guidance on when to use it instead of type_text, tap_element, or adb_shell. Alternatives and exclusions are left to inference.

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