Skip to content

[Bug]: claude-cli backend fails to register model catalog — Unknown model: claude-cli/* (model_not_found) #61093

Description

@bhenne22

Bug type

Regression (worked before, now fails)

Beta release blocker

No

Summary

After updating to 2026.4.2, the claude-cli backend registers zero models at gateway startup, causing all claude-cli/* requests to fail with model_not_found.

Steps to reproduce

  1. Install or update to OpenClaw 2026.4.2
  2. Run: openclaw models set claude-cli/claude-sonnet-4-6
  3. Run: openclaw models fallbacks add claude-cli/claude-opus-4-6
  4. Run: openclaw gateway restart
  5. Send any message
  6. Observe: all claude-cli/* model attempts fail
  7. Confirm: openclaw models list --provider claude-cli --all --plain → "No models found."

Expected behavior

openclaw models list --provider claude-cli --all --plain should return the available claude-cli models, and messages should route successfully through the claude-cli backend (as observed prior to 2026.4.2).

Actual behavior

openclaw models list --provider claude-cli --all --plain returns No models found. The gateway log shows:

All models failed (2): claude-cli/sonnet: Unknown model: claude-cli/sonnet (model_not_found) | claude-cli/opus: Unknown model: claude-cli/opus (model_not_found)

This occurs with all tested model ID formats: claude-cli/claude-sonnet-4-6, claude-cli/claude-opus-4-6, claude-cli/sonnet, claude-cli/opus.

OpenClaw version

2026.4.2 (d74a122)

Operating system

macOS (arm64) — Darwin 25.3.0

Install method

Homebrew (/opt/homebrew/lib/node_modules/openclaw), running as LaunchAgent

Model

claude-cli/claude-sonnet-4-6 (primary), claude-cli/claude-opus-4-6 (fallback)

Provider / routing chain

claude-cli → local Claude CLI binary → Anthropic

Additional provider/model setup details

Auth store: ~/.openclaw/agents/main/agent/auth-profiles.json
Providers with tokens: anthropic (1 token profile), openai (1 token profile)
models status shows: Missing auth — claude-cli
claude-cli binary is present and functional in shell ($PATH)
openclaw models auth login --provider anthropic --method cli --set-default completes without error but does not resolve "No models found"
openclaw plugins doctor → No plugin issues detected
openclaw doctor --fix → no change

Logs, screenshots, and evidence

# models status (abbreviated)
Default       : anthropic/claude-sonnet-4-6  ← switched to workaround
Configured models (6): anthropic/claude-sonnet-4-6, anthropic/claude-opus-4-6,
  claude-cli/claude-sonnet-4-6, claude-cli/claude-opus-4-6, claude-cli/sonnet, claude-cli/opus

Missing auth  : claude-cli

# models list --provider claude-cli --all --plain
No models found.

# gateway log error line
Embedded agent failed before reply: All models failed (2):
  claude-cli/claude-sonnet-4-6: Unknown model: claude-cli/claude-sonnet-4-6 (model_not_found) |
  claude-cli/claude-opus-4-6: Unknown model: claude-cli/claude-opus-4-6 (model_not_found)

# gateway status
Service: LaunchAgent (not loaded at time of check)
Config (cli): ~/.openclaw/openclaw.json
Config (service): ~/.openclaw/openclaw.json  ← no drift
Command: /opt/homebrew/opt/node/bin/node /opt/homebrew/lib/node_modules/openclaw/dist/index.js gateway --port 18789

Impact and severity

  • Affects any user routing through claude-cli/* models on 2026.4.2
  • Severity: blocks workflow — claude-cli is completely non-functional as a backend
  • Frequency: always reproducible
  • Consequence: forced fallback to direct anthropic/* API key routing; users with Claude Pro/Max subscriptions relying on CLI auth cannot use their subscription credits through OpenClaw

Additional information

Workaround confirmed: switching default and fallbacks to anthropic/claude-sonnet-4-6 + anthropic/claude-opus-4-6 (direct API token auth) works correctly. The issue onset coincided with Anthropic's usage/credits change on 2026-04-04, though it is unknown whether that change is causal or coincidental. Last known good behavior: prior to 2026.4.2. First known bad: 2026.4.2 (d74a122).

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingregressionBehavior that previously worked and now fails

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions