Skip to content

support custom CDP WebSocket origin - #2275

Draft
baptistecolle wants to merge 1 commit into
jackwener:mainfrom
baptistecolle:agent/support-cdp-websocket-origin
Draft

support custom CDP WebSocket origin#2275
baptistecolle wants to merge 1 commit into
jackwener:mainfrom
baptistecolle:agent/support-cdp-websocket-origin

Conversation

@baptistecolle

Copy link
Copy Markdown

What changed

  • add optional OPENCLI_CDP_ORIGIN support to direct CDP WebSocket connections
  • preserve the existing handshake when the variable is unset
  • document the setting and cover both paths with unit tests

Why

Private, page-scoped CDP brokers may reject browser or missing-origin WebSocket handshakes. This lets trusted OpenCLI callers supply a broker-specific Origin without changing normal Chrome/CDP behavior.

Validation

  • npx vitest run src/browser/cdp.test.ts
  • npm run typecheck

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant