Skip to main content
Glama

type_text

Destructive

Types Unicode-safe text into the focused field; optionally clears existing content first or presses Return to submit it.

Instructions

Type into the focused field — unicode-safe. Click the field first to focus it.

To set a form field in one verified call use fill() instead (click + replace + read back). Returns {"ok", "action", "instance", "detail", "method": "xdotool"|"clipboard", "warnings"?}. clear=true selects the field's content first (ctrl+a) so the text REPLACES it; submit=true presses Return afterwards — one call for "fill and submit". Pure ASCII is typed via xdotool (timeout scales with length); text with any non-ASCII char (č/š/ž …) is inserted via the clipboard + ctrl+v, because xdotool's synthetic unicode keystrokes get silently dropped by some toolkits (e.g. Inkscape's GTK canvas) even though they work in browsers. The clipboard is put back as it was afterwards (previous text, or cleared), best-effort: an app that reads the selection late (> 0.3 s) can paste the restored text instead, and the host bridge may have mirrored the typed text in that window — see clipboard(). Terminals that paste with shift+Insert instead of ctrl+v need press_keys after clipboard(action='set'). Fails (isError) rather than silently losing characters if xclip is missing for non-ASCII text. observe/settle_ms: see click().

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": {
      "text": "<text>"
    },
    "name": "type_text"
  }
}

Input Schema

NameRequiredDescriptionDefault
textYes
clearNo
submitNo
observeNonone
instanceNo
settle_msNo
observe_regionNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv0.6.1
    • addedInput schema / properties / clear
      Added value: +{
      +  "default": false,
      +  "title": "Clear",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / observe_region
      Added value: +{
      +  "default": "",
      +  "title": "Observe Region",
      +  "type": "string"
      +}
    • addedInput schema / properties / submit
      Added value: +{
      +  "default": false,
      +  "title": "Submit",
      +  "type": "boolean"
      +}
  2. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

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

Annotations only declare mutation/open-world/destructive; the description earns its keep by disclosing the dual backends (xdotool for pure ASCII, clipboard+ctrl+v for any non-ASCII), the reason for that split (synthetic unicode keystrokes silently dropped by some GTK toolkits), timeout scaling with length, and the clipboard-restore race (>0.3 s late readers can paste restored text). It also states the failure contract — isError rather than silent character loss when xclip is absent.

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?

Front-loads purpose, then the alternative, then the return shape, then flags, then behavioral caveats — a sensible order. The clipboard-restore discussion is dense and slightly over-long for the risk it describes, but nearly every sentence carries operational information rather than filler.

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?

For a 7-parameter mutation tool with no output schema, the description supplies the return shape inline ({"ok", "action", "instance", "detail", "method", "warnings"?}), the timing caveat, and the failure mode. Combined with annotations, an agent has enough to call it correctly and interpret the result.

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 0%, so the description must carry the weight. It adequately explains text (unicode handling), clear (ctrl+a then replace), and submit (Return), and defers observe/settle_ms to click(). However, instance and observe_region — two of seven parameters — get no semantic treatment at all, so the gap is only partially closed.

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 target ("Type into the focused field — unicode-safe") and immediately names the sibling it is not (fill() for one verified call). An agent can distinguish type_text from fill, press_keys, and clipboard without opening any schema.

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

Usage Guidelines5/5

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

Gives an explicit precondition ("Click the field first to focus it"), an explicit alternative with its selection condition (fill() when you want click + replace + read-back in one verified call), and per-flag routing (clear=true for replace, submit=true for fill-and-submit). It also names the escape hatch for terminals that paste via shift+Insert by pointing to press_keys after clipboard(action='set').

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