Skip to main content
Glama
nvda-mcp server

nvda-mcp server

by InfiArtt

Accessibility tree

nvda_get_object_tree
Read-onlyIdempotent

Returns the accessibility tree NVDA sees as an indented outline of roles, names, values, and states, so you can survey a window's layout or find controls keyboard focus cannot reach.

Instructions

Return the accessibility tree NVDA sees, as an indented outline of role, name, value and states.

Use it to survey a window's layout or find controls that keyboard focus cannot reach.
Unnamed layout containers (sections, panels, groupings) are skipped and their children shown in
their place. In browsers and Electron apps, 'foreground' starts from the web document.
Long lists are cut to max_children items with a note saying how many were left out: the items around

the focus when it is in the list, otherwise the last items of lists and tables (the newest messages of a chat) and the first items of anything else, such as menus. Large windows are cut off at max_nodes or after 3 seconds; the result says so. If it is truncated, start from a control (id) or the 'focus' instead, or lower max_depth. To look for one control, nvda_find_objects is faster.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "nvda_get_object_tree"
  }
}

Input Schema

NameRequiredDescriptionDefault
idNoInstead of root, start from this control, an id from nvda_find_objects.
rootNoWhere to start: 'foreground' window (default), the 'focus', or the 'navigator' object.foreground
windowNoInstead of root, start from this window, a handle from nvda_list_windows, even if it is in the background. In browsers and Electron apps it starts from the web document.
max_depthNoHow many levels below the root to include.
max_nodesNoStop after this many objects.
max_childrenNoShow at most this many children of each object, so long lists do not crowd out the rest. 0 shows all.
response_formatNo'markdown' (default) is easier to read; 'json' keeps every field for further processing.markdown

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already declare readOnly/idempotent/non-destructive, so the bar is lower, yet the description adds substantial behavior: unnamed layout containers are skipped and children inlined, 'foreground' starts at the web document in browsers/Electron, long lists are trimmed with a note on how many were omitted and which items survive (focus-adjacent, newest, or first), and large windows are cut at max_nodes or after 3 seconds with the result saying so. This is exactly the kind of non-obvious runtime behavior an agent cannot get from annotations.

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?

Purpose and the key alternative are front-loaded, and every sentence carries operational information. It is dense and a bit long, with awkward mid-sentence line breaks, but there is no filler or restatement of the name.

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, all-optional tool with rich truncation semantics, the description covers root selection, trimming behavior, timeout failure mode, and the recovery path. Return values are partly covered by the output schema, and the description still characterizes the outline format and the omission notes, so nothing essential is missing.

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?

Schema coverage is 100%, so parameter documentation already exists. The description goes beyond it by explaining the semantic effect of trimming (which children are kept depending on focus position and list type), the root='foreground' special case in browsers, and the id/window provenance ('an id from nvda_find_objects'). max_depth and response_format are left to the schema, so it is not fully additive.

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 specific verb and resource: 'Return the accessibility tree NVDA sees, as an indented outline of role, name, value and states.' It even specifies the output shape, which lets an agent distinguish this from siblings like nvda_inspect_object or nvda_get_text without consulting the 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?

It gives positive guidance ('survey a window's layout or find controls that keyboard focus cannot reach'), an explicit alternative for the narrow case ('To look for one control, nvda_find_objects is faster'), and recovery instructions when truncated ('start from a control (id) or the focus instead, or lower max_depth'). When-to-use, when-to-use-something-else, and fallback are all present.

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