Anthropic says OpenClaw-style Claude CLI usage is allowed again

Anthropic has confirmed that Claude CLI usage via OpenClaw is permitted once again, alongside updates to prompt caching and the 1M context window beta.
Anthropic (Claude)
Anthropic builds the Claude model family and provides access via an API and Claude CLI. In OpenClaw, Anthropic API keys and Claude CLI reuse are both supported. Existing legacy Anthropic token profiles are still honored at runtime if they are already configured.
Option A: Anthropic API key
Best for: standard API access and usage-based billing. Create your API key in the Anthropic Console.
Thinking defaults (Claude 4.6)
- Anthropic Claude 4.6 models default to
adaptivethinking in OpenClaw when no explicit thinking level is set. - You can override per-message (
/think:<level>) or in model params:agents.defaults.models["anthropic/<model>"].params.thinking.
Fast mode (Anthropic API)
OpenClaw’s shared /fast toggle also supports direct public Anthropic traffic, including API-key and OAuth-authenticated requests sent to api.anthropic.com.
/fast onmaps toservice_tier: "auto"/fast offmaps toservice_tier: "standard_only"
OpenClaw only injects Anthropic service tiers for direct api.anthropic.com requests. If you route anthropic/* through a proxy or gateway, /fast leaves service_tier untouched. Anthropic reports the effective tier on the response under usage.service_tier.
Prompt caching (Anthropic API)
OpenClaw supports Anthropic’s prompt caching feature. This is API-only; legacy Anthropic token auth does not honor cache settings.
Configuration
Use the cacheRetention parameter in your model config:
| Value | Cache Duration | Description |
|---|---|---|
| none | No caching | Disable prompt caching |
| short | 5 minutes | Default for API Key auth |
| long | 1 hour | Extended cache |
Bedrock Claude notes
- Anthropic Claude models on Bedrock (
amazon-bedrock/*anthropic.claude*) acceptcacheRetentionpass-through when configured. - Non-Anthropic Bedrock models are forced to
cacheRetention: "none"at runtime.
1M context window (Anthropic beta)
Anthropic’s 1M context window is beta-gated. In OpenClaw, enable it per model with params.context1m: true for supported Opus/Sonnet models.
Note: Anthropic currently rejects context-1m-* beta requests when using legacy Anthropic token auth (sk-ant-oat-*). If configured, OpenClaw logs a warning and falls back to the standard context window.
Claude CLI backend
The bundled Anthropic claude-cli backend is supported in OpenClaw. Anthropic staff confirmed this usage is allowed again. OpenClaw therefore treats Claude CLI reuse and claude -p usage as sanctioned for this integration unless Anthropic publishes a new policy.
Troubleshooting
- 401 errors / token suddenly invalid: Anthropic token auth can expire or be revoked. Migrate to an Anthropic API key for new setups.
- No API key found for provider "anthropic": Auth is per agent. New agents don’t inherit the main agent’s keys. Re-run onboarding for that agent.
- No available auth profile: Check
openclaw models status --jsonforauth.unusableProfiles. Anthropic rate-limit cooldowns can be model-scoped, so a sibling model may still be usable.
Source: Hacker News















