Skip to main content
Glama

input_text

Type text into focused input fields on Android devices through the Android MCP Server, enabling automated text entry for UI automation tasks.

Instructions

Type text into the currently focused input field on the Android device. The field must already be focused (tapped).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
textYesText to type into the focused field
device_idNoDevice serial number

Implementation Reference

  • Implementation of the input_text tool handler which uses adb shell to send text input.
    export async function inputText(text: string, deviceId?: string): Promise<string> {
      const resolved = await deviceManager.resolveDeviceId(deviceId);
      deviceManager.checkRateLimit(resolved);
    
      const sanitized = sanitizeTextInput(text);
      await adbShell(['input', 'text', sanitized], resolved);
    
      deviceManager.touchSession(resolved);
      log.info('Text input performed', { textLength: text.length, deviceId: resolved });
      return text;
    }
Behavior3/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. It successfully discloses the critical behavioral constraint that the field must be focused first. However, it lacks details on error behavior (what happens if not focused), side effects, or return value structure.

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?

Two sentences with zero waste. The first sentence front-loads the action and target; the second sentence provides the essential prerequisite. Every word earns its place.

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 2-parameter tool with 100% schema coverage and no output schema, the description adequately covers the essential domain-specific constraint (Android focus requirement). It could be improved by mentioning error handling or success indicators, but it is sufficient for correct invocation.

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%, establishing a baseline of 3. The description implies the 'text' parameter ('Type text') and 'device_id' context ('Android device'), but does not add syntax details, format constraints, or examples beyond what the schema already provides.

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 provides a specific verb ('Type'), target resource ('currently focused input field'), and context ('Android device'). It clearly distinguishes from siblings like 'press_key' (individual keys) and 'tap'/'click_element' (focusing actions) by emphasizing the text-input-on-focused-field behavior.

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?

Explicitly states the prerequisite condition ('The field must already be focused') which implies the necessary workflow sequence. However, it does not explicitly name which sibling tools (e.g., tap, click_element) should be used to achieve the focused state, though 'tapped' provides a hint.

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/divineDev-dotcom/android_mcp'

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