Accessibility tree
nvda_get_object_treeReturns the accessibility tree NVDA sees as an indented outline of roles, names, values, and states to survey window layouts 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. 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.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | Instead of root, start from this control, an id from nvda_find_objects. | |
| root | No | Where to start: 'foreground' window (default), the 'focus', or the 'navigator' object. | foreground |
| window | No | Instead 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_depth | No | How many levels below the root to include. | |
| max_nodes | No | Stop after this many objects. | |
| max_children | No | Show at most this many children of each object, so long lists do not crowd out the rest. 0 shows all. | |
| response_format | No | 'markdown' (default) is easier to read; 'json' keeps every field for further processing. | markdown |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |