Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
630 changes: 630 additions & 0 deletions COOKBOOK_AUTHORED.json

Large diffs are not rendered by default.

4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

Find a working starting point for browser automation. Browse by task, choose your language or framework, and open the recipe's setup guide and code.

This cookbook brings together Browserbase's public templates, Playbook patterns, and integrations. It includes the source code, with each project's dependencies kept together. Imported examples have been inspected, but have not all been run against live services.
This cookbook brings together Browserbase's public templates, complete projects, Playbook patterns, and integrations. It includes the source code, with each project's dependencies kept together. Imported examples have been inspected, but have not all been run against live services.

> [!CAUTION]
> **Demo and reference code only.** Browserbase does not claim that any recipe, integration, target, data source, vendor, or workflow in this repository has been vetted, approved, secured, or validated for production use. Independently review the code and obtain all required authorization before running it. You are responsible for compliance, site terms, privacy, security, costs, and outcomes. **Use at your own risk.**
Expand All @@ -34,6 +34,7 @@ This cookbook brings together Browserbase's public templates, Playbook patterns,
| Save a login and handle MFA | [Authentication recipes](docs/topics/authentication.md) |
| Pause an agent for a person | [Human-in-the-loop app](examples/typescript/agent-with-human-in-loop/) |
| Add Browserbase to an agent framework | [Integrations](integrations/README.md) |
| Study a complete consumer browser agent | [Browsie](projects/browsie/) |

## Browse by task

Expand Down Expand Up @@ -99,6 +100,7 @@ Example requests include:
examples/ Standalone Python, TypeScript, and Go templates
integrations/ Framework examples and integration packages
playbook/ Browserbase Playbook patterns and shared helpers
projects/ Complete applications built from Browserbase features
skills/ One cookbook skill with focused topic references
docs/ Recipe guides, task indexes, setup, and maintenance
scripts/ Import, catalog generation, search, and validation
Expand Down
146 changes: 146 additions & 0 deletions catalog.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,151 @@
{
"recipes": [
{
"access": "public",
"caveats": [
"Local Context metadata and native-vault data use local files and need a durable database for a multi-instance deployment.",
"Handoff links expire but are not single-use links.",
"Live integration tests use billable external services and skip without explicit credentials."
],
"collection": "projects",
"dependencies": {
"@1password/sdk": "0.5.0",
"@ai-sdk/openai": "4.0.46",
"@browserbasehq/sdk": "2.18.0",
"@browserbasehq/stagehand": "4.0.2",
"ai": "7.0.82",
"dotenv": "^17.2.0",
"eve": "0.47.6",
"lucide-react": "^1.34.0",
"next": "16.3.0-preview.6",
"react": "^19.2.0",
"react-dom": "^19.2.0",
"zod": "^4.4.0"
},
"entrypoints": [
"projects/browsie/app/page.tsx",
"projects/browsie/agent/agent.ts"
],
"environment_setup_command": "test -f .env || cp .env.example .env",
"environment_template": "projects/browsie/.env.example",
"environment_variables": [
{
"default": null,
"name": "OPENAI_API_KEY",
"provider": "OpenAI",
"purpose": "Runs the Eve agent model.",
"requirement": "required",
"safe_example": "<set-locally>",
"secret": true,
"setup_url": "https://platform.openai.com/api-keys",
"validation": "Must be a valid OpenAI API key"
},
{
"default": null,
"name": "BROWSERBASE_API_KEY",
"provider": "Browserbase",
"purpose": "Creates hosted sessions, Contexts, Live View links, proxies, and Verified Browsers.",
"requirement": "conditional",
"safe_example": "<set-locally>",
"secret": true,
"setup_url": "https://www.browserbase.com/settings",
"validation": "Required when STAGEHAND_BROWSER is browserbase"
},
{
"default": "auto",
"name": "STAGEHAND_BROWSER",
"provider": "Browsie",
"purpose": "Selects automatic, local, or Browserbase browser mode.",
"requirement": "optional",
"safe_example": "browserbase",
"secret": false,
"setup_url": null,
"validation": "Must be auto, local, or browserbase"
},
{
"default": "gpt-5.6-sol",
"name": "BROWSIE_MODEL",
"provider": "OpenAI",
"purpose": "Selects the model used by the Eve agent.",
"requirement": "optional",
"safe_example": "gpt-5.6-sol",
"secret": false,
"setup_url": "https://platform.openai.com/docs/models",
"validation": "Must be a model available to the configured OpenAI account"
},
{
"default": null,
"name": "BROWSIE_HANDOFF_SECRET",
"provider": "Browsie",
"purpose": "Signs short-lived human-handoff links.",
"requirement": "conditional",
"safe_example": "<random-32-or-more-character-value>",
"secret": true,
"setup_url": null,
"validation": "Use a random value with at least 32 characters"
}
],
"frameworks": [
"Stagehand",
"Browserbase SDK",
"Eve",
"Next.js"
],
"id": "projects-browsie",
"languages": [
"typescript"
],
"lifecycle": "current",
"manifests": [
"projects/browsie/package.json"
],
"path": "projects/browsie",
"readme": "docs/recipes/projects-browsie.md",
"run_commands": [
"pnpm dev"
],
"search_aliases": [
"consumer agent",
"browser agent",
"contexts",
"vault",
"live view",
"imessage",
"linq"
],
"setup_commands": [
"pnpm install"
],
"source": {
"kind": "cookbook-authored",
"path": "projects/browsie"
},
"summary": "Build a durable consumer browser agent with Stagehand, Browserbase Contexts, Live View handoff, vaults, and a web workbench.",
"tags": [
"reference-app"
],
"title": "Browsie: consumer browser agent",
"topics": [
"agents-and-human-handoff",
"authentication",
"browser-features",
"integrations-and-orchestration",
"testing-and-observability"
],
"upstream_readme": "projects/browsie/README.md",
"verification": "offline-tested",
"verification_evidence": [
{
"command": "pnpm test && pnpm typecheck && pnpm build && pnpm test:linq-local",
"date": "2026-09-30",
"kind": "offline-tested",
"limits": "84 unit tests passed and 7 credential-dependent live tests skipped; no live Browserbase, model, Linq, or 1Password call was made.",
"result": "passed",
"runtime": "Node.js 25.9.0 with pnpm 10.33.0 on macOS arm64; package target is Node.js 24.x"
}
],
"working_directory": "projects/browsie"
},
{
"access": "public",
"caveats": [],
Expand Down
11 changes: 6 additions & 5 deletions docs/catalog.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ Every entry is source-inspected at minimum. Recipes with stronger install, offli
Search locally with `python3 scripts/catalog.py search "persistent login" --language python --limit 5`. Add `--json` for structured output.

- [Getting started](topics/getting-started.md) (10). Create your first cloud browser and choose a browser SDK.
- [Authentication and saved sessions](topics/authentication.md) (23). Reuse authenticated contexts, handle MFA, and connect login workflows.
- [Browser configuration](topics/browser-features.md) (30). Configure proxies, CAPTCHA handling, extensions, metadata, and caching.
- [Authentication and saved sessions](topics/authentication.md) (24). Reuse authenticated contexts, handle MFA, and connect login workflows.
- [Browser configuration](topics/browser-features.md) (31). Configure proxies, CAPTCHA handling, extensions, metadata, and caching.
- [Files and documents](topics/downloads-and-documents.md) (21). Upload files, retrieve downloads, capture PDFs, and parse documents.
- [Extraction and research](topics/extraction-and-research.md) (53). Find pages and extract structured information from them.
- [Forms and transactions](topics/forms-and-transactions.md) (28). Fill forms and prepare application, booking, and payment workflows.
- [Agents and human handoff](topics/agents-and-human-handoff.md) (26). Build browser agents and pause work for human input.
- [Integrations and orchestration](topics/integrations-and-orchestration.md) (31). Connect Browserbase to agent frameworks, services, and workflow engines.
- [Testing and observability](topics/testing-and-observability.md) (5). Test sites and inspect browser behavior, reliability, and performance.
- [Agents and human handoff](topics/agents-and-human-handoff.md) (27). Build browser agents and pause work for human input.
- [Integrations and orchestration](topics/integrations-and-orchestration.md) (32). Connect Browserbase to agent frameworks, services, and workflow engines.
- [Testing and observability](topics/testing-and-observability.md) (6). Test sites and inspect browser behavior, reliability, and performance.
- [Commerce and travel](topics/commerce-and-travel.md) (14). Compare products, research travel, and inspect booking workflows.
- [Business operations](topics/business-operations.md) (10). Automate research and operations across business domains.

Expand Down Expand Up @@ -183,3 +183,4 @@ Search locally with `python3 scripts/catalog.py search "persistent login" --lang
| [Download save (Python, Playwright)](recipes/playbook-python-playwright-download-download-save.md) | python | runnable example | current / public | playbook |
| [Upload extension (Python, Playwright)](recipes/playbook-python-playwright-extensions-upload-extension.md) | python | runnable example | current / public | playbook |
| [Captcha listening (Python, Browserbase)](recipes/playbook-python-selenium-stealth-captcha-listening.md) | python | runnable example | current / public | playbook |
| [Browsie: consumer browser agent](recipes/projects-browsie.md) | typescript | runnable example | current / public | projects |
100 changes: 100 additions & 0 deletions docs/recipes/projects-browsie.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,100 @@
# Browsie: consumer browser agent

Build a durable consumer browser agent with Stagehand, Browserbase Contexts, Live View handoff, vaults, and a web workbench.

> [!CAUTION]
> Demo and reference code only. This recipe is not a vetted production implementation. Independently review it, obtain authorization, and validate security, privacy, compliance, cost, and site-term requirements before use. Use at your own risk.

**Status:** current · public · offline behavior tested.

**Recipe type:** runnable example.
**LLM requirement:** required (derived from the inspected framework and configuration metadata).

## Code and prerequisites

- Working directory from the cookbook root: `projects/browsie`.
- Languages: typescript.
- Frameworks: Stagehand, Browserbase SDK, Eve, Next.js.
- [Upstream setup and behavior](../../projects/browsie/README.md).
- [Dependency manifest `projects/browsie/package.json`](../../projects/browsie/package.json).
- [Source `projects/browsie/app/page.tsx`](../../projects/browsie/app/page.tsx).
- [Source `projects/browsie/agent/agent.ts`](../../projects/browsie/agent/agent.ts).
- Original use-case taxonomy: reference-app.

## Setup and run

Run from this directory. Commands come from the package manifest, upstream setup guide, or inspected entrypoint. Configure credentials before starting.

```sh
cd projects/browsie
pnpm install
test -f .env || cp .env.example .env
```

Available launch commands are listed below. For applications with separate workers or servers, read the upstream guide for process order. A production `start` command may require a build first.

```sh
pnpm dev
```

## Environment

[Environment template](../../projects/browsie/.env.example) lists example configuration. Fill in your own values locally.

### Required

| Variable | Provider and purpose | Safe example | Validation and default |
| --- | --- | --- | --- |
| `OPENAI_API_KEY` | [OpenAI](https://platform.openai.com/api-keys). Runs the Eve agent model. Secret. | `<set-locally>` | Must be a valid OpenAI API key. No default. |

### Conditional

| Variable | Provider and purpose | Safe example | Validation and default |
| --- | --- | --- | --- |
| `BROWSERBASE_API_KEY` | [Browserbase](https://www.browserbase.com/settings). Creates hosted sessions, Contexts, Live View links, proxies, and Verified Browsers. Secret. | `<set-locally>` | Required when STAGEHAND_BROWSER is browserbase. No default. |
| `BROWSIE_HANDOFF_SECRET` | Browsie. Signs short-lived human-handoff links. Secret. | `<random-32-or-more-character-value>` | Use a random value with at least 32 characters. No default. |

### Optional

| Variable | Provider and purpose | Safe example | Validation and default |
| --- | --- | --- | --- |
| `STAGEHAND_BROWSER` | Browsie. Selects automatic, local, or Browserbase browser mode. Non-secret. | `browserbase` | Must be auto, local, or browserbase. Default: `auto`. |
| `BROWSIE_MODEL` | [OpenAI](https://platform.openai.com/docs/models). Selects the model used by the Eve agent. Non-secret. | `gpt-5.6-sol` | Must be a model available to the configured OpenAI account. Default: `gpt-5.6-sol`. |


## Dependencies

Declared runtime dependencies from [projects/browsie/package.json](../../projects/browsie/package.json). Alternate manifests may differ; use the documented setup path.

| Package | Declared version |
| --- | --- |
| `@1password/sdk` | `0.5.0` |
| `@ai-sdk/openai` | `4.0.46` |
| `@browserbasehq/sdk` | `2.18.0` |
| `@browserbasehq/stagehand` | `4.0.2` |
| `ai` | `7.0.82` |
| `dotenv` | `^17.2.0` |
| `eve` | `0.47.6` |
| `lucide-react` | `^1.34.0` |
| `next` | `16.3.0-preview.6` |
| `react` | `^19.2.0` |
| `react-dom` | `^19.2.0` |
| `zod` | `^4.4.0` |

## Caveats and verification

Source and setup metadata were inspected. No passing authenticated live-workflow check is recorded for this recipe. Websites, model access, paid services, permissions, costs, and operator-specific configuration remain unverified.

| Check | Date | Runtime | Command | Result and limits |
| --- | --- | --- | --- | --- |
| Offline behavior tested | 2026-09-30 | `Node.js 25.9.0 with pnpm 10.33.0 on macOS arm64; package target is Node.js 24.x` | `pnpm test && pnpm typecheck && pnpm build && pnpm test:linq-local` | passed. 84 unit tests passed and 7 credential-dependent live tests skipped; no live Browserbase, model, Linq, or 1Password call was made. |

- Local Context metadata and native-vault data use local files and need a durable database for a multi-instance deployment.
- Handoff links expire but are not single-use links.
- Live integration tests use billable external services and skip without explicit credentials.

## Provenance

Cookbook-authored example. Its reviewed source is included at the local paths above.

Related topics: [Agents and human handoff](../topics/agents-and-human-handoff.md), [Authentication and saved sessions](../topics/authentication.md), [Browser configuration](../topics/browser-features.md), [Integrations and orchestration](../topics/integrations-and-orchestration.md), [Testing and observability](../topics/testing-and-observability.md).
1 change: 1 addition & 0 deletions docs/topics/agents-and-human-handoff.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,6 @@ Open a recipe guide for its working directory, commands, environment references,
| [Vercel · Eve example](../recipes/integrations-examples-integrations-vercel-eve-example.md) | typescript | runnable example | current / public | integrations |
| [Job app agent (TypeScript, Stagehand)](../recipes/playbook-node-stagehand-complete-task-jobappagent.md) | typescript | runnable example | current / public | playbook |
| [SF ticket agent (TypeScript, Stagehand)](../recipes/playbook-node-stagehand-complete-task-sfticketagent.md) | typescript | runnable example | current / public | playbook |
| [Browsie: consumer browser agent](../recipes/projects-browsie.md) | typescript | runnable example | current / public | projects |

[All topics](../catalog.md)
1 change: 1 addition & 0 deletions docs/topics/authentication.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,6 @@ Open a recipe guide for its working directory, commands, environment references,
| [Create extension (TypeScript, Stagehand)](../recipes/playbook-node-stagehand-tools-1password-createextension.md) | typescript | runnable example | current / public | playbook |
| [Main (TypeScript, Stagehand)](../recipes/playbook-node-stagehand-tools-1password-main.md) | typescript | runnable example | current / public | playbook |
| [Initialize context (Python, Playwright)](../recipes/playbook-python-playwright-context-initialize-context.md) | python | runnable example | current / public | playbook |
| [Browsie: consumer browser agent](../recipes/projects-browsie.md) | typescript | runnable example | current / public | projects |

[All topics](../catalog.md)
1 change: 1 addition & 0 deletions docs/topics/browser-features.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,5 +36,6 @@ Open a recipe guide for its working directory, commands, environment references,
| [Custom captcha (Python, Playwright)](../recipes/playbook-python-playwright-captcha-custom-captcha.md) | python | runnable example | current / public | playbook |
| [Upload extension (Python, Playwright)](../recipes/playbook-python-playwright-extensions-upload-extension.md) | python | runnable example | current / public | playbook |
| [Captcha listening (Python, Browserbase)](../recipes/playbook-python-selenium-stealth-captcha-listening.md) | python | runnable example | current / public | playbook |
| [Browsie: consumer browser agent](../recipes/projects-browsie.md) | typescript | runnable example | current / public | projects |

[All topics](../catalog.md)
1 change: 1 addition & 0 deletions docs/topics/integrations-and-orchestration.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,5 +37,6 @@ Open a recipe guide for its working directory, commands, environment references,
| [Convex Stagehand](../recipes/integrations-packages-convex-stagehand.md) | javascript, typescript | runnable example | current / public | integrations |
| [Eve Browserbase](../recipes/integrations-packages-eve-browserbase.md) | typescript | integration package | current / public | integrations |
| [OpenClaw Browserbase](../recipes/integrations-packages-openclaw-browserbase.md) | typescript | integration package | current / public | integrations |
| [Browsie: consumer browser agent](../recipes/projects-browsie.md) | typescript | runnable example | current / public | projects |

[All topics](../catalog.md)
1 change: 1 addition & 0 deletions docs/topics/testing-and-observability.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@ Open a recipe guide for its working directory, commands, environment references,
| [Website link tester (Python)](../recipes/examples-python-website-link-tester.md) | python | runnable example | current / public | examples |
| [Smart fetch scraper (TypeScript)](../recipes/examples-typescript-smart-fetch-scraper.md) | typescript | runnable example | current / public | examples |
| [Website link tester (TypeScript)](../recipes/examples-typescript-website-link-tester.md) | typescript | runnable example | current / public | examples |
| [Browsie: consumer browser agent](../recipes/projects-browsie.md) | typescript | runnable example | current / public | projects |

[All topics](../catalog.md)
Loading
Loading