Skip to content

[Feature]: Claude multi-account on Windows — port the upstream claude-swap adapter #477

Description

@w1lldantas

Existing issues

  • I searched existing issues and did not find a duplicate.

Problem or use case

I have two Claude accounts (personal Pro and work Max 5x) and I want both visible at once, the way Codex accounts work since 0.48.0.

Today there's no path to a second Claude account on Windows:

  • Add account never completes sign-in (filed as [Bug]: Claude "Add account" never completes sign-in (Claude Code running in WSL2) #476)
  • Save current account replaces the existing card instead of adding one
  • codexbar-cli.exe usage -p claude --all-accounts --json returns a single-element array
  • Browser cookies are unavailable, Chrome App-Bound Encryption blocks import on every profile
  • CLAUDE_CONFIG_DIR is ignored, setting it per invocation still reports the account at the default path

Both my accounts share one email address and differ only by plan. Save current account never produces a second card, and Credential Storage reports Token accounts: Not created with the list showing Token accounts 0, so nothing is being persisted at all. The card just renders whatever credential is currently active, which is also why its label goes stale (see screenshots below).

Proposed solution

Port the upstream claude-swap adapter to the Windows shell. docs/claude-multi-account-and-status-items.md already describes the design: invoke cswap --list --json, require schemaVersion == 1, normalize behind a provider-neutral account snapshot. No credential storage on the CodexBar side, display and explicit activation only.

There's no executable path field and no "Read accounts from claude-swap" toggle anywhere in Provider settings → Claude on 0.56.8.

Alternatively, make the Claude Code accounts list hold multiple entries directly, including two accounts under one email distinguished by plan or workspace. Codex already does something like this for same-email workspaces with stable labels.

Affected area

  • Tray panel
  • Settings UI
  • Config file / settings persistence
  • CLI
  • Provider-specific behavior
  • Installer / release packaging
  • Startup / background behavior
  • Documentation
  • Other

Alternatives considered

PowerShell function that stops the app, repoints C:\Users\<win-user>\.claude at another profile directory in WSL, and relaunches. Works reliably, usage and plan update correctly, but it's one account at a time and needs an elevated shell for the symlink.

Installing claude-swap on its own gives me cswap list in the terminal, but without the adapter it doesn't reach the tray, which is the point.

Visual details

Screenshot 1: work account
Image

Screenshot 2: personal account
Image

Same panel, two different accounts, switched by repointing the .claude symlink and restarting the app.

Screenshot 1 (work account): Plan reads Claude Max 5x, Session 0%, Weekly 0%, plus a Fable only row.
Screenshot 2 (personal account): Plan reads Claude (default_claude_ai), Session 81%, Weekly 18%, no Fable only row.

So the app clearly reads whichever account is active. But the list still shows exactly one card in both cases, and in screenshot 2 the card label still reads team even though the active account is the personal one. Emails blurred.

Additional context

Upstream: https://github.com/steipete/CodexBar/blob/main/docs/claude-multi-account-and-status-items.md
claude-swap: https://github.com/realiti4/claude-swap

Environment: Win-CodexBar 0.56.8, Windows 11 25H2, Claude Code running in WSL2.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions