Inspect an application UI
hs_ui_inspectGet an application's accessibility tree to locate clickable controls, labels, and menu actions, returning each element's path for targeted automation and further interaction.
Instructions
Read an application's accessibility tree: the buttons, menus, fields, and their labels, with the actions each supports. This is how you find out what is clickable in an app and what it is called. Returns structure and labels only, never the contents of text fields or documents. Each node carries a path you can pass to hs_ui_press.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| app | No | Application name. Defaults to the frontmost application. | |
| role | No | Only report elements whose role matches, for example "AXButton" or "button". | |
| depth | No | How deep to descend. Deeper finds more but returns much more. | |
| limit | No | Maximum nodes to visit before stopping and reporting truncated. | |
| contains | No | Only report elements whose label contains this text, case-insensitive. |