vibeproxy icon indicating copy to clipboard operation
vibeproxy copied to clipboard

Claude enterprise accounts show "plan: free" / "5-hour-limit 0%" — claude.ai account endpoint blocked by Cloudflare challenge

Open ryancnelson opened this issue 6 months ago • 1 comments

Describe the bug

On Claude enterprise accounts (authenticated via OAuth), the dashboard incorrectly displays plan: free and 5-hour-limit: 0% regardless of actual usage. Requests still go out and get rate-limited by Anthropic, but the proxy is blind to this — no fallback, no usage tracking.

To reproduce

  1. Authenticate with a Claude enterprise account (nonprofit org in this case)
  2. Make several requests until Anthropic rate-limits you
  3. Dashboard continues to show plan: free, 5-hour-limit: 0%

Root cause (debugged)

The account/plan endpoint CLIProxyAPIPlus calls on claude.ai returns a Cloudflare HTML challenge page instead of JSON for enterprise/org accounts:

Content-Type: text/html
Body: <!DOCTYPE html><html lang="en-US"><head><title>Just a moment...</title>...

CLIProxyAPIPlus fails to parse this as JSON, silently defaults to plan: free with 0% usage, and never surfaces the error in the dashboard or logs.

Meanwhile, direct calls to api.anthropic.com/v1/messages confirm the account IS rate-limited:

HTTP/2 429
x-should-retry: true
anthropic-organization-id: dbf298be-fd06-41f8-9b4f-26387882fb3a

{"type":"error","error":{"type":"rate_limit_error","message":"Error"},"request_id":"..."}

Impact

  • Dashboard quota display is permanently wrong for enterprise accounts
  • Proxy forwards all requests blind — no automatic fallback to other providers (Antigravity, OpenRouter) when Claude is rate-limited
  • User has no visibility into actual quota state

Expected behavior

Either:

  • Parse the 429 responses from api.anthropic.com to infer rate-limit state and update the usage meter accordingly, OR
  • Surface a clear error in the dashboard when the account endpoint returns a non-JSON response (Cloudflare challenge) instead of silently defaulting to free/0%

Environment

  • macOS: 26.3 (arm64)
  • Account type: Claude enterprise (nonprofit org)
  • Auth file: [email protected], "type": "claude"

Note: This issue was investigated and written up with AI assistance (Claude via this same VibeProxy setup, ironically). The bug was observed by a human user; the debugging data — response headers, endpoint probing, binary string extraction — was collected programmatically. The root cause hypothesis is machine-generated but the underlying observations are real captured output.

ryancnelson avatar May 27 '26 21:05 ryancnelson

This is an upstream/provider limitation: the plan/quota display depends on the claude.ai account endpoint, which Cloudflare can challenge depending on your IP — nothing the proxy can bypass. Worth tracking upstream (CLIProxyAPI). On the app side, the quota panel work in #485 will surface whatever the backend can report.

ranaroussi avatar Sep 26 '26 09:09 ranaroussi