Conversation
🦋 Changeset detectedLatest commit: 870503e The changes in this PR will be included in the next version bump. This PR includes changesets to release 4 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
✱ Stainless preview buildsThis PR will update the Edit this comment to update it. It will appear in the SDK's changelogs. ✅ stagehand-go studio · code · diff
✅ stagehand-php studio · conflict
✅ stagehand-kotlin studio · code · diff
✅ stagehand-ruby studio · conflict
✅ stagehand-typescript studio · code · diff
⚡ stagehand-python studio · conflict
✅ stagehand-java studio · code · diff
|
| 💡 Schema/DeprecatedWithoutMessage: Confirm schema is deprecated and add missing deprecation details if needed. |
✅ stagehand-openapi studio · code · diff
Your SDK build had at least one new note diagnostic, which is a regression from the base state.
generate ✅New diagnostics (1 note)
💡 Schema/DeprecatedWithoutMessage: Confirm schema is deprecated and add missing deprecation details if needed.
This comment is auto-generated by GitHub Actions and is automatically kept up to date as you push.
If you push custom code to the preview branch, re-run this workflow to update the comment.
Last updated: 2026-05-04 17:38:41 UTC
There was a problem hiding this comment.
No issues found across 6 files
Confidence score: 5/5
- Automated review surfaced no issues in the provided summaries.
- No files require special attention.
Architecture diagram
sequenceDiagram
participant Client
participant Server as Stagehand Server (v3)
participant BB as Browserbase API
Note over Client,BB: Session Initialization Flow
Client->>Server: POST /v1/sessions/start
Note right of Client: Header: x-bb-api-key<br/>Optional: x-bb-project-id (DEPRECATED)
alt Session ID provided
Server->>BB: GET /sessions/{id}
BB-->>Server: Return Session Object (id, projectId, connectUrl)
Server->>Server: CHANGED: Extract projectId from BB response
else New Session
Server->>Server: Prepare Create Payload
Note right of Server: DEPRECATED: projectId from params/headers<br/>no longer prioritized
Server->>BB: POST /sessions (create)
BB-->>Server: Return Session Object (id, projectId, connectUrl)
Server->>Server: CHANGED: Extract projectId from BB response
end
alt Validation
Server->>Server: Ensure browserbaseApiKey & resolved projectId exist
else Missing Credentials
Server-->>Client: 400 Bad Request
end
Note over Server: Initialize streaming context with<br/>resolved browserbaseProjectId
Server-->>Client: 201 Created (Session Details)
Note over Client,BB: Streaming / Command Execution
Client->>Server: POST /v1/requests (stream)
Server->>Server: CHANGED: Use resolved projectId (not from headers)
Server->>BB: Connect to session via connectUrl
BB-->>Server: WebSocket / Stream data
Server-->>Client: Response Stream
why
Browserbase API keys are project-scoped, so Stagehand should keep accepting project IDs without requiring them.
what changed
browserbaseSessionCreateParams.projectIddeprecated in Zod/OpenAPI.BROWSERBASE_PROJECT_IDnullable/deprecated in Stainless config.projectIdin the local server instead ofx-bb-project-id.test plan
pnpm --filter @browserbasehq/stagehand run lintpnpm --filter @browserbasehq/stagehand-server-v3 run lintSummary by cubic
Deprecate Browserbase project ID per STG-1808; Stagehand now relies on project-scoped API keys and the project ID returned by Browserbase. The
x-bb-project-idheader, sessionprojectIdparam, andBROWSERBASE_PROJECT_IDconfig are deprecated but remain optional for now.Refactors
projectIdin session create params as deprecated in Zod/OpenAPI; updated security scheme descriptions to reflect deprecation ofx-bb-project-id.BROWSERBASE_PROJECT_IDnullable and marked deprecated instainless.yml.projectIdfrom the retrieved/created Browserbase session; stops readingx-bb-project-idand adjusts validation messages.Migration
x-bb-project-idand removeBROWSERBASE_PROJECT_ID; they’re no longer needed.projectIdin session creation; it’s accepted but deprecated.Written for commit 5ee90b8. Summary will update on new commits. Review in cubic