Repository navigation
Closed
Labels
documentationImprovements or additions to documentationImprovements or additions to documentationenhancementNew feature or requestNew feature or requestto be testedFix landed; needs verificationFix landed; needs verification
Description
Summary
Per-user Claude Code Connect (each user connects their own Claude subscription via Settings → Models → Connect, billed to their personal account) is gated behind the Features__Ai__Clis__ClaudeCode flag, which is off by default. The backend is already present, but the enablement path and its prerequisites are not documented in one place. Document how to turn it on and what it requires, so a deployment can enable it without reverse-engineering the code.
Background
- The documented per-user "own account" path for Claude is the Claude Code Connect flow (a CLI/subscription provider), not a personal API key — see
src/MeshWeaver.Documentation/Data/AI/ModelProviderSetup.md: "Claude … is intentionally not wired as a shared org key. Each user connects Claude Code … in Settings → Models → Connect … on their own subscription." - This is independent of the shared org Anthropic key (
Features__Ai__Providers__Anthropic) and coexists with it — enabling Connect ADDS the per-user card; it does not remove or change the shared key. - The Connect backend is already registered:
ConnectSessionManager,ClaudeConnectStrategy,CopilotConnectStrategy(src/MeshWeaver.AI/Connect/).
What to document (enablement path)
The flag is gated in memex/Memex.Portal.Shared/MemexConfiguration.cs (~lines 206, 270). A portal that wants per-user Connect must:
- Run the CLI-enabled portal image (one that includes the
claudeCLI binary). - Set
Features__Ai__Clis__ClaudeCode=truein the portal config/env (independent ofFeatures__Ai__Providers__Anthropic). - Set a per-user config-dir root (
ClaudeCode:ConfigDirRoot, e.g. a writable per-user mount) so each user logs in under their own.claudedirectory. - Redeploy / roll out.
Steps to verify
- On a portal with the flag set, open Settings → Models → observe a "Claude Code" card with a Connect / Log in button (absent when the flag is unset).
- Complete Connect as a user and run a Claude model → the run uses that user's own subscription; a per-user encrypted-token node is created.
- Confirm the shared org Anthropic key path is unchanged and still serves users who have not connected.
Notes
- The flag enables the feature portal-wide; each user self-connects (needs their own Claude subscription). No per-person admin activation.
- The CLI provider is resolved by a per-user token (
ResolveConnectToken), not by model id, so it does not collide with the shared catalog.
References
- Docs:
src/MeshWeaver.Documentation/Data/AI/ModelProviderSetup.md,.../AI/ModelProviderSettings.md - Skill:
src/MeshWeaver.AI/Data/Skill/provider-keys.md - Code:
memex/Memex.Portal.Shared/MemexConfiguration.cs(flag gating),src/MeshWeaver.AI/Connect/
Metadata
Metadata
Assignees
Labels
documentationImprovements or additions to documentationImprovements or additions to documentationenhancementNew feature or requestNew feature or requestto be testedFix landed; needs verificationFix landed; needs verification
Activity
rbuergi commentedon Jul 6, 2026
Addressed by #335 (open, pending review — will auto-close on merge).
New "Enabling per-user Claude Code Connect" section in
ModelProviderSetup.md(what Connect is/is not, prerequisites, enablement steps, verification), grounded in code (ClaudeConnectStrategy,ChatClientCredentialResolver.ResolveConnectToken,ClaudeCodeConfiguration.ConfigDirRoot,deploy/base-images/portal-ai/Dockerfile). Precise nuance documented: the flag defaultstruein code, but ships off via deploy configs (deploy/.env.example, Marketplace checkbox) and is **inert without the CLI-bundledportal-aiimage.DocumentationLinkIntegrityTest` passes.Merge pull request #335 from Systemorph/docs/claude-code-connect-324-…
sierragolflima commentedon Jul 7, 2026
Test result (
to be tested): flags + mechanism verify; the documented Connect entry point is staleOn a CLI-enabled portal the enablement checks out — flag (code default
true), theportal-aiimage with theclaudebinary, and the subscription-token mechanism ({user}/_Memex/ClaudeCodeviaClaudeConnectStrategy).One doc correction in
ModelProviderSetup.md: the UI entry point for Connect is out of date. The doc points to Settings → Models → Connect (lines ~192/200 and "Verifying it" step 1: "open Settings → Models: a 'Claude Code' card"), but that tab was retired in68946fbf4—AddModelsSettingsTabis no longer registered and the CLI card (ModelsSettingsTab.RenderCliBody) no longer renders.The current flow is a chat command: switch the active harness to Claude Code with
/harness, then run/login(opens the login-method chooser). Suggested edits:/harness), then/login" throughout the section./login; complete the dialog; confirm a per-user encrypted-token node at{user}/_Memex/ClaudeCode.The rest of the section (flag opt-in behaviour, CLI-image requirement,
ConfigDirRoot, per-user token resolution, coexistence with the shared org key) is accurate.