Unofficial · 非官方 · not from Anthropic

Claude Code Account Center

A local user guide for the macOS Apple Silicon launcher. English is on the left on a wide screen, and 中文 follows in the same section. On a phone, English comes first and 中文 follows.

这是给 Apple Silicon Mac 用的本机说明。宽屏时英文在左、中文在右;手机上先显示英文,再显示中文。

This project is not affiliated with or endorsed by Anthropic. It does not replace the official Claude Code CLI. The CLI still runs in Terminal.

本项目与 Anthropic 没有隶属或背书关系。它不代替官方 Claude Code CLI。CLI 仍然在 Terminal 里运行。

Version 0.2.0. The window can add local accounts, show each account's green remaining-quota card, dispatch official login, check official status, switch the Mac-wide global account after you confirm (with a real test request and automatic restore on failure), mark a default account, import the current global login, delete accounts, open projects in Terminal or an existing Orca runtime, configure an optional official status-line snapshot, and run read-only network observations after you click. It never switches accounts on its own. Missing quota data and unrun checks remain unknown or unverified.

当前是 0.2.0。窗口可以添加本机账号、按账号显示绿色剩余额度卡、派发官方登录、检查官方状态、在你确认后切换整台 Mac 的全局账号(会用真实测试请求核对,失败自动换回)、设为默认账号、导入当前全局登录、删除账号、把项目打开到系统 Terminal 或正在运行的 Orca、配置可选的官方状态栏快照,并在你点击后进行只读网络观察。它从不自己换号。额度数据缺失时保持未知,未运行的检查保持未验证。

Examples on this page use person@example.com and ~/Projects/demo. They are placeholders. Do not put a real email, token, log, address, or home-folder path into a screenshot.

本页例子只用 person@example.com 和 ~/Projects/demo 这种占位符。截图里不要放真实邮箱、令牌、日志、地址或家目录路径。

Install

English

Download the Apple Silicon DMG from v0.2.0, open it, and drag Claude Code Account Center into Applications. The release also includes SHA-256 checksums.

You need macOS 13 or newer, Node.js 20 or newer from nodejs.org, and the official Claude Code CLI installed with Anthropic's quickstart. The app does not install those prerequisites.

The DMG has a local ad-hoc signature, not a Developer ID signature or Apple notarization. If macOS shows a warning, read Apple's own page. This guide does not tell you how to turn off Gatekeeper or remove quarantine attributes.

To build instead, install Apple's command-line developer tools, then run these commands from the repository root. There are no npm dependencies.

npm test
npm run build
open "dist/Claude Code Account Center.app"

中文

从 v0.2.0 下载 Apple Silicon DMG,打开后把 Claude Code Account Center 拖进 Applications(应用程序)。发布页也提供 SHA-256 校验文件。

你需要 macOS 13 或更新版本、nodejs.org 提供的 Node.js 20 或更新版本,以及按 Anthropic 官方快速开始安装的 Claude Code CLI。应用不会替你安装这些前置软件。

DMG 只有本机 ad-hoc 签名,没有 Developer ID 签名,也没有 Apple 公证。macOS 如果报警,请读 Apple 自己的说明。本指南不写如何关闭 Gatekeeper 或删除隔离属性。

如果要自己构建,先安装 Apple 命令行开发工具,再在仓库根目录运行以下命令。这个仓库没有 npm 依赖包。

npm test
npm run build
open "dist/Claude Code Account Center.app"

Add the first account

English

An account here is a label plus a private configuration directory. You can also store an expected email, such as person@example.com, so a later status check can compare it. You do not enter a password or a token.

The core creates accounts/<id>/config under ~/Library/Application Support/ClaudeCodeAccountCenter, unless CCAC_STATE_DIR points somewhere else. Processes started for that account receive CLAUDE_CONFIG_DIR set to that directory. Another account gets a different directory. The Mac-wide Claude configuration is not switched.

Click Add account in the window. A label is required; the expected email is optional. Refreshing shows the local account, its official status when available, and its configuration path.

中文

这里的一个账号,是一个标签加上一个私有配置目录。你也可以存一个预期邮箱,例如 person@example.com,方便以后的状态检查做对照。不需要输入密码或令牌。

核心会在 ~/Library/Application Support/ClaudeCodeAccountCenter 下面建立 accounts/<id>/config。如果设置了 CCAC_STATE_DIR,就用那个位置。为这个账号启动的进程会把 CLAUDE_CONFIG_DIR 设成这个目录。另一个账号用另一个目录。整台 Mac 的 Claude 配置不会被换掉。

点击窗口里的「添加账号」。名称必填,预期邮箱选填。刷新后会显示本机账号、能取得的官方状态,以及它的配置路径。

Official login

English

Login opens the macOS Terminal app and runs the official CLI as auth login, with the working directory set to that account's configuration directory. No extra login flags are added. The official CLI leads you through its own browser sign-in. Anthropic describes that flow in the authentication docs.

This launcher does not capture the login text, does not ask you to paste a session, and does not finish the website login for you. Terminal must be allowed under Privacy & Security → Automation. A successful open means Terminal accepted the script, not that sign-in is finished.

Login does not need a project, and it does not change the last-project memory.

中文

登录会打开 macOS 的 Terminal,在该账号的配置目录里运行官方 CLI 的 auth login。不会附加别的登录参数。官方 CLI 会带你走它自己的浏览器登录。Anthropic 在认证文档里说明了这个过程。

启动器不抓取登录文字,不要求你粘贴会话,也不替你完成网站登录。需要在「隐私与安全性 → 自动化」里允许控制 Terminal。打开成功只表示 Terminal 接受了脚本,不表示登录已经完成。

登录不需要项目,也不会改上次项目的记录。

Add a project

English

A project is an existing local directory, for example ~/Projects/demo, plus a short label. The path has to be a real directory you can enter. The same path is not added twice. The stored path is metadata for the launcher. It is not uploaded.

You can keep many projects. Each account remembers at most one last project. Choosing a project stores that memory. A later launch can reuse it.

中文

项目是一个已经存在的本机目录,例如 ~/Projects/demo,再加上一个短标签。路径必须是你能进入的真实目录。同一个路径不会添加两次。存下来的路径只是启动器的元数据,不会上传。

可以保存很多项目。每个账号最多记住一个上次项目。选中一个项目会记下它。之后的开工可以沿用。

Open a project in Orca

English

If Orca is installed and its runtime is running, the project card can import a ready local Orca project. Choose an account, then click Open in Orca. The launcher asks Orca to create a new terminal whose startup command points at that account's private configuration directory.

A new Orca tab is pinned to the account that created it. Open a second account in a second tab to work on two Claude Code accounts side by side. An existing tab is not silently rebound to another account, and Orca uses its own terminal UI.

The returned receipt means the terminal request was dispatched, not that login or the project succeeded. Read the Orca terminal and check the official status. If Orca is unavailable, the Orca action is hidden and Terminal remains available.

中文

如果已经安装 Orca,而且它的运行服务正在运行,项目卡可以从 Orca 导入已经准备好的本机项目。选好账号,再点「在 Orca 打开」。启动器会让 Orca 新建一个终端,并把启动命令指向这个账号的私有配置目录。

新开的 Orca 标签固定使用创建它的账号。第二个账号开第二个标签,就可以并排使用两个 Claude Code 账号。已经存在的标签不会被偷偷改绑到另一个账号,界面仍然使用 Orca 自己的终端。

返回的回执只表示终端请求已经派发,不表示登录或项目已经成功。请看 Orca 终端,并核对官方登录状态。Orca 不可用时,这个入口会隐藏,系统 Terminal 入口仍然保留。

Launch

English

A launch opens Terminal in the chosen project directory, or in the account's last project when you do not choose one. If there is no last project, launch stops instead of guessing a folder. The official CLI starts with no extra arguments. CLAUDE_CONFIG_DIR points at that account only for this process.

Before starting, the core asks the official CLI for authentication status. Launch continues only for a logged-in claude.ai session. If the status includes a configuration directory, it must be this account's directory. If both the stored email and the status email are present, they must match, as with person@example.com. A launch that starts the official CLI stores that project. A launch that stops on this check leaves the previous last project unchanged.

Nothing switches accounts by itself when a session ends. The next launch uses the account you start.

中文

开工会在你选的项目目录里打开 Terminal;你没有另选时,就用这个账号的上次项目。如果还没有上次项目,开工会停下来,不会猜一个文件夹。官方 CLI 启动时不带额外参数。这个进程的 CLAUDE_CONFIG_DIR 只指向该账号。

启动前,核心会向官方 CLI 查询认证状态。只有已登录的 claude.ai 会话才会继续。状态里如果带了配置目录,必须是这个账号的目录。本地邮箱和状态邮箱都有值时,必须一致,例如 person@example.com。开工若已启动官方 CLI,会记下这个项目。检查没通过而停下时,原来的上次项目保持不变。

会话结束时不会自己换账号。下一次开工用的是你启动的那个账号。

Optional quota snapshot

English

This launcher does not call a usage API. Click Enable official status-line snapshot to add its command to that account's official status line settings. Other settings are preserved. A different existing statusLine command causes a conflict and is not overwritten.

When the official CLI supplies rate_limits.five_hour or rate_limits.seven_day, the local snapshot keeps only the observation time, each valid used percentage, and its reset time. The window can then read that local file; it does not refresh a live balance. A missing window or a reset time in the past stays unknown. Unknown is not zero.

中文

这个启动器不调用额度接口。点击「启用官方状态栏快照」,才会把它的命令加入该账号的官方 status line 设置。其他设置会保留。如果已经有不同的 statusLine 命令,就会提示冲突,不会覆盖。

官方 CLI 提供 rate_limits.five_hour 或 rate_limits.seven_day 时,本地快照只保留观察时间、每个有效的已用百分比和对应重置时间。窗口读取的是这份本地文件,不会刷新实时余额。窗口缺失或重置时间已过时保持未知。未知不是 0。

Four network results

English

The self-check is four separate read-only observations. It does not change DNS, TUN, or proxy settings. The first three run only after you click Start read-only check. The browser layer stays unverified in the app because only the separate browser page can perform it.

ResultMeaning
passThis one check finished, and it did not see the disagreement it looks for. It does not rate the account or any later lookup.
issueThis one check finished, and you should look at the difference it found.
unverifiedThe check did not run or did not finish. This is not a pass.
LayerWhat one look means
ExitThe source address of that one request, as the answering service sees it.
Route and IPv6Whether this one look at the current route shows an IPv6 path.
DNSOne resolver observation for one lookup. It does not describe the next lookup.
WebRTCA browser page you open yourself. See the next section.

The exit layer displays the observed public IP so you can compare it with the browser page. Redact that address before publishing a screenshot.

中文

网络自查是四项分开的只读观察。它不修改 DNS、TUN 或代理。前三项只有在你点击「开始只读检查」后才会运行。应用里的浏览器层保持 unverified(未验证),因为只有单独的浏览器页面才能执行它。

结果含义
pass这一项做完了,而且没有看到它要找的差异。它不评价账号,也不评价之后的查询。
issue这一项做完了,而且你应该看一看它发现的差异。
unverified这项没有运行,或没有做完。这不是通过。
层级看一次表示什么
出口应答服务看到的、这一次请求的来源地址。
路由与 IPv6这一次查看当前路由时,是否出现 IPv6 路径。
DNS对一次查询做一次解析器观察。它不描述下一次查询。
WebRTC你自己打开的浏览器页面。见下一节。

出口层会在窗口里显示观察到的公共 IP,方便与浏览器页面对照。公开截图前请遮住这个地址。

Manual WebRTC page

English

WebRTC is a browser feature that can ask a STUN server how your browser appears on the network. Click Open WebRTC check page, read its privacy note, then click the page's own start button. Opening this guide does not run a probe, and this file contains no probe.

The STUN service receives the request and the source address needed to answer it. On the check page, pass means candidate gathering finished, not that the browser is leak-free. A timeout or no usable result is unverified. The page does not automatically assign issue; compare its server-reflexive address with the CLI exit observation yourself. Closing the page drops its result, and the launcher does not write it into local state.

中文

WebRTC 是浏览器的一项能力,可以向 STUN 服务器询问浏览器在网络上呈现的地址。点击「打开 WebRTC 检查页」,读完隐私提示,再点击页面自己的开始按钮。打开本指南不会运行探测,这个文件里也没有探测程序。

STUN 服务会收到这次请求以及完成应答所需的来源地址。在检查页里,pass 只表示候选地址收集完成,不表示浏览器没有泄露。超时或没有可用结果是 unverified。页面不会自动判 issue;请自己把它的服务器反射地址与 CLI 出口观察作比较。关掉页面会丢弃页面结果,启动器不会把它写入本地状态。

Privacy

English

The full note is PRIVACY.md. Launcher metadata stays on this Mac: labels, optional expected email, project paths, last project, and the per-account configuration directory. Tokens and sessions are not part of that metadata. The official CLI may write its own files into the configuration directory after you log in. Those files are the official client's, and this launcher does not upload them.

A quota snapshot is limited to the observation time, valid used percentages, reset times, and a small status marker. It never stores the raw status-line payload, session id, transcript path, workspace, cost, email, or token. Public-IP and DNS observations start only after your click; STUN requires the browser page's separate click. A browser result is not persisted. The official CLI's own data use is Anthropic's: data usage and privacy.claude.com.

中文

完整说明在 PRIVACY.md。启动器的元数据留在这台 Mac 上:标签、可选的预期邮箱、项目路径、上次项目,以及每个账号的配置目录。令牌和会话不属于这些元数据。你完成官方登录后,官方 CLI 可能往配置目录写入它自己的文件。那些文件属于官方客户端,启动器不上传它们。

额度快照只保留观察时间、有效的已用百分比、重置时间和少量状态标记。它不会保存 status line 原始数据、会话编号、会话记录路径、工作区、费用、邮箱或令牌。公共 IP 和 DNS 观察只有在你点击后才运行;STUN 还需要浏览器页面里的另一次点击。浏览器结果不会被持久保存。官方 CLI 自己的数据使用以 Anthropic 为准:数据使用和 privacy.claude.com。

Safety

English

The reporting route is SECURITY.md. Use a GitHub Security Advisory when private reporting is enabled. If it is not, open an Issue and leave out secrets. The launcher reads or copies keychain logins only for an explicit global switch, import, or delete, and never displays, logs, stores in its own files, or sends them. It does not relay Claude.ai sessions. The documented status response is parsed in memory; only allowlisted fields reach the window, and the raw JSON is not persisted. It never switches accounts on its own and does not replace the official login.

It does not change system DNS, TUN, or proxy settings. It does not bypass macOS permissions. Finding claude on disk is not a check that Anthropic signed that file. A finished network observation would not be a statement about account enforcement.

中文

报告方式在 SECURITY.md。私人报告已启用时,走 GitHub Security Advisory。还没启用时,开一条 Issue,并且不要附上秘密。只有明确的全局切换、导入或删除操作,启动器才会读取或复制钥匙串里的登录;登录内容不显示、不记录、不写进启动器文件、不上传。它不中转 Claude.ai 会话。官方状态响应只在本机内存解析;窗口只收到允许列出的字段,原始 JSON 不会落盘。它不更换整台 Mac 的默认账号,不自动换号,也不代替官方登录。

它不修改系统 DNS、TUN 或代理,也不绕过 macOS 权限。在磁盘上找到 claude,并不能证明那个文件由 Anthropic 签名。做完一次网络观察,也不说明平台会如何处理账号。

When something fails

English

The longer list is TROUBLESHOOTING.md.

  • Node.js missing: install 20 or newer, or set CCAC_NODE_PATH to the absolute path of node.
  • CLI missing: install the official CLI, or set CLAUDE_CODE_CLI.
  • Terminal did not open: allow Automation for Terminal, then try again.
  • Not logged in: finish auth login in that account's directory. Other authentication methods are not launched.
  • Quota unknown: configure the optional status line, use the official CLI, then read the local snapshot. Missing or reset windows remain unknown.
  • statusLine already set: leave the official setting in place. This app does not overwrite a different command.
  • Network unverified: click the check button and review the per-layer reason. WebRTC also requires the browser page's own click.
  • macOS warning on open: the build is ad-hoc only. Do not follow instructions that disable Gatekeeper.

中文

更完整的列表在故障排查。

  • 找不到 Node.js:安装 20 或更新版本,或把 CCAC_NODE_PATH 设成 node 的绝对路径。
  • 找不到 CLI:安装官方 CLI,或设置 CLAUDE_CODE_CLI。
  • Terminal 没有打开:在自动化里允许控制 Terminal,然后再试。
  • 还没登录:在该账号的目录里完成 auth login。其他认证方式不会被拿来开工。
  • 额度未知:先配置可选状态栏,再使用官方 CLI,然后读取本地快照。窗口缺失或已经重置时仍是未知。
  • 已经设置了 statusLine:保留官方设置。本应用不会覆盖不同的命令。
  • 网络未验证:点击检查按钮并查看每层原因。WebRTC 还需要在浏览器页面里再次点击。
  • 打开时 macOS 报警:构建只有 ad-hoc 签名。不要按关闭 Gatekeeper 的办法去做。

Uninstall

English

Quit the app. Delete the copy you built, dist/Claude Code Account Center.app. That removes the launcher from this repository's build output. It does not uninstall the official claude program.

Launcher metadata, and the per-account configuration directories, live in ~/Library/Application Support/ClaudeCodeAccountCenter or in CCAC_STATE_DIR. Remove that folder only when you want the local accounts gone. The official CLI may have written its own login files inside each config directory. Deleting the folder removes that local copy. To sign out of the official client first, use claude auth logout with CLAUDE_CONFIG_DIR set to that account's directory. See the CLI reference.

A default ~/.claude directory used outside this launcher is separate. Uninstalling this app does not delete it.

中文

先退出应用。删掉你构建出来的 dist/Claude Code Account Center.app。这会去掉本仓库构建产物里的启动器,不会卸载官方 claude 程序。

启动器元数据和每个账号的配置目录,在 ~/Library/Application Support/ClaudeCodeAccountCenter,或在 CCAC_STATE_DIR。只有当你想去掉这些本地账号时,才删除那个文件夹。官方 CLI 可能已经在每个 config 目录里写入它自己的登录文件。删掉文件夹,就是删掉这份本地副本。如果要先退出官方客户端,在该账号的目录上设置 CLAUDE_CONFIG_DIR,再运行 claude auth logout。见CLI 参考。

启动器之外使用的默认 ~/.claude 是另一份目录。卸载本应用不会删除它。