Skip to content

[Bug]: Anthropic OAuth tokens stopped working - 'OAuth authentication is currently not supported' #9938

@adamsmaka-12ac

Description

@adamsmaka-12ac

[Bug]: Anthropic OAuth tokens stopped working - "OAuth authentication is currently not supported"

Describe the bug

All Anthropic OAuth tokens (sk-ant-oat01-*) obtained via claude setup-token and configured through OpenClaw are now returning 401 authentication errors from Anthropic API.

Steps to reproduce

  1. Configure Anthropic auth using openclaw configure --section model
  2. Choose "Anthropic token (paste setup-token)"
  3. Run claude setup-token and paste the generated OAuth token
  4. Try to use any Anthropic model (opus-4-5, sonnet-4-5, etc.)
  5. Observe 404/401 errors

Expected behavior

OAuth tokens should authenticate successfully with Anthropic Messages API.

Actual behavior

API returns:

{"type":"error","error":{"type":"authentication_error","message":"OAuth authentication is currently not supported."}}

Direct API test

curl -s https://api.anthropic.com/v1/messages \
  -H "Authorization: Bearer sk-ant-oat01-..." \
  -H "anthropic-version: 2023-06-01" \
  -H "Content-Type: application/json" \
  -d '{"model":"claude-opus-4-5-20250918","max_tokens":50,"messages":[{"role":"user","content":"test"}]}'

Returns: "OAuth authentication is currently not supported."

Environment

  • OpenClaw version: 2026.2.4 (commit 821520a, also tested on 4629054)
  • Platform: macOS Darwin 25.2.0
  • Install method: git clone + pnpm build
  • Auth profiles tested: claude-max (subscription), iOS sub - all OAuth tokens fail

Timeline

This was working correctly until ~4 hours ago (around when opus-4.6 commit eb80b9a was merged). May be related to Anthropic API changes, not OpenClaw code.

Workaround

Use standard Anthropic API keys from console.anthropic.com instead of OAuth tokens (per-token billing instead of subscription).

Additional context

  • Tested with multiple fresh OAuth tokens - all fail the same way
  • OpenAI Codex OAuth tokens also have permission issues (missing api.model.read scope)
  • No related issues found in recent GitHub issues
  • Gateway logs show HTTP 404 from Anthropic API endpoints

Related issues

This may affect all users using OAuth-based authentication (Claude Max, iOS subscriptions, ChatGPT Plus) rather than API keys.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions