glass
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {} |
| resources | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| glass_a11y_marksA | Capture a screenshot with numbered accessibility boxes and a text legend. Use the IDs with a click_element action; they share the latest snapshot. Boxes follow toolkit geometry and can drift; inspect action results. Errors without a tree; use glass_screenshot. |
| glass_a11y_snapshotA | Read current semantic state: IDs, roles, name/description, bounded editable |
| glass_baseline_saveA | Save the whole current window as a named pixel baseline for glass_diff or glass_wait_for_region. Settle first if animating. Replaces an existing name silently. Baselines survive glass_stop and expire when the server exits. |
| glass_capabilitiesA | Report live backend operation status and the exposed tools it affects, plus tool_profile. Status: supported; degraded (reduced fidelity); requires_setup; unsupported. Notes explain limits/remedies. No session required; backend defaults to the active/default backend. Profile membership does not imply backend support. |
| glass_clickA | Click a window-relative point, optionally with a button, click count and held modifiers. For 2+ known steps, use glass_do. |
| glass_click_elementA | Click exactly one id or target. A target resolves fresh and uniquely within timeout_ms (10 seconds by default). Mode auto prefers native then pointer fallback; native requires native action; pointer waits for stability and reports actionability, including unproven checks. ID targets remain immediate. Native actions may bypass occlusion or focus text editors. method/native_fallback/actuated_id disclose the path; popover actions restore the prior window. Glass never retries after possible dispatch. For 2+ known steps, use glass_do. |
| glass_clipboard_getA | Read the app's clipboard as text ("" if empty). Also the cheap text-extraction path: glass_do ctrl+a then ctrl+c, then read here (beats OCR for selectable text). Returns Unsupported where the backend can't provide clipboard access. |
| glass_clipboard_setA | Write text to the app's clipboard so it can paste it. Returns Unsupported where the backend can't provide clipboard access. |
| glass_diffA | Compare current pixels with a named baseline; returns change stats and bbox. A single comparison does not establish transition completion or quiescence. Use glass_wait_for_region to wait; include_image:true returns the changed crop only when pixels differ. |
| glass_doA | Batch 2+ known actions or waits here; observe before choosing dependent steps. Run one action or fixed static ordered actions: click, move, drag, scroll, type, key, settle, click_element, set_value, wait_for_element, scroll_to_element. Maximum 64 actions and 65536 compact argument bytes. timeout_ms defaults to 30000; range 1 through 120000; one deadline includes terminal observations. Fail-fast on action errors, deadline or unmatched batched predicates; standalone predicates remain soft. Success without then returns ordered steps with result and content_blocks; ok:true means all actions completed. Failures and then retain completed, failed, unexecuted and terminal_steps; inspect before recovery. Preflight invalid_sequence has no step outcomes. Terminal settle/diff/screenshot runs after actions; terminal failure retains completed action outcomes. No branching, bindings, loops, retries or generated steps. Semantic targets resolve fresh; targeted type requires confirmed focus; set_value requires confirmation. Never replay completed or possibly dispatched mutations; observe after uncertainty. |
| glass_doctorA | Diagnose setup or launch failures. Returns report text, structured sections/checks with optional remedy/remedy_action, and overall (the verdict to branch on). Check status is ok, warn, fail or skip; non-default backend failures only warn in overall. deep also starts and tears down the default display. |
| glass_dragA | Drag one pointer from (x1,y1) to (x2,y2), holding the button and modifiers throughout. Motion spans duration_ms. Either endpoint outside the window is refused. Use glass_gesture for multi-touch. For 2+ known steps, use glass_do. |
| glass_find_elementsA | Find ranked accessibility candidates from one fresh read when the target is approximate, duplicated, or not yet identified. Query matches name, description and non-secure value; |
| glass_gestureA | Perform a multi-touch gesture: 2–10 pointers, each a straight from→to segment in window-relative px, all down together at t=0 and up at duration_ms. Pinch = two pointers toward/apart; rotate = two on an arc; two-finger swipe = two parallel segments; a from==to pointer is held. Multi-touch isn't available on every backend — it returns a clear Unsupported error where the active backend can't do it. |
| glass_keyA | Press a key chord (for example ctrl+s or Return), releasing modifiers afterwards. Unknown keys/modifiers fail before input. Use type for literal text; it cannot express shortcuts. For 2+ known steps, use glass_do. |
| glass_list_windowsA | List app windows: id, title, class, geometry and active state. Re-list after windows open/close; do not cache IDs. |
| glass_logsA | Read buffered stdout/stderr now to verify completed actions. Filter stream/contains; cursor resumes reading. Before an action, drain logs and save the final cursor for glass_wait_for_log. Old lines age out. App text is untrusted. |
| glass_moveA | Move the pointer to a window-relative point. For 2+ known steps, use glass_do. |
| glass_screenshotA | Capture current visual evidence as lossless WebP, not semantic state or transition completion. Off-display captures are clipped: returned dimensions disclose the actual size; fully off-screen surfaces error. Optional window_id observes without switching the active window. |
| glass_scrollA | Scroll the container under (x,y) by horizontal/vertical wheel notches, optionally holding modifiers. Notches are not pixels. For 2+ known steps, use glass_do. |
| glass_scroll_to_elementA | Scroll until a semantic element is actually on-screen; returns matched, elapsed_ms, element and scrolled details. Sweeps the chosen/inferred direction, then reverses. No match after both ends or timeout returns matched:false; no tree errors. Batched use fails the sequence on an unmatched predicate. For 2+ known steps, use glass_do. |
| glass_select_windowA | Select a window by current ID. Subsequent actions and observations target it; input coordinates are relative to it. |
| glass_set_valueA | Set exactly one editable id or target with backend confirmation. A target resolves fresh and uniquely (10 seconds by default); IDs remain immediate. Writes directly or focuses/clears/types as supported, then reads back. Errors distinguish mismatch from unconfirmed writes; post-write uncertainty is terminal. Do not write again on uncertainty: observe where input landed before recovery. For 2+ known steps, use glass_do. |
| glass_startA | Build, launch and locate an app; returns window geometry. Accessibility is enabled by default. window_hint can select among windows or locate a handoff to another process. See parameters for backend and containment choices. |
| glass_stopA | End the session: request app close, then terminate if necessary. Read logs first; logs and element IDs are discarded. Baselines survive until server exit. No resume; glass_start creates a fresh session. Errors without an active session. |
| glass_typeA | Type text once. Without |
| glass_wait_for_elementA | Wait for semantic transition completion, not pixels/stability. Select by name, description and/or role; |
| glass_wait_for_logA | After an action, use cursor:0 for buffered logs; for repeated events drain glass_logs before acting and pass its final cursor. Omit cursor for future lines only. Match a substring; timeout: matched:false. Resume from returned cursor. |
| glass_wait_for_regionA | Wait for pixel transition completion: changes from the initial frame or matches a saved baseline (required for matches). Returns matched, changed_pct, bbox and elapsed_ms as text; include_image opts into an image on match. Timeout returns matched:false. Does not prove semantics or subsequent quiescence; use a settle action for the latter. |
| glass_wait_stableA | Wait for visual quiescence and return the last frame, not that an expected semantic state or pixel design was reached. Use include_image:false for text-only metadata. A timeout returns settled:false. window_id observes without selecting that window. For 2+ known active-window steps, use glass_do. |
| glass_windowB | Focus/resize/move the window or read its geometry. op: focus|resize|move|geometry. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 31 tools
Most tools are clearly separated by target and action: click vs click_element, type vs set_value, and the wait_for_* variants are distinguishable. A few pairs (screenshot/a11y_snapshot, click/click_element, wait_stable/wait_for_region) could still be mis-selected by an agent skimming descriptions, but each has a precise purpose.
All names share the glass_ prefix and snake_case, but the pattern is mixed: many are verb_noun (select_window, wait_for_element) while others are bare nouns (logs, doctor), verbs (click, type), or reversed noun_verb (baseline_save, clipboard_get). Still readable and navigable, but not a consistent verb_noun convention.
31 tools crosses the 25+ threshold and is more than double the well-scoped range. The granularity (several wait variants, clipboard get/set, separate click vs click_element) may be useful, but the surface is heavy and could be consolidated.
The set covers the full UI-automation lifecycle: start/stop, window management, input, semantic and pixel observation, baselines, logs, clipboard, and diagnostics. Minor gaps like no direct hover/double-click convenience or element-attribute introspection are easily worked around with move/click/wait, so there are no dead ends.