Install Claude Code
Three steps. Two minutes. No fork, no wrapper — you'll be running Anthropic's official claude binary, just routed through the gateway.
1. Get an API key
Sign up at luckyapi.chat. Top up with $5 to start. The dashboard issues you a key that looks like sk-....
2. Install the official CLI
npm install -g @anthropic-ai/claude-codenpm install -g @anthropic-ai/claude-codeIf you don't have Node.js, install it first via nodejs.org or your package manager (brew install node, winget install OpenJS.NodeJS.LTS).
3. Point it at the gateway
Set two environment variables. Persist them in your shell rc so future sessions inherit them.
export ANTHROPIC_BASE_URL="https://luckyapi.chat"
export ANTHROPIC_AUTH_TOKEN="sk-..." # your key from step 1
export ANTHROPIC_API_KEY="" # ensure the official var is empty[Environment]::SetEnvironmentVariable("ANTHROPIC_BASE_URL", "https://luckyapi.chat", "User")
[Environment]::SetEnvironmentVariable("ANTHROPIC_AUTH_TOKEN", "sk-...", "User")
[Environment]::SetEnvironmentVariable("ANTHROPIC_API_KEY", "", "User")Run it
claudeThat's it. The first prompt opens an editor session against your repo. Switch permission modes with Shift+Tab. Check usage in real time with /cost.
Verify it's actually using the gateway
claude --version # any version works
echo $ANTHROPIC_BASE_URL
# → https://luckyapi.chatRun a tiny prompt, then check the luckyapi.chat dashboard — you should see the request show up in the usage feed within a few seconds.
Next
- Models & pricing — what's available, what it costs
- Codex CLI — same trick, OpenAI's tool
- Cline & VS Code — for editor-first workflows
- Tips & shortcuts