- {/* Chat column */}
-
-
-
-
-
- {/* Live browser view — liveUrl available from session creation */}
-
-
- );
-}
+```bash
+export BROWSER_USE_API_KEY=bu_...
+browser-use auth status
```
----
+### Claim the account (optional)
-## Summary
+If the human wants to see the account in the dashboard later, use the [claim endpoint](https://docs.browser-use.com/cloud/agent-signup#claim-the-account). The returned claim URL is valid for 1 hour.
-| Method | Purpose |
-|--------|---------|
-| `client.sessions.create()` | Create a session (returns `liveUrl` immediately) |
-| `client.run()` | Send a task and stream messages with `for await` |
-| `client.sessions.stop()` | Stop the current task |
-| `client.sessions.waitForRecording()` | Get MP4 recording URLs |
+# Agent Sign Up for Browser Use
+Source: https://docs.browser-use.com/cloud/agent-signup
-# Grow Therapy provider search
-Source: https://docs.browser-use.com/cloud/tutorials/grow-therapy-compare
+An AI agent can create its own free Browser Use account without a human opening the dashboard. This is useful when an agent has terminal or HTTP access and needs a Browser Use API key before it can run cloud browser tasks.
+The flow is a Browser Use agent challenge: the agent requests a challenge, solves the math problem, verifies the answer, and receives an API key.
-This tutorial builds a provider search tool for [Grow Therapy](https://www.growtherapy.com) — a therapy marketplace that handles insurance credentialing for providers. We combine [structured output](https://docs.browser-use.com/cloud/agent/structured-output) with [deterministic rerun](https://docs.browser-use.com/cloud/agent/cache-script) to build a fast, repeatable search pipeline.
+## REST flow
-## What you'll build
+### 1. Request a challenge
-A script that:
-1. Searches Grow Therapy's provider directory with filters (location, insurance, specialty)
-2. Extracts therapist profiles with ratings and availability
-3. Caches the search so you can sweep across geographies or specialties instantly
+```bash
+curl -X POST https://api.browser-use.com/cloud/signup \
+ -H "Content-Type: application/json" \
+ -d '{}'
+```
----
+Request body, optional (include a user email/name if available):
-## Setup
+```json
+{
+ "email": "user@example.com",
+ "name": "User Name"
+}
+```
-```python Python
-import asyncio
-import json
-from pydantic import BaseModel
-from browser_use_sdk.v3 import AsyncBrowserUse
+Response:
-client = AsyncBrowserUse()
+```json
+{
+ "challenge_id": "uuid",
+ "challenge_text": "..."
+}
```
-```typescript TypeScript
-import { BrowserUse } from "browser-use-sdk/v3";
-import { z } from "zod";
-const client = new BrowserUse();
-```
+### 2. Solve the challenge
-## 1. Define the output schema
+Read `challenge_text` and solve the math problem. Return the answer as a string with two decimal places, for example `"144.00"`.
-```python Python
-class Provider(BaseModel):
-name: str
-title: str
-specialties: list[str]
-insurance_plans: list[str]
-rating: float | None = None
-next_available: str | None = None
-
-class ProviderSearch(BaseModel):
-providers: list[Provider]
-total_found: int | None = None
-location: str
-specialty: str
-```
-```typescript TypeScript
-const ProviderSearch = z.object({
- providers: z.array(z.object({
-name: z.string(),
-title: z.string(),
-specialties: z.array(z.string()),
-insurancePlans: z.array(z.string()),
-rating: z.number().nullable(),
-nextAvailable: z.string().nullable(),
- })),
- totalFound: z.number().nullable(),
- location: z.string(),
- specialty: z.string(),
-});
+### 3. Verify the answer
+
+```bash
+curl -X POST https://api.browser-use.com/cloud/signup/verify \
+ -H "Content-Type: application/json" \
+ -d '{"challenge_id":"uuid","answer":"144.00"}'
```
-## 2. Create a workspace
+Request body:
-```python Python
-workspace = await client.workspaces.create(name="grow-therapy-search")
+```json
+{
+ "challenge_id": "uuid",
+ "answer": "144.00"
+}
```
-```typescript TypeScript
-const workspace = await client.workspaces.create({ name: "grow-therapy-search" });
+
+Response:
+
+```json
+{
+ "api_key": "bu_..."
+}
```
-## 3. Search for providers
+Use the returned key for Browser Use Cloud API requests.
-```python Python
-result = await client.run(
-"Go to growtherapy.com and search for therapists in {{New York}} "
-"who specialize in {{anxiety}} and accept insurance. "
-"Return the first 5 provider profiles as JSON.",
-workspace_id=str(workspace.id),
-output_schema=ProviderSearch,
-)
+For example, create an API V4 run:
-for p in result.output.providers:
-print(f"{p.name} ({p.title})")
-print(f" Specialties: {', '.join(p.specialties)}")
-print(f" Rating: {p.rating}")
-print(f" Next available: {p.next_available}")
-print()
+```bash
+curl https://api.browser-use.com/api/v4/runs \
+ -H "X-Browser-Use-API-Key: bu_..." \
+ -H "Content-Type: application/json" \
+ -d '{"task":"Find the top Hacker News story"}'
```
-```typescript TypeScript
-const result = await client.run(
- "Go to growtherapy.com and search for therapists in {{New York}} " +
- "who specialize in {{anxiety}} and accept insurance. " +
- "Return the first 5 provider profiles as JSON.",
- { workspaceId: workspace.id, schema: ProviderSearch },
-);
-for (const p of result.output.providers) {
- console.log(`${p.name} (${p.title})`);
- console.log(` Specialties: ${p.specialties.join(", ")}`);
- console.log(` Rating: ${p.rating}`);
- console.log(` Next available: ${p.nextAvailable}`);
-}
-```
+See the [API V4 quick start](https://docs.browser-use.com/cloud/agent/quickstart).
-## 4. Sweep across locations and specialties
+## Claim the account
-After the first run caches the search flow, sweep across different parameters at $0 LLM cost:
+If a human wants to see the agent-created account in the dashboard later, the agent can create a claim link:
-```python Python
-locations = ["Los Angeles", "Chicago", "Houston", "Miami"]
-specialties = ["depression", "trauma", "ADHD"]
-
-for location in locations:
-for specialty in specialties:
- result = await client.run(
- f"Go to growtherapy.com and search for therapists in {{{{{location}}}}} "
- f"who specialize in {{{{{specialty}}}}} and accept insurance. "
- f"Return the first 5 provider profiles as JSON.",
- workspace_id=str(workspace.id),
- output_schema=ProviderSearch,
- )
- count = len(result.output.providers)
- print(f"{location} / {specialty}: {count} providers found")
+```bash
+curl -X POST https://api.browser-use.com/cloud/signup/claim \
+ -H "X-Browser-Use-API-Key: bu_..."
```
-```typescript TypeScript
-const locations = ["Los Angeles", "Chicago", "Houston", "Miami"];
-const specialties = ["depression", "trauma", "ADHD"];
-for (const location of locations) {
- for (const specialty of specialties) {
-const result = await client.run(
- `Go to growtherapy.com and search for therapists in {{${location}}} ` +
- `who specialize in {{${specialty}}} and accept insurance. ` +
- `Return the first 5 provider profiles as JSON.`,
- { workspaceId: workspace.id, schema: ProviderSearch },
-);
-console.log(`${location} / ${specialty}: ${result.output.providers.length} providers`);
- }
+Response:
+
+```json
+{
+ "claim_url": "https://..."
}
```
----
-
-## Summary
-
-| Step | What happens | Cost |
-|------|-------------|------|
-| First search | Agent navigates Grow Therapy, caches the flow | ~$0.10 |
-| 12 cached sweeps (4 cities x 3 specialties) | Script reruns with new params | **$0 LLM each** |
-| Site layout change | [Auto-healing](https://docs.browser-use.com/cloud/agent/cache-script#auto-healing) regenerates the script | ~$0.10 |
+The claim URL is valid for 1 hour.
-Therapy platforms have dynamic UIs that can change frequently. [Auto-healing](https://docs.browser-use.com/cloud/agent/cache-script#auto-healing) ensures your cached scripts stay working without manual maintenance.
+## CLI usage
-## Next steps
+Agents with shell access can use the Browser Use CLI after the REST flow returns an API key:
-- [Structured output](https://docs.browser-use.com/cloud/agent/structured-output) — Learn more about extracting typed data with Pydantic and Zod schemas.
-- [Human in the loop](https://docs.browser-use.com/cloud/agent/human-in-the-loop) — Let a human review or interact with the browser mid-task, useful for auth flows or approving results before continuing.
-- [Deterministic rerun](https://docs.browser-use.com/cloud/agent/cache-script) — Deep dive into how caching and auto-healing work.
+```bash
+uv tool install browser-use
+export BROWSER_USE_API_KEY=bu_...
+browser-use auth status
+```
+Replace `bu_...` with the key returned by the REST flow.
# FAQ
Source: https://docs.browser-use.com/cloud/faq
@@ -2532,19 +1608,30 @@ Source: https://docs.browser-use.com/cloud/faq
## Which model should I use?
-- **Claude Opus 4.6** (`claude-opus-4.6`) — most capable. Use for the hardest tasks that need maximum accuracy.
-- **Claude Sonnet 4.6** (`claude-sonnet-4.6`, default) — best balance of capability and cost. Use for complex multi-step workflows.
-- **GPT-5.4 mini** (`gpt-5.4-mini`) — fast and efficient. Good for simple, well-defined tasks.
+- **Claude Opus 5** (`claude-opus-5`) — maximum intelligence for difficult, long-horizon work.
+- **GPT-5.6** (`gpt-5.6`) — fast on complex tasks.
+- **Gemini 3.5 Flash** (`gemini-3.5-flash`) — fast for simpler tasks.
+- **MiniMax M3** (`minimax-m3`, default) — cheapest for simple and high-volume tasks.
+
+See [Models](https://docs.browser-use.com/cloud/agent/models) for the complete V4 picker and pricing.
## How do I get the live browser URL?
-`live_url` is returned on session creation. Embed it in an iframe or open it in a browser.
+The V4 run's `browser.ready` event contains `live_view_url`. Embed it in an iframe or open it in a browser.
```python
-session = await client.sessions.create(task="Go to example.com")
-print(session.live_url)
+from browser_use_sdk.v4 import BrowserUse
+
+client = BrowserUse()
+created = client.runs.create("Go to example.com")
+client.runs.wait_for_completion(created.id)
+events = client.runs.events(created.id, limit=100)
+ready = next(event for event in events.events if event.type == "browser.ready")
+print(ready.data["live_view_url"])
```
+Poll events until `browser.ready` appears if you need the URL while the run is still active. See [Human in the loop](https://docs.browser-use.com/cloud/agent/human-in-the-loop) for a complete flow.
+
## Getting blocked by a website
Stealth and proxies are active by default. If you're still getting blocked:
@@ -2558,25 +1645,21 @@ If it still doesn't work, contact support inside the [Cloud Dashboard](https://c
The SDK auto-retries 429 responses with exponential backoff. If persistent, you may need more concurrent sessions — contact support.
-## v2 vs v3 — which should I use?
-
-**v3 is the recommendation for everything.** It's a premium agent (not available in open source) that is significantly more capable than v2:
+## V2 or V4 — which should I use?
-- **Much better at complex tasks** and multi-step workflows
-- **Much better at large data extraction**
-- **File system** with persistent memory across tasks
-- **Task scheduling** with 1,000+ integrations (Gmail, Slack, and more)
+Use **V4** for difficult tasks where accuracy matters. It supports:
-v2 is the closest to the open-source experience — pure browser automation, nothing else. If the open source already works great for your use case, v2 is the natural fit. For everything else, use v3.
+- Run-focused API with a cheap status polling endpoint
+- Conversation sessions with follow-ups
+- Persistent workspaces and turn-scoped file attachments
+- Incremental events for custom UIs and monitoring
+- Per-run cost totals, cost caps, and optional judgement
-```python
-# v3 (recommended)
-from browser_use_sdk.v3 import AsyncBrowserUse
-
-# v2 (simple browser-only tasks)
-from browser_use_sdk.v2 import AsyncBrowserUse
-```
+Use **V2** when tasks are simple and your priority is very low cost and
+predictable speed. Its accuracy is substantially lower.
+See Browser Use at #1 on the
+[Odysseys benchmark](https://odysseysbench.com/leaderboard).
# Agent (v2)
Source: https://docs.browser-use.com/cloud/legacy/agent
@@ -2587,7 +1670,6 @@ Source: https://docs.browser-use.com/cloud/legacy/agent
| Model | API String | Cost per Step |
| ----- | ---------- | ------------- |
| Browser Use 2.0 (default) | `browser-use-2.0` | \$0.006 |
-| Browser Use LLM | `browser-use-llm` | \$0.002 |
| O3 | `o3` | \$0.03 |
| Gemini Flash Latest | `gemini-flash-latest` | \$0.0075 |
| Gemini Flash Lite Latest | `gemini-flash-lite-latest` | \$0.005 |
@@ -2621,15 +1703,15 @@ client = AsyncBrowserUse()
session = await client.sessions.create()
upload = await client.files.session_url(
-session.id,
-file_name="input.pdf",
-content_type="application/pdf",
-size_bytes=1024,
+ session.id,
+ file_name="input.pdf",
+ content_type="application/pdf",
+ size_bytes=1024,
)
with open("input.pdf", "rb") as f:
-async with httpx.AsyncClient() as http:
- await http.post(upload.url, content=f.read(), headers={"Content-Type": "application/pdf"})
+ async with httpx.AsyncClient() as http:
+ await http.post(upload.url, content=f.read(), headers={"Content-Type": "application/pdf"})
result = await client.run("Summarize the uploaded PDF", session_id=session.id)
```
@@ -2662,8 +1744,8 @@ const result = await client.run("Summarize the uploaded PDF", { sessionId: sessi
```python Python
result = await client.tasks.get(task_id)
for file in result.output_files:
-output = await client.files.task_output(task_id, file.id)
-print(output.download_url) # download URL
+ output = await client.files.task_output(task_id, file.id)
+ print(output.download_url) # download URL
```
```typescript TypeScript
const result = await client.tasks.get(taskId);
@@ -2685,8 +1767,8 @@ from browser_use_sdk import AsyncBrowserUse
client = AsyncBrowserUse()
run = client.run("Find the most upvoted post on Reddit r/technology today")
async for step in run:
-print(f"Step {step.number}: {step.next_goal}")
-print(f" URL: {step.url}")
+ print(f"Step {step.number}: {step.next_goal}")
+ print(f" URL: {step.url}")
print(run.result.output) # final result after iteration
```
@@ -2727,7 +1809,6 @@ console.log(run.result?.output); // final result after iteration
| `op_vault_id` | `str` | 1Password vault ID for auto-fill credentials and 2FA. |
| `metadata` | `dict[str, str]` | Custom metadata attached to the task. |
-
# Public share links (v2)
Source: https://docs.browser-use.com/cloud/legacy/public-share
@@ -2743,7 +1824,6 @@ const share = await client.sessions.createShare(session.id);
console.log(share.shareUrl);
```
-
# Skills
Source: https://docs.browser-use.com/cloud/legacy/skills
@@ -2767,8 +1847,8 @@ from browser_use_sdk import AsyncBrowserUse
client = AsyncBrowserUse()
skill = await client.skills.create(
-goal="Extract the top X posts from HackerNews. For each post return: title, URL, score, author, comment count, and rank. X is an input parameter.",
-agent_prompt="Go to https://news.ycombinator.com, click on the first post to load its content, go back to the list, and scroll down to trigger loading of additional posts.",
+ goal="Extract the top X posts from HackerNews. For each post return: title, URL, score, author, comment count, and rank. X is an input parameter.",
+ agent_prompt="Go to https://news.ycombinator.com, click on the first post to load its content, go back to the list, and scroll down to trigger loading of additional posts.",
)
print(skill.id)
```
@@ -2789,8 +1869,8 @@ Skill creation takes ~30 seconds. You can also create skills visually from the [
```python Python
result = await client.skills.execute(
-skill.id,
-parameters={"X": 10},
+ skill.id,
+ parameters={"X": 10},
)
print(result)
```
@@ -2831,7 +1911,6 @@ const result = await client.marketplace.execute(skillId, { parameters: { ... } }
See [Pricing](https://browser-use.com/pricing) for skill costs.
-
# 1Password & 2FA
Source: https://docs.browser-use.com/cloud/guides/1password
@@ -2862,9 +1941,9 @@ from browser_use_sdk import AsyncBrowserUse
client = AsyncBrowserUse()
result = await client.run(
-"Log into my Jira account and create a new ticket",
-op_vault_id="your-vault-id",
-allowed_domains=["*.atlassian.net"],
+ "Log into my Jira account and create a new ticket",
+ op_vault_id="your-vault-id",
+ allowed_domains=["*.atlassian.net"],
)
print(result.output)
```
@@ -2875,8 +1954,8 @@ const client = new BrowserUse();
const result = await client.run(
"Log into my Jira account and create a new ticket",
{
-opVaultId: "your-vault-id",
-allowedDomains: ["*.atlassian.net"],
+ opVaultId: "your-vault-id",
+ allowedDomains: ["*.atlassian.net"],
},
);
console.log(result.output);
@@ -2886,17 +1965,17 @@ For SSO/OAuth redirects, include all required domains:
```python Python
result = await client.run(
-"Log into Jira and create a ticket for the Q4 release",
-op_vault_id="your-vault-id",
-allowed_domains=["*.atlassian.net", "*.okta.com"],
+ "Log into Jira and create a ticket for the Q4 release",
+ op_vault_id="your-vault-id",
+ allowed_domains=["*.atlassian.net", "*.okta.com"],
)
```
```typescript TypeScript
const result = await client.run(
"Log into Jira and create a ticket for the Q4 release",
{
-opVaultId: "your-vault-id",
-allowedDomains: ["*.atlassian.net", "*.okta.com"],
+ opVaultId: "your-vault-id",
+ allowedDomains: ["*.atlassian.net", "*.okta.com"],
},
);
```
@@ -2912,7 +1991,6 @@ When the agent encounters a login form:
The agent never sees your actual credentials. The actual username, password, and 2FA codes are filled in programmatically — keeping your secrets hidden from the AI model.
-
# Secrets
Source: https://docs.browser-use.com/cloud/guides/secrets
@@ -2924,9 +2002,9 @@ from browser_use_sdk import AsyncBrowserUse
client = AsyncBrowserUse()
result = await client.run(
-"Log into GitHub and star the browser-use/browser-use repo",
-secrets={"github.com": "username:password123"},
-allowed_domains=["github.com"],
+ "Log into GitHub and star the browser-use/browser-use repo",
+ secrets={"github.com": "username:password123"},
+ allowed_domains=["github.com"],
)
```
```typescript TypeScript
@@ -2936,8 +2014,8 @@ const client = new BrowserUse();
const result = await client.run(
"Log into GitHub and star the browser-use/browser-use repo",
{
-secrets: { "github.com": "username:password123" },
-allowedDomains: ["github.com"],
+ secrets: { "github.com": "username:password123" },
+ allowedDomains: ["github.com"],
},
);
```
@@ -2948,30 +2026,29 @@ For SSO/OAuth redirects, include all domains in the auth flow:
```python Python
result = await client.run(
-"Log into the company portal and download the Q4 report",
-secrets={
- "portal.example.com": "user@company.com:password123",
- "okta.com": "user@company.com:password123",
-},
-allowed_domains=["portal.example.com", "*.okta.com"],
+ "Log into the company portal and download the Q4 report",
+ secrets={
+ "portal.example.com": "user@company.com:password123",
+ "okta.com": "user@company.com:password123",
+ },
+ allowed_domains=["portal.example.com", "*.okta.com"],
)
```
```typescript TypeScript
const result = await client.run(
"Log into the company portal and download the Q4 report",
{
-secrets: {
- "portal.example.com": "user@company.com:password123",
- "okta.com": "user@company.com:password123",
-},
-allowedDomains: ["portal.example.com", "*.okta.com"],
+ secrets: {
+ "portal.example.com": "user@company.com:password123",
+ "okta.com": "user@company.com:password123",
+ },
+ allowedDomains: ["portal.example.com", "*.okta.com"],
},
);
```
-
# API Reference
-Source: https://docs.browser-use.com/cloud/api-reference
+Source: https://docs.browser-use.com/cloud/api-v4-overview
## Authentication
@@ -2987,42 +2064,44 @@ Get a key at [cloud.browser-use.com/settings](https://cloud.browser-use.com/sett
## Base URL
```
-https://api.browser-use.com/api/v3
+https://api.browser-use.com/api/v4
```
-## Quick example
+## The core loop
-```bash Create a session
-curl -X POST https://api.browser-use.com/api/v3/sessions \
+Create a run, poll its status until terminal, then fetch the full result. `status` is a cheap indexed lookup — poll it, not the full run.
+
+```bash Create a run
+curl -X POST https://api.browser-use.com/api/v4/runs \
-H "X-Browser-Use-API-Key: bu_your_key_here" \
-H "Content-Type: application/json" \
-d '{"task": "Find the top 3 trending repos on GitHub today"}'
```
-```bash Get session result (replace SESSION_ID)
-curl https://api.browser-use.com/api/v3/sessions/SESSION_ID \
+```bash Poll status until completed | failed | cancelled (replace RUN_ID)
+curl https://api.browser-use.com/api/v4/runs/RUN_ID/status \
-H "X-Browser-Use-API-Key: bu_your_key_here"
```
-## Environment variable
-
-Set the key once so SDKs pick it up automatically:
-
-```bash
-export BROWSER_USE_API_KEY=bu_your_key_here
+```bash Fetch the full run once it's terminal
+curl https://api.browser-use.com/api/v4/runs/RUN_ID \
+ -H "X-Browser-Use-API-Key: bu_your_key_here"
```
----
+## Sessions and follow-ups
-Prefer the SDK? See the [Agent docs](https://docs.browser-use.com/cloud/agent/quickstart) — the SDK has all API endpoints available as methods, including `client.browsers.create()`.
+A run belongs to a session (a conversation). Send a follow-up message to a session's queue — it runs as the next turn, or immediately with `interrupt: true`:
-```bash Python
-pip install browser-use-sdk
-```
-```bash TypeScript
-npm install browser-use-sdk
+```bash Queue a follow-up (replace SESSION_ID)
+curl -X POST https://api.browser-use.com/api/v4/sessions/SESSION_ID/queue \
+ -H "X-Browser-Use-API-Key: bu_your_key_here" \
+ -H "Content-Type: application/json" \
+ -d '{"text": "Now open the top result", "interrupt": false}'
```
+## SDKs
+
+The [Cloud SDK quick start](https://docs.browser-use.com/cloud/agent/quickstart) wraps this loop — `runs.create()` then `runs.waitForCompletion()` / `runs.wait_for_completion()` — for TypeScript and Python.
# API key
Source: https://docs.browser-use.com/cloud/api-v2-overview
@@ -3046,66 +2125,3 @@ pip install browser-use-sdk
```bash TypeScript
npm install browser-use-sdk
```
-
-
-## Browser Use Agent Challenge to Get a Free Account
-
-AI agents can create a free Browser Use account autonomously via a challenge-response flow at `https://api.browser-use.com`.
-
-Do this to get an API key (no human required):
-1. `POST https://api.browser-use.com/cloud/signup` — request a challenge.
-
-Request body, optional (include a user email/name if available):
-```json
-{
- "email": "user@example.com",
- "name": "User Name"
-}
-```
-
-Response:
-```json
-{
- "challenge_id": "uuid",
- "challenge_text": "..."
-}
-```
-
-2. Solve the math problem in `challenge_text` — answer as a string with 2 decimal places, e.g. `"144.00"`
-
-3. `POST https://api.browser-use.com/cloud/signup/verify` with `challenge_id` + `answer`.
-
-Request body:
-```json
-{
- "challenge_id": "uuid",
- "answer": "144.00"
-}
-```
-
-Response:
-```json
-{
- "api_key": "bu_..."
-}
-```
-
-4. Use `X-Browser-Use-API-Key: bu_...` on Browser Use Cloud API requests. For example, create a browser session (docs: https://docs.browser-use.com/cloud/api-v3/browsers/create-browser-session):
-
-```bash
-curl -X POST https://api.browser-use.com/api/v3/browsers \
- -H "X-Browser-Use-API-Key: bu_..." \
- -H "Content-Type: application/json" \
- -d '{}'
-```
-
-To let a human claim the account later: `POST https://api.browser-use.com/cloud/signup/claim` with `X-Browser-Use-API-Key: bu_...`.
-
-Response:
-```json
-{
- "claim_url": "https://..."
-}
-```
-
-The claim URL is valid for 1 hour.
diff --git a/docs/cloud/llms.txt b/docs/cloud/llms.txt
index 8b1c30c10..3a2b3937e 100644
--- a/docs/cloud/llms.txt
+++ b/docs/cloud/llms.txt
@@ -1,15 +1,35 @@
-# Browser Use Cloud SDK
+# Browser Use Cloud
-> Browser Use Cloud is a managed API for AI browser automation. Send a natural-language task, get structured results back. SDKs for Python and TypeScript. Always use API v3 — v2 is legacy and uses different method names. Auth via `X-Browser-Use-API-Key` header (keys start with `bu_`).
+> Browser Use Cloud has two products on the same managed browser
+> infrastructure. **Agent** accepts a natural-language goal and completes the
+> web task. **Browser** gives Playwright, Puppeteer, and other remote CDP
+> clients direct control of a cloud browser. Both include stealth, residential
+> proxies, profiles, and live observability. Auth uses
+> `X-Browser-Use-API-Key` (keys start with `bu_`).
- Dashboard: https://cloud.browser-use.com
- Create API key: https://cloud.browser-use.com/settings?tab=api-keys&new=1
- Docs: https://docs.browser-use.com
-- OpenAPI spec (v3): https://docs.browser-use.com/cloud/openapi/v3.json
-- Chat UI example: https://docs.browser-use.com/cloud/tutorials/chat-ui — Full end-to-end example with live browser, streaming, auth. Best starting point to build a prototype.
+- OpenAPI spec (v4): https://docs.browser-use.com/cloud/openapi/v4.json
- Open-source repo: https://github.com/browser-use/browser-use — The open-source Python library. Note: the open-source API is different from the Cloud SDK. If you want the easiest path to production with managed infrastructure, use the Cloud SDK below.
-**Always use v3.** v2 is legacy with different method names and should not be used for new projects.
+**Choose API V4 for hard, high-accuracy tasks.** It is the recommended Agent API for new integrations and works especially well for long, complex workflows.
+
+**Choose API V2 for simple tasks when extremely low cost or predictable speed matters more than accuracy.** V2 accuracy is substantially lower than V4.
+
+Browser Use ranks #1 on the [Odysseys benchmark](https://odysseysbench.com/leaderboard). Use the benchmark when accuracy is the deciding factor.
+
+**Stopping standalone browsers:** Do not use `client.close()`,
+`browser.close()`, or a dropped CDP connection as the API V4 stop operation.
+Keep the browser session ID returned by `POST /api/v4/browsers`, then call
+`PATCH /api/v4/browsers/{id}` with `{"action":"stop"}`. This stops billing and
+refunds unused browser time.
+
+**Current TypeScript SDK typing:** Pass `model` explicitly (use `grok-4.5` for
+the best price/accuracy balance). Whenever `browserSettings` is present, also
+pass `proxyCountryCode`: use `"us"` to keep the default or `null` to disable
+the managed proxy. New model strings can reach REST before the generated
+TypeScript union; use `POST /api/v4/runs` directly if a listed model is rejected.
Before writing code, check if `browser-use-sdk` is already installed. If so, upgrade to the latest version. If not, install it:
- Python: `pip install --upgrade browser-use-sdk`
@@ -22,43 +42,44 @@ export BROWSER_USE_API_KEY=bu_your_key_here
## Get Started
-- [Quick start](https://docs.browser-use.com/cloud/quickstart): State-of-the-art AI browser automation with stealth browsers, CAPTCHA solving, residential proxies, and managed infrastructure.
-- [Agent Sign Up for Browser Use](https://docs.browser-use.com/cloud/agent-signup): How an AI agent can complete the Browser Use agent challenge to get a free account and API key.
+- [Quick start](https://docs.browser-use.com/cloud/quickstart): Run a hosted agent or launch a cloud browser.
- [Prompt for Vibecoders](https://docs.browser-use.com/cloud/vibecoding): Complete Cloud SDK reference for AI coding agents.
## Agent
-- [Introduction](https://docs.browser-use.com/cloud/agent/quickstart): Easiest way to automate the web. Tell this agent in natural language what it should do, and it can interact with the web like a human.
-- [Models](https://docs.browser-use.com/cloud/agent/models): Choose the right model for your task.
-- [Structured output](https://docs.browser-use.com/cloud/agent/structured-output): Get validated, typed data back from agent tasks.
-- [Follow-up tasks](https://docs.browser-use.com/cloud/agent/follow-up-tasks): Run multiple tasks in the same browser session.
-- [Live messages](https://docs.browser-use.com/cloud/agent/streaming): Stream the agent's messages in real time to build custom UIs or monitor progress.
-- [Workspaces & files](https://docs.browser-use.com/cloud/agent/workspaces): Upload files for the agent, download files the agent creates.
-- [Deterministic rerun](https://docs.browser-use.com/cloud/agent/cache-script): Run a task once, then re-execute it for $0 LLM cost.
-- [Human in the loop](https://docs.browser-use.com/cloud/agent/human-in-the-loop): Let a human interact with the live browser while the agent is running. Useful for approvals, payments, complex auth flows, or reviewing agent work before continuing.
+- [Run a task](https://docs.browser-use.com/cloud/agent/quickstart): Give a high-accuracy browser agent a goal and get the result.
+- [Models](https://docs.browser-use.com/cloud/agent/models): Choose a V4 model and understand its token pricing.
+- [Structured output](https://docs.browser-use.com/cloud/agent/structured-output): Ask for JSON and validate the V4 result in your application.
+- [Sessions](https://docs.browser-use.com/cloud/agent/sessions): Continue one conversation across multiple V4 runs.
+- [Workspaces & files](https://docs.browser-use.com/cloud/agent/workspaces): Persist files across V4 runs and conversations.
+- [Scripts](https://docs.browser-use.com/cloud/agent/scripts): Save tested browser scripts in a workspace and reuse them on later runs.
+- [Human in the loop](https://docs.browser-use.com/cloud/agent/human-in-the-loop): Open the live browser, take over, then continue the same session.
+- [Observability](https://docs.browser-use.com/cloud/agent/observability): Poll ordered V4 events to monitor a run or build a custom UI.
## Browser
-- [Introduction Stealth](https://docs.browser-use.com/cloud/browser/stealth): Best stealth on the planet. We fork Chromium to give agents access to all websites.
-- [Proxies](https://docs.browser-use.com/cloud/browser/proxies): Residential proxies in 195+ countries. On by default.
-- [Live preview & recording](https://docs.browser-use.com/cloud/browser/live-preview): Watch the agent's browser in real time. Embed it in your app.
-- [Playwright, Puppeteer, Selenium](https://docs.browser-use.com/cloud/browser/playwright-puppeteer-selenium): Connect your automation framework to Browser Use's stealth infrastructure via CDP.
+- [Browser quickstart](https://docs.browser-use.com/cloud/browser/quickstart): Launch a cloud browser and connect to it from your code.
+- [Stealth](https://docs.browser-use.com/cloud/browser/stealth): Best stealth on the planet. We fork Chromium to give agents access to all websites.
+- [Proxies](https://docs.browser-use.com/cloud/browser/proxies): Route API V4 agent runs through residential or custom proxies.
+- [Live preview & recording](https://docs.browser-use.com/cloud/browser/live-preview): Watch an API V4 run in real time or record its browser.
+- [Playwright, Puppeteer, Selenium](https://docs.browser-use.com/cloud/browser/playwright-puppeteer-selenium): Control a Browser Use cloud browser directly over CDP.
## Authentication
-- [Profiles](https://docs.browser-use.com/cloud/guides/authentication): Persistent browser state — cookies, localStorage, saved passwords. Login once, reuse across sessions.
-- [Sync local and cloud cookies](https://docs.browser-use.com/cloud/guides/profile-sync): Sync your local browser cookies to the cloud — instantly authenticate without managing credentials.
-- [2FA](https://docs.browser-use.com/cloud/guides/2fa): Best practices for handling two-factor authentication in automated browser sessions.
+- [Profiles](https://docs.browser-use.com/cloud/guides/authentication): Reuse cookies and browser state in API V4 runs.
+- [Sync local and cloud cookies](https://docs.browser-use.com/cloud/guides/profile-sync): Sync a local login, then use it in an API V4 run.
+- [2FA](https://docs.browser-use.com/cloud/guides/2fa): Handle two-factor authentication in API V4 runs.
## More
- [FAQ](https://docs.browser-use.com/cloud/faq): Common questions and solutions.
## Integrations
- [OpenClaw](https://docs.browser-use.com/cloud/tutorials/integrations/openclaw): Give OpenClaw agents browser automation with Browser Use — via CDP or the CLI skill.
-- [MCP Server](https://docs.browser-use.com/cloud/guides/mcp-server): Run browser automation tasks from your AI coding assistant. Connect to Claude, Cursor, Windsurf, or any MCP client.
-- [Webhooks](https://docs.browser-use.com/cloud/guides/webhooks): Receive real-time notifications when tasks complete. Configure webhook endpoints for async task monitoring.
-- [n8n](https://docs.browser-use.com/cloud/tutorials/integrations/n8n): Use Browser Use as an HTTP node in n8n workflows.
+- [Hermes Agent](https://docs.browser-use.com/cloud/tutorials/integrations/hermes-agent): Give Hermes Agent cloud browser automation with Browser Use.
+
+## Anthropic
+- [Claude Code](https://docs.browser-use.com/cloud/tutorials/integrations/claude-code): Give Claude Code cloud browser automation with Browser Use.
+- [Claude Managed Agents](https://docs.browser-use.com/cloud/tutorials/integrations/claude-managed-agents): Give Anthropic's Claude Managed Agents a stealth cloud browser via the Browser Use CLI.
## Tutorials
-- [Chat UI](https://docs.browser-use.com/cloud/tutorials/chat-ui): Full end-to-end example. Build a chat UI with live browser preview, follow-up tasks, recording, and streaming messages.
-- [Grow Therapy provider search](https://docs.browser-use.com/cloud/tutorials/grow-therapy-compare): Search Grow Therapy for therapists by location, insurance, and specialty — with cached reruns.
+- [Agent Sign Up for Browser Use](https://docs.browser-use.com/cloud/agent-signup): How the Browser Use agent challenge lets an AI agent create a free account and API key.
## Legacy (v2)
- [Agent (v2)](https://docs.browser-use.com/cloud/legacy/agent): V2 agent models and file handling.
@@ -67,70 +88,8 @@ export BROWSER_USE_API_KEY=bu_your_key_here
- [1Password & 2FA](https://docs.browser-use.com/cloud/guides/1password): Auto-fill passwords and TOTP codes from 1Password during agent tasks.
- [Secrets](https://docs.browser-use.com/cloud/guides/secrets): Pass domain-scoped credentials to the agent securely.
-## API v3
-- [API Reference](https://docs.browser-use.com/cloud/api-reference): Authenticate and start using the Browser Use REST API.
+## API v4
+- [API Reference](https://docs.browser-use.com/cloud/api-v4-overview): Authenticate and start using the Browser Use API v4 — the current REST API for long-horizon agents.
## API v2
- [API key](https://docs.browser-use.com/cloud/api-v2-overview): Set your API key to access the Browser Use v2 REST API.
-
-## Browser Use Agent Challenge to Get a Free Account
-
-AI agents can create a free Browser Use account autonomously via a challenge-response flow at `https://api.browser-use.com`.
-
-Do this to get an API key (no human required):
-1. `POST https://api.browser-use.com/cloud/signup` — request a challenge.
-
-Request body, optional (include a user email/name if available):
-```json
-{
- "email": "user@example.com",
- "name": "User Name"
-}
-```
-
-Response:
-```json
-{
- "challenge_id": "uuid",
- "challenge_text": "..."
-}
-```
-
-2. Solve the math problem in `challenge_text` — answer as a string with 2 decimal places, e.g. `"144.00"`
-
-3. `POST https://api.browser-use.com/cloud/signup/verify` with `challenge_id` + `answer`.
-
-Request body:
-```json
-{
- "challenge_id": "uuid",
- "answer": "144.00"
-}
-```
-
-Response:
-```json
-{
- "api_key": "bu_..."
-}
-```
-
-4. Use `X-Browser-Use-API-Key: bu_...` on Browser Use Cloud API requests. For example, create a browser session (docs: https://docs.browser-use.com/cloud/api-v3/browsers/create-browser-session):
-
-```bash
-curl -X POST https://api.browser-use.com/api/v3/browsers \
- -H "X-Browser-Use-API-Key: bu_..." \
- -H "Content-Type: application/json" \
- -d '{}'
-```
-
-To let a human claim the account later: `POST https://api.browser-use.com/cloud/signup/claim` with `X-Browser-Use-API-Key: bu_...`.
-
-Response:
-```json
-{
- "claim_url": "https://..."
-}
-```
-
-The claim URL is valid for 1 hour.
diff --git a/docs/cloud/openapi/v4.json b/docs/cloud/openapi/v4.json
index 0a15025f7..ec1f6424c 100644
--- a/docs/cloud/openapi/v4.json
+++ b/docs/cloud/openapi/v4.json
@@ -3105,9 +3105,12 @@
"enum": [
"glm-5.2",
"grok-4.5",
+ "kimi-k3",
"minimax-m3",
"claude-opus-4.7",
"claude-opus-4.8",
+ "claude-opus-5",
+ "claude-fable-5",
"claude-sonnet-5",
"gpt-5.5",
"gpt-5.6",
@@ -3751,7 +3754,7 @@
"anyOf": [
{
"type": "string",
- "maxLength": 255
+ "maxLength": 100
},
{
"type": "null"
diff --git a/docs/cloud/quickstart.mdx b/docs/cloud/quickstart.mdx
index b461a5ffc..8590383d9 100644
--- a/docs/cloud/quickstart.mdx
+++ b/docs/cloud/quickstart.mdx
@@ -1,10 +1,28 @@
---
title: Quick start
-description: "State-of-the-art AI browser automation with stealth browsers, CAPTCHA solving, residential proxies, and managed infrastructure."
+description: "Run a hosted agent or launch a cloud browser."
icon: rocket
---
-## 1. Install
+