Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault

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.

Read-only access to Windows desktop windows.

Typical flow:

  1. list_windows -> pick a window, get its hwnd.

  2. get_ui_tree(hwnd) -> compact list of buttons, edits, tabs with screen rects.

  3. capture_window(hwnd) -> pixels of that window only, even if it is covered.

  4. capture_som(hwnd) -> the same capture with numbered boxes on every control, for when you need to locate something visually or in a dense layout.

Nothing here clicks, types or moves the mouse. Coordinate space is physical screen pixels, and captures report the screen position of image pixel (0,0).

Known limits: elevated windows need an elevated server; Chromium/Electron apps expose no UI tree unless started with --force-renderer-accessibility (screenshots still work); minimised windows and some GPU surfaces capture blank.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": false
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}

Tools

Functions exposed to the LLM to take actions

NameDescription
list_windowsA

List visible top-level windows, foreground first.

Returns hwnd, process name, rect in physical screen pixels, whether the
window is covered by another window (occluded), and whether it can only be
read by an elevated server (elevated). Titles are localized by Windows.

Use the hwnd with get_ui_tree and capture_window. hwnds are stable for the
lifetime of a window but change when the app is restarted.
get_ui_treeA

Read the UI Automation tree of one window as a compact text list.

`window` is an hwnd from list_windows (e.g. "132456") or a unique part of a
title or process name (e.g. "notepad"). ambiguous matches are an error, not
a guess.

Returns one line per interactive element: path, control type, name,
automation id, screen rect. Invisible and zero-size elements are dropped.

max_depth defaults to 8 and the walk is breadth-first, because shallow
depth limits hide real controls (a calculator loses its keypad at depth 4,
Explorer hides the file list at depth 6). max_nodes caps the walk: dense
windows cost about 2.5 ms per node, so raise it deliberately.
include_text also lists static text elements, which is useful for reading
labels and status messages. include_containers adds List/Tree/Table/DataGrid
nodes: their paths are what inspect_element expects when you want to read a
whole table or list instead of numbering every row.

Read-only. If the window runs elevated while this server does not, Windows
blocks UIA and the tool reports that instead of returning an empty tree.
inspect_elementA

Read the full content of one element, identified by a path.

Call get_ui_tree first, then pass the path of the element you care about
(for example "0.4.0.1"). Use this for elements that hold a lot of content -
a document, a table, a long list, an edit field - where numbering every row
would waste the whole mark budget.

Returns the element's type, name, screen rect, its value or text (up to
max_chars), and a summary of its immediate children. That child summary is
usually enough to understand a table without capturing or marking it.

Paths are positional: if the UI changed between calls, call get_ui_tree
again. Read-only.
capture_windowA

Capture one window's pixels, including while it is covered.

Uses PrintWindow, which asks the window to render itself, so the window does
not need to be in the foreground: a window hidden behind your terminal still
captures cleanly and only that window's content is in the image.

Returns an image plus a text block with the window title, the image size,
and `origin` - the screen coordinate of image pixel (0,0), so any pixel can
be mapped back to a screen position.

max_side downscales large windows to keep image tokens sane (0 disables).
Read-only. Minimised windows and some GPU-rendered surfaces capture blank,
which is reported instead of a useless image.
capture_somA

Capture a window with numbered marks on every interactive element.

This is the tool to use when you need to understand *where* things are, not
just *what* they are. The accessibility tree decides the boxes, so marks are
pixel-exact and never hallucinated, and every mark in the legend carries a
real screen rect.

Prefer this over capture_window when you plan to act on the result: answer
with a mark number, or use the rect directly and skip vision entirely.

max_marks caps how many controls are numbered (dense toolbars get crowded);
the highest-value controls are kept - named ones first, then larger ones.
max_side downscales the image before drawing, so badges stay sharp.

Falls back to a plain unmarked capture with an explanation when the window
exposes no UI tree (Chromium/Electron without --force-renderer-accessibility).

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A4.3/5.0

Scored across 5 tools

Disambiguation4/5

The five tools target distinct stages of window inspection, but there is some inherent overlap: get_ui_tree and inspect_element both read the UIA tree at different granularities, and capture_window and capture_som both return screenshots. The descriptions explicitly clarify when to use the marked capture or element-level inspection, so an agent can usually choose correctly.

Naming Consistency5/5

All tool names use consistent snake_case with clear verb_noun forms: list_windows, get_ui_tree, inspect_element, capture_window, capture_som. The verbs are predictable and the nouns identify the resource or output type.

Tool Count5/5

Five tools is well-scoped for a focused window-inspection server. Each tool covers a distinct capability: enumeration, tree reading, element detail, plain capture, and marked capture.

Completeness4/5

The surface covers the read-only inspection lifecycle well: list windows, inspect their UI trees, drill into elements, and capture plain or marked images. The main gap is the absence of any interaction or action tools such as clicking or typing, which an agent may expect from a window-automation server.

Maintenance

ActivityMaintained
ResponsivenessNo recent community issues