MCP server
zgx inspect mcp serves every command as an MCP tool on stdio.
zgx inspect mcp serves the same commands as MCP tools on stdio (zgx_tree, zgx_node, zgx_find, zgx_state, zgx_set_state, zgx_click, zgx_type, zgx_key, zgx_scroll, zgx_command, zgx_errors, zgx_lint, zgx_frames, zgx_snapshot, zgx_record, zgx_replay, zgx_wait, zgx_sleep, zgx_apps), each answering the text the CLI prints, with isError when it failed. Every tool takes an optional app (a pid) for when several apps run.
claude mcp add zgx -- zgx inspect mcp # Claude Code; any MCP client runs the same command