稳定可靠 · 低价薄利 · 高并发架构
轻松处理每秒数万次请求
SLA 服务可用率99.9%
按需付费 token自由
使用 NodeSource 安装最新 LTS 版本:
curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash -
sudo apt-get install -y nodejs验证安装:
node --version
npm --version打开终端,运行以下命令:
npm install -g @anthropic-ai/claude-code验证安装:
claude --version访问 nodejs.org 下载 LTS 版本并安装,或使用 Homebrew:
brew install node验证安装:
node --version
npm --version打开终端,运行以下命令:
npm install -g @anthropic-ai/claude-code访问 nodejs.org 下载 LTS 版本并安装,保持默认设置即可。
验证安装:
node --version
npm --versionWindows 环境下需要使用 Git Bash 安装 Claude Code。安装完成后,环境变量设置和使用仍在 PowerShell 中进行。
访问 git-scm.com 下载并安装,保持默认设置。
验证安装:
git --version打开 PowerShell,运行以下命令:
npm install -g @anthropic-ai/claude-codeclaude login在终端中执行以下命令:
curl -fsSL https://cc-help.midlight.top/claude-cli-setup.sh | bash在 PowerShell 中执行以下命令:
irm https://cc-help.midlight.top/claude-cli-setup.ps1 | iexmacOS / Linux(写入 ~/.bashrc 或 ~/.zshrc):
# 你的 API Key(在平台令牌管理中生成)
export ANTHROPIC_API_KEY="sk-xxx你的密钥xxx"
# 指向 iCode 中转地址
export ANTHROPIC_BASE_URL="https://cc.midlight.top"
# 使配置生效
source ~/.bashrcWindows (PowerShell):
# 永久写入用户环境变量
[System.Environment]::SetEnvironmentVariable("ANTHROPIC_API_KEY", "sk-xxx你的密钥xxx", "User")
[System.Environment]::SetEnvironmentVariable("ANTHROPIC_BASE_URL", "https://cc.midlight.top", "User")
# 设置后重启终端使变量生效在任意项目目录下输入命令:
claudeuser@dev:~/project
$ claude
Claude Code v0.1.0
Welcome! Let's get set up.
Select a theme:
> Dark (Default)
Light
High Contrast