Repository navigation
Conversation
sunrisegm
marked this pull request as ready for review
September 30, 2026 19:03
Co-authored-by: Cursor <cursoragent@cursor.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.
Summary
Add a complete Claude subscription OAuth provider plugin, based on clean upstream commit
9a8fde2with no unrelated local changes.Structure
The host change prevents an auxiliary OAuth refresh from claiming the model-call recorder and persisting token request/response bodies with detailed logging enabled. Only inference streams now claim that recorder; a Rust regression test covers this behavior. No frontend, database schema, or provider-independent history changes are included.
Verification completed locally
Linux, Rust 1.98.1, in isolated Docker build environments using this checkout:
cargo fmt --all -- --check: passed.cargo clippy --locked --workspace --all-targets -- -D warnings: passed.cargo test --locked --workspace --all-targets -- --test-threads=2: 306 passed, 0 failed. Includes 20 plugin-host tests and the credential-recording regression.cargo build --locked --offline --workspace: passed, server and desktop debug binaries linked.Deno 2.9.6, matching
server/src/plugin/asset.rs:deno task test:host: 1 passed. Starts the actual SDK worker with host sandbox restrictions and drives OAuth completion, profile/model lookup, automatic refresh, streamed events, resource patches, and stream cleanup through the JSON protocol. Upstream responses are mocked.Frontend, Node 22.23.2:
npm run check: passed (both TypeScript checks and Vite production build; 1,849 modules transformed).npm ciwas attempted but hit a registry download timeout; a fresh dependency install is therefore not verified.Live Claude verification — 2026-09-30
A temporary, memory-only harness invoked the actual plugin modules with explicit browser consent:
claude-haiku-4-5-20251001: passed.The requested scopes were
user:profile user:inference. This live request succeeded without impersonating Claude Code, injecting an official-client system identity, or forging a CLI version. Tokens remained in process memory and were not written to files, Git, or the running application's profile.Remaining coverage boundaries
Status
The plugin is a complete Claude subscription connection: sign-in, token refresh, model discovery, and streamed inference. Anthropic's authentication policy still governs how subscription credentials may be used.
Use a build containing the host recording fix rather than installing this plugin into an unpatched release. See
server/plugins/build-in/claude-auth/README.mdfor installation, lifecycle, storage/crash limitations, and protocol sources.