Agent-ready tools and LangGraph integrations for vercel-agent-browser
Project description
agent-browser-agent
An agent-facing layer over vercel-agent-browser,
the typed Python wrapper for Vercel's agent-browser CLI.
It turns the wrapper's complete, versioned CLI inventory into LLM-friendly
StructuredTool objects and adds composed workflows that reduce browser tasks
to fewer model turns. Tools can be used directly, passed to LangChain, placed
in a LangGraph ToolNode, or assembled into a Deep Agent.
What is exposed
The default maximum-control profile provides 167 tools:
- all 151 commands in the
agent-browser0.31.1 inventory; - the runtime
addinitscriptcommand and Pythonnavigatealias; - JSON, text, and typed-method escape hatches for forward compatibility;
- 11 composed workflows for inspection, forms, resilient clicks, diagnostics, downloads, screenshots, login, and isolated sessions.
Every tool has a generated JSON schema based on the native Python method
signature, synchronous and asynchronous execution, structured recoverable
errors, output limiting, and stable agent_browser_* names.
Install
Install the Vercel CLI and Chrome runtime once:
npm install -g agent-browser
agent-browser install
Install agent-browser-agent from PyPI:
pip install agent-browser-agent
Add the integration you need:
pip install "agent-browser-agent[langgraph,openai]"
# or
pip install "agent-browser-agent[deepagents,openai]"
Use the tools directly
from agent_browser_agent import AgentBrowserToolkit
toolkit = AgentBrowserToolkit()
result = toolkit.get_tool("agent_browser_open_and_inspect").invoke(
{"url": "https://example.com"}
)
print(result)
# All tools also support ainvoke().
snapshot = await toolkit.get_tool("agent_browser_snapshot").ainvoke(
{"interactive": True, "include_urls": True}
)
The underlying browser daemon persists between calls. Use one toolkit per agent/session, or create an isolated clone:
research = toolkit.for_session("research", namespace="my-app")
LangGraph agent
from agent_browser import AgentBrowser, ClientConfig, GlobalOptions
from agent_browser_agent import (
AgentBrowserToolkit,
AgentBrowserToolkitConfig,
create_agent_browser_langgraph_agent,
)
browser = AgentBrowser(
ClientConfig(
timeout=60,
options=GlobalOptions(
session="research",
namespace="my-app",
headed=False,
allowed_domains=("example.com", "*.example.com"),
),
)
)
toolkit = AgentBrowserToolkit(
browser,
AgentBrowserToolkitConfig(access="browser", include_raw_commands=False),
)
agent = create_agent_browser_langgraph_agent(
"openai:gpt-5.2",
toolkit=toolkit,
confirm_dangerous=True,
)
result = agent.invoke(
{"messages": [{"role": "user", "content": "Inspect example.com."}]},
config={"configurable": {"thread_id": "browser-1"}},
)
For a custom Graph API workflow:
from agent_browser_agent import create_agent_browser_tool_node
tool_node = create_agent_browser_tool_node(toolkit=toolkit)
Deep Agent
from agent_browser_agent import create_agent_browser_deep_agent
agent = create_agent_browser_deep_agent(
model="openai:gpt-5.2",
toolkit=toolkit,
confirm_dangerous=True,
)
Additional options such as checkpointer, store, backend, subagents,
skills, memory, and response_format are forwarded to
deepagents.create_deep_agent.
Access control
Maximum control is the default:
AgentBrowserToolkitConfig(access="all")
This includes install, upgrade, plugin mutation, saved-state mutation, and raw command tools. For normal web automation use:
AgentBrowserToolkitConfig(
access="browser",
include_raw_commands=False,
)
Fine-grained policy is available with allowed_tools and denied_tools.
recommended_interrupts() returns the host-mutating tools that should require
human approval in agent runtimes.
Composed tools
agent_browser_open_and_inspectagent_browser_call_and_inspectagent_browser_run_workflowagent_browser_page_contextagent_browser_fill_formagent_browser_smart_clickagent_browser_screenshot_and_snapshotagent_browser_download_and_verifyagent_browser_login_and_inspectagent_browser_diagnoseagent_browser_session_workflow
Use primitive tools when the model must inspect an intermediate result. Use a composed tool for deterministic steps that should happen together.
Safety notes
- No tool invokes a shell. Raw commands accept argument arrays and optional stdin.
- Prefer
access="browser"andallowed_domainsfor untrusted tasks. - Snapshot refs become stale after navigation or large DOM changes; take a new snapshot before retrying.
- Credentials passed as LLM tool arguments may appear in model traces. Prefer
saved
agent-browserauth profiles. - Host paths returned for downloads, screenshots, PDFs, traces, or recordings
refer to the machine running
agent-browser.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file agent_browser_agent-0.1.1.tar.gz.
File metadata
- Download URL: agent_browser_agent-0.1.1.tar.gz
- Upload date:
- Size: 18.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.8 {"installer":{"name":"uv","version":"0.11.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8d671a0b2e2ea9e74dcb664082bf3d0ff6ff2ea186a7edaa94c3fca4ea90da82
|
|
| MD5 |
7fe10948378114d31f0506d3fe86bb0f
|
|
| BLAKE2b-256 |
7060c44b76c2a4915b1d28f32d4bce2c0a65e5027e19677fd1694f77640fb978
|
File details
Details for the file agent_browser_agent-0.1.1-py3-none-any.whl.
File metadata
- Download URL: agent_browser_agent-0.1.1-py3-none-any.whl
- Upload date:
- Size: 22.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.8 {"installer":{"name":"uv","version":"0.11.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
64e6ec90f1bd767918fd140e9c35be9140eecf94c4e65de1db9f9fd869356f22
|
|
| MD5 |
cf3aacb57edc938d2d004dbaa53dae4c
|
|
| BLAKE2b-256 |
ad8a2d4a8828b56e40339f80da87e673d6223c31b87b085e73f4b7a8161c5c44
|