> For the complete documentation index, see [/llms.txt](/llms.txt).

> Source: /docs/integrations/claude-code

# Claude Code

Run [Claude Code](https://www.anthropic.com/claude-code), Anthropic's agentic coding CLI, on
**Upstage Solar** models. A single script points Claude Code at the Upstage API and launches it —
your shell profile and existing `~/.claude` settings are left untouched.

## Install

Run the one-line setup:

```bash
curl -fsSL https://console.upstage.ai/claude-solar.sh | sh
```

On first run the script reads your Upstage API key, verifies it with a test call, and launches
Claude Code on Solar. It installs nothing without your confirmation.

## Prerequisites

- **Upstage API key** — create one in the [Upstage Console](https://console.upstage.ai/api-keys).
- **Claude Code CLI** installed. See Anthropic's
  [installation guide](https://docs.anthropic.com/en/docs/claude-code/setup).

## What the script does

### Finds your API key

Reads your key from the `UPSTAGE_API_KEY` environment variable, your saved credentials, or a
one-time masked prompt — then verifies it before launch.

The key is only ever sent to `https://api.upstage.ai`.

### Stores it securely (optional)

If you opt in, the key is saved to your OS secret store — macOS Keychain or Linux Secret Service —
or a permission-locked file. Answer no and nothing is stored.

### Launches Claude Code on Solar

Starts Claude Code against Upstage Solar (default model: `solar-pro4`). The Solar environment
applies only to that Claude Code session.

## Useful commands

The first run offers to install the script to `~/.local/bin` as `claude-solar`. Once installed
you can use its subcommands:

```bash
claude-solar                 # launch Claude Code on Solar
claude-solar --model <id>    # launch with a specific Solar model
claude-solar --continue      # resume your most recent session
claude-solar --resume        # pick a past session to resume
claude-solar models          # list available models
claude-solar doctor          # check your setup (CLI, API key)
claude-solar login           # save a new API key
claude-solar logout          # remove the saved API key
```

## What you can do next

With Claude Code running on Solar, you can drive your codebase through natural-language commands:

- **Automate routine tasks** — write, refactor, and fix code across your project.
- **Understand code** — ask Claude Code to explain complex or unfamiliar code.
- **Handle git workflows** — stage changes, write commit messages, and open pull requests.

### Where does my API key go?

Nowhere, unless you opt in. When you do, it goes to your OS keychain (or a permission-locked
file) and is only ever sent to `https://api.upstage.ai`. Remove it any time with
`claude-solar logout`.

### Will this change my existing Claude Code setup?

No. The Solar environment variables apply only to the Claude Code process the script launches.
Your shell profile and `~/.claude` settings are not modified.