Skip to main content
Browser resources are the evidence and control-plane objects around a managed browser. They are how browser work becomes inspectable, reviewable, and useful to another process. Browser-agent workflows surface important resources through result.artifacts, result.steps, status, and browser IDs. Use direct resource APIs when your application needs lower-level control.

Common recipes

Upload a file

Inside browser-code execution, use files.path(fileId) to resolve a staged file to a runtime-local path. Prefer staged files over embedding large data directly into prompts.

Save a download

Use maxBytes and overwrite in production:

Handle a dialog

Handle dialogs deliberately. A confirm dialog can represent a destructive or irreversible action.

Grant and clear permissions

Grant permissions only for the origin that needs them, then clear overrides when the workflow is done.

Inspect events

Use events and recordings together when a run needs an audit trail.

Download recording evidence

Recordings require recording: true when the browser is created.

Inspect pages

Use page IDs only when targeting a known non-active page. Ordinary browser-code execution should use the active page.

Check blockers and CAPTCHA state

Return blocker evidence when a workflow cannot continue. Do not describe CAPTCHA or WAF handling as guaranteed access. Reference: SDK resources reference, SDK browser reference, and API reference.