On this page

Actions DSL

See endpoint schemas for typed request fields, defaults, response schemas and endpoint errors from the shipped OpenAPI contract. SDK installation and changelog and migrations cover client compatibility.

Actions are the steps your agent takes in a session, supervised or not: it acts with navigate, click, fill, type and press, and reads the page with get_a11y_tree or screenshot. While a person holds control of a supervised session, actions are refused until they hand back (see Supervised sessions).

All commands are executed via POST /v1/browser/action with the action name and parameters.

json
{
  "session_id": "sess_xxxx",
  "action": "navigate",
  "params": { "url": "https://example.com" }
}

Navigate the browser to a URL.

ParamTypeDefaultDescription
urlstringrequiredTarget URL including protocol
wait_untilstringnetworkidleload, domcontentloaded, or networkidle
timeout_msnumber30000Max wait time in milliseconds

Result:

json
{
  "url": "https://example.com",
  "title": "Example Domain",
  "status_code": 200,
  "load_time_ms": 847
}

Credit cost: 1


get_a11y_tree

Extract the accessibility tree from the current page. This is the primary tool for LLM consumption — 77% fewer tokens than a screenshot.

ParamTypeDefaultDescription
include_hiddenbooleanfalseInclude aria-hidden elements
root_selectorstringnullScope to a specific CSS selector

Result:

json
{
  "tree": "- heading \"Example Domain\" [level=1]\n- link \"More information...\"",
  "node_count": 12,
  "estimated_tokens": 340
}

Credit cost: 1


click

Click an element by CSS selector or accessible label.

ParamTypeDefaultDescription
selectorstringnullCSS selector
labelstringnullAccessible name from a11y tree
buttonstringleftleft, right, or middle
click_countnumber1Number of clicks
wait_after_msnumber0Wait after clicking (for animations)

Use label when possible — it's more reliable than CSS selectors across page changes.

Credit cost: 1


fill

Set the value of an input, textarea, or contenteditable element in one operation. Use type when a UI needs individual keystrokes.

ParamTypeDefaultDescription
selectorstringnullCSS selector
labelstringnullAccessible label
valuestringrequiredText to type
clear_firstbooleantrueClear existing value first

Credit cost: 1


type

Append text key by key to an input, textarea, contenteditable composer or combobox. Each character fires keyboard and input events, so rich editors and app-search suggestions can react. This does not clear existing text; use press with Control+A to select it first when needed.

ParamTypeDefaultDescription
selectorstringnullCSS selector; selector or ref is required
refstringnullRef from the latest get_a11y_tree
textstringrequiredText to append
delay_msnumber0Non-negative delay between keystrokes, in milliseconds
page_idstringcurrent pagePage to type into
framestring or string[]main frameIframe selector or nested iframe selectors
json
{"session_id":"sess_xxxx","action":"type","params":{"selector":"[contenteditable=true]","text":"/invite @sentry","delay_ms":20}}

Result: { "typed": true, "selector": "[contenteditable=true]", "length": 15 }, plus page metadata. Typed text is never logged or echoed in the action response or activity. As with fill, later page observations may show the field's value.

Credit cost: 1. Uses the site's fill action permissions. In supervised sessions, requires agent control and a fresh observation after handback.


press

Press a key or shortcut using Playwright key names: Enter, Tab, Escape, ArrowDown, Control+A, or ControlOrMeta+A. An optional target is focused first. Without a target, the key goes to the currently focused element on the selected page.

ParamTypeDefaultDescription
keystringrequiredKey or combination
selectorstringnullOptional CSS selector to focus
refstringnullOptional ref to focus
page_idstringcurrent pagePage to send the key to
framestring or string[]main frameIframe selector or nested iframe selectors for the target
json
{"session_id":"sess_xxxx","action":"press","params":{"key":"Enter"}}

Result: { "pressed": true }, plus page metadata.

Credit cost: 1. Uses the site's click action permissions. In supervised sessions, requires agent control and a fresh observation after handback.


select

Select an option from a <select> element.

ParamTypeDefaultDescription
selectorstringnullCSS selector
valuestringnullOption value
label_textstringnullVisible option text

Credit cost: 1


scroll

Scroll the page or a specific element.

ParamTypeDefaultDescription
directionstringdownup, down, left, right
amountnumber500Pixels to scroll
selectorstringnullScroll within a specific element

Credit cost: 1


wait_for

Wait for a condition before proceeding.

ParamTypeDescription
typestringselector, text, url, or timeout
valuestringCSS selector, text to find, URL pattern, or milliseconds
statestringFor selectors: visible, hidden, attached, detached
timeout_msnumberMax wait time (default: 10000)

Credit cost: 0


screenshot

Capture a screenshot within an active session.

ParamTypeDefaultDescription
selectorstringnullScreenshot a specific element
full_pagebooleanfalseCapture full scrollable page
formatstringpngpng or jpeg

Result:

json
{
  "url": "https://s3.amazonaws.com/rove-artifacts/scr_xxxx.png?...",
  "expires_at": "2026-04-20T10:00:00Z"
}

Credit cost: 1


get_text

Extract text content from an element.

ParamTypeDescription
selectorstringCSS selector
trimbooleanTrim whitespace (default: true)

Result:

json
{ "text": "$49.99" }

Credit cost: 1


get_attribute

Get an attribute value from an element.

ParamTypeDescription
selectorstringCSS selector
attributestringAttribute name (e.g. href, src)

Credit cost: 1


evaluate

Execute JavaScript in the browser context. Power-user escape hatch.

Supervised sessions refuse this action with 409 interactive-mode-prohibited, including in Auto. To submit a prepared form POST, use navigate, fill and click on a hosted HTTPS form as described in supervised form submission.

ParamTypeDescription
expressionstringJavaScript expression to evaluate

Result:

json
{
  "value": 23,
  "type": "number"
}

Credit cost: 1


Pages, popups and frames

Every page in a session has an id: p1 for the first, then p2, p3… for each popup or new tab the site opens. Every page action (navigate, click, fill, select, scroll, wait_for, screenshot, get_text, get_attribute, get_a11y_tree, evaluate) takes an optional page_id (default: the current page; it does not change the current page). Element actions also take:

ParamTypeDescription
page_idstringThe page to act on, from list_pages or pages_opened. Defaults to the current page.
refstringAn element ref from this page's latest get_a11y_tree, such as e5, or f1e3 inside an iframe.
framestring or string[]A CSS selector for an iframe, or a list of them for nested iframes. selector, label and ref then resolve inside it.

get_a11y_tree shows iframe content, cross-origin included. Every result carries page_id, current_page_id, page_events_seq_start and page_events_seq, plus pages_opened, pages_closed, popups_blocked, navigations_refused and pages_replaced when something changed while it ran. get_text on a form field returns its value (a password field returns "").

In a supervised session a popup becomes the current page, as in a browser; its own window.close() returns the session to the page that opened it. In other sessions the current page stays put until switch_page. Every navigation in a supervised session, in any page or frame, passes the same target policy as navigate: a popup to a refused address is blocked, and a session holds at most 8 open pages.

list_pages

The open pages (then the last 20 closed or blocked ones) with page_id, opener_page_id, url, title and status, the current_page_id, and the page events since the previous list_pages (or after params.after_seq). Does not count as a fresh observation. Credit cost: 0

switch_page

Make another open page current (params.page_id). Credit cost: 0

close_page

Close an open page (params.page_id). If it was current, the session returns to the page that was current when it opened. The last open page cannot be closed (409 last-page). Credit cost: 0

wait_for_popup

Wait for a popup opened by your last navigate, click, fill, select, scroll or evaluate, even one that has already opened, and return its page_id and opener_page_id. A blocked popup answers 422 popup-blocked at once; no popup within timeout_ms (default 10000, max 30000) answers 504 popup-timeout. Pass after_seq (an earlier result's page_events_seq_start) to choose the anchor. Credit cost: 0

json
{ "session_id": "sess_xxxx", "action": "click", "params": { "selector": "#sign-in" } }
{ "session_id": "sess_xxxx", "action": "wait_for_popup", "params": {} }
{ "session_id": "sess_xxxx", "action": "fill", "params": { "page_id": "p2", "ref": "e5", "value": "alice" } }

close_session

Close a session and trigger artifact upload (if video was recorded).

Returns artifact URLs if record_video was enabled.

Credit cost: 0


Credit Cost Summary

ActionCredits
navigate1
get_a11y_tree1
click1
fill1
select1
scroll1
wait_for0
screenshot1
get_text1
get_attribute1
evaluate1
list_pages0
switch_page0
close_page0
wait_for_popup0
close_session0

Help improve this page: Report a correction.

Blocked on a task? Contact support. Include the error type and session ID; omit keys and viewer credentials.

Rove — the supervised browser for agents