feat: add Qoder OAuth, price-source selection, and Claude inspection - #722
Draft
Circumsized wants to merge 6 commits into
Draft
Circumsized wants to merge 6 commits into
Circumsized wants to merge 6 commits into
Conversation
Promote the frozen v1.12.9 integration state from dev to main.
Promote the frozen v1.12.10 integration state from dev to main.
Add Claude as a Manager Server-only inspection target that reads OAuth usage quota without ever mutating credentials. Backend: - New claude_probe.go performs a read-only GET to the Anthropic OAuth usage endpoint via the CPA /v0/management/api-call envelope; every outcome returns Action=keep, AutoRecoverEligible=false. - inspectSingleAccount dispatches per provider and fails closed: only codex/xai/claude probe the network, unknown providers are retained without any upstream call. - providerActionAllowed blocks delete/disable/enable/reauth for Claude in both executeAction and allowAutoAction (defense in depth). - normalizeInspectionProvider maps the anthropic alias to claude so aliased accounts route correctly and stay under the mutation guard. Frontend: - Claude target is gated behind allowClaudeTarget (server inspector only); browser-local inspection strips claude via the local settings normalizer and fails closed on stale/crafted targets. Docs: - Document the read-only Claude contract across EN/CN manuals and the capability matrix; unavailable targets (qwen/qoder/iflow) noted. Also ignore local AI tooling artifacts (.mimosa, .zcode, nul). Tests: backend probe/fail-closed/guard tests added; frontend 208 tests green. Backend go test not run locally (no Go toolchain on this host).
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
Adds Qoder OAuth management, selectable model-price sources, catalog input/output modality display, and Manager Server-backed read-only Claude OAuth inspection.
Draft — not ready to merge. Pre-submission verification identified the provider-isolation and translation blockers below. Backend/runtime verification and complete UI evidence are also outstanding.
Scope
Changes
Four feature commits: 7dba3d2, bdacfdc, 5d9b8e7, 65c18ff. Two inherited main-promotion commits add ancestry but no additional three-dot PR diff content. Local merge-tree check against dev at 61d7962 completed without conflicts; no rebase or merge was applied.
User Impact
Compatible CPA deployments gain a Qoder login entry. Manager Server users can select price-catalog sources, see advertised model modalities, and configure read-only Claude quota inspection. The draft blockers must be resolved before shipping these changes.
Compatibility / Runtime Notes
Data / Security Notes
Claude server probes use authIndex and the upstream-injected Bearer$TOKEN$ placeholder. The new server path retains accounts and does not enable delete/disable/enable/reauth or auto-recovery for Claude. No credentials or runtime data are included in this PR.
The pre-push security scan did not produce a complete result (scanner_enobufs); this is not a passing security assessment. No complete audit is claimed.
Known blockers before ready-for-review
Risk / Rollback
Risk level: High until the browser-local provider-isolation blocker is resolved; otherwise this spans provider workflows and server outbound catalog fetching.
Rollback notes: this PR has not been merged or deployed. Keep it draft. If later deployed, restore the previous application build and disable Claude inspection before rollback; retain existing data backups.
Verification
Commands / evidence, rerun against 65c18ff on Windows:
The 12 focused files are OAuthPage.test.tsx, services/api/oauth.test.ts, accountReauth.test.ts, demoApi.authFiles.test.ts, sourceDisplay.test.ts, utils/usage.test.ts, usageService.modelPrices.test.ts, modelPricesPageModel.test.ts, codexInspection.test.ts, InspectionConfigFields.test.tsx, and both local/server CodexInspectionPage lifecycle suites.
The docs failure is at tests/docsContentIntegrity.test.mjs:200: a literal LF-only regex for the collapsed Advanced Configuration group does not match the Windows CRLF working-tree config.
git ls-files --eolconfirms CRLF; neither that test nor apps/docs/.vitepress/config.ts differs from upstream/dev. No line-ending or test change was made to conceal the failure. Documentation build completed successfully.Go is unavailable on this host, so Go tests, race tests, and backend execution were not run. The full frontend/repository suite was not rerun in this submission pass. Focused passing tests do not cover the provider-isolation blocker above.
Screenshots / Recordings
Pending usable review artifacts. A local demo DOM check confirmed the Qoder OAuth card and start-login button. The browser capture was not suitable as complete visual evidence; no real login was initiated. Price-source, modality, Claude settings, and deployment-mode visual checks remain outstanding.
Docs
Docs decision: document Qoder's upstream dependency, Manager Server-only capabilities, and the distinction between catalog metadata and measured billing. Resolve remaining label/navigation gaps before release.
Related
N/A