Read the screen's accessibility tree
The accessibility tree where the system has one, flattened in document order, for a model to read beside a screenshot.
GET/v1/sandboxes/{sandbox_id}/screen/tree
Not available yet The API does not serve a screen's tree, live stream, takeovers, watch links or recordings yet.
The accessibility tree where the system has one, flattened in document order, for a model to read beside a screenshot. A system without one answers not_supported.
A key with the screen:read scope.
Request
curl "https://api.pod.mapier.ai/v1/sandboxes/sbx_3ahrz6dmv29gqy5ckt18fpx4b/screen/tree" \
-H "Authorization: Bearer $POD_API_KEY"Parameters
| Name | In | Type | Required | What it is |
|---|---|---|---|---|
sandbox_id | path | string | Yes |
Answer
200. The tree.
{
"frame_seq": 0,
"nodes": [
{
"depth": 0,
"role": "example",
"name": "example",
"value": null,
"bounds": null,
"visible": false
}
]
}| Field | Type | Always | What it is |
|---|---|---|---|
frame_seq | integer | Yes | At least 0. |
nodes | ScreenTreeNode[] | Yes |
Errors
The refusals this call is known for: not_found, not_ready, not_supported, unavailable, in_other_cell. Any call can also answer unauthorized, rate_limited, unavailable or internal; the error list says what each means and when to send the call again.
In the SDKs
| Client | Call |
|---|---|
| TypeScript | sandbox.screen.tree() |
| Python | sandbox.screen.tree() |