SDK Improvements#354
Merged
khaliqgant merged 7 commits intomainfrom Feb 1, 2026
Merged
Conversation
This commit implements four SDK improvements from the friction report: 1. **WebSocket/browser transport** - Transport abstraction layer with - `SocketTransport` for Unix sockets (Node.js) - `WebSocketTransport` for WebSocket (browser/Node.js) - `BrowserRelayClient` - browser-compatible client - Auto-detection utilities (`isBrowser()`, `createAutoTransport()`) 2. **Native RPC pattern** - `client.request()` method with correlation ID tracking for request/response messaging. Includes `respond()` for responders and automatic timeout handling. 3. **Electron integration guide** - Comprehensive docs/guides/electron-integration.mdx with main process setup, preload scripts, contextBridge patterns, React hooks, lifecycle management, and security considerations. 4. **Spawn readiness signal** - `AGENT_READY` protocol message broadcast when agents complete HELLO/WELCOME handshake. SDK gains: - `onAgentReady` callback for all agent connections - `waitForReady` option on `spawn()` to block until ready - `waitForAgentReady()` standalone method 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
…nce reconnection - Resolve package.json conflict: keep both browser/transports exports AND discovery/errors exports - Fix BrowserRelayClient reconnection: when using transportInstance config, auto-reconnection is not possible since we cannot recreate an externally provided transport. Now properly warns and transitions to DISCONNECTED state instead of silently failing Addresses PR review feedback from devin-ai-integration bot. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add dedicated SDK reference page covering: - RelayClient and BrowserRelayClient APIs - New request/response RPC pattern (request/respond methods) - Spawn with readiness signals (waitForReady, onAgentReady) - Transport abstraction (Socket, WebSocket, auto-detection) - Standalone relay for simple use cases - Discovery utilities for socket and cloud workspace detection - Error types for better error handling - Complete examples for common patterns Add SDK reference to docs navigation (first in Reference section). 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.