Get Page Content
get_page_contentExtract visible text from an Arc browser page or from elements matching a CSS selector. Reports matches so partial results are not silent.
Instructions
Get the visible text of a page, or of every element matching a selector joined with blank lines. Always reports "matched", so a partial answer is never silent. Nested matches repeat their text, so prefer a leaf-ish selector.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tab_id | No | Arc tab id from list_tabs. Omit to use this agent's current tab. A tool that changes a tab will not fall back to the tab the user is looking at, so pass this or call open_url first. | |
| selector | No | CSS selector, or one of: "text=Some label" (visible text, case-insensitive substring, exact matches ranked first); "ref=e12" (a ref from snapshot, re-resolved if the page re-rendered); "role=button[name="Save"]" (ARIA or implicit role, name an exact match, or name~="sav" for a substring); "label=Email" (the control a label names); "placeholder=Search" | |
| max_chars | No | Truncate the joined text at this length | |
| first_only | No | Return only the first match instead of joining all of them |