Claude Code v2.1.84 — 6 New Environment Variables: Idle Management and Stream Resilience#
Published on March 26, 2026
Part of the Claude Code Version Tracker series. | Official Env Vars | Official Changelog
Claude Code v2.1.84 adds 6 new environment variables and ships a substantial changelog compared to v2.1.83. The headline additions are idle session management controls, a configurable stream timeout, and a PowerShell tool for Windows — but the deeper theme is operational resilience: better handling of stale sessions, stuck prompts, and timeout debugging across the entire stack.
What Changed#
| v2.1.83 | v2.1.84 | |
|---|---|---|
| Environment variables | 191 | 197 (+6) |
Model IDs (16), feature gates (41), dynamic configs (29), and slash commands (22) are unchanged from v2.1.83.
New Environment Variables#
| Variable | Likely Purpose |
|---|---|
CLAUDE_STREAM_IDLE_TIMEOUT_MS | Configures the streaming idle watchdog threshold — the maximum time Claude Code waits for data on an open SSE connection before treating it as stalled. The changelog confirms this variable and notes the default is 90 seconds. Enterprise users behind proxies that silently drop idle connections can lower this to fail fast; users on slow networks or large tool calls can raise it to avoid false timeouts. |
CLAUDE_CODE_IDLE_THRESHOLD_MINUTES | Sets the threshold (in minutes) before a session is considered idle. The changelog describes a new "idle-return prompt" that nudges users returning after 75+ minutes to /clear, reducing unnecessary token re-caching on stale sessions. This variable likely controls that 75-minute default. For users who context-switch frequently between projects, tuning this avoids re-caching costs on sessions that are still mentally fresh. |
CLAUDE_CODE_IDLE_TOKEN_THRESHOLD | Works alongside CLAUDE_CODE_IDLE_THRESHOLD_MINUTES to gate when the idle-return prompt appears. The token threshold likely ensures the prompt only fires for sessions with significant cached context — a session with 5k tokens isn't worth clearing, but one with 500k tokens is. Together, these two variables give operators fine-grained control over the idle-session cleanup behavior. |
CLAUDE_CODE_AGENT_LIST_IN_MESSAGES | Controls whether the list of available agents is included in conversation messages. When Claude Code runs with many custom agents or plugins, the agent list can consume meaningful context. This variable likely lets SDK consumers and automation scripts suppress the list to save tokens, or enable it to give the model full awareness of available sub-agents for orchestration scenarios. |
CLAUDE_AI_ORIGIN | Overrides the base URL for Claude AI authentication endpoints. This complements the existing CLAUDE_CODE_API_BASE_URL (which controls the inference endpoint) by allowing the OAuth/auth origin to be pointed elsewhere — useful for corporate environments with custom auth gateways, staging environments, or air-gapped deployments where the auth server and inference server live at different addresses. |
CLAUDE_CODE_SUBAGENT_MODELU | Appears to be a variant of CLAUDE_CODE_SUBAGENT_MODEL. The trailing U may indicate an "uncapped" or "urgent" model override for sub-agents — allowing specific sub-agent invocations to use a different model than the default sub-agent model. Alternatively, this could be a typo that shipped in the binary; it appears alongside the existing CLAUDE_CODE_SUBAGENT_MODEL in the extraction. One to watch for documentation or removal in the next release. |
Key Changes in This Release#
Bedrock / Vertex / Foundry Parity#
The changelog adds ANTHROPIC_DEFAULT_{OPUS,SONNET,HAIKU}_MODEL_SUPPORTS env vars to override effort and thinking capability detection for pinned default models on third-party providers (Bedrock, Vertex, Foundry), plus _MODEL_NAME and _DESCRIPTION variants to customize the /model picker label. This is a meaningful step for teams running Claude through AWS Bedrock or Google Vertex — previously, Claude Code's capability detection could misidentify what a pinned model supported, leading to degraded behavior (no extended thinking, wrong effort levels). These env vars let operators explicitly declare "this model supports X" rather than relying on auto-detection that doesn't always survive the provider abstraction layer.
New Hooks: TaskCreated and WorktreeCreate HTTP#
Two new hook events expand the automation surface. TaskCreated fires when a task is created via TaskCreate, enabling external systems to react to subagent spawning — think logging, rate limiting, or routing tasks to specific compute. WorktreeCreate now supports type: "http", letting hook handlers return a custom worktree path via hookSpecificOutput.worktreePath in the response JSON. This is the first hook that accepts structured return data, opening the door for hooks that don't just observe but actively influence Claude Code's behavior. Combined with the CwdChanged and FileChanged hooks from v2.1.83, the hooks system is rapidly becoming a proper extension API.
Deep Links Now Open in Preferred Terminal#
The claude-cli:// deep link protocol now opens in your preferred terminal instead of whichever terminal happens to be first in the detection list. Previously, clicking a claude-cli:// link might open iTerm when you wanted Ghostty, or Terminal.app when you live in Warp. A small fix that removes a real friction point for anyone using deep links in documentation, onboarding flows, or shared team scripts.
PowerShell Tool (Windows Preview)#
An opt-in PowerShell tool for Windows joins the existing Bash tool. Controlled by CLAUDE_CODE_USE_POWERSHELL_TOOL, this gives Windows-native users access to PowerShell cmdlets, .NET integration, and Windows-specific system management without routing everything through a Bash compatibility layer. This is a preview — expect rough edges.
Idle Session Management#
The new idle-return prompt is a smart quality-of-life feature. When you return to a session after 75+ minutes, Claude Code now suggests /clear instead of silently re-caching a stale context window. The three new idle-related variables (CLAUDE_CODE_IDLE_THRESHOLD_MINUTES, CLAUDE_CODE_IDLE_TOKEN_THRESHOLD, CLAUDE_STREAM_IDLE_TIMEOUT_MS) give operators control over both the user-facing prompt and the underlying stream watchdog. Token counts also now display as "1.5m" instead of "1512.6k" for readability.
MCP Hardening#
MCP tool descriptions and server instructions are now capped at 2KB, preventing OpenAPI-generated servers from bloating context. Servers configured both locally and via claude.ai connectors are now deduplicated (local config wins). The MCP tool/resource cache leak on server reconnect is fixed, and global system-prompt caching now works when ToolSearch is enabled — including for users with MCP tools configured.
TIL: Stats Screenshot#
Here's one buried in the changelog worth a spotlight: Ctrl+S in /stats now captures a screenshot of your session statistics — and it's 16x faster than before. If you've ever wanted to share your token usage or session metrics without a manual screenshot, this is the way. Works in all builds now, not just debug.
Windows QOL: Drive Root Protection#
In the "fixes you hope never applied to you" category: Claude Code now has improved detection for dangerous removals of Windows drive roots (C:\, C:\Windows, etc.). Yes, this implies someone (or some agent) attempted a recursive delete at the drive root and the guardrails needed tightening. A good reminder that agentic coding tools need defense-in-depth for destructive operations — especially on Windows where a wrong-path delete can brick a machine.
What These Tell Us#
Session lifecycle is getting first-class treatment. The idle-return prompt, configurable stream timeout, and token-threshold gating all address the same problem: long-lived sessions that silently degrade. Previously, returning to a 2-hour-old session meant re-caching hundreds of thousands of tokens with no warning. Now Claude Code actively manages session freshness. The three new env vars give enterprise teams the knobs to tune this behavior for their specific usage patterns — high-frequency context-switchers versus deep-focus sessions.
Third-party provider support is maturing beyond "it works." The Bedrock/Vertex/Foundry capability override env vars, combined with CLAUDE_AI_ORIGIN for custom auth gateways, signal that Anthropic is treating third-party deployments as first-class citizens rather than best-effort compatibility. The ability to explicitly declare model capabilities per provider means teams on Bedrock no longer have to accept degraded behavior when auto-detection fails — they can configure their way to parity with the direct API experience.
The hooks system is becoming an extension API. With TaskCreated, WorktreeCreate (now with HTTP response support), and the CwdChanged/FileChanged hooks from v2.1.83, Claude Code now has five hook events — and WorktreeCreate's structured return data sets a precedent for hooks that actively shape runtime behavior rather than just observing it. This is the foundation for a plugin system that doesn't require bundling code into Claude Code itself.
This analysis is conducted for independent security research and interoperability purposes under fair use principles. All trademarks belong to their respective owners. The information presented here documents publicly observable behavior of installed software and is not intended to circumvent any technological protection measures, infringe on intellectual property rights, or encourage unauthorized use. Use these findings at your own discretion.
Related Versions#
- Claude Code v2.1.83 — 8 New Environment Variables — managed-settings.d/, transcript search, 40+ fixes
- Claude Code v2.1.81 — 1 New Environment Variable —
--bareflag, concurrent OAuth fix - Claude Code v2.1.80 — Channels, Plugin Simplification, and a Bug Fix Sprint —
--channelsresearch preview - Claude Code v2.1.79 — 3 New Environment Variables — subprocess sandboxing, startup optimization
- Claude Code v2.1.78 — 2 New Environment Variables — plugin persistence, security hardening
Related: Context Window Management Guide | Claude Code Productivity Tips | The Agentic Engineering Playbook