# OpenClaw Quick Start

## Purpose

This guide connects OpenClaw to AnyRoute and verifies that the model service responds correctly. Channel integrations and background-service deployment are outside this guide.

If Node.js is not installed, complete the [Node.js Installation Guide](https://en-guide.anyroute.io/9233269m0.md) first.

## 1. Before you begin

Confirm that:

- You created an API key on the [AnyRoute API Keys page](https://cc.anyroute.io/keys).
- You know the exact model ID you want to use.
- Your environment meets OpenClaw's requirements: Node.js 24 is recommended, and Node.js 22.16 or later is supported by the source guide.
- On Windows, WSL2 with Ubuntu is the recommended environment.

## Supported models

### OpenAI-compatible

- `gpt-5.4-mini`
- `gpt-5.4`
- `gpt-5.5`
- `gpt-5.6-sol`
- `gpt-5.6-terra`
- `gpt-5.6-luna`

### Anthropic-compatible

- `claude-opus-4-8`
- `claude-opus-4-7`
- `claude-opus-4-6`
- `claude-fable-5`
- `claude-sonnet-5`
- `claude-sonnet-4-6`
- `claude-haiku-4-5-20251001`

For the complete current list, see [Supported Models](https://en-guide.anyroute.io/9233271m0.md).

## 2. Recommended setup: OpenClaw onboarding wizard

### Step 1: install OpenClaw

On macOS, Linux, or WSL2, the source guide uses the official installer:

```bash
curl -fsSL https://openclaw.ai/install.sh | bash -s -- --no-onboard
```

`--no-onboard` installs the CLI without starting the wizard automatically.

> Review remote installation scripts before running them in a managed or production environment.

Verify the installation:

```bash
openclaw --help
```

### Step 2: start the onboarding wizard

```bash
openclaw onboard
```

### Step 3: configure a custom provider

Select **Custom provider**, then use:

| Field | Value |
|---|---|
| Compatibility | `Anthropic-compatible` or `OpenAI-compatible` |
| Base URL | See below |
| Model ID | For example, `claude-sonnet-4-6` or `gpt-5.4` |
| Provider ID | `anyroute` |
| API key | Your AnyRoute API key |

Base URL:

- Anthropic-compatible: `https://cc.anyroute.io`
- OpenAI-compatible: `https://cc.anyroute.io/v1`

### Step 4: validate the setup

Keep the default gateway port, binding, and background-service settings for the first test, then run:

```bash
openclaw doctor
openclaw status
openclaw dashboard
```

Send a test message in the local dashboard. Receiving a model response confirms the connection.

## 3. Non-interactive setup

For scripts, server provisioning, or managed images, export the key:

```bash
export CUSTOM_API_KEY="YOUR_ANYROUTE_API_KEY"
```

Then run:

```bash
openclaw onboard --non-interactive \
  --mode local \
  --auth-choice custom-api-key \
  --custom-base-url "https://cc.anyroute.io" \
  --custom-model-id "gpt-5.6-sol" \
  --custom-provider-id "anyroute" \
  --custom-compatibility openai \
  --secret-input-mode ref \
  --gateway-port 18789 \
  --gateway-bind loopback
```

With `--secret-input-mode ref`, OpenClaw normally stores a reference to an environment variable instead of embedding the key. Inspect `~/.openclaw/openclaw.json` to confirm the actual variable name used by your installed version.

## 4. Manual configuration reference

The OpenClaw configuration file is `~/.openclaw/openclaw.json`. Preserve unrelated settings when editing an existing file.

```json5
{
  agents: {
    defaults: {
      model: { primary: "anyroute/gpt-5.6-sol" },
    },
  },
  models: {
    providers: {
      anyroute: {
        baseUrl: "https://cc.anyroute.io",
        apiKey: "${CUSTOM_API_KEY}",
        api: "openai-completions",
        models: [
          {
            id: "gpt-5.6-sol",
            name: "gpt-5.6-sol",
          },
        ],
      },
    },
  },
}
```

The default model must use `provider-id/model-id`, for example `anyroute/gpt-5.6-sol`.

## 5. Success checklist

- The correct AnyRoute base URL is configured for the selected compatibility mode.
- The API key is active, unexpired, and has remaining balance.
- The default model uses `anyroute/<model-id>`.
- `openclaw doctor` and `openclaw status` report no configuration error.
- A dashboard message receives a response.

## Troubleshooting

### The service cannot be reached

Check the base URL and remove accidental trailing spaces. Use the compatibility-specific value shown above.

### OpenClaw starts, but the model is not found

Confirm that the model ID is currently available to your AnyRoute group and that the default model includes the `anyroute/` prefix.

### The non-interactive command reports a missing API key

Confirm that the environment variable is exported in the same shell and matches the variable referenced by `openclaw.json`.

### WhatsApp or Telegram does not work

That is normally a channel-configuration issue, not a model-provider issue. Continue with the [OpenClaw Channels documentation](https://docs.openclaw.ai/channels).

## Next steps

- [Claude Code Quick Start](https://en-guide.anyroute.io/9233273m0.md)
- [Codex CLI Quick Start](https://en-guide.anyroute.io/9233162m0.md)
- [Frequently Asked Questions](https://en-guide.anyroute.io/9233164m0.md)

