Skip to main content

pyagentbrowser

Native browser automation with typed Python APIs and before-and-after evidence.

Documentation · Get started · Examples · PyPI · Issues

PyPI version Python 3.11 through 3.14 Release Check Apache-2.0 license

Control browsers and iframe applications from Python with the native agent-browser engine. Bind page and frame handles, act on inspected elements, capture model-ready images, and retain before-and-after evidence.

Alpha: The public API and native integration can change between minor releases. Pin a version for production automation.

Get started

python -m pip install pyagentbrowser

Requires Python 3.11 through 3.14. Local browsers run headlessly by default. The first launch finds Chrome or Chromium, or downloads Chrome for Testing when needed.

from agentbrowser import Browser

with Browser.launch() as browser:
    browser.page.set_content(
        "<button onclick=\"this.textContent='Done'\">Run</button>"
    )
    snapshot = browser.page.observe()
    result = snapshot.one(role="button", name="Run").click()

    print(result.after.one(role="button").name)
    print(result.diff.changed)
Done
True

page.observe() captures a Snapshot of the page's accessible elements. Selecting a button returns a Ref. Clicking it returns an ActionResult with before, after, and diff. Use page.find for live element queries and page.frames for embedded applications.

Browser workflows

  • Inspect and act. Navigate pages, fill forms, read documents, and capture screenshots and PDFs through typed namespaces.
  • Keep document scope. Bind an exact page or frame so observation, evaluation, waits, scrolling, capture, and ref actions share one target.
  • Deliver evidence. Read screenshot bytes and MIME metadata, and inspect structured snapshots and action results.
  • Manage sessions. Launch a browser or attach to an existing one. Work with tabs, cookies, saved state, and explicit cleanup.
  • Control actions. Configure domain restrictions and confirmation policy for operations through the native engine.
  • Compose in Python. Use synchronous or asynchronous controllers, agent skills, and the complete engine protocol through browser.native.

Documentation

Get started · Concepts · Action evidence · Code-mode integration · Safety · API reference · Troubleshooting

The documentation site covers browser workflows, optional packages, supported platforms, and integrations. See examples for Python scripts and Contributing for development setup and checks.

License

pyagentbrowser is licensed under the Apache License 2.0. See NOTICE for bundled software attribution.

Metadata

Release files for pyagentbrowser 0.38.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyagentbrowser 0.38.1
File Size Uploaded
pyagentbrowser-0.38.1.tar.gz 1.3 MB Details

Built distributions (wheels)

Table of built distributions (wheels) for pyagentbrowser 0.38.1
File
pyagentbrowser-0.38.1-cp311-abi3-win_amd64.whl CPython 3.11 abi3 Windows x86-64 Details
pyagentbrowser-0.38.1-cp311-abi3-manylinux_2_28_x86_64.whl CPython 3.11 abi3 Linux glibc 2.28+ x86-64 Details
pyagentbrowser-0.38.1-cp311-abi3-manylinux_2_28_aarch64.whl CPython 3.11 abi3 Linux glibc 2.28+ ARM64 Details
pyagentbrowser-0.38.1-cp311-abi3-macosx_11_0_arm64.whl CPython 3.11 abi3 macOS 11.0+ ARM64 Details
pyagentbrowser-0.38.1-cp311-abi3-macosx_10_12_x86_64.whl CPython 3.11 abi3 macOS 10.12+ x86-64 Details

Total release size: 50.4 MB

Release files / pyagentbrowser-0.38.1.tar.gz

Download URL pyagentbrowser-0.38.1.tar.gz
Size 1.3 MB
Tags Source
SHA-256 checksum
How to use checksums
9df704826266752389e83bbfd733cc374f12a116a9036b3e63208010698800e7
BLAKE2b-256 checksum
How to use checksums
061fb7c81306786a18b6d2b3ab1d34dfb51df7aa61494afb3135023031a1952b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.15 {"installer":{"name":"uv","version":"0.12.15","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / pyagentbrowser-0.38.1-cp311-abi3-win_amd64.whl

Download URL pyagentbrowser-0.38.1-cp311-abi3-win_amd64.whl
Size 9.7 MB
Tags CPython 3.11 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
2686c5fbb05f1c37f17ecfe12ac9a1aa968146c00680fc93fb061baea9a89a01
BLAKE2b-256 checksum
How to use checksums
100add3c911279d6de371f55a304f02160eadf3f77cb432bf744f11fb595c898
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.15 {"installer":{"name":"uv","version":"0.12.15","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / pyagentbrowser-0.38.1-cp311-abi3-manylinux_2_28_x86_64.whl

Download URL pyagentbrowser-0.38.1-cp311-abi3-manylinux_2_28_x86_64.whl
Size 10.4 MB
Tags CPython 3.11 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
7d8dedc0b6adb0e92ecf0bc2e1b0df353a847fab4bc97ca8ad4888e1cc51fc82
BLAKE2b-256 checksum
How to use checksums
9919e67422f58575b6fb0f9e031b6f298961c9093e4360f1b21696046dc36939
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.15 {"installer":{"name":"uv","version":"0.12.15","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / pyagentbrowser-0.38.1-cp311-abi3-manylinux_2_28_aarch64.whl

Download URL pyagentbrowser-0.38.1-cp311-abi3-manylinux_2_28_aarch64.whl
Size 9.9 MB
Tags CPython 3.11 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
d85c5dc3d21b777e16f97d2c709cfeafb8bd27e3bb76f43ed9d9fe7cc8c5c001
BLAKE2b-256 checksum
How to use checksums
7e6477e12968948f3be6e90961bce6717149ea0443551134d2c6a07aed7521b5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.15 {"installer":{"name":"uv","version":"0.12.15","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / pyagentbrowser-0.38.1-cp311-abi3-macosx_11_0_arm64.whl

Download URL pyagentbrowser-0.38.1-cp311-abi3-macosx_11_0_arm64.whl
Size 9.2 MB
Tags CPython 3.11 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
ed34bd943a7296ab7b7beb1c43d7803a9bda7b4b873b49d623e2063280322d91
BLAKE2b-256 checksum
How to use checksums
1df8f292db868b10544898011060e10f8f57d9fbad87b0b77624ceb689ef8f92
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.15 {"installer":{"name":"uv","version":"0.12.15","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / pyagentbrowser-0.38.1-cp311-abi3-macosx_10_12_x86_64.whl

Download URL pyagentbrowser-0.38.1-cp311-abi3-macosx_10_12_x86_64.whl
Size 9.8 MB
Tags CPython 3.11 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
ba9294ddf8f1a160aa3f64dbbbdb4506903545d9d4b8b786440c2187623b79cf
BLAKE2b-256 checksum
How to use checksums
ffbca0f71ad6b699328a856a1c4771a0c9c85bdd85bb5fcc3de3a3835724234b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.15 {"installer":{"name":"uv","version":"0.12.15","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page