glass_type
Types synthetic keystrokes into the focused UI element or a specified target, resolving and confirming focus before typing to avoid missed input. Use when you need to enter text reliably in a desktop app.
Instructions
Type text once. Without target, focused-window typing sends keystrokes to current focus. A target resolves one fresh unique element; focus_mode auto, native or pointer confirms focus then types once. Unconfirmed focus never types or tries another path. Newlines do not press Return: use a key action. No value confirmation; verify the resulting field. Never replay after uncertain dispatch. For 2+ known steps, use glass_do.
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": "glass_type"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes | Synthetic keystrokes, not paste. When `target` is omitted: current keyboard focus. When `target` is supplied: resolves and focuses the target, confirms focus, then types. Newlines do not press Return. | |
| return | No | none (default): no observation; settle: text-only visual stability; snapshot: settle and read the current accessibility tree, including app-visible text, with secure values redacted. | |
| target | No | ||
| max_nodes | No | ||
| focus_mode | No | ||
| timeout_ms | No |