[BUG] incorrect API error 400
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
Every command in Claude Code returns the following error, making the tool completely unusable:
API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"You're out of extra usage. Add more at claude.ai/settings/usage and keep going."}}
This affects all commands without exception — including logout, config set, and auth status — meaning there is no way to recover from within Claude Code itself. However, the claude.ai/settings/usage dashboard clearly shows only 5% of the current 5-hour usage window has been consumed, with approximately 3 hours remaining before reset.
The following steps were attempted without success:
Restarting Claude Code and opening a fresh session
Running claude logout and claude login from Command Prompt
Deleting %USERPROFILE%\.claude\.credentials.json to force a clean re-authentication (briefly appeared to work, then failed again immediately)
Checking for ANTHROPIC_API_KEY environment variable (not set)
Updating Claude Code via npm update -g @anthropic-ai/claude-code (already on latest version 2.1.23)
The dashboard and Claude Code appear to be out of sync, with Claude Code incorrectly believing extra usage has been exhausted when the subscription allocation is nearly untouched.
What Should Happen?
Claude Code should respect the subscription's included usage allocation. When the claude.ai/settings/usage dashboard shows only 5% of the current 5-hour window has been used, Claude Code should allow requests to proceed normally without triggering extra usage errors or blocking all commands including logout, config, and auth status.
Error Messages/Logs
Steps to Reproduce
Open Command Prompt and launch Claude Code with claude
Authenticate using a Claude Pro account via claude login
Attempt any command (e.g. claude config set model claude-sonnet-4-6, /status, logout)
Observe API Error: 400 "out of extra usage" returned for every command
Navigate to claude.ai/settings/usage in a browser
Observe that the current 5-hour usage window shows only 5% consumed with ~3 hours until reset
Note the discrepancy — Claude Code blocks all requests while the dashboard shows ample remaining allocation
Environment:
OS: Windows 10 (Build 26200.8037)
Claude Code version: 2.1.23
Plan: Claude Pro
Authentication method: Claude Pro Account (OAuth)
Model: Default Opus 4.5
Claude Model
Opus
Is this a regression?
I don't know
Last Working Version
_No response_
Claude Code Version
2.1.23
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
Windows Terminal
Additional Information
The issue appears to be a server-side tracking mismatch where Claude Code is reading a stale or incorrect usage state rather than the actual account allocation. This is not an isolated case — similar reports exist in issues #32544, #24727, and #5001 describing Claude Code reporting exhausted usage while the dashboard shows remaining capacity.
Deleting %USERPROFILE%\.claude\.credentials.json and re-authenticating appeared to resolve the issue momentarily, but the error returned within minutes despite no significant usage occurring in that window.
The fact that even logout and auth status commands return the "out of extra usage" error suggests the check is happening too early in the request lifecycle — before the command type is even evaluated. Non-API commands like logout should not be subject to usage limits at all.
Request IDs for Anthropic engineers to trace:
req_011CZrDMXwnYCQM9SHrmQkgh
req_011CZrDmdpRPoVXYYUr7us8v
req_011CZrE5yT84qCm5uPXkpu5p
req_011CZrFbdABrMWUGXek7Efum
req_011CZrK7Uhsg1b1k57rZzZMb
req_011CZrK8M9V41UGE9UBZZvsv
req_011CZrKTRGoxDkKVLYzUHJSt
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗