mirror of
https://github.com/browser-use/browser-use.git
synced 2026-09-14 19:59:47 +08:00
33 lines
1.1 KiB
Plaintext
33 lines
1.1 KiB
Plaintext
---
|
|
title: "All Parameters"
|
|
description: "Sandbox configuration reference"
|
|
icon: "sliders"
|
|
---
|
|
|
|
## Reference
|
|
|
|
| Parameter | Type | Description | Default |
|
|
|-----------|------|-------------|---------|
|
|
| `BROWSER_USE_API_KEY` | `str` | API key (or env var) | Required |
|
|
| `cloud_profile_id` | `str` | Browser profile UUID | `None` |
|
|
| `cloud_proxy_country_code` | `str` | us, uk, fr, it, jp, au, de, fi, ca, in | `None` |
|
|
| `cloud_timeout` | `int` | Minutes (max: 15 free, 240 paid) | `None` |
|
|
| `on_browser_created` | `Callable` | Live URL callback | `None` |
|
|
| `on_log` | `Callable` | Log event callback | `None` |
|
|
| `on_result` | `Callable` | Success callback | `None` |
|
|
| `on_error` | `Callable` | Error callback | `None` |
|
|
|
|
## Example
|
|
|
|
```python
|
|
@sandbox(
|
|
cloud_profile_id='550e8400-e29b-41d4-a716-446655440000',
|
|
cloud_proxy_country_code='us',
|
|
cloud_timeout=60,
|
|
on_browser_created=lambda data: print(f'Live: {data.live_url}'),
|
|
)
|
|
async def task(browser: Browser):
|
|
agent = Agent(task="your task", browser=browser, llm=ChatBrowserUse())
|
|
await agent.run()
|
|
```
|