| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Name | Name | Last commit date | ||
|---|---|---|---|---|
Run Claude Code v2.1.88 from leaked source code - one command setup.
git clone https://github.com/yourname/start-claude-code.git
cd start-claude-code
# Set API key
export ANTHROPIC_API_KEY="sk-ant-xxx"
# Run!
./start.shFirst run will automatically install Bun, dependencies, and configure everything.
export ANTHROPIC_API_KEY="sk-ant-xxx"
./start.shexport ANTHROPIC_API_KEY="sk-ant-xxx"
./start.sh -p "explain this code" --dangerously-skip-permissions < /dev/nullexport ANTHROPIC_BASE_URL="https://your-proxy.com" # Don't include /v1
export ANTHROPIC_API_KEY="your-key"
export DISABLE_PROMPT_CACHING=1
./start.sh -p "hello" --model claude-sonnet-4-20250514 \
--dangerously-skip-permissions --no-session-persistence < /dev/null./start.sh --model claude-sonnet-4-20250514
./start.sh --model claude-opus-4-20250514
./start.sh --model claude-haiku-4-5-20241022If you prefer to set up step by step:
# 1. Install Bun
curl -fsSL https://bun.sh/install | bash
export PATH="$HOME/.bun/bin:$PATH"
# 2. Run setup
node scripts/setup.mjs
# 3. Run
bun src/entrypoints/cli.tsx| Variable | Description | Default |
|---|---|---|
| ANTHROPIC_API_KEY | Required. Your API key | - |
| ANTHROPIC_BASE_URL | API base URL (no /v1 suffix) | https://api.anthropic.com |
| ANTHROPIC_MODEL | Default model | claude-sonnet-4-6 |
| DISABLE_PROMPT_CACHING | Disable prompt caching (needed for most proxies) | 0 |
| DISABLE_INTERLEAVED_THINKING | Disable interleaved thinking | 0 |
| CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS | Disable experimental beta headers | 0 |
On March 31, 2026, the full source code of Anthropic's Claude Code CLI was leaked via a .map file in their npm registry. This repository contains:
Source authenticity: Verified by comparing all 1,902 source files against @anthropic-ai/claude-code@2.1.88's source map — 100% byte-identical match, zero differences.
| Component | Technology |
|---|---|
| Runtime | Bun |
| Language | TypeScript |
| Terminal UI | React + Ink |
| CLI Parser | Commander.js |
| API | Anthropic SDK |
| Code Search | ripgrep (bundled) |
| Protocols | MCP, LSP |
src/ ├── main.tsx # CLI entrypoint ├── QueryEngine.ts # Core LLM API caller ├── tools/ # ~40 agent tools (Bash, Edit, Read, etc.) ├── commands/ # ~50 slash commands (/commit, /review, etc.) ├── components/ # ~140 Ink UI components ├── services/ # API, MCP, OAuth, analytics ├── bridge/ # IDE integration (VS Code, JetBrains) ├── coordinator/ # Multi-agent orchestration ├── skills/ # Skill system ├── plugins/ # Plugin system ├── memdir/ # Persistent memory └── ...
| Feature | Status | Notes |
|---|---|---|
| --version / --help | Working | |
| -p non-interactive mode | Working | Full API call + tool use |
| Third-party proxy support | Working | Set ANTHROPIC_BASE_URL |
| Interactive TUI | WIP | See below |
The leak only contains the src/ directory — raw TypeScript source before compilation. Running it from source requires reverse-engineering the build infrastructure that Anthropic didn't ship:
| Missing piece | What it is | Our workaround |
|---|---|---|
| bun:bundle | Compile-time feature flag API (dead code elimination) | Runtime shim returning false for all flags |
| MACRO.* | Build-time constant injection (MACRO.VERSION etc.) | Global variable definition in preload |
| package.json | Dependency declarations (94 packages) | Reverse-engineered from import statements |
| Private npm packages | @anthropic-ai/sandbox-runtime, @ant/*, @anthropic-ai/mcpb | Empty stub modules with fake exports |
| Generated files | coreTypes.generated.ts etc. (built by internal scripts) | Manually created type stubs |
| Feature-gated files | Files deleted at compile time (connectorText.ts, TungstenTool/*) | Empty stub files |
The interactive TUI uses a custom fork of Ink (React terminal renderer) with 140+ components. Most rendering works, but some components depend on stubbed packages that return empty/no-op values, causing subtle rendering issues.
We're actively reverse-engineering the remaining pieces. PRs welcome.
Your proxy doesn't support Claude beta headers. The code auto-disables betas for non-Anthropic URLs, but you can also set:
export CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1
export DISABLE_INTERLEAVED_THINKING=1export DISABLE_PROMPT_CACHING=1Your ANTHROPIC_BASE_URL should NOT include /v1:
# Wrong
export ANTHROPIC_BASE_URL="https://proxy.com/v1"
# Correct
export ANTHROPIC_BASE_URL="https://proxy.com"Always pipe /dev/null to stdin:
bun src/entrypoints/cli.tsx -p "hello" < /dev/nullThis repository archives source code that was leaked from Anthropic's npm registry. All original source code is the property of Anthropic.
| Back | FazBrowse Home | New Git URL |