[DOCS] CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC also disables the plan-usage fetch, which isn't documented
Nobody has claimed this yet.
Assessment
- Difficulty
- 1/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 83/100
- Issue type
- Documentation
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- typescript
- Domain
- documentation
Research direction
Read the env-vars and data-usage pages named in the issue and check how each describes CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC. Confirm the documented behavior against the reported SDK usage result, where rate_limits is null when the variable is set. Update both pages to explain that the plan-usage fetch is skipped, or clarify its behavior if maintainers choose to treat that fetch as essential.
Written by the indexing model from the issue text.
Description
Documentation Type
Missing documentation (feature not documented)
Documentation Location
https://code.claude.com/docs/en/env-vars
https://code.claude.com/docs/en/data-usage
Section/Topic
CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC and "Telemetry services"
Current Documentation
The env-vars row lists what the variable disables: "auto-updates, telemetry, error reporting, the /feedback command, Claude-drafted feedback, release notes, the PR and MR status badge checks, and availability checks such as the fast mode check", plus feature-flag fetching and plugin command sources. The data-usage page describes it as a way to "disable all non-essential traffic at once".
What's Wrong or Missing?
With the variable set, Claude Code also skips the plan-usage request (/api/oauth/usage). Neither page mentions this. The SDK's usage call returns rate_limits_available: true, rate_limits: null in a few milliseconds, without a network request. Anything that reads plan limits from it shows nothing. Streamed rate_limit_events and the status line's rate_limits keep working, because they come from inference response headers.
It's easy to hit without knowing. Org admins push the variable to every member through managed settings to turn off telemetry. Members can't override it, and "0" still counts as set. The members then lose the 5-hour and weekly usage numbers in tools built on the SDK, with no hint why.
Repro (Claude Code 2.1.318, Team plan, macOS):
- Set
CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC=1in org managed settings. The same org already setsDISABLE_TELEMETRY,DISABLE_ERROR_REPORTING,DISABLE_FEEDBACK_COMMANDandCLAUDE_CODE_DISABLE_FEEDBACK_SURVEY. - Call the SDK usage method (
usage_EXPERIMENTAL_MAY_CHANGE_DO_NOT_RELY_ON_THIS_API_YET). Result:rate_limits: null, every time. - Remove only that variable from managed settings and restart. The same call returns
five_hour,seven_dayand the per-model weekly window.
Downstream report: https://github.com/pingdotgg/t3code/issues/27492 (T3 Code shows "Could not read limits").
Suggested Improvement
Either:
- add "the plan-usage fetch (
/api/oauth/usage)" to the list in the env-vars row and on the data-usage page, or - treat the usage fetch as essential traffic. It only reads the account's own limits, the same data the status line already gets from response headers.
The second seems more useful. Admins who set the variable to turn off telemetry don't intend to hide their members' plan limits.
Impact
High - Prevents users from using a feature
Additional Context
Possibly related: #96124 (/usage shows no rate-limit bars while the status line has rate_limits). The reporter suspects CLAUDE_CODE_OAUTH_TOKEN auth. This variable is another cause of the same symptom.
- Dominant language
- TypeScript
- Stars
- 154k
- Forks
- 25.6k
- Avg merge
- 12h 27m
- Merged PRs (30d)
- 4
Getting set up
Starts the project's dev container in your browser, under your own GitHub account.
- No Dockerfile or Docker Compose file
- No pull request template
- No contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from anthropics/claude-code
-
area:plugins bug has repro platform:linux
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
anthropics/claude-code#108218 ·
-
area:tui bug keybindings platform:linux
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
anthropics/claude-code#108201 ·
-
area:docs documentation enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 73/100
anthropics/claude-code#108192 · 1 comment ·
-
area:agents area:plugins bug has repro platform:macos
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
anthropics/claude-code#108157 ·
-
area:chrome area:permissions bug has repro platform:macos
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
anthropics/claude-code#108139 ·
All issues in anthropics/claude-code
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
earendil-works/pi-claude-code#36 ·
Maintainers usually reply within 6 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
Maintainers usually reply within 1 day
-
Resources: New work of jabodetabekPossibly taken @rmt-svc claimed this today. Openresources
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
railmapgen/rmp-gallery#4167 ·
Maintainers usually reply within 2 days
-
documentation p1
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
microsoft/monaco-editor#5577 ·
Maintainers usually reply within 1 day