[BUG] Visual Studio says API Error: Usage credits required for 1M context

Resolved 💬 1 comment Opened Jun 3, 2026 by rk3301 Closed Jul 7, 2026

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?

API Error: Usage credits required for 1M context · turn on usage credits at claude.ai/settings/usage, or use --model to switch to standard context

Usage shows 0% session, 3% weekly but still getting the limit error
Usage credits are enabled
Sonnet is selected as the model
Logging out and back in didn't fix it

What Should Happen?

should be able to use claude

Error Messages/Logs

API Error: Usage credits required for 1M context · turn on usage credits at claude.ai/settings/usage, or use --model to switch to standard context

Steps to Reproduce

log into visual studio.
type "hi"
get the error message

Claude Model

Sonnet (default)

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

I can't even get that output

Platform

Other

Operating System

Windows

Terminal/Shell

VS Code integrated terminal

Additional Information

it was working then suddenly encountered this issue

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗