One npm install, three auth paths
Claude Code is a single npm package — @anthropic-ai/claude-code. Once installed it's claude on your PATH. The interesting choice is authentication, because it determines how you're billed and how your sessions get tracked.
OAuth via Claude Max / Pro. Run claude, follow the browser flow, done. Token lives in ~/.claude.json. Best for individuals — your usage rolls up under the same subscription as Claude.ai. No API key to rotate, no env var to forget.
API key. Set ANTHROPIC_API_KEY in the environment. Pay-as-you-go billing, programmatic key rotation, what every CI server uses. Treat the key like a deploy credential — never commit, always inject.
Cloud provider routing. CLAUDE_CODE_USE_BEDROCK=1 or CLAUDE_CODE_USE_VERTEX=1 route through AWS Bedrock or Google Vertex AI. Enterprises use this when their data-residency or procurement story requires the model to live behind their cloud account.
After install, claude doctor is your first stop for any "it doesn't work" question — it checks node version, PATH, auth, and connectivity in one command.