> For the complete documentation index, see [llms.txt](https://docs.stackai.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.stackai.com/integrations/catalog/browserbase.md).

# Browserbase

Create and inspect Browserbase cloud browser sessions and contexts.

### Connectors

Choose the connector that matches your authentication method. The options below use the names shown in StackAI.

| Connector   | Authentication |
| ----------- | -------------- |
| Browserbase | API Key        |

#### Browserbase

Connect to Browserbase cloud browser sessions with an API key.

**Set up in Browserbase**

1. Prepare the Browserbase account or service that the workflow will access. Grant access to the required resources and operations.
2. **API Key:** Copy an API key from the Browserbase dashboard.

**Set up in StackAI**

1. Open **Settings → Connections**, add a connection, and select **Browserbase**.
2. Enter the credentials and connection details in the fields below.
3. Save the connection and check its connection status. Select this saved connection when configuring an action or feature that uses it.

**Connection fields**

| StackAI field | Required | What to enter                                                                                                  |
| ------------- | -------- | -------------------------------------------------------------------------------------------------------------- |
| API Key       | Yes      | Copy an API key from the Browserbase dashboard. [Provider instructions](https://www.browserbase.com/overview). |

#### Verify the connection

Check that the connection is healthy. Then run a read operation against a resource the connected account can access. A successful connection check confirms authentication; it does not guarantee permission for every action.

If access is denied, check the credential or OAuth permissions, the selected account or environment, and access to the specific resource. Update expired credentials or reconnect after permissions change.

### Use an action

1. Add the required **Browserbase** action to the workflow.
2. Select a connection when the action requests one.
3. Complete the required fields. Use the reference picker when a value comes from another workflow step.
4. Run the workflow and inspect the action’s output. Check the result before using it in a later step.

### Actions

#### Create Session

Start a Browserbase cloud browser session with safe, commonly used controls.

**Inputs**

| Field                   | Type            | Required | Description                                                                                                                                                                    |
| ----------------------- | --------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Timeout (seconds)       | integer         | No       | How long the session may run before Browserbase ends it; leave blank to use the project default. Minimum: 60. Maximum: 21600.                                                  |
| Region                  | select (string) | No       | The Browserbase region where the browser should run. Available values: US West (Oregon), US East (Virginia), Europe (Frankfurt), Asia Pacific (Singapore). Default: us-west-2. |
| Context ID              | string          | No       | Reuse cookies and browser storage from an existing Browserbase context.                                                                                                        |
| Persist Context Changes | boolean         | No       | Save cookies and browser storage back to the selected context when the session ends. Default: false.                                                                           |
| Record Session          | boolean         | No       | Allow Browserbase to record the session for later review. Default: true.                                                                                                       |
| Use Browserbase Proxy   | boolean         | No       | Route browser traffic through Browserbase's managed proxy network. Default: false.                                                                                             |
| Allowed Domains         | string          | No       | Comma-separated domains that top-level page navigation may visit.                                                                                                              |
| Correlation ID          | string          | No       | A caller-chosen unique value used to find a session after an uncertain network outcome.                                                                                        |

**Outputs**

| Field      | Type     | Description                                      |
| ---------- | -------- | ------------------------------------------------ |
| Session ID | string   | The created Browserbase session identifier.      |
| Status     | select   | The session lifecycle state.                     |
| Created At | datetime | When Browserbase created the session.            |
| Started At | datetime | When the browser session started.                |
| Expires At | datetime | When Browserbase will end the session.           |
| Region     | select   | The region running the browser.                  |
| Context ID | string   | The context linked to the session, when present. |

#### Get Session

Get sanitized lifecycle details for one Browserbase session.

**Inputs**

| Field      | Type            | Required | Description                                                                    |
| ---------- | --------------- | -------- | ------------------------------------------------------------------------------ |
| Session ID | select (string) | Yes      | The Browserbase session to inspect. Options load from the selected connection. |

**Outputs**

| Field   | Type   | Description                                   |
| ------- | ------ | --------------------------------------------- |
| Session | object | Sanitized lifecycle metadata for the session. |

#### List Sessions

List sanitized Browserbase sessions with optional lifecycle or StackAI correlation filters.

**Inputs**

| Field           | Type            | Required | Description                                                                                                            |
| --------------- | --------------- | -------- | ---------------------------------------------------------------------------------------------------------------------- |
| Status          | select (string) | No       | Return only sessions in this lifecycle state. Available values: Pending, Running, Error, Timed Out, Completed.         |
| Correlation ID  | string          | No       | Find sessions created with a specific StackAI correlation value.                                                       |
| Maximum Results | integer         | No       | Limit how many sanitized session summaries are retained in the workflow output. Minimum: 1. Maximum: 100. Default: 50. |

**Outputs**

| Field          | Type          | Description                                               |
| -------------- | ------------- | --------------------------------------------------------- |
| Sessions       | object\_array | Sanitized session summaries up to the requested cap.      |
| Truncated      | boolean       | Whether more provider results existed than were returned. |
| Returned Count | integer       | How many session summaries were returned.                 |

#### Get Session Recording

Get per-page recording state and signed download references for completed pages.

**Inputs**

| Field      | Type            | Required | Description                                                                                               |
| ---------- | --------------- | -------- | --------------------------------------------------------------------------------------------------------- |
| Session ID | select (string) | Yes      | The completed Browserbase session whose recording to retrieve. Options load from the selected connection. |

**Outputs**

| Field           | Type          | Description                                                                                                                                                                                                                      |
| --------------- | ------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Recording Pages | object\_array | Per-page assembly states. A completed page's download\_url is a time-limited signed URL granting access to session recording media, which may contain credentials typed into pages, and is persisted in the workflow run output. |

#### Create Context

Create a named Browserbase context for reusable cookies and browser storage.

**Inputs**

| Field        | Type   | Required | Description                                                 |
| ------------ | ------ | -------- | ----------------------------------------------------------- |
| Context Name | string | Yes      | A unique name that identifies the reusable browser context. |

**Outputs**

| Field      | Type   | Description                                 |
| ---------- | ------ | ------------------------------------------- |
| Context ID | string | The created Browserbase context identifier. |

#### Request Session Recording Assembly

Request one MP4 assembly job per recorded page of a completed session.

**Inputs**

| Field      | Type            | Required | Description                                                                                               |
| ---------- | --------------- | -------- | --------------------------------------------------------------------------------------------------------- |
| Session ID | select (string) | Yes      | The completed Browserbase session whose recording to assemble. Options load from the selected connection. |

**Outputs**

| Field           | Type          | Description                                               |
| --------------- | ------------- | --------------------------------------------------------- |
| Recording Pages | object\_array | The recorded pages Browserbase accepted for MP4 assembly. |

### Important behavior

Actions that create, update, send, or delete data can change the connected service. Review their inputs before running them. A retry can repeat an operation; consider this when configuring retries for actions that change data.

The catalog lists the fields and capabilities available in the supplied provider definition. Availability can also depend on your deployment and organization’s Feature Access settings.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.stackai.com/integrations/catalog/browserbase.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
