[BUG] [CRITICAL BUG] VSCode Extension: Re-authentication causes 401 error, has Extra Usage Enabled stuck at false, Max plan not recognized
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?
After re-authenticating in Claude Code VSCode extension (v2.1.5) on Jan 12, 2026, the subscription API returns 401 error and sets hasExtraUsageEnabled: false in ~/.claude.json, despite having an active Max plan - 5x subscription (£90/month, Invoice 89CF8798-0009).
This causes the system to silently downgrade from Sonnet to Haiku model without any error notification. The UI still shows "Sonnet 4.5" but logs confirm Haiku is actually running.
TIMELINE:
- Dec 4, 2025 - Jan 11, 2026: Used Opus + Sonnet successfully (no Haiku ever used)
- Jan 12, 2026 at 12:48 GMT: Re-logged into Claude Code VSCode extension
- Jan 12, 2026 at 12:51:10 GMT: Started getting "Failed to fetch subscription: AxiosError: 401"
- Jan 12, 2026 at 12:48:42 GMT: System switched to Haiku for the FIRST TIME
EVIDENCE:
- Log line 511: "Failed to fetch subscription: AxiosError: Request failed with status code 401"
- Log line 134: "Tool search disabled for model 'claude-haiku-4-5-20251001'"
- ~/.claude.json shows: "hasExtraUsageEnabled": false (should be true for Max plan)
- settings.json shows: "claudeCode.selectedModel": "claude-sonnet-4-5-20250929" (user selected Sonnet)
IMPACT:
- Paying £90/month for Max plan but receiving free tier functionality (Haiku)
- No error notification shown to user about downgrade
- UI shows "Sonnet" while actually running "Haiku" (misleading)
ACCOUNT:
- Email: atlitude@mail.com
- Account UUID: bd421421-2133-47ed-ae66-59e786088a65
- Organization UUID: 17140a2e-1f56-4155-a307-84818a65dc53
- Invoice: 89CF8798-0009 (Max plan - 5x, valid Jan 7 - Feb 7, 2026)
The re-authentication generated new OAuth tokens that are not properly linked to my paid subscription in the backend database, causing the subscription verification endpoint to return 401.
<img width="730" height="624" alt="Image" src="https://github.com/user-attachments/assets/1f2ab04b-18c2-4047-917a-5c22a8fdef1a" />
<img width="1133" height="655" alt="Image" src="https://github.com/user-attachments/assets/dd344352-a8f7-4da4-81e4-683e4787ed35" />
<img width="1245" height="658" alt="Image" src="https://github.com/user-attachments/assets/dd754403-9a68-4ee2-9acf-d99b5875fb5f" />
What Should Happen?
- OAuth login completes successfully
- Extension attempts to fetch subscription status from API
- API recognizes my paid Max plan - 5x subscription (Invoice 89CF8798-0009)
- ~/.claude.json is updated with "hasExtraUsageEnabled": true
- Sonnet/Opus models remain available as per my Max plan subscription
- No silent downgrade to Haiku
- If subscription verification fails, user should see clear error notification with actionable steps
Expected result: I continue using Sonnet model with 5x usage limits as paid for in my £90/month Max plan subscription.
Error Messages/Logs
=== LOG FILE PATH ===
~/.config/Code/logs/20260112T124835/window1/exthost/Anthropic.claude-code/Claude VSCode.log
=== ERROR 401 - Subscription Fetch Failure (Line 511) ===
2026-01-12 12:51:10.929 [error] Failed to fetch subscription: AxiosError: Request failed with status code 401
=== CONTEXT AROUND ERROR 401 (Lines 507-513) ===
2026-01-12 12:51:10.398 [info] Received message from webview: {"type":"request","requestId":"u7snofwg4et","request":{"type":"submit_oauth_code","code":"XVMgHr8eKRxKsmTp12eWdTVyMRkU5SzhvhL4dt1JXqKNYaTs#EbrU7RRK7PdPBT7sEUK4nVbAeySw513OVil0t37f97U"}}
2026-01-12 12:51:10.399 [info] Handling manual auth code input
2026-01-12 12:51:10.929 [error] Failed to fetch subscription: AxiosError: Request failed with status code 401
2026-01-12 12:51:10.929 [info] Saving OAuth tokens to secure storage
2026-01-12 12:51:10.929 [info] Login successful
2026-01-12 12:51:10.929 [info] Getting authentication status
=== HAIKU MODEL RUNNING - Should be Sonnet (Line 134) ===
2026-01-12 12:48:42.804 [info] From claude: 2026-01-12T12:48:42.804Z [DEBUG] Tool search disabled for model 'claude-haiku-4-5-20251001': model does not support tool_reference blocks. This feature is only available on Claude Sonnet 4+, Opus 4+, and newer models.
=== CONFIG FILE: ~/.claude.json (Relevant Section) ===
{
"oauthAccount": {
"accountUuid": "bd421421-2133-47ed-ae66-59e786088a65",
"emailAddress": "atlitude@mail.com",
"organizationUuid": "17140a2e-1f56-4155-a307-84818a65dc53",
"hasExtraUsageEnabled": false,
"displayName": "Bob"
}
}
=== USER SETTINGS: ~/.config/Code/User/settings.json (Line 46) ===
"claudeCode.selectedModel": "claude-sonnet-4-5-20250929"
Steps to Reproduce
- Have an active Max plan - 5x subscription (confirmed with Invoice 89CF8798-0009, £90.00, valid Jan 7 - Feb 7, 2026)
- Install Claude Code VSCode extension v2.1.5
- Use Claude Code normally with Opus/Sonnet models for several weeks (works fine)
- Open VSCode Command Palette (Ctrl+Shift+P)
- Run: "Claude Code: Logout"
- Close and reopen VSCode
- Launch Claude Code again
- Complete OAuth authentication flow (login via claude.ai)
- Observe in logs: "Failed to fetch subscription: AxiosError: Request failed with status code 401"
- Check ~/.claude.json - see "hasExtraUsageEnabled": false (should be true)
- Notice system silently switched to Haiku model despite Sonnet being selected in settings
- UI still shows "Sonnet 4.5" but logs confirm Haiku is running
Claude Model
Sonnet (default)
Is this a regression?
I don't know
Last Working Version
_No response_
Claude Code Version
2.1.6
Platform
Other
Operating System
Ubuntu/Debian Linux
Terminal/Shell
Other
Additional Information
ENVIRONMENT:
- VSCode Extension: anthropic.claude-code v2.1.6
- OS: Linux Debian 6.1.0-42-amd64
- VSCode: Latest version
- Installation method: VSCode Marketplace
SUBSCRIPTION DETAILS:
- Plan: Max plan - 5x (£90.00/month)
- Invoice: 89CF8798-0009
- Payment date: January 7, 2026
- Valid until: February 7, 2026
- Account email: atlitude@mail.com
WHAT I'VE TRIED:
- Logged out and logged back in (Jan 12 at 12:48 GMT) - didn't help
- Contacted support - received incorrect instructions for CLI version instead of VSCode extension
- Support bot declined refund citing "previously issued refund" (unrelated issue from Jan 10)
- Manually set selectedModel in settings.json to force Sonnet (temporary workaround)
HISTORICAL DATA:
- Extension installed: Dec 4, 2025
- Dec 4 - Jan 11: Used Opus + Sonnet successfully (NO Haiku ever)
- Jan 12 after re-login: Haiku appeared for the FIRST TIME
- stats-cache.json confirms NO Haiku usage before Jan 12
ROOT CAUSE HYPOTHESIS:
Re-authentication on Jan 12 generated new OAuth tokens that are not properly linked to my paid subscription (Invoice 89CF8798-0009) in the backend database, causing the subscription API to return 401.
WORKAROUND:
Set "claudeCode.selectedModel": "claude-sonnet-4-5-20250929" in ~/.config/Code/User/settings.json
Note: This doesn't fix has Extra Usage Enabled: false, so I'm still not getting 5x usage limits.
RELATED ISSUES:
- #6330 - Max plan subscribers shown as Pro users
- #12249 - Using API credits instead of subscription
- #16157 - Usage limits issues with Max subscription
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗