Skip to main content
Glama

Robot Actions — Remote Device Control

webpage_type

Type text into an input/textarea in the device browser, by CSS selector or by a ref from a page-elements listing — works on BOTH iOS Safari and Android Chrome. On iOS it taps the field and types on the DEVICE keyboard, so the page gets real trusted keystrokes (keydown, keypress, beforeinput, input) exactly as from a person — use this for anything that reacts to typing rather than just reading .value. Otherwise it sets the value via the native HTMLInputElement/HTMLTextAreaElement value setter (so React/Vue-controlled inputs register the change) and dispatches bubbling input and change events, which are isTrusted:false. The response reports which happened via via ("nativeKeyboard" or "jsValue"), and when it fell back to jsValue it names the cause in fallbackReason — you never have to guess whether a degraded path was taken. Pass require:"native" to make an unavailable device keyboard a hard error instead of a silent downgrade, for fields that only behave correctly under real keystrokes. exact:false means the keystrokes landed but the component rewrote the value as you typed (masks, autocompletes) — that is a success, not a failure. By default appends to the existing value; pass clear:true to replace it.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
refNoElement ref from a page-elements listing, e.g. "e12". Provide this or `selector`. A ref points straight at the element it was issued for, so it survives markup that shifted position, and it can address elements no CSS selector can reach from the top of the page.
textYesText to type
udidYesDevice UDID / serial (iOS or Android)
clearNoReplace the existing value instead of appending (default: false)
pageIdNoTarget page/tab id — auto-picked when omitted
socketNoAndroid only: abstract unix socket name (default: chrome_devtools_remote)
requireNoSet to "native" to fail loudly when the device keyboard is unavailable, instead of silently falling back to setting .value (isTrusted:false). Use for fields that gate on real keystrokes. iOS only — Android has no native-keyboard path here.
selectorNoCSS selector for the target element. Provide this or `ref`.
platformVersionNoIgnored (kept for compatibility)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / require
      Added value: +{
      +  "description": "Set to \"native\" to fail loudly when the device keyboard is unavailable, instead of silently falling back to setting .value (isTrusted:false). Use for fields that gate on real keystrokes. iOS only — Android has no native-keyboard path here.",
      +  "enum": [
      +    "native"
      +  ],
      +  "type": "string"
      +}
  2. Changed3 schema fields changed
    • addedInput schema / properties / ref
      Added value: +{
      +  "description": "Element ref from a page-elements listing, e.g. \"e12\". Provide this or `selector`. A ref points straight at the element it was issued for, so it survives markup that shifted position, and it can address elements no CSS selector can reach from the top of the page.",
      +  "type": "string"
      +}
    • changedInput schema / properties / selector / description
      Previous value: -"CSS selector for the input/textarea element"New value: +"CSS selector for the target element. Provide this or `ref`."
    • changedInput schema / required
      Previous value: -[
      -  "udid",
      -  "selector",
      -  "text"
      -]New value: +[
      +  "udid",
      +  "text"
      +]
  3. First observed

TDQS

A4.7/5.0
Behavior5/5

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

With no annotations provided, the description must fully disclose behavior itself, and it does exceptionally well. It details the two execution paths, the isTrusted flag on dispatched events, the response fields (`via`, `fallbackReason`), the semantics of `exact:false` (success, not failure), and the append-vs-clear default. The agent knows exactly what will happen, including degraded paths, without needing to guess.

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 long (eight sentences) but every sentence carries critical operational information: purpose, platform difference, event trust, fallback reporting, error handling, and value mutations. The main action is front-loaded in the first sentence, and the rest unfolds logically. No filler or redundancy—each sentence earns its place given the complexity of the tool.

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

Completeness5/5

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

Given the tool's complexity (dual execution paths, platform differences, fallback semantics) and the absence of both annotations and an output schema, this description is remarkably complete. It even covers response fields like `via`, `fallbackReason`, and `exact` to prevent misinterpretation. An agent has everything needed to invoke the tool correctly and anticipate its 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?

The schema already describes all 9 parameters (100% coverage), so the baseline is 3. The description adds genuine value beyond the schema by explaining the trade-offs of `ref` vs `selector`, the purpose of `require` (hard error on unavailable keyboard, iOS only), and the append/clear default behavior. This extra context meaningfully helps agent selection, though the schema alone was already quite informative.

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 opens with a precise action and target: 'Type text into an input/textarea in the device browser, by CSS selector or by a ref.' It immediately scopes the tool to device browsers (iOS Safari and Android Chrome), which distinguishes it from sibling tools like device_type (native apps) and web_type (desktop web). The specific mention of the two platform paths and the trusted-keystroke mechanism makes the purpose unmistakable.

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?

It gives clear context on when to rely on the native keyboard path ('use this for anything that reacts to typing rather than just reading .value') and when the JavaScript value setter is appropriate (React/Vue-controlled inputs). It also explains the require:"native" option for fields that need real keystrokes. However, it never names sibling tools like device_type, ios_send_keys, or web_type, or says when to prefer them, so the exclusion guidance is implicit rather than explicit.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources