Changes on
55 changes detected
--- a/accessibility.md
+++ b/accessibility.md
@@ -137,7 +137,7 @@
Some behaviors aren’t adapted for screen reader mode:
* Screen reader mode doesn’t turn on automatically when a screen reader is running.
- * Claude Code doesn’t announce a permission mode change made in any way other than cycling with `Shift+Tab`, such as entering [plan mode](</docs/en/permission-modes#analyze-before-you-edit-with-plan-mode>) from a command.
+ * Claude Code doesn’t announce a permission mode change you make with a command, such as entering [plan mode](</docs/en/permission-modes#analyze-before-you-edit-with-plan-mode>) with `/plan`.
* Attaching to a [background session](</docs/en/agent-view>) with `claude attach` or from agent view enters the terminal’s alternate screen, which has no native scrollback. This is the [same behavior as other attached sessions](</docs/en/fullscreen>). To get back out, press Left Arrow on an empty prompt, or Ctrl+Z if a dialog has focus.
* Claude Code announces costs in the summary it prints at exit, not per turn.
* Screen reader mode doesn’t change [non-interactive mode](</docs/en/headless>) with the `-p` flag. Non-interactive mode already writes plain text and remains an alternative for scripting.
--- a/agent-teams.md
+++ b/agent-teams.md
@@ -73,7 +73,7 @@
* **Enter** : open the selected teammate’s transcript and message it directly
* **Escape** : clear the selection. While you’re viewing a teammate’s transcript, Escape interrupts that teammate’s current turn
-As of v2.1.199, an idle teammate’s row stays in the panel while any teammate or subagent is still working, so you can select it to review its transcript or send it more work. Once every agent in the panel is idle, idle rows hide after 30 seconds and reappear on the teammate’s next turn; the teammate stays running and addressable while hidden. In v2.1.181 through v2.1.198, an idle row hid 30 seconds after its own turn ended, even while other teammates were still working; idle rows are not hidden on versions before v2.1.181. When more than three teammates are idle at once, the rows beyond the first three collapse into a single row that counts the collapsed teammates, such as `2 idle agents` when five are idle. Select it and press Enter to expand the collapsed rows, or press Esc to collapse them again. Working teammates, failed teammates, and the teammate you’re viewing always keep their own rows. If you want each teammate in its own split pane, see Choose a display mode.
+An idle teammate’s row stays in the panel while any teammate or subagent is still working, so you can select it to review its transcript or send it more work. Once every agent in the panel is idle, idle rows hide after 30 seconds and reappear on the teammate’s next turn; the teammate stays running and addressable while hidden. When more than three teammates are idle at once, the rows beyond the first three collapse into a single row that counts the collapsed teammates, such as `2 idle agents` when five are idle. Select it and press Enter to expand the collapsed rows, or press Esc to collapse them again. Working teammates, failed teammates, and the teammate you’re viewing always keep their own rows. If you want each teammate in its own split pane, see Choose a display mode.
##
--- a/agent-view.md
+++ b/agent-view.md
@@ -440,8 +440,9 @@
How file edits are isolated
-Every background session, whether started from agent view, `/bg`, or `claude --bg`, starts in your working directory. Before editing files, Claude moves the session into an isolated [git worktree](</docs/en/worktrees>) under `.claude/worktrees/`, so parallel sessions can read the same checkout but each writes to its own. Once the session is in its worktree, Claude Code [enforces worktree isolation](</docs/en/worktrees#how-claude-code-enforces-isolation>) for the session and for any subagents it spawns. Claude skips the worktree when:
-
+When you dispatch a background session from agent view or start one with `claude --bg`, the session starts in your working directory. Before editing files, Claude moves the session into an isolated [git worktree](</docs/en/worktrees>) under `.claude/worktrees/`, so parallel sessions can read the same checkout but each writes to its own. Once the session is in its worktree, Claude Code [enforces worktree isolation](</docs/en/worktrees#how-claude-code-enforces-isolation>) for the session and for any subagents it spawns. Claude skips the worktree when:
+
+ * You moved a session you already had open to the background with `←` or `/background`. That session keeps editing files where it was already working
* The session is already inside a linked git worktree, whether Claude created it under `.claude/worktrees/` or you created it with `git worktree add` somewhere else
* The file that Claude is editing is inside a linked git worktree, such as one that the session or its subagent created with `git worktree add`
* The working directory isn’t a git repository and no [`WorktreeCreate` hook](</docs/en/hooks#worktreecreate>) is configured
@@ -455,7 +456,7 @@
}
}
-Outside a git repository, sessions write to the working directory directly and aren’t isolated from each other, so avoid dispatching parallel sessions that edit the same files. If you use a different version control system, configure a [`WorktreeCreate` hook](</docs/en/worktrees#non-git-version-control>) and Claude isolates edits the same way it does for git. When the hook fails in a directory that isn’t a git repository, Claude skips isolation for that directory and edits the working directory in place. Inside a git repository, Claude Code blocks writes to the shared checkout until Claude moves the session into a worktree. To find a session’s worktree path, peek the session or attach and check its working directory. A [subagent](</docs/en/sub-agents>) the background session spawns inherits the session’s working directory, so its file edits land in the session’s worktree rather than your working copy. To give a subagent its own separate worktree instead, set [`isolation: worktree`](</docs/en/sub-agents#supported-frontmatter-fields>) in its frontmatter or pass `isolation: "worktree"` when spawning it. When a background session has made code changes in a worktree Claude entered, Claude Code instructs Claude to preserve the work before finishing, so it survives if you delete the session and its worktree:
+Outside a git repository, sessions write to the working directory directly and aren’t isolated from each other, so avoid dispatching parallel sessions that edit the same files. If you use a different version control system, configure a [`WorktreeCreate` hook](</docs/en/worktrees#non-git-version-control>) and Claude isolates edits the same way it does for git. When the hook fails in a directory that isn’t a git repository, Claude skips isolation for that directory and edits the working directory in place. Inside a git repository, a session that Claude moves into a worktree before editing can’t edit files in the shared checkout until that move happens. To find a session’s worktree path, peek the session or attach and check its working directory. A [subagent](</docs/en/sub-agents>) the background session spawns inherits the session’s working directory. Once the session is in a worktree, the subagent’s file edits land in that worktree rather than in your working copy. To give a subagent its own separate worktree instead, set [`isolation: worktree`](</docs/en/sub-agents#supported-frontmatter-fields>) in its frontmatter or pass `isolation: "worktree"` when spawning it. When a background session has made code changes in a worktree Claude entered, Claude Code instructs Claude to preserve the work before finishing, so it survives if you delete the session and its worktree:
* **Commit and push** : Claude commits without asking, and pushes the branch when the repository has a remote.
* **Draft pull request** : Claude opens one when the task calls for it, and the `#N` label appears on the row.
--- a/amazon-bedrock.md
+++ b/amazon-bedrock.md
@@ -428,7 +428,7 @@
"availableModels": ["opus", "sonnet", "claude-haiku-4-5", "anthropic.claude-haiku-4-5"]
}
-Entries with the `anthropic.` prefix are added as custom picker options and routed to Mantle. Replace `anthropic.claude-haiku-4-5` with the model ID your account has been granted. See [Restrict model selection](</docs/en/model-config#restrict-model-selection>) for how `availableModels` interacts with other model settings. When both providers are active, `/status` shows `Amazon Bedrock + Amazon Bedrock (Mantle)`.
+Entries with the `anthropic.` prefix are added as custom picker options, and the ones that match the Mantle format are routed to Mantle. Replace `anthropic.claude-haiku-4-5` with the model ID your account has been granted. See [Restrict model selection](</docs/en/model-config#restrict-model-selection>) for how `availableModels` interacts with other model settings. When both providers are active, `/status` shows `Amazon Bedrock + Amazon Bedrock (Mantle)`.
###
--- a/champion-kit.md
+++ b/champion-kit.md
@@ -46,7 +46,7 @@
The most useful posts describe a technique a colleague can reuse tomorrow rather than an outcome that is already complete. Techniques compound as they spread through a team; status updates do not. Examples of reusable techniques:
* “I learned that @-mentioning a directory works. Pointing it at `@src/components/` and asking which were missing tests surfaced two I had overlooked.”
- * “Plan mode (`Shift+Tab`) shows exactly which files will be touched before any edit is made, which is why I am comfortable using it on shared code.”
+ * “Plan mode (`Shift+Tab`) lays out the proposed changes first, which is why I am comfortable using it on shared code.”
* “I configured a Stop hook so I receive a desktop notification when a long task completes. Configuration is in the thread.”
* “Running `/init` generates a `CLAUDE.md` from the repository so the assistant stops re-asking about our conventions.”
@@ -82,8 +82,8 @@
it finished. Configuration is in the thread.
Plan mode is the reason I am comfortable using this on code that matters.
- Press Shift+Tab until you see "plan"; it lays out exactly which files it
- intends to touch before changing anything.
+ Press Shift+Tab until you see "plan"; it lays out the changes it proposes
+ without editing your source.
##
@@ -124,7 +124,7 @@
Question| Suggested response| Follow-up resource
---|---|---
”What should I try it on first?”| Recommend a real but contained task, ideally a bug or chore the person has been postponing because it is tedious rather than difficult.| [Common workflows](</docs/en/common-workflows>)
-”How do I trust it with my code?”| Introduce plan mode: pressing `Shift+Tab` cycles into it, Claude proposes exactly what it intends to change, and nothing is modified until the user approves.| [Permissions](</docs/en/permissions>)
+”How do I trust it with my code?”| Introduce plan mode: pressing `Shift+Tab` cycles into it, and Claude researches and proposes changes without editing your source.| [Permissions](</docs/en/permissions>)
”Is the setup worth the effort?”| Installation takes roughly two minutes, runs in the terminal, and requires no IDE extension. Running `/init` once is sufficient to begin working.| [Quickstart](</docs/en/quickstart>)
”It produced an incorrect result.”| Encourage them to provide the failure back to Claude. Pasting the error message or failing test is far more effective than rephrasing the original request.| [Common workflows](</docs/en/common-workflows>)
”It does not understand our codebase conventions.”| Suggest running `/init` to generate a `CLAUDE.md` file, then adding the team’s conventions, test commands, and any directories that should be avoided.| [Memory](</docs/en/memory>)
@@ -205,7 +205,7 @@
Concern| Suggested response| Evidence to offer
---|---|---
”I am faster without it.”| That is likely true for code the person writes routinely. Suggest trying it on the work they tend to avoid: legacy files, unfamiliar services, or test scaffolding, where it helps the most.| Time one tedious task both ways and compare.
-”I do not trust AI to touch production code.”| Agree that no change should land unread. Plan mode combined with normal diff review means nothing is applied that the engineer has not inspected, the same standard as any pull request.| Demonstrate plan mode on a real file.
+”I do not trust AI to touch production code.”| Agree that no change should land unread. Suggest plan mode to see the proposed changes first, then review the diff to the same standard as any pull request.| Demonstrate plan mode on a real file.
”It will make junior engineers weaker.”| Used well, it is an effective explainer. Encourage junior engineers to ask Claude to explain a file and its call sites before asking it to change anything.| Run “Explain @file and where it is called from” together.
”I tried it once and it hallucinated.”| This is usually a context problem rather than a model problem. @-mentioning the relevant files, running `/init`, and providing the actual error output typically resolves it.| Re-run their original prompt with proper `@`-context.
”We do not have time to learn another tool.”| Claude Code is a terminal command rather than a platform. If it does not return value within the first session, it is reasonable to set it aside.| A two-minute install followed by one real bug.
@@ -221,7 +221,7 @@
Technique| How to apply it
---|---
Provide the right context| Use `@file` or `@directory/` references, or paste the error or log output directly. Supplying relevant context is more effective than elaborate prompting.
-Review the plan before the edit| Press `Shift+Tab` to enter plan mode. Claude will describe the intended changes for your approval before executing them.
+Review the plan before the edit| Press `Shift+Tab` to enter plan mode. Claude researches and proposes changes without editing your source.
Teach it your repository| Run `/init` to generate a `CLAUDE.md` file, then add your conventions, test commands, and any directories that should not be modified. See [Memory](</docs/en/memory>).
Reuse a workflow| Save a `SKILL.md` file in `.claude/skills/<name>/` to create a `/name` skill that the entire team can use. See [Skills](</docs/en/skills>).
Stay informed during long tasks| Configure a Stop hook to receive a desktop notification when a long-running task completes. See [Hooks](</docs/en/hooks-guide>).
Show diff (103 lines)
--- a/changelog.md
+++ b/changelog.md
@@ -1,4 +1,100 @@
This page is generated from the [CHANGELOG.md on GitHub](<https://github.com/anthropics/claude-code/blob/main/CHANGELOG.md>). Run `claude --version` to check your installed version.
+
+
+
+2.1.288
+
+October 2, 2026
+
+ * Added `$.ui.selection()` for mods: returns the text you last selected in fullscreen mode and, when the selection lies within one transcript row, that row
+ * Added a built-in `gh api` to cloud sessions whose image has no GitHub CLI, and fixed the built-in sending control characters from file names, jq filters or GitHub errors to the terminal
+ * Added recovery for a prompt cleared with Ctrl+C: pressing Up on the empty prompt brings the draft back, including pasted text and images
+ * Added a re-authenticate prompt when an MCP server asks for more OAuth scope during a tool call
+ * Added `--max-findings <n>|all` to /code-review to report more or fewer findings than the usual limit; the choice is reused until you pass `--max-findings default`
+ * Added Ctrl+F to find a session by name and Alt+↑/↓ to jump between groups in the agents view; both, and rename, can be rebound in keybindings.json
+ * Added a screen reader mode announcement of the new permission mode when you approve a plan, including with Shift+Tab
+ * Fixed mid-response API timeouts failing the turn: non-interactive sessions and subagents now continue from the partial response, and thinking-only responses are retried
+ * Fixed long conversations failing with “Prompt is too long” instead of auto-compacting when the last reply reported zero token usage
+ * Fixed `--resume` sometimes dropping files and other context that a compaction had just restored
+ * Fixed a resumed session sometimes not saving the last response of a turn, so that the next `--resume` showed the prompt unanswered
+ * Fixed resume occasionally loading a transcript cut short when the same session rewrote the file during the load
+ * Fixed resuming a conversation started on 2.1.286 or earlier dropping the model’s earlier thinking
+ * Fixed session titles, memory recall and prompt hooks failing on Mantle or behind gateways that reject structured outputs; added `CLAUDE_CODE_DISABLE_STRUCTURED_OUTPUTS` to turn structured outputs off
+ * Fixed auto mode denials pointing Claude at a Bash permission rule when the blocked tool was not Bash
+ * Fixed auto mode on Bedrock and Mantle switching to the local classifier for the rest of the session after a request to an older model, such as a WebFetch summary or a `sonnet` subagent
+ * Fixed cloud sessions that restarted on a newly picked model replying with that model after the server refused it
+ * Fixed Cowork cloud sessions staying marked as waiting for input after a WebFetch permission prompt for an unapproved URL went unanswered for five minutes
+ * Fixed prompt suggestions not appearing on a phone that joins a Cowork cloud session started on another device
+ * Fixed a mod’s button sometimes running a different button’s action when pressed on a view drawn before Claude Code restarted
+ * Fixed a plugin’s pane showing nothing when one `Code` element held a diff that does not parse; it now draws as plain code
+ * Fixed plugin LSP servers receiving literal `${user_config.*}` and `${CLAUDE_PLUGIN_ROOT}` placeholders in `initializationOptions` and `settings` instead of substituted values or manifest defaults
+ * Fixed a plugin’s `tool.call` hook making Bash fail and file searches read the wrong folder in subagents that run in a worktree
+ * Fixed `git-subdir` plugin installs failing, or caching an incomplete plugin, on older git (before 2.39, e.g. Ubuntu 22.04’s 2.34)
+ * Fixed plugins loaded with `--plugin-dir` not showing “Configure options” in `/plugin`
+ * Fixed background sessions ending when a plugin was reloaded or disabled while one of its timers or reads was still running
+ * Fixed sandboxed heredocs with an unquoted delimiter (`python3 <<EOF`) asking for approval on every run under sandbox auto-allow when the body holds only plain text and simple `$VAR` references
+ * Fixed Bash tool permission check to prompt before a `BASHPID` assignment whose value the shell would evaluate as arithmetic, instead of allowing it silently
+ * Fixed fullscreen sessions exiting with “unrecoverable interface error” when opening the background tasks dialog while a plugin or mod showed rows above the prompt
+ * Fixed Claude reporting a message to another session as delivered when that session held it: the notice now says it wasn’t delivered and names the session, and in SDK sessions Claude can now learn of it mid-turn
+ * Fixed OpenTelemetry `claude_code.tool.blocked_on_user` spans reporting `unknown` source or decision in `-p` and SDK sessions and for PreToolUse hook approvals
+ * Fixed permission asks that ended unanswered, in `-p` or on an interrupted turn, emitting no `tool_decision` event
+ * Fixed Edit and Retry in Cowork cloud sessions refusing a message sent before `/compact` even though its history was still saved
+ * Fixed unattended sessions (`CLAUDE_CODE_RETRY_WATCHDOG`) retrying for hours after a very long response stream failed; Claude Code now streams again, and gives up after three timeouts
+ * Fixed `/login` reporting “Login successful” when credentials could not be saved to secure storage; it now shows the failure, and offers a retry when the new login didn’t take effect (anthropics/claude-code#73861)
+ * Fixed a Stop during Bedrock credential lookup sometimes moving the session to a fallback model instead of ending the request
+ * Fixed a second `gcpAuthRefresh`/`awsAuthRefresh` browser sign-in opening when a laptop wakes from sleep while another Claude Code process is signing in
+ * Fixed agent teams: a plugin-defined agent spawned by name now runs with its own prompt, tools, disallowedTools and effort instead of the defaults
+ * Fixed headless (`-p` / SDK) sessions occasionally ignoring SIGTERM when a supervisor such as `timeout` or systemd sends SIGCONT alongside it
+ * Fixed restarted cloud sessions restoring a model that the organization’s enforced model list refuses
+ * Fixed MCP tool calls sometimes running twice when a remote server’s result was over 16 MB or could not be parsed
+ * Fixed subagents in Claude Desktop’s Code tab getting none of the tools of a user-configured MCP server named `memory`
+ * Fixed Claude in Chrome asking before every screenshot and page read on a site you allowed when auto mode is unavailable (such as with `disableAutoMode` or an older model); typing, navigation and JavaScript still ask
+ * Fixed `claude plugin install` failing for GitHub-source plugins on macOS and Linux machines with no GitHub SSH key: the clone now falls back to HTTPS and prints a notice
+ * Fixed `sandbox.credentials.files` entries on git config files not taking effect while `permissions.blockReadsOutsideWorkingDirectories` is on
+ * Fixed Claude leaving out your organization’s design systems when starting slides or a design with the Artifact tool on Team and Enterprise plans or machines with managed settings
+ * Fixed the keyboard not working on Windows after Claude Code restarts itself (first sign-in to a Claude apps gateway, provider setup, `/tui`)
+ * Fixed a stall when launching an agent whose `tools:` lists very many `Agent(...)` entries
+ * Fixed sessions on Claude 3 Opus and Claude 3 Sonnet failing on every turn after a whole PDF entered the conversation
+ * Fixed the npm auto-updater reporting success when the platform-native binary failed to download and only the placeholder `claude` stub was installed
+ * Fixed Remote Control cleanup archiving a session that is still connected or was just re-attached by another Claude Code process
+ * Fixed `owner/repo` plugin marketplaces showing only the second attempt’s error when both the SSH and HTTPS fetch fail; both errors are now shown, with the transport tried first on top
+ * Fixed path-scoped `.claude/rules` and nested CLAUDE.md files not loading when Write or Edit creates or changes a file in their scope (previously only Read loaded them)
+ * Fixed a dangerous `rm` (such as one on `/` or the home directory) inside a `bash -c` or `sh -c` script running without a prompt in bypassPermissions mode or under a shell allow rule (anthropics/claude-code#96300)
+ * Fixed LSP tool calls hanging indefinitely when a language server uses dynamic capability registration or stops responding; requests now time out after 60s (per-server `requestTimeout`)
+ * Fixed `idle_prompt` notification hooks firing while background agents are still running (anthropics/claude-code#93672)
+ * Fixed PreToolUse and PermissionRequest hooks being skipped when matching them failed or the tool’s input could not be serialized to JSON; the call is now blocked
+ * Fixed the first request in a fresh environment or after a model switch using the built-in output limit and auto-compact window, not the server’s; that request may now wait up to 1.5 seconds
+ * Fixed the “What should Claude do instead?” hint showing on the Interrupted row after sending queued messages with ctrl+enter
+ * Fixed `/login` in a `--bare` session running a sign-in the session never reads, which could replace your saved login; it now says which credentials work
+ * Fixed the InstructionsLoaded hook omitting agent_id and agent_type when a subagent’s file access loads a rule or nested CLAUDE.md; rules and nested CLAUDE.md files loaded on file access now also report effort
+ * Fixed the Agent tool in `claude mcp serve` always reporting no available agents and rejecting every subagent_type
+ * Fixed the terminal cursor not following the typed text in the fullscreen transcript viewer’s search and in `/theme`’s custom color search
+ * Fixed `/permissions` in screen reader mode: typing a rule’s number now picks it instead of opening the search box
+ * Improved auto mode: when a conversation grows too long for the client-side safety classifier to review, it is now compacted instead of prompting for, or failing, every tool call
+ * Improved screen reader mode: short announcements, such as a deleted word, now stay on screen until your next key press or until something above them on screen changes
+ * Improved screen reader mode: answered questions in question dialogs now say “answered” beside their box
+ * Improved the `/usage-credits` message shown to Team and Enterprise members whose organization has turned off usage credit requests
+ * Improved cloud sessions: a new conversation’s first turn no longer waits for a stdio MCP server whose config sets `alwaysLoad: false`
+ * Improved “You should know” notes to say “we”, “the main agent” or “you” depending on who was responsible for a decision
+ * Improved the error for an artifact database write refused at the database’s size limit: it now states the limit and what frees space
+ * Improved Bash permission prompts to give a shorter reason when part of a command can’t be checked before it runs
+ * Self-hosted runner: Improved the built-in `gh api`: a refused gh command now prints its `gh api` equivalent, `--paginate` follows every page of a repository’s lists, and a nested `claude` no longer removes it
+ * Improved Remote Control’s recovery from an expired server credential: sessions stay connected during renewal and are kept if it gives up after a server outage
+ * Changed the background command time limit to apply only in unattended sessions (`-p`, Agent SDK, CI, cloud); terminal, desktop app and VS Code sessions have no limit
+ * Changed the client-side auto mode classifier to ignore an `ANTHROPIC_DEFAULT_SONNET_MODEL` pin that names Claude Sonnet 5.5 or Opus 5.5 and use Claude Sonnet 5 instead
+ * Changed `claude project purge` to `claude purge`; the old name still works and prints a notice
+ * Changed the agents view `n:` filter (and Ctrl+F search) so Enter opens the session whose name matches best instead of the top row
+ * Changed `/autocompact` to save the auto-compact window per model, so each model keeps its own setting when you switch
+ * Changed MCP URL prompts from servers that can’t report when you’re done to wait for “I’m done, continue” before the tool call continues, so you can finish in the browser first
+ * [VSCode] Fixed a claude.ai connector staying on “Needs authentication” after you authorize it: the MCP servers dialog now offers Check connection
+ * [VSCode] Fixed the opt-in New Conversation shortcut (Cmd/Ctrl+N) starting a conversation in every visible Claude view instead of only the one you are in
+ * [VSCode] Fixed the chat view resuming the next saved session after you archive the one it shows; it now starts a new conversation instead
+ * [Cloud sessions] Fixed the Cloud sessions switch in Claude Code admin settings staying locked off while an unrelated security setting was loading or had failed to load
+ * [Cloud sessions] Fixed pressing Stop while a self-hosted runner was still starting not cancelling the queued message, which could then run once the runner was up
+ * [Claude Tag] Fixed Claude Tag admin settings offering a “Remove this scope” option, which always failed, on channels whose settings were created automatically
+ * [Claude Tag] Improved Claude to also follow a related Slack thread in another channel that it only read, so updates there reach the conversation that depends on them
+ * [Claude Tag] Improved save errors on a channel’s Configure page: too-long channel instructions now say to shorten them, and a save refused for lost access no longer says to try again
+ * Fixed `claude plugin test` reporting mods as turned off remotely when it had only read an out-of-date saved setting
--- a/channels.md
+++ b/channels.md
@@ -311,7 +311,7 @@
]
}
-If you set an empty array, you block all channel plugins from the allowlist, but `--dangerously-load-development-channels` can still bypass that block for local testing. To block channels entirely including the development flag, leave `channelsEnabled` unset instead. This setting requires `channelsEnabled: true`. If a user passes a plugin to `--channels` that isn’t on your list, Claude Code starts normally but the channel doesn’t register, and the startup notice explains that the plugin isn’t on the organization’s approved list. If you set `MCP_PROTOCOL_NEGOTIATION` to `auto` on the v2 MCP client runtime, a channel can also fail to register because Claude Code [doesn’t register a channel server that negotiates protocol revision 2026-07-28](</docs/en/mcp#push-messages-with-channels>).
+If you set an empty array, you block all channel plugins from the allowlist, but `--dangerously-load-development-channels` can still bypass that block for local testing. To block channels entirely including the development flag, leave `channelsEnabled` unset instead. This setting requires `channelsEnabled: true`. If a user passes a plugin to `--channels` that isn’t on your list, Claude Code starts normally but the channel doesn’t register, and the startup notice explains that the plugin isn’t on the organization’s approved list. On the v2 MCP client runtime, a channel can also fail to register because Claude Code [doesn’t register a channel server that negotiates protocol revision 2026-07-28](</docs/en/mcp#push-messages-with-channels>).
##
--- a/chrome.md
+++ b/chrome.md
@@ -112,7 +112,7 @@
In a VS Code session, whether Claude Code asks you before a browser action depends on how the session connected to your browser:
* **You typed`@browser`**: the extension approves each browser action that Claude Code would otherwise ask you about.
- * **TheEnabled by default setting connected it at start**: Claude Code asks you before browser actions in Manual, Edit automatically, Auto, and Bypass permissions modes, until you type `@browser` in that session.
+ * **TheEnabled by default setting connected it at start**: Claude Code asks you before browser actions on a site you haven’t allowed, in Manual, Edit automatically, Auto, and Bypass permissions modes, until you type `@browser` in that session.
###
--- a/claude-apps-gateway-config.md
+++ b/claude-apps-gateway-config.md
@@ -71,7 +71,8 @@
Field| Required| Description
---|---|---
`issuer`| Yes| OIDC discovery base. Must serve discovery at `/.well-known/openid-configuration`. Use HTTPS in production; the gateway accepts an `http://` issuer. A loopback issuer such as `http://localhost:8081` is rejected by the [SSRF guard](</docs/en/claude-apps-gateway-deploy#threat-model-summary>) unless `CLAUDE_GATEWAY_ALLOW_LOOPBACK=1` is set in the gateway’s environment.
-`client_id` / `client_secret`| Yes| From your OAuth client registration
+`client_id`| Yes| From your OAuth client registration
+`client_secret`| Unless `token_endpoint_auth_method` is `private_key_jwt`| From your OAuth client registration. Leave it out when you use certificate client authentication.
`allowed_email_domains`| No| Reject id_tokens whose `email` claim isn’t in one of these domains, case-insensitive. Defense-in-depth against multi-tenant IdP misconfiguration. Independent of this setting, an id_token whose `email_verified` claim is explicitly `false` is always rejected.
`allowed_groups`| No| Restrict sign-in to members of these IdP groups, matched against `groups_claim`. A user in an allowed email domain but in none of these groups is rejected. Requires the IdP to emit the groups claim. Matching is an exact, case-sensitive string comparison against the values in that claim, and the gateway doesn’t expand nested groups: to admit members of a sub-group, list the sub-group here or configure the IdP to emit flattened membership.
`groups_claim`| No| Which id_token claim carries group membership. Default `groups`. Microsoft Entra emits app roles under `roles`. Accepts a flat key or an RFC 6901 JSON Pointer such as `/resource_access/gateway/roles` for nested claims.
@@ -83,13 +84,76 @@
`userinfo_fallback`| No| When the id_token omits email or groups, fetch them from `/userinfo`. Needed for Keycloak lightweight access tokens, the Okta org server, and ADFS minimal tokens. The id_token stays authoritative; userinfo only fills gaps. Default `false`.
`use_pkce`| No| Send a PKCE (S256) challenge on the authorization request. Default `true`. Set `false` only if your IdP rejects PKCE for this confidential client.
`clock_skew_seconds`| No| Tolerate clock drift when validating id_token time claims. Default `0`, which is strict. Raise if you see “token expired / not yet valid” errors right after sign-in due to host/IdP clock skew.
-`token_endpoint_auth_method`| No| Override the token-endpoint auth method. Accepts `client_secret_basic` or `client_secret_post`. Auto-negotiated by default.
+`token_endpoint_auth_method`| No| How the gateway authenticates to the IdP’s token endpoint: `client_secret_basic`, `client_secret_post`, or `private_key_jwt` for certificate client authentication. By default the gateway picks one of the two `client_secret` methods from what the IdP advertises.
+`client_assertion`| With `private_key_jwt`| A block with `private_key_pem` and `certificate_pem`: the private key and certificate for certificate client authentication. Requires v2.1.284 or later.
`id_token_signed_response_alg`| No| Expected id_token signing algorithm. Default `RS256`. Set for IdPs that sign with ES256, PS256, or EdDSA.
`additional_authorized_parties`| No| Extra `azp` values to accept beyond `client_id`, for Keycloak broker and token-exchange flows
`discovery_url`| No| Fetch the discovery document from this URL instead of deriving it from `issuer`, for IdPs behind a proxy that rewrites the issuer host. The path must contain `/.well-known/`.
`use_proxy`| No| Send the gateway’s own IdP requests through the forward proxy in `HTTPS_PROXY` or `HTTP_PROXY`, honoring `NO_PROXY`. `false` keeps those requests direct. Requires v2.1.227 or later; see IdP requests through a forward proxy below.
`form_action_origins`| No| Additional origins for the `/device` page’s `Content-Security-Policy: form-action` directive. The gateway already allows `'self'` and the discovered `authorization_endpoint` origin, but Chrome enforces `form-action` against the entire redirect chain. If your IdP redirects through a second host, such as Azure AD federated to ADFS, hub-spoke Okta, or a corporate SSO interceptor, list every origin the authorization request may redirect through.
`ca_cert_pem`| No| The PEM-encoded CA certificate itself, not a path to a file. It replaces the system trust store for IdP requests only. To load a mounted file, write `${file:/etc/gateway/idp-ca.pem}`. Use for Keycloak or Dex behind corporate PKI.
+
+####
+
+
+
+Certificate client authentication
+
+If your identity provider authenticates OAuth clients with a certificate instead of a client secret, as Microsoft Entra does with certificate credentials, set `token_endpoint_auth_method: private_key_jwt`. Requires Claude Code v2.1.284 or later on the gateway server. With this configuration the gateway sends no secret. It authenticates to the IdP’s token endpoint with a short-lived JWT signed with the certificate’s private key when a developer signs in and each time the gateway refreshes their session. The JWT is signed with RS256 and identifies the certificate by `x5t` and `x5t#S256` thumbprint headers rather than a `kid`. Your IdP must be able to find the registered certificate by thumbprint.
+
+1
+
+Create the key and certificate
+
+Create an unencrypted RSA private key of at least 2048 bits, in PKCS#8 or PKCS#1 PEM form, and a certificate for it. The gateway refuses to start with any key that doesn’t meet these conditions. This `openssl` command creates such a key with a self-signed certificate that is valid for one year:
+
+ openssl req -x509 -newkey rsa:2048 -nodes -keyout idp-client.key -out idp-client.crt -days 365 -subj "/CN=claude-gateway"
+
+It writes `idp-client.key` and `idp-client.crt` to the current directory. Copy or mount both files where the gateway can read them. The example in step 3 uses `/etc/gateway/`.
+
+2
+
+Upload the certificate to the IdP
+
+Upload the certificate, not the private key, to the gateway’s app registration at the IdP.
+
+3
+
+Add the key and certificate to gateway.yaml
+
+Give the gateway the private key and the certificate in a `client_assertion` block. Leave `client_secret` out, because the gateway refuses to start when one is set together with `private_key_jwt`. This `oidc` block authenticates the gateway to a Microsoft Entra tenant with a certificate:
+
+ oidc:
+ issuer: https://login.microsoftonline.com/<tenant-id>/v2.0
+ client_id: <application-id>
+ token_endpoint_auth_method: private_key_jwt
+ client_assertion:
+ private_key_pem: ${file:/etc/gateway/idp-client.key}
+ certificate_pem: ${file:/etc/gateway/idp-client.crt}
+
+Both values are the PEM contents, not file paths, so load mounted files with `${file:/path}` as the example does. The gateway refuses to start unless `certificate_pem` is a single PEM certificate, without the rest of its chain, whose public key matches `private_key_pem`.
+
+4
+
+Restart the gateway and check the boot log
+
+Restart the gateway and find this line in the boot log:
+
+ [gateway] 2026-10-01T23:07:40.512Z info oidc: client authentication private_key_jwt; certificate CN=claude-gateway, SHA-1 thumbprint DE92821854EE8BAA1D98C758FAA04AABE80B9F57, expires Oct 1 23:07:31 2027 GMT
+
+Compare the SHA-1 thumbprint with the one the IdP shows for the certificate you uploaded. If the certificate has expired or isn’t valid yet, the gateway still starts but logs a warning that sign-ins and refreshes will fail until you replace it. To confirm that the IdP accepts the certificate, have one developer sign in through the gateway.
+
+####
+
+
+
+Rotate the client certificate
+
+The gateway reads the key and certificate once at boot, so a changed file takes effect only after a restart. Rotate in this order so that no token request presents a certificate the IdP doesn’t have:
+
+ 1. Upload the new certificate to the IdP alongside the old one.
+ 2. Replace the key and certificate files that `gateway.yaml` loads, then restart the gateway.
+ 3. Remove the old certificate from the IdP.
####
@@ -1006,7 +1070,7 @@
---|---|---|---
`access_control`| `allow_cidrs` / `deny_cidrs`| empty| Inbound IP allow/deny by client address, after `trusted_proxies` resolution. `deny_cidrs` is checked first; a client it matches is rejected even if `allow_cidrs` also matches. If `allow_cidrs` is non-empty the gateway is default-deny. `/healthz` and `/readyz` are exempt from `allow_cidrs`. When a trusted proxy sends an `X-Forwarded-For` entry that isn’t an IP address, the real client is unknown and the gateway logs a warning once naming what to check. Where either list applies to the request, it refuses it with `403` and audit reason `xff_unparseable`. Where neither does, it serves the request and uses the proxy’s own address as the client IP for per-IP rate limits and audit.
`limits`| `max_request_bytes`| 32 MiB| Max inbound request body; oversize requests get `413` before the body is buffered. Raise for large file or image requests.
-`limits`| `max_request_header_bytes`| unset| When set, oversize headers return `431`
+`limits`| `max_request_header_bytes`| unset| Lowers the gateway’s 256 KiB limit on a request’s total headers. A request over the limit returns `431`, and a value above 256 KiB has no effect. If developers get `431` after signing in, see [Request headers too large after sign-in](</docs/en/claude-apps-gateway-deploy#request-headers-too-large-after-sign-in>).
`limits`| `max_url_length`| unset| When set, an over-long URL returns `414`
`timeouts`| `upstream_ttfb_ms`| 120000| Max wait for the upstream’s response headers (time to first byte). The response body then streams with no wall-clock cap. Applies to the direct Anthropic upstream path; on every other provider the gateway waits up to one hour for the response to start.
`rate_limits`| `device_authorization.max` / `.window_seconds`| 30 / 600| Per-IP rate limit on the unauthenticated device-authorization endpoint. Raise for a large org behind a shared egress IP or NAT. [Large rollouts](</docs/en/claude-apps-gateway-deploy#large-rollouts>) shows how to size it. These limits apply only to the device-grant sign-in flow, not to `/v1/messages` inference. See [User-code brute-force resistance](</docs/en/claude-apps-gateway-deploy#user-code-brute-force-resistance>).
--- a/claude-apps-gateway-deploy.md
+++ b/claude-apps-gateway-deploy.md
@@ -15,7 +15,7 @@
Identity provider setup
-Register a confidential OAuth/OpenID Connect (OIDC) web application with a single redirect URI, `https://<gateway>/oauth/callback`, and assign it to the users or groups who should have gateway access. Any OIDC-compliant IdP works: Okta, Microsoft Entra ID, Google Workspace, Keycloak, Dex, PingFederate, and others. The IdP must meet three requirements:
+Register a confidential OAuth/OpenID Connect (OIDC) web application with a single redirect URI, `https://<gateway>/oauth/callback`, and assign it to the users or groups who should have gateway access. The gateway authenticates to the IdP with the registration’s client secret, or with a certificate you upload to the registration if your IdP uses [certificate credentials](</docs/en/claude-apps-gateway-config#certificate-client-authentication>) instead. Any OIDC-compliant IdP works: Okta, Microsoft Entra ID, Google Workspace, Keycloak, Dex, PingFederate, and others. The IdP must meet three requirements:
* Serves `/.well-known/openid-configuration`, over HTTPS in production; the gateway accepts an [`http://` issuer](</docs/en/claude-apps-gateway-config#oidc>), and a loopback issuer additionally requires `CLAUDE_GATEWAY_ALLOW_LOOPBACK=1`
* Supports the authorization-code flow. PKCE (Proof Key for Code Exchange) is on by default; disable it with `oidc.use_pkce: false` for IdPs that don’t support it
@@ -362,6 +362,7 @@
`/oauth/callback` shows “Sign-in could not be completed”| Email domain rejected, id_token validation failed, or `email_verified` is explicitly `false`, which the gateway always rejects with no override| Check `allowed_email_domains` and that the IdP returns a verified `email` claim. For `email_verified: false`, fix the IdP-side verification. If your IdP emits email under a different claim name, set `oidc.email_claim`.
Log: `token exchange failed request_id=<id>: id_token missing email claim`| The IdP isn’t including `email` in the id_token by default. This rejection fires only when `allowed_email_domains` is set; without it, a missing email mints a session with no email| Configure the IdP to emit `email` in the id_token. Okta: add `email` to a custom authorization server’s ID-token claims. Entra: add `email` as an optional claim on the app registration. PingFederate: enable an OpenID Connect Policy that emits `email`. If the IdP serves `email` from the userinfo endpoint but won’t include it in the id_token, such as the Okta org authorization server, set `oidc.userinfo_fallback: true`.
Log: `refresh failed request_id=<id>: invalid_token (…) (at userinfo_no_id_token, …)`, and developers see `Cloud gateway session expired` every `session.ttl_hours`| The IdP accepted the refresh token but returned no id_token with it, so the gateway asked the IdP’s userinfo endpoint for the user’s claims. The IdP rejected the refreshed access token there. The gateway answers `temporarily_unavailable`, so Claude Code keeps the refresh token but can’t renew the session. Gateway versions before v2.1.260 log the same line without the `(at …)` detail.| Set [`oidc.scope_on_refresh: true`](</docs/en/claude-apps-gateway-config#oidc>), available in gateway v2.1.260 or later, so the refresh request asks for `openid` again. Some IdPs, such as Okta, return an id_token on refresh only when asked. On PingFederate, enable **Return ID Token On Refresh Grant** under **Applications > OAuth > OpenID Connect Policy Management** instead. The key doesn’t change PingFederate’s behavior. For other IdPs that still omit it, check whether the userinfo endpoint accepts access tokens issued by a refresh. As a stopgap, raise [`session.ttl_hours`](</docs/en/claude-apps-gateway-config#session>). See Identity provider setup for the deprovisioning tradeoff.
+A developer signs in, then every request from that session fails with a `431` error| The session token in every request’s `Authorization` header lists the developer’s IdP groups, so for a developer in many groups the headers can total more than the gateway accepts| See Request headers too large after sign-in for which limit applies and what to change
Every Amazon Bedrock request returns 502; log shows `Could not load credentials from any providers`| On EC2, IMDSv2’s default hop limit of 1 blocks the instance-metadata request from inside the container. Boot and `/readyz` pass anyway because the AWS SDK resolves instance credentials on the first request, not at client construction| Raise the hop limit with `aws ec2 modify-instance-metadata-options --instance-id <id> --http-put-response-hop-limit 2`, or set it in the launch template. The change applies to every container on the instance. Prefer ECS task roles where available, which read credentials from the ECS container-credentials endpoint and avoid the change entirely, or apply the change on a dedicated gateway instance to limit the exposure.
At peak load, responses are slow to start or appear to hang, or fail with a 502 `all upstreams failed` while the upstream is healthy| A replica has more requests open than it sends upstream at once, so the extra requests wait inside the gateway. On a `provider: anthropic` upstream, a request that waits longer than `timeouts.upstream_ttfb_ms` gives up on that upstream, which produces the 502 when no later upstream serves it. The log shows a warning that contains `client requests are open`.| Add replicas, or raise the limit on each replica. See Concurrent upstream requests.
IdP error: unknown or unsupported scope| The IdP rejects scopes it doesn’t recognize| Set `oidc.scopes` to exactly the list your IdP accepts; it must include `openid`. The default is `openid profile email offline_access`.
@@ -377,6 +378,18 @@
The `Cloud gateway sign-in was not completed` message names the gateway hostname. When Claude Code has both the pinned fingerprint and the presented one, the message also shows the first 16 characters of each. If Claude Code reports `couldn't load your organization's managed settings` after a gateway sign-in, Claude Code names the reason, restarts in place, and resumes the conversation. If Claude Code can’t restart, for example in a background session, Claude Code ends the session and keeps the sign-in.
+###
+
+
+
+Request headers too large after sign-in
+
+A developer’s requests can fail with a `431` error after sign-in when the developer belongs to many IdP groups. The gateway answers `431` when a request’s headers total more than 256 KiB, or more than [`limits.max_request_header_bytes`](</docs/en/claude-apps-gateway-config#http-tuning>) if you set it. It writes no log line or audit event for these requests. Gateway versions before v2.1.284 answer `431` above 16 KiB. What to change depends on your gateway’s version and configuration:
+
+ * **Gateway older than v2.1.284** : upgrade the gateway
+ * **`limits.max_request_header_bytes` set**: raise the value or remove the key
+ * **Neither applies, or`431` continues afterward**: have your IdP emit fewer groups. Identity provider setup covers how Okta, Microsoft Entra ID, and Google Workspace supply groups
+
##
--- a/claude-directory.md
+++ b/claude-directory.md
@@ -172,7 +172,7 @@
* **Linux** : `/tmp/claude-<uid>/<project>/<session-id>/scratchpad/`, or the same shape under `$TMPDIR` when your system sets one
* **Windows** : `%TEMP%\claude\<project>\<session-id>\scratchpad\`
-`<project>` is your working directory path with every character other than letters and digits replaced by `-`, such as `-Users-you-my-project`. If you set [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>), the tree moves under that directory instead. Hooks receive the current session’s path as [`scratchpad_dir`](</docs/en/hooks#common-input-fields>). Scratchpad files last as long as the session’s transcript: the retention sweep deletes the directory when it deletes the transcript, and `claude project purge` doesn’t touch the temp directory. Because the directory sits under the system temp location, your operating system can also clear it, such as on restart. To keep something Claude wrote there, ask Claude to move it into your project. A session has a scratchpad only when all of these hold:
+`<project>` is your working directory path with every character other than letters and digits replaced by `-`, such as `-Users-you-my-project`. If you set [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>), the tree moves under that directory instead. Hooks receive the current session’s path as [`scratchpad_dir`](</docs/en/hooks#common-input-fields>). Scratchpad files last as long as the session’s transcript: the retention sweep deletes the directory when it deletes the transcript, and `claude purge` doesn’t touch the temp directory. Because the directory sits under the system temp location, your operating system can also clear it, such as on restart. To keep something Claude wrote there, ask Claude to move it into your project. A session has a scratchpad only when all of these hold:
* You’re signed in with a claude.ai account rather than an API key
* The session uses the Anthropic API, not Amazon Bedrock, Google Cloud’s Agent Platform, or Microsoft Foundry
@@ -225,16 +225,16 @@
Clear local data
-Run `claude project purge` to delete the state Claude Code holds for one project. It deletes:
+Run `claude purge` to delete the state Claude Code holds for one project. It deletes:
* Transcripts and auto memory under `projects/`
* Per-session `tasks/`, `debug/`, and `file-history/` entries
* Matching prompt lines in `history.jsonl`
* The project’s entry in `~/.claude.json`
-Images you pasted or attached in the project’s sessions and each session’s scratchpad are stored under Claude Code’s temp directory rather than `~/.claude`, so the purge doesn’t remove them. The retention sweep still deletes the images once they’re older than `cleanupPeriodDays`; a purged session’s scratchpad stays until you delete it or your operating system clears the temp directory. The command prints the full deletion plan and asks for confirmation before removing anything. The examples below use `~/work/my-repo` as a placeholder. Replace it with the path to your project. If no state matches the path, the command prints an error and exits with status 1. Preview the plan without deleting anything:
-
- claude project purge ~/work/my-repo --dry-run
+Images you pasted or attached in the project’s sessions and each session’s scratchpad are stored under Claude Code’s temp directory rather than `~/.claude`, so the purge doesn’t remove them. The retention sweep still deletes the images once they’re older than `cleanupPeriodDays`; a purged session’s scratchpad stays until you delete it or your operating system clears the temp directory. The command prints the full deletion plan and asks for confirmation before removing anything. Before v2.1.288, the command was `claude project purge`. The examples below use `~/work/my-repo` as a placeholder. Replace it with the path to your project. If no state matches the path, the command prints an error and exits with status 1. Preview the plan without deleting anything:
+
+ claude purge ~/work/my-repo --dry-run
The plan lists each matching item and why it is included:
@@ -253,11 +253,11 @@
Delete with a single confirmation prompt:
- claude project purge ~/work/my-repo
+ claude purge ~/work/my-repo
The command prints the same plan, then asks `Delete 3 item(s) for /home/user/work/my-repo? This cannot be undone. [y/N]` and deletes only if you answer `y`. Omit the path to pick a project from an interactive list. Skip the confirmation prompt for use in scripts:
- claude project purge ~/work/my-repo --yes
+ claude purge ~/work/my-repo --yes
Pass `--all` instead of a path to purge state for every project at once, which deletes `history.jsonl` outright rather than filtering it. Pass `-i` to step through the deletion plan one item at a time. The command leaves `shell-snapshots/` and `backups/` alone because those are not project-scoped, and warns about them in the plan output. You can also delete any of the application-data paths above by hand, apart from the state files to keep. New sessions are unaffected. The table below shows what you lose for past sessions.
--- a/claude-projects.md
+++ b/claude-projects.md
@@ -524,7 +524,7 @@
Limitations
- * Projects are available at claude.ai/code, in the desktop app, and in the Claude mobile app, not in the terminal CLI, the VS Code extension, or the JetBrains plugin, and not through Amazon Bedrock, Google Cloud’s Agent Platform, or Microsoft Foundry. The CLI’s [`claude project`](</docs/en/cli-reference>) command, which manages local Claude Code state for a directory, is unrelated.
+ * Projects are available at claude.ai/code, in the desktop app, and in the Claude mobile app, not in the terminal CLI, the VS Code extension, or the JetBrains plugin, and not through Amazon Bedrock, Google Cloud’s Agent Platform, or Microsoft Foundry.
* Project threads are [cloud sessions](</docs/en/claude-code-on-the-web>), or sessions on your own machine through [Remote Control](</docs/en/remote-control>), with Anthropic as the model provider in both cases. [Security](</docs/en/security>) and [Data usage](</docs/en/data-usage>) cover how cloud sessions are isolated and what’s retained, and [Connection and security](</docs/en/remote-control#connection-and-security>) covers how a thread on your machine connects and what’s stored.
* You can’t add a session you started yourself on your machine to a project. A project reaches your machine only by running a thread there through Remote Control, and that section lists what it needs.
* A cloud thread’s sandbox pauses between turns and resumes when the thread continues. If the sandbox can’t be resumed, the thread continues from a fresh clone, so uncommitted changes can be lost. On long tasks, ask Claude to commit and push work in progress.
--- a/claude-tag.md
+++ b/claude-tag.md
@@ -43,7 +43,8 @@
Slack users don’t each need a Claude seat to work with Claude in channels.
* **In channels** : by default, anyone in the paired Slack workspace can tag `@Claude` in a channel, and an Owner can [restrict who can use Claude](</docs/claude-tag/admins/restrict-access#restrict-who-can-use-claude>) to people in your Claude organization or, on Enterprise, to specific roles. Channel work bills by usage to your organization’s usage balance, under a [spend limit](</docs/claude-tag/admins/set-spend-limit>) an Owner sets.
- * **In DMs** : a DM from a member who has connected a Claude account runs on that account and bills to that person’s seat. The seat must include Claude Code, or, on the Enterprise plan, be a **Standard** or **Usage-Based Chat** seat held by someone who also has Cowork. A [DM from a member who hasn’t connected a Claude account](</docs/claude-tag/admins/restrict-access#direct-messages-from-members-without-a-claude-account>) can bill to your organization for a limited time.
+ * **In group DMs** : the same restriction on who can use Claude applies, and the work bills to your organization’s usage balance. See [Group DMs](</docs/claude-tag/admins/restrict-access#group-dms>).
+ * **In one-to-one DMs** : a DM from a member who has connected a Claude account runs on that account and bills to that person’s seat. The seat must include Claude Code, or, on the Enterprise plan, be a **Standard** or **Usage-Based Chat** seat held by someone who also has Cowork. A [DM from a member who hasn’t connected a Claude account](</docs/claude-tag/admins/restrict-access#direct-messages-from-members-without-a-claude-account>) can bill to your organization for a limited time.
##
@@ -67,7 +68,7 @@
Billing and spend limits
-Adding Claude to Slack doesn’t add a per-seat charge. Channel and thread work is billed by usage instead: it draws from a **usage balance** , an amount in your organization’s billing currency that an Owner funds. A [spend limit](</docs/claude-tag/admins/set-spend-limit>) caps how much of that balance Claude Tag can use each billing period. Direct messages from members who have connected a Claude account don’t draw from this balance. Such a DM runs on the sender’s own claude.ai account and follows that seat’s usual usage limits, so the organization spend limit doesn’t apply to it. A [DM from a member who hasn’t connected a Claude account](</docs/claude-tag/admins/restrict-access#direct-messages-from-members-without-a-claude-account>) can draw from this balance. To learn what your team’s usage costs, run a pilot with a spend limit set and watch the per-channel breakdown on the [usage page in your admin settings](<https://claude.ai/admin-settings/usage/claude-tag>). Your organization may already have a [launch usage credit](<https://support.claude.com/en/articles/15575654-claude-tag-launch-promo-for-claude-team-and-enterprise>) to run that pilot against before it funds the balance itself. The usage page doesn’t count usage that a credit covers, so that usage shows as $0.00 there. While the credit covers your pilot, watch the **List price** column of the **Spend by channel** table at [`claude.ai/analytics/claude-tag`](<https://claude.ai/analytics/claude-tag>) instead. That column shows each channel’s list-price spend for the current month, including covered usage. [Set a spend limit](</docs/claude-tag/admins/set-spend-limit>) covers how to fund the balance on each plan, set the limit, and what happens when usage reaches it.
+Adding Claude to Slack doesn’t add a per-seat charge. Channel, thread, and group DM work is billed by usage instead: it draws from a **usage balance** , an amount in your organization’s billing currency that an Owner funds. A [spend limit](</docs/claude-tag/admins/set-spend-limit>) caps how much of that balance Claude Tag can use each billing period. One-to-one direct messages from members who have connected a Claude account don’t draw from this balance. Such a DM runs on the sender’s own claude.ai account and follows that seat’s usual usage limits, so the organization spend limit doesn’t apply to it. A [DM from a member who hasn’t connected a Claude account](</docs/claude-tag/admins/restrict-access#direct-messages-from-members-without-a-claude-account>) can draw from this balance. To learn what your team’s usage costs, run a pilot with a spend limit set and watch the per-channel breakdown on the [usage page in your admin settings](<https://claude.ai/admin-settings/usage/claude-tag>). [Set a spend limit](</docs/claude-tag/admins/set-spend-limit>) covers how to fund the balance on each plan, set the limit, and what happens when usage reaches it.
For end users
@@ -77,7 +78,7 @@
Put Claude Tag to work
-If Claude Tag is in your channel, you can use it now. (If it isn’t there yet, an Owner in your Claude organization runs setup: see [Set up Claude Tag](</docs/claude-tag/admins/setup-overview>).) Anyone in the channel can hand it work, and channel work bills to the organization, not to you. What it can reach starts with the channel you’re in. The fastest way to find out is to ask it: `@Claude what can you access from this channel?` Or, if you’re signed in to your Claude organization, click **Configure** in the footer of a Claude reply in the channel to see its [connections](</docs/claude-tag/concepts/glossary#connection>), the external services an admin has connected for that channel. Replies in org-shared channels have no Configure link. For your own requests, Claude can also [use the connectors on your claude.ai account](</docs/claude-tag/concepts/personal-connectors>), after you allow it. The one exception is a DM, where it runs on your own claude.ai account instead of the channel’s setup. Owners can disable DMs organization-wide; see [Allow or disable direct messages](</docs/claude-tag/admins/restrict-access#allow-or-disable-direct-messages>).
+If Claude Tag is in your channel, you can use it now. (If it isn’t there yet, an Owner in your Claude organization runs setup: see [Set up Claude Tag](</docs/claude-tag/admins/setup-overview>).) Anyone in the channel can hand it work, and channel work bills to the organization, not to you. What it can reach starts with the channel you’re in. The fastest way to find out is to ask it: `@Claude what can you access from this channel?` Or, if you’re signed in to your Claude organization, click **Configure** in the footer of a Claude reply in the channel to see its [connections](</docs/claude-tag/concepts/glossary#connection>), the external services an admin has connected for that channel. Replies in org-shared channels have no Configure link. For your own requests, Claude can also [use the connectors on your claude.ai account](</docs/claude-tag/concepts/personal-connectors>), after you allow it. In a one-to-one DM, Claude runs on your own claude.ai account instead of a channel’s setup. Owners can disable DMs organization-wide; see [Allow or disable direct messages](</docs/claude-tag/admins/restrict-access#allow-or-disable-direct-messages>).
###
--- a/cli-reference.md
+++ b/cli-reference.md
@@ -34,7 +34,7 @@
`claude mcp login <name>`| Run a configured MCP server’s OAuth flow without opening the interactive `/mcp` panel. Works for HTTP, SSE, and claude.ai connector servers. Add `--no-browser` over SSH to print the authorization URL instead of opening a browser, then paste the redirect URL back at the prompt. See [Authenticate from the command line](</docs/en/mcp#authenticate-from-the-command-line>)| `claude mcp login sentry`
`claude mcp logout <name>`| Clear stored OAuth credentials for an MCP server| `claude mcp logout sentry`
`claude plugin`| Manage Claude Code [plugins](</docs/en/plugins/overview>). Alias: `claude plugins`. See [plugin reference](</docs/en/plugins/cli-reference#claude-plugin-commands>) for subcommands| `claude plugin install code-review@claude-plugins-official`
-`claude project purge [path]`| Delete all local Claude Code state for a project: transcripts, task lists, debug logs, file-edit history, prompt history lines, and the project’s entry in `~/.claude.json`. Omit `[path]` to pick from an interactive list. Flags: `--dry-run` to preview, `-y`/`--yes` to skip confirmation, `-i`/`--interactive` to confirm each item, `--all` for every project. See [Clear local data](</docs/en/claude-directory#clear-local-data>)| `claude project purge ~/work/repo --dry-run`
+`claude purge [path]`| Delete all local Claude Code state for a project: transcripts, task lists, debug logs, file-edit history, prompt history lines, and the project’s entry in `~/.claude.json`. Omit `[path]` to pick from an interactive list. Flags: `--dry-run` to preview, `-y`/`--yes` to skip confirmation, `-i`/`--interactive` to confirm each item, `--all` for every project. See [Clear local data](</docs/en/claude-directory#clear-local-data>)| `claude purge ~/work/repo --dry-run`
`claude remote-control`| Start a [Remote Control](</docs/en/remote-control>) server to control Claude Code from Claude.ai or the Claude app. Runs in server mode (no local interactive session). See [Server mode flags](</docs/en/remote-control#start-a-remote-control-session>). After you stop the server, you can bring back the sessions it was serving. See [Resume sessions after stopping the server](</docs/en/remote-control#resume-sessions-after-stopping-the-server>)| `claude remote-control --name "My Project"`
`claude respawn <id>`| Restart a [background session](</docs/en/agent-view#manage-sessions-from-the-shell>), running or stopped, with its conversation intact. Use `--all` to restart every running session, e.g. to pick up an updated Claude Code binary| `claude respawn 7c5dcf5d`
`claude rm <id>`| Remove a [background session](</docs/en/agent-view#manage-sessions-from-the-shell>) from the list. When the removal is [refused over the session’s worktree](</docs/en/agent-view#what-deleting-a-session-removes>) and a second `claude rm` can resolve it, the refusal prints the exact flag and value to pass: `--discard-unpushed <commit>@<worktree-id>` discards a worktree that has unpushed commits along with those commits, and `--force-remove-worktree <worktree-id>` deletes a worktree directory that git or the `WorktreeRemove` hook couldn’t remove. `--discard-unpushed` requires Claude Code v2.1.260 or later, and `--force-remove-worktree` requires v2.1.268 or later. The conversation transcript stays on your local machine, available through `claude --resume`| `claude rm 7c5dcf5d`
@@ -43,7 +43,7 @@
`claude stop <id>`| Stop a [background session](</docs/en/agent-view#manage-sessions-from-the-shell>). Also accepts `claude kill`| `claude stop 7c5dcf5d`
`claude ultrareview [target]`| Run [ultrareview](</docs/en/ultrareview#run-ultrareview-non-interactively>) non-interactively. Prints findings to stdout and exits 0 on success or 1 on failure. Use `--json` for the raw payload and `--timeout <minutes>` to override the 45-minute default. Use `--post` on a `github.com` pull request target to post the finished findings to the PR as one plain comment from your GitHub account. `--no-post` is the default. `--post` and `--no-post` require Claude Code v2.1.227 or later. See [Post findings to the pull request](</docs/en/ultrareview#post-findings-to-the-pull-request>)| `claude ultrareview 1234 --json`
-If you mistype a subcommand, Claude Code suggests the closest match and exits without starting a session. For example, `claude udpate` prints `Did you mean claude update?`. As of v2.1.199, `claude --dangerously-skip-permissions daemon <subcommand>` runs the `daemon` subcommand. Earlier versions treated `daemon <subcommand>` as the prompt for a new interactive session, so the subcommand never ran when the flag came first, a common setup when `claude` is aliased to include the flag. Only a leading `--dangerously-skip-permissions` or `--allow-dangerously-skip-permissions` routes to `daemon` this way; any other leading flag still starts an interactive session.
+If you mistype a subcommand, Claude Code suggests the closest match and exits without starting a session. For example, `claude udpate` prints `Did you mean claude update?`. `claude --dangerously-skip-permissions daemon <subcommand>` runs the `daemon` subcommand, so the subcommand works when `claude` is aliased to include the flag. Only a leading `--dangerously-skip-permissions` or `--allow-dangerously-skip-permissions` routes to `daemon` this way; with any other flag ahead of `daemon`, the subcommand doesn’t run.
##
--- a/cloud-environments.md
+++ b/cloud-environments.md
@@ -96,13 +96,13 @@
Add a credential
-You add credentials one at a time from the editor of an environment that already exists. The dialog for a new environment doesn’t offer them. There’s no edit, either. To change a credential’s hosts or value, delete it and add it again.
+You add credentials one at a time, and you can’t edit a credential after you add it. To change a credential’s hosts or value, delete it and add it again.
1
Open the environment's API credentials
-Open the environment for editing at [claude.ai/code](<https://claude.ai/code>). In the **Edit cloud environment** dialog, find **API credentials** below **Environment variables**. You see the credentials already on the environment, each with the hosts it applies to.
+Open the environment for editing at [claude.ai/code](<https://claude.ai/code>). In the **Edit environment** dialog, find the **API credentials** section. You see the credentials already on the environment, each with the hosts it applies to.
2
--- a/code-review.md
+++ b/code-review.md
@@ -322,6 +322,7 @@
* `--fix`: applies the findings to your working tree after the review
* `--comment`: posts the findings on a GitHub pull request as inline comments, or on a GitLab merge request as a single note
* `--post`: on an `ultra` cloud review of a `github.com` pull request, preselects posting the finished findings to the PR in the launch dialog; see [Post findings to the pull request](</docs/en/ultrareview#post-findings-to-the-pull-request>). Requires Claude Code v2.1.227 or later
+ * `--max-findings <n>`, `--max-findings all`, or `--max-findings default`: reports up to `n` findings, or every finding with `all`, in place of the review’s usual limit. Later reviews reuse the value you typed until you pass `--max-findings default`. Requires Claude Code v2.1.288 or later
When you pass `--comment` for a GitLab merge request, Claude Code posts the findings through GitLab’s `glab` CLI. Requires Claude Code v2.1.257 or later. When `glab` isn’t installed, Claude prints the findings in the terminal instead.Pass the merge request as its URL or a `!123` reference. Claude Code treats a bare number or branch name as a merge request only when the checkout’s origin is on `gitlab.com`. On a self-managed GitLab instance, pass the URL or `!123` form.
--- a/commands.md
+++ b/commands.md
@@ -46,7 +46,7 @@
`/claude-api [migrate|upgrade|managed-agents-onboard|prompt-audit|cost-optimize|build-eval|hillclimb|preserved-thinking-migration]`| **[Skill](</docs/en/skills#bundled-skills>).** Load [Claude API](<https://platform.claude.com/docs/en/api/overview>) and [Managed Agents](<https://platform.claude.com/docs/en/managed-agents/overview>) reference material for your project’s language. Also activates automatically when your code imports `anthropic` or `@anthropic-ai/sdk`. For what each subcommand does and the version it requires, see [Work on Claude API projects](</docs/en/skills#work-on-claude-api-projects>)
`/claude-in-chrome [task]`| **[Skill](</docs/en/skills#bundled-skills>).** Have Claude carry out a task in your browser, such as testing a page, filling a form, or reading console logs, through [Claude in Chrome](</docs/en/chrome>). Available when Chrome integration is enabled for the session, for example with `claude --chrome`, or when Claude Code can offer to [install the extension](</docs/en/chrome#install-the-extension-when-claude-asks>)
`/clear [name]`| Start a new conversation with empty context. Pass a name to label the previous conversation in the `/resume` picker. To free up context while continuing the same conversation, use `/compact` instead. Resume the previous conversation with `/resume`, or, in the same Claude Code process, restore it from [the rewind menu’s previous-session entry](</docs/en/checkpointing#rewind-past-a-cleared-conversation>). Aliases: `/reset`, `/new`
-`/code-review [low|medium|high|xhigh|max|ultra] [--fix] [--comment] [pr#|branch|path]`| **[Skill](</docs/en/skills#bundled-skills>).** Review the current diff, or a PR number, branch, or path you pass, for correctness bugs. Depending on your model and effort level, the review also covers cleanup opportunities. Pass `--fix` to apply findings, `--comment` to post them on the GitHub PR or GitLab merge request, or `ultra` to run a deep [cloud review](</docs/en/ultrareview>). Posting to a GitLab merge request requires Claude Code v2.1.257 or later. With `ultra` on a `github.com` PR target, pass `--post` to preselect [posting the finished findings to the PR](</docs/en/ultrareview#post-findings-to-the-pull-request>) in the launch dialog; `--post` requires Claude Code v2.1.227 or later. See [Review a diff locally](</docs/en/code-review#review-a-diff-locally>) for the effort levels, targeting, and how it relates to `/simplify`. Alias: `/review`
+`/code-review [low|medium|high|xhigh|max|ultra] [--fix] [--comment] [--max-findings n|all|default] [pr#|branch|path]`| **[Skill](</docs/en/skills#bundled-skills>).** Review the current diff, or a PR number, branch, or path you pass, for correctness bugs. Depending on your model and effort level, the review also covers cleanup opportunities. Pass `--fix` to apply findings, `--comment` to post them on the GitHub PR or GitLab merge request, or `ultra` to run a deep [cloud review](</docs/en/ultrareview>). Posting to a GitLab merge request requires Claude Code v2.1.257 or later. With `ultra` on a `github.com` PR target, pass `--post` to preselect [posting the finished findings to the PR](</docs/en/ultrareview#post-findings-to-the-pull-request>) in the launch dialog; `--post` requires Claude Code v2.1.227 or later. See [Review a diff locally](</docs/en/code-review#review-a-diff-locally>) for the effort levels, targeting, and how it relates to `/simplify`. Alias: `/review`
`/color [color|default]`| Set the prompt bar color for the current session. Available colors: `red`, `blue`, `green`, `yellow`, `purple`, `orange`, `pink`, `cyan`. Use `default` to reset, or run with no argument to pick a random color. When [Remote Control](</docs/en/remote-control>) is connected, the color syncs to claude.ai/code. Also available in non-interactive mode (`-p`); requires Claude Code v2.1.205 or later
`/compact [instructions]`| Free up context by summarizing the conversation so far. Optionally pass focus instructions for the summary. See [how compaction handles rules, skills, and memory files](</docs/en/context-window#what-survives-compaction>)
`/config [key=value ...]`| Open the [Settings](</docs/en/settings>) interface to adjust theme, model, [output style](</docs/en/output-styles>), and other preferences. Pass one or more `key=value` pairs to set a setting directly without opening the interface, for example `/config thinking=false`, `/config theme=dark`, or `/config model=sonnet`. The `key=value` form also works in non-interactive mode (`-p`) and from the Claude mobile app via [Remote Control](</docs/en/remote-control>). The `key=value` form can’t turn on a setting that needs your confirmation in the panel, such as [`autoContinueAtUsageLimit`](</docs/en/interactive-mode#turn-automatic-continue-off>), though it can turn one off. Run `/config --help` to list the keys it accepts. Alias: `/settings`
@@ -108,7 +108,7 @@
`/remote-env`| Choose the default [cloud environment](</docs/en/cloud-environments#select-an-environment-from-the-cli>) for cloud sessions you start from the CLI
`/rename [name]`| Rename the current session and show the name on the prompt bar. Without a name, auto-generates one from conversation history. Also available in non-interactive mode (`-p`); requires Claude Code v2.1.205 or later. From every rename surface, including claude.ai and the desktop app, Claude Code replaces control and invisible characters in the new name with spaces and caps the name at 200 characters. If the name is empty once invisible characters are removed, Claude Code rejects it and shows `That name is empty once invisible characters are removed. Usage: /rename <name>`. The character replacement and length cap require Claude Code v2.1.221 or later. If another live session on this machine already uses a name you pass, Claude Code applies [a variant of it](</docs/en/sessions#name-your-sessions>) instead
`/resume [session]`| Resume a conversation by ID or name, or open the session picker. [Background sessions](</docs/en/agent-view>) appear in the picker marked with `bg`. Resuming one that is still running, from the picker or by ID or name, [opens that session](</docs/en/sessions#resume-a-running-background-session>): your current conversation moves to the background and this terminal attaches to the running one. Press `←` on an empty prompt to return to agent view, which also lists the conversation you left. Before v2.1.285, Claude Code refused and told you to open the session with `claude attach` or stop it first. Alias: `/continue`
-`/review [low|medium|high|xhigh|max|ultra] [--fix] [--comment] [pr#|branch|path]`| Alias of [`/code-review`](</docs/en/code-review#review-a-diff-locally>): reviews the current diff, or a PR number, branch, or path you pass, such as `/review 1234`, and takes the same effort levels and flags. With no level given, the review reuses the last `low` through `max` level you typed; see [Review a diff locally](</docs/en/code-review#review-a-diff-locally>) for the exact rules. For a deep cloud review, use [`/code-review ultra`](</docs/en/ultrareview>). Before v2.1.223, `/review` was a separate command that ran a single-pass, read-only review of a GitHub pull request by number, listing open PRs to pick from when run with no argument; from v2.1.186 through v2.1.201, it ran the same multi-agent engine as `/code-review medium`
+`/review [low|medium|high|xhigh|max|ultra] [--fix] [--comment] [--max-findings n|all|default] [pr#|branch|path]`| Alias of [`/code-review`](</docs/en/code-review#review-a-diff-locally>): reviews the current diff, or a PR number, branch, or path you pass, such as `/review 1234`, and takes the same effort levels and flags. With no level given, the review reuses the last `low` through `max` level you typed; see [Review a diff locally](</docs/en/code-review#review-a-diff-locally>) for the exact rules. For a deep cloud review, use [`/code-review ultra`](</docs/en/ultrareview>). Before v2.1.223, `/review` was a separate command that ran a single-pass, read-only review of a GitHub pull request by number, listing open PRs to pick from when run with no argument; from v2.1.186 through v2.1.201, it ran the same multi-agent engine as `/code-review medium`
`/rewind`| Rewind the conversation and/or code to a previous point, or summarize from a selected message. See [checkpointing](</docs/en/checkpointing>). Aliases: `/checkpoint`, `/undo`
`/run`| **[Skill](</docs/en/skills#bundled-skills>).** Launch and drive your project’s app to see a change working, not only passing tests. See [Run and verify your app](</docs/en/skills#run-and-verify-your-app>)
`/run-skill-generator`| **[Skill](</docs/en/skills#bundled-skills>).** Teach `/run` and `/verify` how to build, launch, and drive your project’s app from a clean environment by writing a per-project [skill](</docs/en/skills#run-and-verify-your-app>)
--- a/communications-kit.md
+++ b/communications-kit.md
@@ -46,8 +46,7 @@
As of today you have access to Claude Code, an AI coding agent that runs in
your terminal, reads your actual codebase, and works through real tasks end
to end: debugging, refactors, tests, PRs. It is not autocomplete and it is
- not a chat window. It edits files, runs your commands, and asks permission
- before anything risky.
+ not a chat window. It edits files and runs your commands.
Get running in two minutes:
@@ -65,9 +64,8 @@
- "Look at my working diff and tell me what's risky before I push"
Where your code goes: Claude Code runs in your terminal and talks directly
- to Anthropic's API, with no third-party servers in the loop. It asks before
- editing files or running commands. On our Team or Enterprise plan, Anthropic
- does not use your code or prompts to train its models.
+ to Anthropic's API. On our Team or Enterprise plan, Anthropic does not use
+ your code or prompts to train its models.
Details: https://code.claude.com/docs/en/data-usage
https://code.claude.com/docs/en/security
@@ -82,14 +80,14 @@
🚀 *Claude Code is live for [team]*
AI coding agent, runs in your terminal, reads your repo, does real work:
- bugs, refactors, tests, PRs. Asks before it touches anything.
+ bugs, refactors, tests, PRs.
`curl -fsSL https://claude.ai/install.sh | bash` → `cd your-repo` → `claude`
*First thing to try* → run `/init`, then: "the test in [file] is flaky,
figure out why and fix it."
- 🔒 Runs in your terminal, talks only to Anthropic's API. On our Team or
+ 🔒 Runs in your terminal, talks directly to Anthropic's API. On our Team or
Enterprise plan, your code and prompts are not used to train models.
Data usage → https://code.claude.com/docs/en/data-usage
@@ -169,8 +167,8 @@
[Continue with "Get running in two minutes" from the standard announcement]
One extra thing for pilots: on your first multi-file change, press Shift+Tab
- until you see "plan". Claude will lay out exactly what it intends to do
- before it touches a file. It is the fastest way to calibrate how much to
+ until you see "plan". Claude will lay out what it intends to do
+ without editing your source. It is the fastest way to calibrate how much to
trust it.
###
@@ -312,12 +310,11 @@
`default` setting value) asks before file edits and most shell commands, *acceptEdits* lets file
edits and common filesystem commands
flow through while still checking before other shell commands, and *plan*
- proposes changes for your approval before anything is touched. Plan mode is
+ researches and proposes changes without editing your source. Plan mode is
the trust-builder, so start there for anything touching multiple files.
*Try it now:* on your next refactor, hit Shift+Tab until you see "plan",
- then describe the change. You'll get a full proposal before a single file
- moves.
+ then describe the change. You'll get a full proposal to review.
📖 Permission modes → https://code.claude.com/docs/en/permissions
@@ -472,10 +469,9 @@
Someone on your team is going to ask "wait, where does my code go?"
Here's the short version you can paste.
- Permission-first by design. Every file edit, shell command, and external
- call is gated by your approval. The CLI runs in your terminal and talks
- directly to Anthropic's API, with no third-party servers, and supports
- optional OS-level sandboxing for shell commands. On a Team or Enterprise plan,
+ A permission mode sets which actions Claude can take without asking you
+ first. The CLI runs in your terminal, talks directly to Anthropic's API,
+ and supports optional OS-level sandboxing for shell commands. On a Team or Enterprise plan,
Anthropic does not use your code or prompts to train its models.
*Try it now:* save these two links for the next time the question comes up.
@@ -520,8 +516,8 @@
---|---
”Does it work in VS Code?”| Yes. There is a VS Code extension and a JetBrains plugin with the same features, embedded in your editor. [VS Code →](</docs/en/vs-code>)
“Do I have to configure anything first?”| No. Install, then run `claude` in any repo. Run `/init` once and you’re set. [Quickstart →](</docs/en/quickstart>)
-“Where does my code go?”| The CLI runs in your terminal and sends context to Anthropic’s API for inference, with no third-party servers. On a Team or Enterprise plan, your code and prompts are not used to train models. [Data usage →](</docs/en/data-usage>)
-“Can it see my whole repo?”| It reads what you give it access to. File reads inside your working directory don’t prompt; permission prompts gate edits, non-read-only shell commands, and file-tool reads outside that directory. A built-in set of read-only shell commands such as `ls` and `cat` runs without prompting; restrict it with [sandbox `denyRead` rules](</docs/en/sandboxing#filesystem-isolation>). [Permissions →](</docs/en/permissions>)
+“Where does my code go?”| The CLI runs in your terminal and sends context to Anthropic’s API for inference. On a Team or Enterprise plan, your code and prompts are not used to train models. [Data usage →](</docs/en/data-usage>)
+“Can it see my whole repo?”| It reads what you give it access to. File reads inside your working directory don’t prompt. [Permissions →](</docs/en/permissions>)
“How is this different from Copilot?”| Copilot autocompletes lines. Claude Code is an agent that reads files, runs commands, and makes multi-file edits. [Overview →](</docs/en/overview>)
“What should I try first?”| A bug you’ve been putting off because it’s tedious. “The test in [file] is flaky, figure out why.” [Quickstart →](</docs/en/quickstart>)
--- a/create.md
+++ b/create.md
@@ -351,7 +351,14 @@
Share your mod
-A mod is a plugin, so you version it in the manifest and people install and update it with the `/plugin` commands. To give it to other people, [add it to a marketplace](</docs/en/plugins/publish>). Before you do, check the plugin’s `name`: `claude plugin validate` fails a name that [looks like one of Anthropic’s own](</docs/en/plugins/manifest-reference#name>), such as one that starts with `claude-`. The events and methods can change between releases, so your README is the place to say which Claude Code version you tested with. Keep developing against the directory with `--plugin-dir`, not against an installed copy. Claude Code caches an installed plugin by version, so your edits don’t reach the installed copy until you increment the version and install again.
+A mod is a plugin, so you version it in the manifest and people install and update it with the `/plugin` commands. How you share it depends on who it’s for:
+
+ * **A few people** : send them the plugin’s directory or a `.zip` of it. See [Share a plugin without a marketplace](</docs/en/plugins/publish#share-a-plugin-without-a-marketplace>)
+ * **Your team** : list it in [your own marketplace](</docs/en/plugins/publish#publish-through-your-own-marketplace>), such as a private repository with one directory for each plugin. To add that marketplace for everyone who works in a repository, [register it in the repository’s settings](</docs/en/plugins/host-marketplace#register-the-marketplace-for-everyone-in-a-repository>)
+ * **Your whole organization** : an administrator can [install your organization’s mods](</docs/en/plugins/mods/admin#install-your-organizations-mods>) through managed settings
+ * **Anyone** : make your marketplace’s repository public, or [submit the plugin to Anthropic’s directory](</docs/en/plugins/publish#submit-to-anthropics-directory>)
+
+Before you do, check the plugin’s `name`: `claude plugin validate` fails a name that [looks like one of Anthropic’s own](</docs/en/plugins/manifest-reference#name>), such as one that starts with `claude-`. The events and methods can change between releases, so your README is the place to say which Claude Code version you tested with. Keep developing against the directory with `--plugin-dir`, not against an installed copy. Claude Code caches an installed plugin by version, so your edits don’t reach the installed copy until you increment the version and install again.
##
--- a/cross-session-messaging.md
+++ b/cross-session-messaging.md
@@ -196,7 +196,7 @@
* **The receiving session prompts for permissions** : Claude Code delivers each message. It holds one for your approval only when the sending session identifies itself as bypassing permission prompts.
* **The receiving session bypasses permission prompts** : Claude Code holds each message for your approval. It delivers one only when the sending session identifies itself as also bypassing.
-When the default holds a message, Claude Code opens an approval dialog in the receiving session. The dialog shows the sender and a preview:
+When the default holds a message in an interactive terminal session, Claude Code opens an approval dialog there. The dialog shows the sender and a preview:
* **Approve** delivers that one message to Claude.
* **Deny** , or dismissing the dialog, drops it.
@@ -204,7 +204,7 @@
* While no terminal is attached to a [background session](</docs/en/agent-view>), Claude Code leaves the dialog open past the deadline. After you attach, if the dialog stays unanswered for a full deadline period, Claude Code closes it and drops the message.
* If this session’s permission-mode class changes while messages are held, Claude Code re-applies the inbound rules, delivers the messages they now accept, and shows a notice.
-Claude Code holds at most 100 messages, and past that drops the oldest.
+A session in the VS Code extension or the Desktop app can’t show the dialog. Claude Code keeps a held message there until the same deadline, as Non-interactive sessions describes. Claude Code holds at most 100 messages, and past that drops the oldest.
###
--- a/debug-your-config.md
+++ b/debug-your-config.md
@@ -19,7 +19,7 @@
`/debug [issue]`| Enables debug logging for the session and prompts Claude to diagnose using the log output and settings paths
`/status`| Active settings sources, including whether managed settings are in effect
-If a memory file is missing from the `/context` breakdown, check its location against [how CLAUDE.md files load](</docs/en/memory#how-claude-md-files-load>). Subdirectory `CLAUDE.md` files load on demand when Claude reads a file in that directory with the Read tool, not at session start. If `/context` confirms the file loaded but Claude still isn’t following a particular instruction, the issue is likely how the instruction is written rather than whether it loaded. CLAUDE.md works well for the kinds of guidance you’d give a new teammate, such as project conventions, build commands, and where files belong. Adherence drops when an instruction is vague enough to interpret multiple ways, when two files give conflicting direction, or when the file has grown long enough that individual rules get less attention. [Write effective instructions](</docs/en/memory#write-effective-instructions>) covers the specificity, size, and structure patterns that keep adherence high.
+If a memory file is missing from the `/context` breakdown, check its location against [how CLAUDE.md files load](</docs/en/memory#how-claude-md-files-load>). Subdirectory `CLAUDE.md` files load on demand after Claude uses the Read, Write, or Edit tool on a file in that directory, not at session start. If `/context` confirms the file loaded but Claude still isn’t following a particular instruction, the issue is likely how the instruction is written rather than whether it loaded. CLAUDE.md works well for the kinds of guidance you’d give a new teammate, such as project conventions, build commands, and where files belong. Adherence drops when an instruction is vague enough to interpret multiple ways, when two files give conflicting direction, or when the file has grown long enough that individual rules get less attention. [Write effective instructions](</docs/en/memory#write-effective-instructions>) covers the specificity, size, and structure patterns that keep adherence high.
CLAUDE.md and permissions solve different problems. CLAUDE.md tells Claude how your project works so it makes good decisions. [Permissions](</docs/en/permissions>) and [hooks](</docs/en/hooks>) enforce limits regardless of what Claude decides. Use CLAUDE.md for “we do it this way here.” Use permissions or hooks for security boundaries and anything that must never happen, where you need a guarantee instead of guidance.
@@ -98,7 +98,7 @@
A `settings.json` value seems ignored| The same key is set in `settings.local.json`| `settings.local.json` overrides `settings.json`, and both override `~/.claude/settings.json`. See [settings precedence](</docs/en/settings#settings-precedence>).
Skill doesn’t appear in `/skills`| Skill file is at `.claude/skills/name.md` instead of in a folder| Use a folder with `SKILL.md` inside: `.claude/skills/name/SKILL.md`.
Skill appears in `/skills` but Claude never invokes it| Skill has `disable-model-invocation: true` in its frontmatter, or its description doesn’t match how you phrase the request| Check the badge in `/skills`: a “user-only” label means Claude won’t trigger it on its own. See [skill invocation](</docs/en/skills>).
-Subdirectory `CLAUDE.md` instructions seem ignored| Subdirectory files load on demand, not at session start| They load when Claude reads a file in that directory with the Read tool, not at launch and not when writing or creating files there. See [how CLAUDE.md files load](</docs/en/memory#how-claude-md-files-load>).
+Subdirectory `CLAUDE.md` instructions seem ignored| Subdirectory files load on demand, not at session start| They load after Claude uses the Read, Write, or Edit tool on a file in that directory, not at launch. Before v2.1.288, only the Read tool loaded them. See [how CLAUDE.md files load](</docs/en/memory#how-claude-md-files-load>).
Subagent ignores `CLAUDE.md` instructions| The built-in Explore and Plan agents skip `CLAUDE.md`. A custom subagent loads it the same way the main conversation does, unless its definition sets [`omitClaudeMd`](</docs/en/sub-agents#supported-frontmatter-fields>)| For Explore or Plan, restate the instruction in your delegating prompt. For a subagent that sets `omitClaudeMd`, remove the field. For any other custom subagent, put critical instructions in the agent file body, which becomes the agent’s system prompt. See [what loads at startup](</docs/en/sub-agents#what-loads-at-startup>).
Cleanup logic never runs at session end| No `SessionEnd` hook configured| Add a `SessionEnd` hook in `settings.json`. See the [hook events list](</docs/en/hooks#hook-events>).
MCP servers in `.mcp.json` never load| File is under `.claude/`, or its servers sit under a top-level `servers` key, as in VS Code’s `mcp.json`, instead of `mcpServers`| Project MCP config goes at the repository root as `.mcp.json`, not inside `.claude/`, with servers under the `mcpServers` key. See [MCP configuration](</docs/en/mcp>).
--- a/env-vars.md
+++ b/env-vars.md
@@ -162,9 +162,9 @@
`API_FORCE_IDLE_TIMEOUT`| Override the 5-minute body idle timeout that aborts a streaming model response when no bytes arrive. Set to `0` to turn the timeout off, for example when a slow [gateway](</docs/en/llm-gateway>) or local model pauses longer than 5 minutes between chunks, or `1` to keep it on for every provider. When unset, the timeout is active on providers other than the direct Anthropic API, [Claude Platform on AWS](</docs/en/claude-platform-on-aws>), and Amazon Bedrock with `CLAUDE_ENABLE_BYTE_WATCHDOG_BEDROCK=1` set. The [stream watchdogs](</docs/en/network-config#streaming-idle-watchdogs>) run independently of it and abort a long silent pause even when you set `0` here
`API_TIMEOUT_MS`| Timeout for API requests in milliseconds (default: 600000, or 10 minutes; maximum: 2147483647). Increase this when requests time out on slow networks or when routing through a proxy. Values above the maximum overflow the underlying timer and cause requests to fail immediately
`AWS_BEARER_TOKEN_BEDROCK`| Amazon Bedrock API key for authentication (see [Amazon Bedrock API keys](<https://aws.amazon.com/blogs/machine-learning/accelerate-ai-development-with-amazon-bedrock-api-keys/>))
-`BASH_DEFAULT_TIMEOUT_MS`| Default timeout for a foreground Bash or PowerShell tool command, in milliseconds (default: 120000, or 2 minutes). A default longer than 30 minutes also becomes the default [time limit for background commands](</docs/en/tools-reference#time-limit-for-background-commands>). The background time limit requires Claude Code v2.1.285 or later
+`BASH_DEFAULT_TIMEOUT_MS`| Default timeout for a foreground Bash or PowerShell tool command, in milliseconds (default: 120000, or 2 minutes). A default longer than 30 minutes also becomes the default [time limit for background commands](</docs/en/tools-reference#time-limit-for-background-commands>) in unattended sessions. The background time limit requires Claude Code v2.1.285 or later
`BASH_MAX_OUTPUT_LENGTH`| Maximum number of characters of bash output that Claude Code reads back into a command’s result (default: 30000; maximum: 150000). If you set the [`bashOutputMaxChars`](</docs/en/settings-reference#bashoutputmaxchars>) setting, Claude Code ignores this variable. See [Output limits](</docs/en/tools-reference#output-limits>)
-`BASH_MAX_TIMEOUT_MS`| Maximum timeout the model can set for a foreground Bash or PowerShell tool command, in milliseconds (default: 600000, or 10 minutes). The effective ceiling is the larger of this and `BASH_DEFAULT_TIMEOUT_MS`. An effective ceiling longer than 2 hours also becomes the maximum [time limit for background commands](</docs/en/tools-reference#time-limit-for-background-commands>). The background time limit requires Claude Code v2.1.285 or later
+`BASH_MAX_TIMEOUT_MS`| Maximum timeout the model can set for a foreground Bash or PowerShell tool command, in milliseconds (default: 600000, or 10 minutes). The effective ceiling is the larger of this and `BASH_DEFAULT_TIMEOUT_MS`. An effective ceiling longer than 2 hours also becomes the maximum [time limit for background commands](</docs/en/tools-reference#time-limit-for-background-commands>) in unattended sessions. The background time limit requires Claude Code v2.1.285 or later
`BETA_TRACING_ENDPOINT`| OTLP endpoint for [detailed beta tracing](</docs/en/monitoring-usage#traces-beta>): with `ENABLE_BETA_TRACING_DETAILED=1`, logs and traces go there instead of to the configured exporters. Set it in your shell, user settings, or managed settings. Ignored in [project and local settings](</docs/en/settings-reference#variables-claude-code-ignores-in-env>)
`CCR_FORCE_BUNDLE`| Set to `1` to force [`claude --cloud`](</docs/en/claude-code-on-the-web#send-local-repositories-without-github>) to bundle and upload your local repository instead of cloning from its remote
`CLAUDECODE`| Set to `1` in subprocesses Claude Code spawns (Bash and PowerShell tools, tmux sessions, [hook](</docs/en/hooks>) commands, [status line](</docs/en/statusline>) commands, stdio [MCP server](</docs/en/mcp>) subprocesses). IDE extensions also set this in their integrated terminals. Use to detect when a script is running inside a subprocess spawned by Claude Code. To check whether the current process was spawned directly by a tool call or hook, rather than inside a stdio MCP server that Claude Code started, use `CLAUDE_CODE_CHILD_SESSION` instead
@@ -245,6 +245,7 @@
`CLAUDE_CODE_DISABLE_PERMISSION_PROMPT_NOTIFY_HOOKS`| Set to `1` to stop Claude Code from running your [`Notification` hooks for unanswered permission requests](</docs/en/hooks#notification>) in sessions where Claude Code sends them to the Agent SDK’s `canUseTool` callback, which is how Claude Desktop and the VS Code extension host Claude Code. Has no effect in terminal sessions. Requires Claude Code v2.1.233 or later
`CLAUDE_CODE_DISABLE_POLICY_SKILLS`| Set to `1` to skip loading skills from the system-wide managed skills directory. Useful for container or CI sessions that should not load operator-provisioned skills
`CLAUDE_CODE_DISABLE_POWERSHELL_CMD_RM_DENY`| Set to `1` to turn off the [PowerShell tool](</docs/en/tools-reference#powershell-tool>) check that denies the `cmd` built-ins `rd`, `rmdir`, `del`, and `erase` on a [system path](</docs/en/permission-modes#remove-item-in-powershell>), such as a drive root or your home directory. Claude Code ignores this variable in a settings file’s `env` block. Requires Claude Code v2.1.283 or later
+`CLAUDE_CODE_DISABLE_STRUCTURED_OUTPUTS`| Set to `1` to stop Claude Code from sending the structured-output `output_config.format` field and the `anthropic-beta` value that pairs with it, for an [LLM gateway](</docs/en/llm-gateway-protocol#feature-pass-through>) whose upstream rejects them. This leaves on the other pre-release capabilities that [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS`](</docs/en/llm-gateway-protocol#disable-pre-release-capabilities>) turns off. Requires Claude Code v2.1.288 or later
`CLAUDE_CODE_DISABLE_SUBSTITUTION_RM_PROMPT`| Set to `1` to turn off the [critical-path](</docs/en/permission-modes#critical-paths>) check for a recursive `rm` whose target is entirely the output of a command substitution, such as `rm -rf "$(pwd)"`. The other critical-path checks keep running. Set it in the environment that launches Claude Code, since Claude Code ignores a copy delivered through a settings `env` block. Requires Claude Code v2.1.281 or later
`CLAUDE_CODE_DISABLE_TERMINAL_TITLE`| Set to `1` to disable automatic terminal title updates based on conversation context. This also skips the background small/fast-model request that [generates a session title](</docs/en/sessions#name-your-sessions>)
`CLAUDE_CODE_DISABLE_THINKING`| Set to `1` to omit the `thinking` parameter from API requests entirely. This is a compatibility option for proxies and gateways that reject the parameter. On models that think by default, omitting the parameter means the model may still think. To explicitly disable [extended thinking](<https://platform.claude.com/docs/en/build-with-claude/extended-thinking>) on the Anthropic API, use `MAX_THINKING_TOKENS=0` instead. Neither variable turns thinking off on Opus 5.5, Sonnet 5.5, or the Fable models, which can’t have thinking turned off. On [third-party providers](</docs/en/third-party-integrations>), `MAX_THINKING_TOKENS=0` likewise omits the parameter, so the two variables behave the same there
@@ -304,6 +305,7 @@
`CLAUDE_CODE_NATIVE_CURSOR`| Set to `1` to show the terminal’s own cursor at the input caret instead of a drawn block. The cursor respects the terminal’s blink, shape, and focus settings
`CLAUDE_CODE_NEW_INIT`| Set to `1` to make `/init` run an interactive setup flow. The flow asks which files to generate, including CLAUDE.md, skills, and hooks, before exploring the codebase and writing them. Without this variable, `/init` generates a CLAUDE.md automatically without prompting
`CLAUDE_CODE_NONBLOCKING_STDOUT`| Set to `1` to write terminal output through a second non-blocking file descriptor, so a terminal that stops reading, such as a paused tmux control-mode pane or a stalled SSH connection, can’t freeze Claude Code mid-session. Applies on macOS, Linux, and WSL when stdout is a terminal. Requires Claude Code v2.1.261 or later
+`CLAUDE_CODE_NONSTREAMING_TIMEOUT_RETRIES`| Limit how many times Claude Code re-sends a [non-streaming request](</docs/en/errors#streaming-response-ended-before-any-complete-data-was-received>) that times out. With `0`, the request fails on the first timeout. Unset by default, so `CLAUDE_CODE_MAX_RETRIES` limits these re-sends. See [Tune retry behavior](</docs/en/errors#tune-retry-behavior>) for the timeout. Requires Claude Code v2.1.285 or later
`CLAUDE_CODE_NO_FLICKER`| Set to `1` to enable [fullscreen rendering](</docs/en/fullscreen>), a research preview that reduces flicker and keeps memory flat in long conversations. Overrides the [`tui`](</docs/en/settings-reference#tui>) setting; you can also switch with `/tui fullscreen`
`CLAUDE_CODE_OAUTH_REFRESH_TOKEN`| OAuth refresh token for Claude.ai authentication. When set, `claude auth login` exchanges this token directly instead of opening a browser. Requires `CLAUDE_CODE_OAUTH_SCOPES`. Useful for provisioning authentication in automated environments
`CLAUDE_CODE_OAUTH_SCOPES`| Space-separated OAuth scopes the refresh token was issued with, such as `"user:profile user:inference user:sessions:claude_code"`. Required when `CLAUDE_CODE_OAUTH_REFRESH_TOKEN` is set
@@ -447,7 +449,7 @@
`MCP_DISCOVERY_CACHE_STRIKES`| At a start where a [discovery-cache](</docs/en/mcp#server-status-detail>) entry is older than `MCP_DISCOVERY_CACHE_TTL_S`, Claude Code refreshes it in the background. This variable sets how many refreshes in a row can fail before Claude Code discards the entry and connects the server at the next start instead (default: 1). Raise it if your network connection drops occasionally, so that one failed refresh doesn’t discard the entry. Requires Claude Code v2.1.238 or later
`MCP_DISCOVERY_CACHE_TTL_S`| Seconds for which Claude Code uses a [discovery-cache](</docs/en/mcp#server-status-detail>) entry without refreshing it (default: 900). At a start where the entry is older than that, Claude Code still uses it but refreshes it in the background. Once the entry is older than `MCP_DISCOVERY_CACHE_MAX_STALE_S`, Claude Code discards it instead. Claude Code caps the value at `MCP_DISCOVERY_CACHE_MAX_STALE_S`, which is 4 hours by default. Before v2.1.238, Claude Code didn’t cap the value
`MCP_OAUTH_CALLBACK_PORT`| Fixed port for the OAuth redirect callback, as an alternative to `--callback-port` when adding an MCP server with [pre-configured credentials](</docs/en/mcp#use-pre-configured-oauth-credentials>)
-`MCP_PROTOCOL_NEGOTIATION`| On the [v2 MCP client runtime](</docs/en/mcp#mcp-client-runtimes>) only, whether Claude Code probes servers for MCP protocol revision 2026-07-28. Set `auto` to probe HTTP, claude.ai connector, and stdio servers; a server that doesn’t answer the probe connects on the earlier protocol instead, as SSE and WebSocket servers always do. Set `legacy` to skip the probe for every server. Without the variable, Claude Code probes HTTP servers, and also probes claude.ai connector servers in sessions where it fetches feature flags. Any other value is ignored with a warning in the debug log. Requires Claude Code v2.1.221 or later
+`MCP_PROTOCOL_NEGOTIATION`| On the [v2 MCP client runtime](</docs/en/mcp#mcp-client-runtimes>) only, whether Claude Code probes servers for MCP protocol revision 2026-07-28. Set `auto` to probe HTTP, claude.ai connector, and stdio servers, or `legacy` to probe none. With the variable unset, Claude Code probes the servers described under [MCP client runtimes](</docs/en/mcp#mcp-client-runtimes>). Any other value is ignored with a warning in the debug log. Requires Claude Code v2.1.221 or later
`MCP_REMOTE_SERVER_CONNECTION_BATCH_SIZE`| Maximum number of remote MCP servers (HTTP/SSE) to connect in parallel during startup (default: 20)
`MCP_SDK_GENERATION`| Pin which [MCP client runtime](</docs/en/mcp#mcp-client-runtimes>) this process connects to MCP servers with: `v1`, built on MCP TypeScript SDK 1.x, or `v2`, built on [MCP TypeScript SDK 2.0](<https://ts.sdk.modelcontextprotocol.io/v2/>). Without the variable, Claude Code uses v2, starting with the versions listed in that section. On Claude Code v2.1.221 or later, the v2 runtime checks the issuer an MCP OAuth server returns in its authorization response and fails the sign-in with an error that begins `Issuer mismatch in authorization response` when it doesn’t match. The v1 runtime doesn’t run this check. If you set an unrecognized value, Claude Code ignores it and writes a warning to the debug log. Claude Code reads the value once per process. Requires Claude Code v2.1.218 or later
`MCP_SERVER_CONNECTION_BATCH_SIZE`| Maximum number of local MCP servers (stdio) to connect in parallel during startup (default: 3)
@@ -515,7 +517,7 @@
* Use [the advisor tool](</docs/en/advisor#requirements>)
* Read or reply to [comments on an artifact](</docs/en/artifacts#collect-comments-on-an-artifact>)
* Have Claude read [another organization’s public artifact](</docs/en/artifacts#read-an-artifact-shared-with-you>)
- * Have Claude Code probe claude.ai connector servers for [MCP protocol revision 2026-07-28](</docs/en/mcp#mcp-client-runtimes>) unless you set `MCP_PROTOCOL_NEGOTIATION=auto`
+ * Have Claude Code probe claude.ai connector servers or stdio servers for [MCP protocol revision 2026-07-28](</docs/en/mcp#mcp-client-runtimes>) unless you set `MCP_PROTOCOL_NEGOTIATION=auto`
* Get the [PowerShell tool](</docs/en/tools-reference#powershell-tool>) by default for claude.ai and Console accounts on Windows with Git Bash installed; Claude Code routes shell commands through Git Bash unless you set `CLAUDE_CODE_USE_POWERSHELL_TOOL=1`. On Windows without Git Bash, the tool stays on
* Get [Claude-drafted feedback](</docs/en/tools-reference#sendfeedback-tool-behavior>), which Claude Code turns on through a fetched flag
* Have Claude [treat large pastes as pasted rather than typed text](</docs/en/terminal-config#how-claude-treats-pasted-text>); the content behind a `[Pasted text #N]` placeholder reaches Claude unmarked
--- a/errors.md
+++ b/errors.md
@@ -177,6 +177,7 @@
`<model>'s safeguards flagged this message`| Request errors
`<model>'s safeguards flagged this session`| Request errors
`<model> has safety measures that flagged this message for a cybersecurity topic`| Request errors
+`API Error: Output blocked by content filtering policy`| Request errors
`Installation was killed before it could finish (exit code 137)`| Installation errors
`The connection dropped while downloading the update`| Installation errors
`Download timed out: exceeded the total deadline`| Installation errors
@@ -390,6 +391,7 @@
* An Amazon Bedrock streaming response with an unexpected content-type, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
* A non-streaming retry of a failed streaming request that gets a success status but no Claude API message in the body. Claude Code ends the turn with that error.
* A request that your organization’s policy check denied, which surfaces as an `API Error:` line carrying the denial message. Your organization’s administrators set up the check with [Inference hooks](<https://platform.claude.com/docs/en/manage-claude/inference-hooks>), a Claude Enterprise feature, and the message ends with the instructions they configured, or by default tells you to contact them. Claude Code doesn’t re-send the denied request to the same model or to a [fallback model](</docs/en/model-config#fallback-model-chains>), because the denial is about the request’s content rather than the model. Before v2.1.239, Claude Code could re-send a denied request, without streaming or on a configured fallback model, before showing you the denial.
+ * A response the API’s output content filter blocked. Claude Code shows Output blocked by content filtering policy at once and doesn’t retry or re-send that request.
###
@@ -418,6 +420,7 @@
[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186; as of v2.1.199 `CLAUDE_CODE_RETRY_WATCHDOG` raises the default and removes the cap. Lower it to surface failures faster in scripts.
[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once when a standard-speed request gets a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. For fast mode requests, see [Handle rate limits](</docs/en/fast-mode#handle-rate-limits>). On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies. It also caps how long Claude Code waits for response headers, described in No response from API.
+[`CLAUDE_CODE_NONSTREAMING_TIMEOUT_RETRIES`](</docs/en/env-vars>)| unset| Limit on re-sends of a non-streaming request that times out. At the limit, the request fails. A response from Claude that takes longer than the timeout to generate times out again on every re-send, so set a low number such as `0` to fail sooner. Each non-streaming attempt times out after 300 seconds in a local session, or after `API_TIMEOUT_MS` when you set a positive value. Requires Claude Code v2.1.285 or later.
[`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>)| unset| Deadline in milliseconds for the first response byte of a streaming request. Requires Claude Code v2.1.242 or later. For how Claude Code picks the deadline when this is unset, see No response from API.
##
@@ -1749,7 +1752,7 @@
You may also see a TLS certificate that doesn’t match the destination’s real certificate. Cloud sessions route outbound traffic through a proxy that enforces the network policy, so a mismatched certificate means the proxy terminated the connection, not the destination. This is not a client-side network problem. Cloud sessions and [routines](</docs/en/routines>) run inside a sandboxed VM whose outbound traffic through the session’s network is filtered to the [cloud environment’s](</docs/en/cloud-environments>) allowlist; [GitHub operations](</docs/en/cloud-environments#github-proxy>) and MCP connector traffic use separate channels, which is why they can keep working while other hosts are blocked. The **Default** environment uses **Trusted** access, which permits the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains and blocks other domains on that path. **What to do:** These steps change one of your own environments. An [organization-shared environment](</docs/en/cloud-environments#organization-shared-environments>) opens read-only in the selector, so ask an Owner to change its network access from the **Cloud environments** page in [admin settings](<https://claude.ai/admin-settings>).
* Open your environment for editing, either from the [routine’s form](</docs/en/routines#environments-and-network-access>) or from the [environment selector](</docs/en/cloud-environments#configure-your-environment>) where you start cloud sessions.
- * In the **Edit cloud environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
+ * In the **Edit environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
* Click **Save changes**. The next run uses the updated allowlist. For a cloud session that’s already open, see [when a network access change reaches existing sessions](</docs/en/cloud-environments#network-access>).
See [Network access](</docs/en/cloud-environments#network-access>) for access levels and the default allowlist. Local CLI sessions are not affected by this policy.
@@ -2200,6 +2203,7 @@
The binary the [VS Code extension](</docs/en/vs-code>) bundles| Update the extension
The binary an Agent SDK package bundles| [Upgrade the SDK package](</docs/en/agent-sdk/hosting#runtime-dependencies>), then restart your application. In a [compiled single-file executable](</docs/en/agent-sdk/typescript#compile-to-a-single-executable>), rebuild it
+ * If you run `claude update` on the [stable release channel](</docs/en/setup#configure-release-channel>), it doesn’t move you past the newest stable release, which can still be below the required minimum. Move to the latest channel, then update again. If your organization pins your channel or version through [managed settings](</docs/en/managed-settings>), ask your admin to change it
* For the per-model wording, you can keep working in the current session by switching to another model: run `/model` in the CLI, call [`setModel()`](</docs/en/agent-sdk/typescript#query-object>) on the TypeScript SDK’s `Query` object in streaming input mode, or call [`set_model()`](</docs/en/agent-sdk/python#claudesdkclient>) on the Python SDK’s `ClaudeSDKClient`
* For the organization-policy wording, update before you continue
@@ -2316,6 +2320,7 @@
**What to do:**
* Run `claude update` and restart Claude Code. Opus 4.7 needs v2.1.111 or later. Opus 4.8 needs v2.1.154 or later. Sonnet 5 needs v2.1.197 or later. Opus 5 needs v2.1.219 or later. Opus 5.5 needs v2.1.280 or later. Sonnet 5.5 needs v2.1.284 or later
+ * On the [stable release channel](</docs/en/setup#configure-release-channel>), updating doesn’t move you past the newest stable release, which can still be older than these versions. Move to the latest channel, then update
* If you can’t upgrade, run `/model` and select Opus 4.6 or Sonnet 4.6 instead
* If you hit this in the [Agent SDK](</docs/en/agent-sdk/overview>), upgrade the SDK package instead. Opus 4.8 needs TypeScript SDK v0.3.154 or later and Python SDK v0.2.88 or later. Sonnet 5 needs TypeScript SDK v0.3.197 or later. Opus 5 needs TypeScript SDK v0.3.219 or later. Opus 5.5 needs TypeScript SDK v0.3.280 or later. Sonnet 5.5 needs TypeScript SDK v0.3.284 or later
@@ -2470,6 +2475,21 @@
* If your request wasn’t about a cybersecurity topic, run `/feedback` to report the false positive
* To keep working in the same session, press Esc twice or run `/rewind` to step back to a checkpoint before the turn that triggered the flag, then take a different approach. See [Checkpointing](</docs/en/checkpointing>).
+###
+
+
+
+Output blocked by content filtering policy
+
+The API’s output content filter stopped the response Claude was generating. The message text comes from the API:
+
+ API Error: Output blocked by content filtering policy
+
+Claude Code shows the error as soon as the block arrives and ends the request there. It doesn’t retry the request, re-send it without streaming, or switch to a [fallback model](</docs/en/model-config#fallback-model-chains>). Before v2.1.285, Claude Code could re-send and retry a blocked request, sometimes for minutes, before showing you the error. **What to do:**
+
+ * Rephrase your last message or take a different approach
+ * To step back to a checkpoint before the turn that triggered the block, press Esc twice or run `/rewind`. See [Checkpointing](</docs/en/checkpointing>)
+
##
@@ -3849,7 +3869,7 @@
Teammate’s agent definition was not restored
-Claude messaged a stopped [agent team](</docs/en/agent-teams>) teammate, and Claude Code brought it back without re-applying the [subagent definition](</docs/en/agent-teams#use-subagent-definitions-for-teammates>) it was spawned from, because its definition file came from a folder with no saved trust. The notice follows the resume report in the sending agent’s tool result:
+Claude messaged a stopped [agent team](</docs/en/agent-teams>) teammate, and Claude Code brought it back without re-applying the [subagent definition](</docs/en/agent-teams#use-subagent-definitions-for-teammates>) it was spawned from. The notice follows the resume report in the sending agent’s tool result and names the reason. When the definition file came from a folder with no saved trust, it reads:
Its agent definition was not restored: the folder its definition file came from is not trusted (source: projectSettings), so the teammate is running with the team-essential tools and no custom instructions. To restore it, the user needs to run Claude Code in that folder once and accept the trust dialog (the --debug log names the folder); do not change trust settings on the user's behalf.
@@ -3898,7 +3918,7 @@
Cross-session message was dropped at the recipient session’s inbox
-Claude sent a [cross-session message](</docs/en/cross-session-messaging>) to another of your sessions on this machine, and that session’s inbox discarded it before Claude in that session read it. The line names the recipient’s address and, when the recipient gave a reason, adds the reason after a dash:
+Claude sent a [cross-session message](</docs/en/cross-session-messaging>) to another of your sessions on this machine, and that session’s inbox discarded it before Claude in that session read it. The line names the recipient and, when the recipient gave a reason, adds the reason after a dash:
Cross-session message was dropped at the recipient session's inbox (recipient: uds:/tmp/cc-socks/13605.sock) and not delivered — its queue of undelivered peer messages was full. Claude was told not to resend right away.
--- a/glossary.md
+++ b/glossary.md
@@ -380,7 +380,7 @@
Rules
-Modular instruction files in `.claude/rules/` that load alongside CLAUDE.md. A rule can be path-scoped with YAML `paths:` frontmatter so it only loads when Claude reads a matching file, keeping context lean until it’s relevant. Learn more: [Organize rules with `.claude/rules/`](</docs/en/memory#organize-rules-with-claude/rules/>)
+Modular instruction files in `.claude/rules/` that load alongside CLAUDE.md. A rule can be path-scoped with YAML `paths:` frontmatter so it only loads when Claude reads, writes, or edits a matching file, keeping context lean until it’s relevant. Learn more: [Organize rules with `.claude/rules/`](</docs/en/memory#organize-rules-with-claude/rules/>)
##
--- a/hooks.md
+++ b/hooks.md
@@ -153,7 +153,7 @@
`PostToolUse`| Yes| Yes| Tool execution result| Log all file changes to audit trail
`PostToolUseFailure`| Yes| Yes| Tool execution failure| Handle or log tool errors
`PostToolBatch`| No| Yes| A full batch of tool calls resolves, once per batch before the next model call| Inject conventions once for the whole batch
-`UserPromptSubmit`| Yes| Yes| User prompt submission| Inject additional context into prompts
+[`UserPromptSubmit`](</docs/en/hooks#userpromptsubmit>)| Yes| Yes| A prompt is submitted, including a turn Claude Code starts on its own| Inject additional context into prompts
[`UserPromptExpansion`](</docs/en/hooks#userpromptexpansion>)| No| Yes| A user-typed command, or an MCP prompt, expands into a prompt before it reaches Claude. Doesn’t fire when Claude invokes a skill itself| Block a command from direct invocation or add context when a skill is typed
`MessageDisplay`| No| Yes| An assistant message with text completes, once per message with the full message text| Redact or reformat the displayed text without changing the transcript
`Stop`| Yes| Yes| Agent execution stop| Save session state before exit
--- a/hooks-guide.md
+++ b/hooks-guide.md
@@ -433,7 +433,7 @@
---|---
`SessionStart`| When a session begins or resumes
`Setup`| When you start Claude Code with `--init-only`, or with `--init` or `--maintenance` in `-p` mode. For one-time preparation in CI or scripts
-`UserPromptSubmit`| When you submit a prompt, before Claude processes it
+`UserPromptSubmit`| When a prompt is submitted, before Claude processes it. Also fires on [turns Claude Code starts on its own](</docs/en/hooks#userpromptsubmit>)
`UserPromptExpansion`| When a user-typed command expands into a prompt, before it reaches Claude. Can block the expansion
`PreToolUse`| Before a tool call executes. Can block it
`PermissionRequest`| When a tool call needs a permission decision
@@ -882,9 +882,7 @@
* `agent`: 60 seconds.
* [`SessionEnd`](</docs/en/hooks#sessionend>) hooks of any type share a 1.5-second budget. If your settings set a longer per-hook `timeout`, Claude Code raises the budget to match, up to 60 seconds.
* `PostToolUse` hooks can’t undo actions since the tool has already executed.
- * `PermissionRequest` hooks fire when Claude Code is about to ask you for permission.
- * In [non-interactive mode](</docs/en/headless>) with the `-p` flag, that prompt only exists when the Agent SDK’s [`canUseTool` callback](</docs/en/agent-sdk/permissions>) supplies it. In plain `-p` runs or with `--permission-prompt-tool`, use `PreToolUse` hooks for automated permission decisions instead.
- * Background subagents can’t show a prompt in non-interactive mode. Claude Code still runs the hooks for their tool calls, and if no hook returns a decision, it denies the call. In an interactive session, background subagent prompts surface in your main session and the hooks fire as usual.
+ * [`PermissionRequest`](</docs/en/hooks#permissionrequest>) hooks fire when Claude Code is about to ask you for permission, or when it would otherwise auto-deny a call that can’t prompt. In [non-interactive mode](</docs/en/headless>) with the `-p` flag, they still run outside [`dontAsk` mode](</docs/en/permission-modes#allow-only-pre-approved-tools-with-dontask-mode>), and a call that no hook decides and nothing else can answer is denied.
* `Stop` hooks fire whenever Claude finishes responding, not only at task completion. They don’t fire on user interrupts. API errors fire [StopFailure](</docs/en/hooks#stopfailure>) instead.
* When multiple `PreToolUse` hooks return [`updatedInput`](</docs/en/hooks#pretooluse>) to rewrite a tool’s arguments, the last one to finish takes effect. Since hooks run in parallel, the order is non-deterministic. Avoid having more than one hook modify the same tool’s input.
--- a/interactive-mode.md
+++ b/interactive-mode.md
@@ -358,7 +358,7 @@
* On macOS and Linux, Claude Code stops your running background tasks when the operating system reports critical memory pressure, provided the session has been idle for at least 30 minutes and no turn or subagent is running. Requires Claude Code v2.1.193 or later
* The [debug log](</docs/en/debug-your-config>) says why tasks were stopped, or why a pressure event left them running
* Set [`CLAUDE_CODE_DISABLE_BG_SHELL_PRESSURE_REAP`](</docs/en/env-vars>) to `1` to turn off memory-pressure stops
- * Background Bash and PowerShell commands have a time limit, counted from the moment the command enters the background: 30 minutes, or the `timeout` Claude asks for when it starts a command in the background, up to a maximum of 2 hours. A command that moves to the background while it runs, for example with `Ctrl+B`, gets 30 minutes from the move. When a command reaches its limit, Claude Code stops it and tells Claude why, and Claude can start it again with a longer `timeout` if the work still needs it. To lengthen the limits, see [Raise the time limit for background commands](</docs/en/tools-reference#raise-the-time-limit-for-background-commands>) in the tools reference
+ * Background commands in a local session you work in from a terminal, the desktop app, or the VS Code extension have no time limit. In a session that runs unattended, such as a `-p` run or a cloud session, Claude Code stops a background command at its [time limit](</docs/en/tools-reference#time-limit-for-background-commands>)
* A background command that a foreground [subagent](</docs/en/sub-agents#run-subagents-in-foreground-or-background>) started ends when that subagent’s run ends, whether it finished, failed, or was interrupted; see [When a background command stops](</docs/en/tools-reference#when-a-background-command-stops>) in the tools reference
To disable all background task functionality, set the [`CLAUDE_CODE_DISABLE_BACKGROUND_TASKS`](</docs/en/env-vars#variables>) environment variable to `1`. Starting in [bare mode](</docs/en/headless#start-faster-with-bare-mode>) turns it off as well. **Common backgrounded commands:**
--- a/interface.md
+++ b/interface.md
@@ -449,6 +449,9 @@
Up and Down| Move between controls while your drawing fits. When the pane or band has more rows than it can show, they scroll it.
Enter| Presses the focused `Button`, submits the focused `Input`, or picks in a `Select`
A button’s hotkey| Presses that button. While an `Input` has the focus, every printable key goes to the field.
+Page Up, Page Down, Home, and End| Scroll your pane or band when it has more rows than it can show
+Ctrl+X then an arrow key| Resizes your pane. Left or Up gives it more room, and Right or Down gives the room back.
+Ctrl+X then X| Closes your pane, even while one of its fields has the focus
Esc| Returns keyboard focus to the prompt. With `closeOnEscape: true`, it also closes the pane.
A mod can’t bind Tab or the arrow keys to anything else, so a game steers with `w`, `a`, `s`, and `d`.
--- a/keybindings.md
+++ b/keybindings.md
@@ -62,6 +62,8 @@
`EffortSlider`| Effort slider opened by `/effort`
`Select`| Generic select/list components
`Plugin`| Plugin dialog (browse, discover, manage)
+`Pane`| A pane drawn by a [mod](</docs/en/plugins/mods/interface#know-which-keys-your-mod-can-receive>) has keyboard focus
+`PaneField`| An input field or select in a mod’s pane has keyboard focus
`Agents`| [Agent view](</docs/en/agent-view>) (`claude agents`)
`Scroll`| Conversation scrolling and text selection in fullscreen mode
@@ -608,7 +610,15 @@
]
}
-This also works for chord bindings. Unbinding every chord that shares a prefix frees that prefix for use as a single-key binding. A chord in any active context keeps its prefix reserved, so you must unbind each chord in the context that defines it. Claude Code binds these default chords on the `ctrl+x` prefix: `ctrl+x ctrl+k`, `ctrl+x ctrl+e`, `ctrl+x enter`, `ctrl+x ctrl+a`, `ctrl+x ctrl+s`, and `ctrl+x tab` in `Chat`, `ctrl+x ctrl+b` in `Task`, and `ctrl+x b` in `DiffPanel`. The `ctrl+x enter` chord requires v2.1.247 or later, `ctrl+x b`, `ctrl+x ctrl+a`, and `ctrl+x tab` require v2.1.260 or later, and `ctrl+x ctrl+s` requires v2.1.275 or later. To reclaim `ctrl+x` itself as a single-key binding, unbind all of them:
+This also works for chord bindings. Unbinding every chord that shares a prefix frees that prefix for use as a single-key binding. A chord in any active context keeps its prefix reserved, so you must unbind each chord in the context that defines it. Claude Code binds these default chords on the `ctrl+x` prefix, by context:
+
+ * `Chat`: `ctrl+x ctrl+k`, `ctrl+x ctrl+e`, `ctrl+x enter`, `ctrl+x ctrl+a`, `ctrl+x ctrl+s`, and `ctrl+x tab`
+ * `Task`: `ctrl+x ctrl+b`
+ * `DiffPanel`: `ctrl+x b`
+ * `Pane`: `ctrl+x left`, `ctrl+x right`, `ctrl+x up`, `ctrl+x down`, and `ctrl+x x`
+ * `PaneField`: `ctrl+x x`
+
+The `ctrl+x enter` chord requires v2.1.247 or later, `ctrl+x b`, `ctrl+x ctrl+a`, and `ctrl+x tab` require v2.1.260 or later, and `ctrl+x ctrl+s` requires v2.1.275 or later. To reclaim `ctrl+x` itself as a single-key binding, unbind all of them:
{
"bindings": [
@@ -622,6 +632,22 @@
"context": "DiffPanel",
"bindings": {
"ctrl+x b": null
+ }
+ },
+ {
+ "context": "Pane",
+ "bindings": {
+ "ctrl+x left": null,
+ "ctrl+x right": null,
+ "ctrl+x up": null,
+ "ctrl+x down": null,
+ "ctrl+x x": null
+ }
+ },
+ {
+ "context": "PaneField",
+ "bindings": {
+ "ctrl+x x": null
}
},
{
--- a/llm-gateway-connect.md
+++ b/llm-gateway-connect.md
@@ -274,7 +274,7 @@
Slack, cloud sessions, and Remote Control
-[Claude Code in Slack](</docs/en/slack>) and [cloud sessions](</docs/en/claude-code-on-the-web>) always use Anthropic’s API; they aren’t part of a gateway deployment. Gateway variables set in a cloud session’s environment configuration are not applied. If your traffic must stay on the gateway, don’t enable these surfaces for those users. [Remote Control](</docs/en/remote-control>) and [voice dictation](</docs/en/voice-dictation>) both rely on a claude.ai identity: Remote Control to pair a live session with your account, and voice dictation to reach the claude.ai transcription endpoint. They are unavailable while `ANTHROPIC_API_KEY`, `ANTHROPIC_AUTH_TOKEN`, or an `apiKeyHelper` is active. Remote Control is also disabled while `ANTHROPIC_BASE_URL` points at a non-Anthropic host, so signing in with claude.ai isn’t enough on its own. Before v2.1.196, a non-Anthropic base URL didn’t block Remote Control. To restore either feature, log in with claude.ai and unset the gateway variables that feature checks. The Remote Control section of `claude doctor` names what is currently blocking Remote Control.
+[Claude Code in Slack](</docs/en/slack>) and [cloud sessions](</docs/en/claude-code-on-the-web>) aren’t part of a gateway deployment. Gateway variables set in a cloud session’s environment configuration are not applied. If your traffic must stay on the gateway, don’t enable these surfaces for those users. [Remote Control](</docs/en/remote-control>) and [voice dictation](</docs/en/voice-dictation>) both rely on a claude.ai identity: Remote Control to pair a live session with your account, and voice dictation to reach the claude.ai transcription endpoint. They are unavailable while `ANTHROPIC_API_KEY`, `ANTHROPIC_AUTH_TOKEN`, or an `apiKeyHelper` is active. Remote Control is also disabled while `ANTHROPIC_BASE_URL` points at a non-Anthropic host, so signing in with claude.ai isn’t enough on its own. Before v2.1.196, a non-Anthropic base URL didn’t block Remote Control. To restore either feature, log in with claude.ai and unset the gateway variables that feature checks. The Remote Control section of `claude doctor` names what is currently blocking Remote Control.
* Voice dictation: unset the gateway credential
* Remote Control: unset the gateway credential and `ANTHROPIC_BASE_URL`
--- a/llm-gateway-protocol.md
+++ b/llm-gateway-protocol.md
@@ -227,7 +227,7 @@
[Context management](<https://platform.claude.com/docs/en/build-with-claude/context-editing>)| Context management beta header pairs with the `context_management` body field| `400` with `Extra inputs are not permitted`. Common when a gateway accepts Anthropic-format requests but forwards them to Amazon Bedrock| Forward both, or `CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`
[Extended context](<https://platform.claude.com/docs/en/build-with-claude/context-windows#context-window-sizes-by-model>) and [interleaved thinking](<https://platform.claude.com/docs/en/build-with-claude/extended-thinking#interleaved-thinking>)| Beta headers only, no body field| Silently unavailable when the header is stripped; the upstream never sees the capability request| Forward `anthropic-beta` verbatim
Beta [tool fields](<https://platform.claude.com/docs/en/agents-and-tools/tool-use/overview>)| Tool-related beta headers pair with tool schema fields such as `strict` and `defer_loading`| `400` naming the unrecognized tool schema field when the body passes through without its header| Forward both, or `CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`
-[Effort](<https://platform.claude.com/docs/en/build-with-claude/effort>) and [structured outputs](<https://platform.claude.com/docs/en/build-with-claude/structured-outputs>)| The `output_config` body field carries effort, structured-output format, and task budget settings; each pairs with its own beta header| `400` naming `output_config`, often `Extra inputs are not permitted`, on Amazon Bedrock and Google Cloud’s Agent Platform upstreams| Forward the field and its headers together, or have developers set `CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`, which removes the format and task budget settings but not effort
+[Effort](<https://platform.claude.com/docs/en/build-with-claude/effort>) and [structured outputs](<https://platform.claude.com/docs/en/build-with-claude/structured-outputs>)| The `output_config` body field carries effort, structured-output format, and task budget settings; each pairs with its own beta header| `400` naming `output_config`, often `Extra inputs are not permitted`, on Amazon Bedrock and Google Cloud’s Agent Platform upstreams| Forward the field and its headers together, or have developers set `CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`, which removes the format and task budget settings but not effort. To remove only the format, they can set [`CLAUDE_CODE_DISABLE_STRUCTURED_OUTPUTS=1`](</docs/en/env-vars>) instead, which requires v2.1.288 or later
[Prompt caching](</docs/en/prompt-caching>)| No beta pairing. Claude Code attaches `cache_control` markers to `system` blocks and to `messages` entries, including `role: "system"` entries appended mid-conversation| No error: the conversation bills as uncached input on every turn, visible as high `input_tokens` with little or no cache activity in `usage`| Forward `cache_control` unchanged wherever it appears, and don’t convert block-form `system` or message content to plain strings
[Token counting](<https://platform.claude.com/docs/en/build-with-claude/token-counting>)| No beta pairing; uses the `count_tokens` endpoint| No error: Claude Code falls back to a character-based estimate, so `/context` shows approximate counts| Expose the endpoint for exact token counts
@@ -334,7 +334,7 @@
The picker is the interactive model list that opens when a developer runs `/model` in Claude Code. Each discovered entry uses `display_name` as its name when the gateway sends one that differs from the `id`. Otherwise the entry shows the model’s name when Claude Code [recognizes the `id`](</docs/en/model-config#customize-pinned-model-display-and-capabilities>), and the `id` when it doesn’t. For example, an entry with the `id` `my-gateway-claude-sonnet-4-6` and no `display_name` appears as `Sonnet 4.6`. Discovery adds only models that the [`availableModels` managed setting](</docs/en/settings-reference#availablemodels>) allows. Each entry also shows the model’s `description`, collapsed to one line. An entry without a `description` reads “From gateway” instead. Before v2.1.257, every discovered entry read “From gateway”. A discovered ID doesn’t get its own row when it matches a row already in the picker:
* Same ID: the discovered ID exactly matches an existing row’s ID, or the two IDs are spellings of the same [Fable](</docs/en/model-config#work-with-fable>) version.
- * Same model as a built-in alias: when a discovered explicit ID names the model that a built-in alias currently resolves to, the picker shows only the alias row. For example, while `sonnet` resolves to `claude-sonnet-5-5`, a discovered `claude-sonnet-5-5` collapses into the `sonnet` row, and a discovered `claude-sonnet-5` still gets its own row. Before v2.1.197, Claude Code didn’t fold these IDs into built-in rows, so the ID an alias resolved to also got its own “From gateway” row.
+ * Same model as a built-in alias: when a discovered explicit ID names the model that a built-in alias currently resolves to, the picker shows only the alias row. For example, while `sonnet` resolves to `claude-sonnet-5-5`, a discovered `claude-sonnet-5-5` collapses into the `sonnet` row, and a discovered `claude-sonnet-5` still gets its own row.
Results are cached to `~/.claude/cache/gateway-models.json`, or `%USERPROFILE%\.claude\cache\gateway-models.json` on Windows, and refreshed on each startup. If you set [`CLAUDE_CONFIG_DIR`](</docs/en/env-vars>), the cache lives under that directory instead. If the request fails or the gateway doesn’t implement `/v1/models`, the picker falls back to the cached list from the previous startup or to the built-in model list. If your gateway serves Claude models under aliases that don’t match the discovery filter, developers can add those aliases manually with the [model configuration](</docs/en/model-config>) variables.
--- a/manifest-reference.md
+++ b/manifest-reference.md
@@ -351,6 +351,7 @@
`workspaceFolder`| No| Workspace folder path for the server
`startupTimeout`| No| Milliseconds to wait for startup, a positive integer
`shutdownTimeout`| No| Milliseconds to wait for a graceful shutdown, a positive integer. When the timeout elapses, Claude Code terminates the server process. When unset, no timeout applies
+`requestTimeout`| No| Milliseconds to wait for the server to answer a request, a positive integer. Defaults to `60000`, so a request the server never answers fails after 60 seconds. Requires v2.1.288 or later
`restartOnCrash`| No| Whether to restart the server after it crashes. Defaults to `true`. Set to `false` to leave a crashed server stopped instead of restarting it
`maxRestarts`| No| Restart attempts before giving up, zero or more
`diagnostics`| No| Whether to push diagnostics into context after edits. Defaults to `true`
--- a/marketplace-reference.md
+++ b/marketplace-reference.md
@@ -49,7 +49,7 @@
Field| Type| Description
---|---|---
-`name`| string| Marketplace identifier: letters, digits, `.`, `_`, and `-`, starting with a letter or digit, and no `..`. It forms the half after `@` of every [plugin id](</docs/en/plugins/loading#find-where-a-plugin-came-from>) installed from the marketplace, so `claude plugin validate` fails other names. See Reserved names
+`name`| string| Marketplace identifier: letters, digits, `.`, `_`, and `-`, starting with a letter or digit, and no `..`. `claude plugin validate` fails any other name, because Claude Code can’t install plugins from a marketplace that uses one. Users type the name after `@` in a [plugin id](</docs/en/plugins/loading#find-where-a-plugin-came-from>) such as `my-plugin@my-marketplace` when they install a plugin. See Reserved names
`owner`| object| Maintainer information. `name` is required; `email` and `url` are optional
`plugins`| array| Plugin entries. Each entry is validated on its own, so one invalid entry doesn’t fail the marketplace
`$schema`| string| JSON Schema URL for editor autocomplete. Ignored at load time
--- a/memory.md
+++ b/memory.md
@@ -198,7 +198,7 @@
- Use the standard error response format
- Include OpenAPI documentation comments
-Rules without a `paths` field are loaded unconditionally and apply to all files. Path-scoped rules trigger when Claude reads files matching the pattern, not on every tool use. Matching also works when Claude reaches a file through a symlinked path to the project directory, for example in a symlinked checkout. Use glob patterns in the `paths` field to match files by extension, directory, or any combination:
+Rules without a `paths` field are loaded unconditionally and apply to all files. Path-scoped rules trigger when Claude uses the Read, Write, or Edit tool on a file matching the pattern, not on every tool use. Matching also works when Claude reaches a file through a symlinked path to the project directory, for example in a symlinked checkout. Use glob patterns in the `paths` field to match files by extension, directory, or any combination:
Pattern| Matches
---|---
--- a/model-config.md
+++ b/model-config.md
@@ -199,7 +199,12 @@
* **`advisorModel` setting**: the advisor is disabled for the session
* **`--advisor` flag**: Claude Code exits with an error at launch. In a [background session](</docs/en/agent-view>), it starts the session without the advisor instead of exiting
-Claude Code hides excluded models from the `/model` picker. A full model ID in the list that has no built-in picker row, such as an older version that the list pins, appears in the `/model` picker as its own labeled row, unless Claude Code replaces the built-in options with a [`modelPicker`](</docs/en/settings-reference#modelpicker>) lineup. Before v2.1.199, such an ID was selectable only by typing `/model <id>`. Model changes that Claude Code makes on your behalf are checked the same way:
+Claude Code hides excluded models from the `/model` picker. Whether a model ID you list also gets a row of its own differs by provider:
+
+ * **Anthropic API,[Claude Platform on AWS](</docs/en/claude-platform-on-aws>), [Claude apps gateway](</docs/en/claude-apps-gateway>), or an [LLM gateway](</docs/en/llm-gateway>) set through `ANTHROPIC_BASE_URL`**: an Anthropic model ID you list that has no built-in picker row appears as its own labeled row. Claude Code adds such a row for Opus, Sonnet, and Haiku versions, such as an older version that the list pins. If you set `replaceBuiltInOptions` in a [`modelPicker`](</docs/en/settings-reference#modelpicker>) lineup, that row doesn’t appear. Before v2.1.199, such an ID was selectable only by typing `/model <id>`.
+ * **Amazon Bedrock, Google Cloud’s Agent Platform, or Microsoft Foundry** : unless a model ID you list starts with `anthropic.`, Claude Code doesn’t add a row for it, whether it’s an Anthropic model ID or a provider-specific one. Mantle model IDs carry that prefix. To show a listed version that has no built-in row, also add it to a [`modelPicker`](</docs/en/settings-reference#modelpicker>) lineup, which accepts IDs in your provider’s format.
+
+Model changes that Claude Code makes on your behalf are checked the same way:
* **Fallback model chains** : entries outside the allowlist are dropped
* **Plan-mode upgrades** : on the Anthropic API and Claude Platform on AWS, an upgrade such as `opusplan` to an excluded model uses the newest permitted version of the upgrade family. On providers with provider-specific model IDs, and when no version is permitted, the upgrade is skipped and planning continues on the session’s model
@@ -296,7 +301,7 @@
Mantle model IDs
-When the [Amazon Bedrock Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>) is enabled, entries in `availableModels` that start with `anthropic.` are added to the `/model` picker as custom options and routed to the Mantle endpoint. This is an exception to the alias matching described in Pin models for third-party deployments. The setting still restricts the picker to listed entries, and a Mantle ID embeds a family name, so it counts as a specific entry and disables that family’s wildcard: alongside any Mantle IDs, list the version prefixes or full IDs you want to keep selectable. See Merge behavior.
+Entries in `availableModels` that start with `anthropic.` are added to the `/model` picker as custom options. This is an exception to the alias matching described in Pin models for third-party deployments. With the [Amazon Bedrock Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>) enabled, Claude Code routes the entries that match the Mantle format to that endpoint. The setting still restricts the picker to listed entries, and a Mantle ID embeds a family name, so it counts as a specific entry and disables that family’s wildcard: alongside any Mantle IDs, list the version prefixes or full IDs you want to keep selectable. See Merge behavior.
###
@@ -625,7 +630,7 @@
Pro| Requires [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>)| Requires [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>)
API and pay-as-you-go| Full access| Full access
-Claude Code checks these plan requirements only when it connects to the Anthropic API directly. If you point `ANTHROPIC_BASE_URL` at an [LLM gateway](</docs/en/llm-gateway#subscriptions-and-gateways>) and your saved claude.ai login stays the active credential, Claude Code doesn’t check your plan’s usage credits. The `[1m]` options stay available in `/model`, and the gateway decides whether the request succeeds. Before v2.1.229, Claude Code rejected `/model sonnet[1m]` in that configuration when it couldn’t confirm usage credits on the account. If you set `ANTHROPIC_BASE_URL` to an [LLM gateway](</docs/en/llm-gateway>) or another proxy, Claude Code gives each model it recognizes the same context window the model has on the Anthropic API. Fable 5.1, Fable 5, Sonnet 5 and later, and Opus 4.7 and later get the 1M window with no `[1m]` variant to select, and a model that reaches 1M only through its `[1m]` variant, such as Opus 4.6, runs at 200K without it. Claude Code can’t detect a lower limit that the gateway or the server behind it enforces. If your gateway rejects requests above 200K tokens, run `/autocompact 200k` so sessions compact at that boundary. To turn off 1M context, set `CLAUDE_CODE_DISABLE_1M_CONTEXT=1`. Claude Code removes 1M model variants from the model picker. On models with a native 1M window, such as Sonnet 5 and the Fable models, it also treats the model as having a 200K context window:
+Claude Code checks these plan requirements only when it connects to the Anthropic API directly. If you point `ANTHROPIC_BASE_URL` at an [LLM gateway](</docs/en/llm-gateway#subscriptions-and-gateways>) and your saved claude.ai login stays the active credential, Claude Code doesn’t check your plan’s usage credits. The `[1m]` options stay available in `/model`, and the gateway decides whether the request succeeds. Before v2.1.229, Claude Code rejected `/model sonnet[1m]` in that configuration when it couldn’t confirm usage credits on the account. If you set `ANTHROPIC_BASE_URL` to an [LLM gateway](</docs/en/llm-gateway>) or another proxy, Claude Code gives each model it recognizes the same context window the model has on the Anthropic API. Fable 5.1, Fable 5, Sonnet 5 and later, and Opus 4.7 and later get the 1M window with no `[1m]` variant to select, and a model that reaches 1M only through its `[1m]` variant, such as Opus 4.6, runs at 200K without it. Claude Code can’t detect a lower limit that the gateway or the server behind it enforces. If your gateway rejects requests above 200K tokens, set [`CLAUDE_CODE_AUTO_COMPACT_WINDOW=200000`](</docs/en/env-vars>) in the environment that starts Claude Code, so sessions on every model compact at that boundary. To turn off 1M context, set `CLAUDE_CODE_DISABLE_1M_CONTEXT=1`. Claude Code removes 1M model variants from the model picker. On models with a native 1M window, such as Sonnet 5 and the Fable models, it also treats the model as having a 200K context window:
* With auto-compaction on, sessions compact at the 200K boundary through auto-compaction. Setting the auto-compact window above 200K doesn’t lift the hold, because Claude Code caps that window at the model’s context window.
* With auto-compaction off, sessions stop at the 200K boundary with the [context-limit error](</docs/en/errors#prompt-is-too-long>) instead of compacting.
@@ -663,9 +668,10 @@
Set the auto-compact window
-You can set the auto-compact window in three places:
-
- * **For this session and later ones** : run `/autocompact` with a value, like `/autocompact 500k`. Claude Code saves it to your user settings as [`autoCompactWindow`](</docs/en/settings-reference#autocompactwindow>) and applies it to the current session; if a higher-priority [settings scope](</docs/en/settings#settings-precedence>) such as managed settings sets the key, the command saves your value but the session keeps that scope’s window, and the command says so. Run `/autocompact auto` to return to the window tuned for your model.
+You can set the auto-compact window in these places:
+
+ * **For the current model, in this session and later ones** : run `/autocompact` with a value, like `/autocompact 500k`. Claude Code saves it to your user settings under the current model in [`modelSettings`](</docs/en/settings-reference#modelsettings>) and applies it to the current session. If a higher-priority [settings scope](</docs/en/settings#settings-precedence>) such as managed settings sets its own window for that model or for every model, the command saves your value but the session keeps that scope’s window, and the command says so. Run `/autocompact auto` to return to the window tuned for your model. Before v2.1.288, the command saved one window for every model, as the top-level `autoCompactWindow`.
+ * **For every model** : set [`autoCompactWindow`](</docs/en/settings-reference#autocompactwindow>) in a settings file, such as `"autoCompactWindow": 200000` in `~/.claude/settings.json`. A window you saved for a model with `/autocompact` takes precedence over this key in the same file for that model.
* **For one launch** : pass [`--autocompact`](</docs/en/cli-reference#cli-flags>) when starting Claude Code. The flag overrides your saved setting for that launch without changing it, and `claude --autocompact auto` runs the session at the tuned window even if your saved setting has a value. Unlike `/autocompact`, the flag isn’t preempted by a higher-priority settings scope such as managed settings.
* **In scripts and cloud environments** : set [`CLAUDE_CODE_AUTO_COMPACT_WINDOW`](</docs/en/env-vars>). While it’s set, it takes precedence over the command, the flag, and the setting, and `/autocompact` reports the override instead of changing the window.
--- a/monitoring-usage.md
+++ b/monitoring-usage.md
@@ -703,7 +703,7 @@
User prompt event
-Logged when a user submits a prompt. **Event Name** : `claude_code.user_prompt` **Attributes** :
+Logged when a prompt is submitted, including on turns Claude Code starts on its own. **Event Name** : `claude_code.user_prompt` **Attributes** :
* All standard attributes
* `event.name`: `"user_prompt"`
--- a/permission-modes.md
+++ b/permission-modes.md
@@ -466,7 +466,7 @@
Allow only pre-approved tools with dontAsk mode
-If you set `dontAsk` mode, Claude Code auto-denies every tool call that would otherwise prompt you. Claude still runs actions that need no approval in Manual mode, such as file reads inside your working directories and [read-only Bash commands](</docs/en/permissions#read-only-commands>), plus actions matching your `permissions.allow` rules and calls approved by a [PreToolUse hook](</docs/en/permissions#extend-permissions-with-hooks>). Use this mode for CI pipelines or restricted environments where you pre-define what Claude may do; the session never waits for input. The status bar shows `⏵⏵ don't ask on` while this mode is active. Claude Code denies calls matching your explicit [`ask` rules](</docs/en/permissions#manage-permissions>) rather than prompting. It also denies the built-in `AskUserQuestion` tool even if your allow rules match it, and does the same to connector tools [your organization set to `ask`](</docs/en/mcp#organization-controls-on-connector-tools>) in sessions where that setting reaches Claude Code. It denies MCP tools marked [`_meta["anthropic/requiresUserInteraction"]`](</docs/en/mcp#require-approval-for-a-specific-tool>) the same way, because their approval card needs an answer this mode never collects; this requires Claude Code v2.1.199 or later. `rm` and `rmdir` removals targeting a critical path, such as `rm -rf /` and `rm -rf ~`, are denied even when an allow rule matches them or a `PreToolUse` hook allows them. [Cloud sessions](</docs/en/claude-code-on-the-web>) ignore `defaultMode: "dontAsk"`; see bypassPermissions for details. Set it at startup with the flag:
+If you set `dontAsk` mode, Claude Code auto-denies every tool call that would otherwise prompt you. Claude still runs actions that need no approval in Manual mode, such as file reads inside your working directories and [read-only Bash commands](</docs/en/permissions#read-only-commands>), plus actions matching your `permissions.allow` rules and calls approved by a [PreToolUse hook](</docs/en/permissions#extend-permissions-with-hooks>). Use this mode for CI pipelines or restricted environments where you pre-define what Claude may do; the session never waits for input. The status bar shows `⏵⏵ don't ask on` while this mode is active. Claude Code denies calls matching your explicit [`ask` rules](</docs/en/permissions#manage-permissions>) rather than prompting. It also denies the built-in `AskUserQuestion` tool even if your allow rules match it, and does the same to connector tools [your organization set to `ask`](</docs/en/mcp#organization-controls-on-connector-tools>) in sessions where that setting reaches Claude Code. It denies MCP tools marked [`_meta["anthropic/requiresUserInteraction"]`](</docs/en/mcp#require-approval-for-a-specific-tool>) the same way, because their approval card needs an answer this mode never collects. `rm` and `rmdir` removals targeting a critical path, such as `rm -rf /` and `rm -rf ~`, are denied even when an allow rule matches them or a `PreToolUse` hook allows them. [Cloud sessions](</docs/en/claude-code-on-the-web>) ignore `defaultMode: "dontAsk"`; see bypassPermissions for details. Set it at startup with the flag:
claude --permission-mode dontAsk
--- a/publish.md
+++ b/publish.md
@@ -161,19 +161,38 @@
Submit to Anthropic’s directory
-Anthropic’s directory is the catalog people browse on claude.ai and in Cowork to add plugins and connectors. One listing there reaches people on claude.ai, in Cowork, and in Claude Code. You submit from the developer portal at [claude.ai/directory/manage](<https://claude.ai/directory/manage>); [Prepare for review](<https://claude.com/docs/directory/publish#prepare-for-review>) on claude.com describes what happens to each version before it’s published. Submitting requires a paid claude.ai plan. On Pro and Max you submit from your own account. On Team and Enterprise, an Owner can submit, and on Enterprise an Owner can also grant the **Directory** permission to other members through a custom role under **Organization settings > Roles**. See [Confirm you can submit to the directory](<https://claude.com/docs/directory/publish#confirm-you-can-submit-to-the-directory>). The submission steps, the checks each version must pass, and what happens after you publish are documented on claude.com, because they’re the same whichever surface your users are on:
-
- * [Publish to the directory](<https://claude.com/docs/directory/publish#before-you-submit-to-the-directory>): what you can submit and who can submit it
- * [Submit a plugin](<https://claude.com/docs/plugins/submit#submit-a-plugin>): the portal steps and [updating a published plugin](<https://claude.com/docs/plugins/submit#update-a-published-plugin>)
- * [Plugin pre-submission checklist](<https://claude.com/docs/plugins/pre-submission-checklist#run-the-checks-before-you-submit>): the checks to run and fix before you submit
+[Anthropic’s directory](<https://claude.ai/directory>) is the catalog people browse on claude.ai and in Cowork to add plugins and connectors. One listing there reaches people on claude.ai, in Cowork, and in Claude Code. You submit from the developer portal at [claude.ai/directory/manage](<https://claude.ai/directory/manage>), and [Submit a plugin](<https://claude.com/docs/plugins/submit#submit-a-plugin>) on claude.com walks through the portal. Anthropic’s official marketplace, `claude-plugins-official`, doesn’t take submissions through the directory portal. If you work with an Anthropic partner contact, ask them about an official-marketplace listing. To submit a plugin:
+
+1
+
+Confirm you can submit
+
+Submitting requires a paid claude.ai plan. On Pro and Max you submit from your own account. On Team and Enterprise, an Owner can submit, and on Enterprise an Owner can also grant the **Directory** permission to other members through a custom role under **Organization settings > Roles**. See [Confirm you can submit to the directory](<https://claude.com/docs/directory/publish#confirm-you-can-submit-to-the-directory>).
+
+2
+
+Validate the plugin locally
+
+Run `claude plugin validate ./your-plugin --strict` in your shell. Replace `./your-plugin` with the path to your plugin directory. The command catches manifest errors locally; [plugin validate](</docs/en/plugins/cli-reference#plugin-validate>) lists which files each run reads. The portal applies additional directory rules that the CLI doesn’t check, so a clean local run doesn’t guarantee a clean portal validation.The [plugin pre-submission checklist](<https://claude.com/docs/plugins/pre-submission-checklist#run-the-checks-before-you-submit>) on claude.com has the checks to run and fix before you submit.
+
+3
+
+Check what loads where
+
+Some plugin components are Claude Code-only and don’t load on claude.ai or in Cowork. The [component support table](<https://claude.com/docs/plugins/platform-support#compare-component-support-by-app>) lists each component by app, so you know what users outside Claude Code will get.
+
+4
+
+Submit in the developer portal
+
+Open the developer portal at [claude.ai/directory/manage](<https://claude.ai/directory/manage>) and follow [Submit a plugin](<https://claude.com/docs/plugins/submit#submit-a-plugin>) on claude.com.
+
+The rest of the process is documented on claude.com:
+
+ * [Prepare for review](<https://claude.com/docs/directory/publish#prepare-for-review>): what happens to each version before it’s published
+ * [Update a published plugin](<https://claude.com/docs/plugins/submit#update-a-published-plugin>): how a new version reaches the people who have your plugin
+ * [Submit your plugin, and your MCP server as a connector](<https://claude.com/docs/directory/publish#submit-your-plugin-and-your-mcp-server-as-a-connector>): what you can submit
* [Move an earlier submission to the developer portal](<https://claude.com/docs/directory/publish#move-an-earlier-submission-to-the-developer-portal>): what to do if you submitted a plugin through one of the earlier submission forms, before the portal existed
-
-Before you open the portal, validate locally and check which of your components load outside Claude Code:
-
- * **Run`claude plugin validate ./your-plugin --strict` in your shell**: replace `./your-plugin` with the path to your plugin directory. The command catches manifest errors locally; [plugin validate](</docs/en/plugins/cli-reference#plugin-validate>) lists which files each run reads. The portal applies additional directory rules that the CLI doesn’t check, so a clean local run doesn’t guarantee a clean portal validation.
- * **Check what loads where** : some plugin components are Claude Code-only and don’t load on claude.ai or in Cowork. The [component support table](<https://claude.com/docs/plugins/platform-support#compare-component-support-by-app>) lists each component by app, so you know what users outside Claude Code will get.
-
-Anthropic’s official marketplace, `claude-plugins-official`, doesn’t take submissions through the directory portal. If you work with an Anthropic partner contact, ask them about an official-marketplace listing.
###
--- a/python.md
+++ b/python.md
@@ -2204,7 +2204,7 @@
"PreToolUse", # Called before tool execution
"PostToolUse", # Called after tool execution
"PostToolUseFailure", # Called when a tool execution fails
- "UserPromptSubmit", # Called when user submits a prompt
+ "UserPromptSubmit", # Called when a prompt is submitted
"Stop", # Called when stopping execution
"SubagentStop", # Called when a subagent stops
"PreCompact", # Called before message compaction
@@ -2403,7 +2403,7 @@
Field| Type| Description
---|---|---
`hook_event_name`| `Literal["UserPromptSubmit"]`| Always “UserPromptSubmit”
-`prompt`| `str`| The user’s submitted prompt
+`prompt`| `str`| The submitted prompt
###
--- a/reference.md
+++ b/reference.md
@@ -59,7 +59,7 @@
---|---|---
[`tool.call`](</docs/en/plugins/mods/events#guard-or-change-a-tool-call>)| A tool is about to run| `next(e)`, `{ deny: reason }`, or `{ result }`
[`tool.check`](</docs/en/plugins/mods/events#where-settings-hooks-run-in-the-order>)| Claude Code decides whether a tool call may run, after the `tool.call` and `PreToolUse` hooks. `next(e)` resolves to the decision the rules, the permission mode, and those hooks reached.| `{ decision }`, which is `allow`, `ask`, or `deny`
-`tool.describe`| Once for each tool, when its description is first sent to Claude| `{ description }`
+`tool.describe`| Once for each tool, when its description is first sent to Claude| `{ description }`, optionally with `isDeferred` set to `true` to put the tool behind [tool search](</docs/en/mcp#scale-with-mcp-tool-search>) or `false` to load it upfront
###
--- a/routines.md
+++ b/routines.md
@@ -363,7 +363,7 @@
Change the network access level
-In the **Edit cloud environment** dialog, change **Network access** to **Custom** and enter your domains in **Allowed domains**. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead for unrestricted access.
+In the **Edit environment** dialog, change **Network access** to **Custom** and enter your domains in **Allowed domains**. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead for unrestricted access.
5
--- a/sandboxing.md
+++ b/sandboxing.md
@@ -385,7 +385,7 @@
Mask credentials
-When you mask a credential, Claude Code shows sandboxed commands a per-session placeholder called the sentinel, and the sandbox proxy substitutes the real value on outbound requests to hosts you allow. A `deny` entry under Protect credentials blocks the credential instead. For files on macOS, Claude Code blocks the file instead of masking it. Masking environment variables requires Claude Code v2.1.199 or later. The [`sandbox.credentials`](</docs/en/settings-reference#sandbox-credentials>) reference lists every field. Masking requires the following:
+When you mask a credential, Claude Code shows sandboxed commands a per-session placeholder called the sentinel, and the sandbox proxy substitutes the real value on outbound requests to hosts you allow. A `deny` entry under Protect credentials blocks the credential instead. For files on macOS, Claude Code blocks the file instead of masking it. The [`sandbox.credentials`](</docs/en/settings-reference#sandbox-credentials>) reference lists every field. Masking requires the following:
* **TLS termination** : the proxy substitutes the real value inside request contents, so it has to see them. Set [`network.tlsTerminate`](</docs/en/settings-reference#sandbox-network-tlsterminate>) so the proxy terminates TLS itself. Without it, masking fails without exposing anything: the command still sees only the sentinel, but the sentinel reaches the server unchanged and authentication fails. Claude Code reports this misconfiguration at startup.
* **An allowed destination** : each `mask` entry can list `injectHosts`, the hosts the real value is allowed to reach. The proxy injects only on connections the domain allowlist admits, so each `injectHosts` host must also be reachable through `network.allowedDomains`. For a `mask` entry with no `injectHosts`, the proxy substitutes the real value on requests to every host in `network.allowedDomains`.
@@ -533,7 +533,7 @@
In a `WebFetch(domain:...)` rule, the sandbox honors two wildcard forms: a leading `*.`, such as `*.example.com`, and a bare `*`. The bare `*` form requires Claude Code v2.1.186 or later. A wildcard in any other position, such as `WebFetch(domain:example.*)`, still matches fetches but has no effect on sandboxed commands.
-The built-in proxy enforces the allowlist based on the requested hostname and, by default, does not terminate or inspect TLS traffic. The experimental [`network.tlsTerminate`](</docs/en/settings-reference#sandbox-network-tlsterminate>) setting, available in Claude Code v2.1.199 and later, makes the built-in proxy terminate TLS itself, which `mask` credential entries require. See Security limitations for the implications of the default, and Custom proxy configuration if your threat model requires TLS inspection.
+The built-in proxy enforces the allowlist based on the requested hostname and, by default, does not terminate or inspect TLS traffic. The experimental [`network.tlsTerminate`](</docs/en/settings-reference#sandbox-network-tlsterminate>) setting makes the built-in proxy terminate TLS itself, which `mask` credential entries require. See Security limitations for the implications of the default, and Custom proxy configuration if your threat model requires TLS inspection.
####
--- a/self-hosted-environments.md
+++ b/self-hosted-environments.md
@@ -14,7 +14,7 @@
* **Runner** : a program running on hosts inside your network. Runners execute the sessions; the idea is the same as a self-hosted CI runner.
* **Session** : one Claude Code task a developer started.
-When a developer starts a cloud session, the session-start UI shows an environment picker listing Anthropic-hosted environments alongside any your organization has created. If they choose yours, Anthropic’s control plane places the session on your environment’s queue, where a runner claims it, clones the repository the developer chose, and starts a Claude Code process on your host to run it. The runner authenticates to your git host with credentials you configure; [Configure git](</docs/en/self-hosted-environments-deploy#configure-git>) covers the options. Sessions reach your internal services from inside your network, and your git host the same way when it’s internal; the traffic to Anthropic, queue polling, the session’s event stream, and model inference, is outbound HTTPS to `api.anthropic.com`, with the short list of further hosts sessions can reach in [Network requirements](</docs/en/self-hosted-environments-deploy#network-requirements>). Anthropic never connects into your network.
+When a developer starts a cloud session, the session-start UI shows an environment picker listing Anthropic-hosted environments alongside any your organization has created. If they choose yours, Anthropic’s control plane places the session on your environment’s queue, where a runner claims it, clones the repository the developer chose, and starts a Claude Code process on your host to run it. The runner authenticates to your git host with credentials you configure; [Configure git](</docs/en/self-hosted-environments-deploy#configure-git>) covers the options. Sessions reach your internal services from inside your network, and your git host the same way when it’s internal; the traffic to Anthropic, queue polling, the session’s event stream, and by default model inference, is outbound HTTPS to `api.anthropic.com`, with the short list of further hosts sessions can reach in [Network requirements](</docs/en/self-hosted-environments-deploy#network-requirements>). Anthropic never connects into your network.
The two Claude Code boxes in the diagram are session processes: one runner executing two sessions at once, up to its configured capacity. A runner serves one owner at a time and locks to that owner when it claims its first session, so checked-out code never mixes between owners; Runner lifecycle covers the rule. You can start runners yourself and keep them running, or run the [autoscaling orchestrator](</docs/en/self-hosted-environments-configuration#on-demand-runners>), a second process you host, which starts runners as sessions queue; each runner exits on its own when its work finishes. Either way, you set the environment up once, and it appears in the picker on every supported surface.
@@ -28,7 +28,7 @@
* **Plans** : public beta for Team and Enterprise organizations. Self-hosted environments are off by default; an [Owner](</docs/en/cloud-environments#organization-shared-environments>) turns on **Allow self-hosted environments** on the [**Cloud environments** admin page](<https://claude.ai/admin-settings/cloud-environments>), which requires [cloud sessions](</docs/en/claude-code-on-the-web>) to be enabled for the organization.
* **Zero Data Retention** : unavailable for organizations with [Zero Data Retention](</docs/en/zero-data-retention>) enabled.
- * **Model inference** : sessions use the Anthropic API, and inference can’t be routed through [Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry](</docs/en/third-party-integrations>), or an [LLM gateway](</docs/en/llm-gateway>).
+ * **Model inference** : sessions use the Anthropic API unless you configure a runner to [send model requests to Amazon Bedrock or Google Cloud’s Agent Platform](</docs/en/self-hosted-environments-configuration#send-model-requests-to-bedrock-or-agent-platform>). Session content goes to Anthropic in both cases. On a runner configured this way, [server-managed settings](</docs/en/server-managed-settings>) and organization policies from claude.ai don’t reach sessions.
* **Surfaces** : sessions started from [claude.ai/code](<https://claude.ai/code>), the mobile and desktop apps, [scheduled routines](</docs/en/routines>), and the terminal, with [`claude --cloud`](</docs/en/claude-code-on-the-web#from-terminal-to-cloud>) or an [`--environment` dispatch](</docs/en/self-hosted-environments-testing#run-the-test-loop>), can run in self-hosted environments. [Claude Tag](<https://claude.com/docs/claude-tag/overview>) sessions can run in them too, but Claude can’t use [Access bundles](<https://claude.com/docs/claude-tag/concepts/glossary#access-bundle>) in those sessions yet. [Claude Security](</docs/en/claude-security>) and [Code Review](</docs/en/code-review>) sessions don’t route to them yet. Support for those two surfaces follows separately.
* **Repositories** : sessions check out repositories from GitHub; see [GitHub authentication options](</docs/en/claude-code-on-the-web#github-authentication-options>). For a GitHub Enterprise Server host, see its [network requirements](</docs/en/github-enterprise-server#network-requirements>).
* **Billing** : sessions in a self-hosted environment consume your organization’s Claude Code usage the same way sessions in Anthropic-hosted environments do.
@@ -43,7 +43,7 @@
* **Network access** : sessions run inside your network and can reach internal services, databases, and registries without exposing them to the public internet
* **Custom tooling** : pre-install compilers, SDKs, and internal CLIs in your runner image so every session starts ready to build
- * **Compliance** : repository checkouts and build artifacts stay on infrastructure you control. Session content still goes to `api.anthropic.com` for model inference.
+ * **Compliance** : repository checkouts and build artifacts stay on infrastructure you control. Session content still goes to `api.anthropic.com`.
##
@@ -124,7 +124,7 @@
* **Git** : the runner clones from and pushes to your git host over HTTPS or SSH, authenticated with credentials your deployment provides; [Configure git](</docs/en/self-hosted-environments-deploy#configure-git>) covers the options, including per-session minted credentials and the [Anthropic git proxy](</docs/en/self-hosted-environments-deploy#use-the-anthropic-git-proxy>), which routes git through `api.anthropic.com` instead.
* **Session child** : the child Claude Code process holds the session’s event stream to `api.anthropic.com`, and makes its own outbound calls for model inference and for git commands run during the session. See [Network requirements](</docs/en/self-hosted-environments-deploy#network-requirements>) for the full egress list. The diagram above shows these paths, apart from the optional SCM connector.
-Model inference uses the Anthropic API. The control plane delivers the API endpoint to each session, and the session authenticates with an Anthropic-issued, session-scoped OAuth token, so inference can’t be routed through [Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry](</docs/en/third-party-integrations>), or an [LLM gateway](</docs/en/llm-gateway>) in self-hosted environments. Corporate egress proxies are supported. The runner and the optional [autoscaling orchestrator](</docs/en/self-hosted-environments-configuration#on-demand-runners>) honor the proxy and mTLS environment variables described in [Network configuration](</docs/en/network-config>), such as `HTTPS_PROXY` and `NO_PROXY`; set them in each process’s environment. The variables cover control-plane calls, the orchestrator’s [SCM connector](</docs/en/self-hosted-environments-reference#scm-connector-flags>) WebSocket, and the built-in clone for HTTPS remotes, and sessions inherit them from the runner. Session streaming uses server-sent events over HTTPS, so a proxy in the path must not buffer responses. If your proxy also requires a `Proxy-Authorization` header, the runner can add it to each connection it opens to the proxy; see [Authenticate to an egress proxy](</docs/en/self-hosted-environments-deploy#authenticate-to-an-egress-proxy>).
+By default, model inference uses the Anthropic API. The control plane delivers the API endpoint to each session, and the session authenticates with an Anthropic-issued, session-scoped OAuth token. To send model requests to your own cloud account instead, see [Send model requests to Bedrock or Agent Platform](</docs/en/self-hosted-environments-configuration#send-model-requests-to-bedrock-or-agent-platform>). Corporate egress proxies are supported. The runner and the optional [autoscaling orchestrator](</docs/en/self-hosted-environments-configuration#on-demand-runners>) honor the proxy and mTLS environment variables described in [Network configuration](</docs/en/network-config>), such as `HTTPS_PROXY` and `NO_PROXY`; set them in each process’s environment. The variables cover control-plane calls, the orchestrator’s [SCM connector](</docs/en/self-hosted-environments-reference#scm-connector-flags>) WebSocket, and the built-in clone for HTTPS remotes, and sessions inherit them from the runner. Session streaming uses server-sent events over HTTPS, so a proxy in the path must not buffer responses. If your proxy also requires a `Proxy-Authorization` header, the runner can add it to each connection it opens to the proxy; see [Authenticate to an egress proxy](</docs/en/self-hosted-environments-deploy#authenticate-to-an-egress-proxy>).
##
@@ -132,7 +132,7 @@
What stays on your infrastructure
-Repository checkouts, build artifacts, secrets, and any files a session creates or modifies stay on the machines you provision. The conversation itself, including prompts, responses, and tool results, goes to `api.anthropic.com` for model inference, and Anthropic stores the session transcript so you can resume the session from another supported surface. A self-hosted environment moves session execution into your network. The control plane remains Anthropic-hosted: session orchestration, queueing, and the claude.ai interface continue to run on Anthropic’s infrastructure.
+Repository checkouts, build artifacts, secrets, and any files a session creates or modifies stay on the machines you provision. The conversation itself, including prompts, responses, and tool results, goes to `api.anthropic.com`, and Anthropic stores the session transcript so you can resume the session from another supported surface. When a runner [sends model requests to Amazon Bedrock or Google Cloud’s Agent Platform](</docs/en/self-hosted-environments-configuration#send-model-requests-to-bedrock-or-agent-platform>), the conversation still goes to `api.anthropic.com` in the session’s event stream. A self-hosted environment moves session execution into your network. The control plane remains Anthropic-hosted: session orchestration, queueing, and the claude.ai interface continue to run on Anthropic’s infrastructure.
##
Show diff (108 lines)
--- a/self-hosted-environments-configuration.md
+++ b/self-hosted-environments-configuration.md
@@ -24,7 +24,7 @@
`CLAUDE_CODE_REMOTE_SESSION_UUID`| The same session ID in canonical UUID form, for systems that key on UUIDs.
`CLAUDE_SESSION_INGRESS_TOKEN_FILE`| Absolute path to a per-session file holding the current session JWT, kept fresh across token refreshes. Shell subprocesses read it for their `Authorization` header when downloading attachments the user added to the session. `exec` preserves the variable automatically; a wrapper that rebuilds the child’s environment must carry the variable over, or attachment downloads silently stop working.
`CLAUDE_CONFIG_DIR`| Per-session Claude config directory, written at session start from the snapshot of the runner host’s config that the runner captures at startup; see Permissions and tool approval. Writes here are isolated to this session. The directory stays under `<base-dir>/_sessions/` after the session ends unless you start the runner with [`--remove-session-state`](</docs/en/self-hosted-environments-reference#runner-cli-flags>); see [Reuse a pre-warmed checkout](</docs/en/self-hosted-environments-deploy#reuse-a-pre-warmed-checkout>).
-`ANTHROPIC_BASE_URL`| The API base URL the child will use, delivered by the control plane per session and normally `https://api.anthropic.com`. Don’t override it: the session’s inference credential is an Anthropic-issued OAuth token that other providers don’t accept, so inference in self-hosted environments isn’t routable elsewhere.
+`ANTHROPIC_BASE_URL`| The API base URL the child will use, delivered by the control plane per session and normally `https://api.anthropic.com`. Don’t override it: the session’s inference credential is an Anthropic-issued OAuth token that other providers don’t accept.
`CLAUDE_CODE_OAUTH_TOKEN`| The short-lived OAuth access token the child uses for model inference, scoped to model inference and file upload only, with a lifetime of about 30 minutes. The runner re-mints it before expiry and delivers the rotation over the child’s stdin, so a wrapper that doesn’t keep stdin attached sees only the initial value. Don’t rely on your organization’s IP allowlist to bound this token’s use: treat it as a bearer credential that stays usable for roughly 30 minutes if it leaks, and don’t log it, write it to disk, or forward it outside the session container.
The wrapper also inherits the rest of the child’s managed environment, including any server-provided environment variables. `exec` propagates all of it automatically; if your wrapper spawns the child another way, forward the full environment.
@@ -267,6 +267,87 @@
+Send model requests to Bedrock or Agent Platform
+
+If your organization needs model requests to go through its own AWS or Google Cloud account, configure the runner for [Amazon Bedrock](</docs/en/amazon-bedrock>) or [Google Cloud’s Agent Platform, formerly Vertex AI](</docs/en/google-vertex-ai>). Every session that runner starts then calls the model in your cloud account, with your cloud credentials. Without this configuration, sessions send model requests to the Anthropic API. The runner still polls Anthropic for sessions, and each session still sends its event stream to `api.anthropic.com`. The event stream carries prompts, responses, and tool results. The plan requirement and the Zero Data Retention exclusion in [Availability and limitations](</docs/en/self-hosted-environments#availability-and-limitations>) still apply. Sessions are routed to an environment, not to a runner, and a requeued or resumed session can run on a different runner. Configure every runner in the environment the same way. Before you start, read what differs on these providers.
+
+1
+
+Prepare the cloud account and your egress rules
+
+Set up model access, a narrowly scoped policy or role, and network access:
+
+ * **Amazon Bedrock** : [submit use case details](</docs/en/amazon-bedrock#1-submit-use-case-details>), then create the policy in [IAM configuration](</docs/en/amazon-bedrock#iam-configuration>), limiting `bedrock:InvokeModel` and `bedrock:InvokeModelWithResponseStream` to the inference profiles your sessions use and the foundation models behind them
+ * **Agent Platform** : [enable the API](</docs/en/google-vertex-ai#1-enable-agent-platform-api>) and [request model access](</docs/en/google-vertex-ai#2-request-model-access>), then create the custom role that [IAM configuration](</docs/en/google-vertex-ai#iam-configuration>) describes, with only `aiplatform.endpoints.predict`
+ * **Egress** : allow your provider’s endpoints through your egress rules. See [Network requirements](</docs/en/self-hosted-environments-deploy#network-requirements>). If sessions can’t reach them, Claude Code can keep retrying for hours before the session shows an error.
+
+2
+
+Give sessions narrowly scoped credentials
+
+Attach the policy or role from step 1 to an identity that can do nothing else. For the methods Claude Code accepts, see [Configure AWS credentials](</docs/en/amazon-bedrock#2-configure-aws-credentials>) and [Configure GCP credentials](</docs/en/google-vertex-ai#3-configure-gcp-credentials>).
+
+Anyone who can get code to run in a session, including through prompt injection, can use these credentials at your cost for as long as the credentials are valid. Claude Code runs inside the session, so the credential it calls the model with has to be readable there.The shell commands Claude runs, your [Claude Code hooks](</docs/en/hooks>), and stdio MCP servers inherit the session’s environment and run as the same user as Claude Code. As a result, they can read credential variables and credential files.When you [harden your deployment](</docs/en/self-hosted-environments-deploy#harden-your-deployment>), you keep host credentials out of sessions, but you can’t keep this credential out. Give the identity behind it nothing beyond the policy or role from step 1.
+
+Check the method you choose against these runner behaviors:
+
+ * **Metadata endpoint** : if you deny sessions the [cloud metadata endpoint](</docs/en/self-hosted-environments-deploy#harden-your-deployment>) outright, credentials served from it, such as an instance profile, don’t reach Claude Code either. A file-based web identity, such as IAM Roles for Service Accounts (IRSA) on Amazon EKS or a Workload Identity Federation credential file, doesn’t depend on it.
+ * **Renewal** : a session can outlive a credential, so use a method that renews itself, such as a file-based web identity
+ * **Wrapper script** : the runner starts your wrapper script once per session, so credentials it exports aren’t renewed. Claude Code reads AWS credentials from its environment, so if your wrapper already exports AWS credentials for other work, Claude Code can sign model requests with them.
+
+3
+
+Set one provider's variables in the runner's environment
+
+Set exactly one provider’s variables where you set the runner’s other environment variables, such as the container spec or service unit, then restart the runner. The examples show them as shell exports. With on-demand runners, set them on the workload your `spawn-runner` hook starts.Start these runners with [`--confine-repo-settings enforce`](</docs/en/self-hosted-environments-deploy#harden-your-deployment>). It refuses sessions on repositories whose committed settings it flags, so run in the default `warn` mode first and clear what it logs.
+
+ * Amazon Bedrock
+
+ * Google Cloud's Agent Platform
+
+Replace the region with your own:
+
+ export CLAUDE_CODE_USE_BEDROCK=1
+ export AWS_REGION=us-east-1
+
+For how Claude Code resolves the region, see [Configure Claude Code](</docs/en/amazon-bedrock#3-configure-claude-code>). For which inference profile prefix Claude Code uses for your region, see [Cross-region inference profile prefixes](</docs/en/amazon-bedrock#cross-region-inference-profile-prefixes>).
+
+Replace the region and project ID with your own:
+
+ export CLAUDE_CODE_USE_VERTEX=1
+ export CLOUD_ML_REGION=global
+ export ANTHROPIC_VERTEX_PROJECT_ID=YOUR-PROJECT-ID
+
+To choose a region, see [Region configuration](</docs/en/google-vertex-ai#region-configuration>).
+
+4
+
+Check that the variables reached a session
+
+Your own shell on the host is a different process, so check from inside a session. Start one in the environment and ask Claude to run this command:
+
+ env | grep -E 'CLAUDE_CODE_USE_(BEDROCK|VERTEX)'
+
+A line that sets `CLAUDE_CODE_USE_BEDROCK` or `CLAUDE_CODE_USE_VERTEX` to `1` means the variable reached the session. If both appear, Claude Code uses Amazon Bedrock. No output means neither reached it.The command shows configuration, not traffic. To confirm the requests themselves, look for them in your cloud account’s own metrics or request logs. If the first message fails instead, see troubleshooting for [Amazon Bedrock](</docs/en/amazon-bedrock#troubleshooting>) or [Agent Platform](</docs/en/google-vertex-ai#troubleshooting>).
+
+###
+
+
+
+What differs from sessions on the Anthropic API
+
+A session that sends model requests to Amazon Bedrock or Google Cloud’s Agent Platform differs from a session on the Anthropic API in these ways:
+
+ * **Policy from claude.ai** : [server-managed settings](</docs/en/server-managed-settings>) don’t reach these sessions. Neither do the organization policies an Owner sets in Claude Code admin settings, so Claude Code doesn’t enforce them inside the session. Put the rules you rely on in the runner image’s [managed settings file](</docs/en/managed-settings#delivery-mechanisms>).
+ * **Files** : files that people attach to a session in claude.ai or the mobile or desktop app don’t reach it, and Claude can’t send files back with the [`SendUserFile` tool](</docs/en/tools-reference>). Put input files in the repository or on the runner instead.
+ * **Model selection** : Anthropic’s control plane sends each session’s model, and when a session starts without one, Claude Code uses its default for the provider. The runner removes `ANTHROPIC_MODEL` and `ANTHROPIC_DEFAULT_MODEL` from the environment it passes to sessions. The provider pages’ examples set `ANTHROPIC_MODEL`, but in the runner’s environment neither variable has any effect. The per-family variables in Pin model versions for [Amazon Bedrock](</docs/en/amazon-bedrock#4-pin-model-versions>) and [Agent Platform](</docs/en/google-vertex-ai#5-pin-model-versions>) do reach sessions. They decide what an alias such as `opus` resolves to, not what a full model ID resolves to.
+ * **Models your account doesn’t serve** : a session can fail on a message with an error that names the model. Enable the models your developers can choose, the background model described in Pin model versions, and the classifier model that [auto mode](</docs/en/permission-modes#enable-auto-mode-on-bedrock-agent-platform-or-foundry>) uses. On Amazon Bedrock, allow each of them in your policy.
+ * **Web search and fast mode** : [web search](</docs/en/tools-reference#websearch-tool-behavior>) isn’t available on Amazon Bedrock, and [fast mode](</docs/en/fast-mode>) isn’t available on either provider. For other capabilities that differ by provider, see [CLI capabilities that vary by provider](</docs/en/feature-availability#cli-capabilities-that-vary-by-provider>).
+
+##
+
+
+
MCP servers
To make [MCP servers](</docs/en/mcp>) available in every session, add them at image build time with the same `claude mcp add` command used on a desktop install. If your runner is a bare process rather than a container, run the same command as the runner’s user on the host, then restart the runner: it reads host config once at startup. The `--scope user` flag is required; the default local scope writes under a per-directory key that the runner doesn’t seed into sessions. For example, in your Dockerfile:
@@ -300,7 +381,7 @@
}
}
-A rule that names the whole server covers tools the server gains later too. To turn off one tool and keep the rest, append two more underscores and the tool name to each rule, as in `mcp__Claude_Code_Remote__add_repo`. To block the server from connecting at all rather than removing its tools, add the three names without the `mcp__` prefix as `serverName` entries under [`deniedMcpServers`](</docs/en/managed-mcp#policy-based-control-with-allowlists-and-denylists>) instead. Put the rules in [server-managed settings](</docs/en/server-managed-settings>) to reach every session with no change to the runner, or in `~/.claude/settings.json` on the runner. Permissions and tool approval explains how settings on the runner reach sessions. To confirm the rules took effect, start a session on the environment and ask Claude to list its MCP tools. Claude Code removes a denied tool from Claude’s context, so the denied tools are absent from its answer.
+A rule that names the whole server covers tools the server gains later too. To turn off one tool and keep the rest, append two more underscores and the tool name to each rule, as in `mcp__Claude_Code_Remote__add_repo`. To block the server from connecting at all rather than removing its tools, add the three names without the `mcp__` prefix as `serverName` entries under [`deniedMcpServers`](</docs/en/managed-mcp#policy-based-control-with-allowlists-and-denylists>) instead. Put the rules in [server-managed settings](</docs/en/server-managed-settings>) to reach sessions with no change to the runner, or in `~/.claude/settings.json` on the runner. On a runner that sends model requests to Bedrock or Agent Platform, use that file, because server-managed settings don’t reach those sessions. Permissions and tool approval explains how settings on the runner reach sessions. To confirm the rules took effect, start a session on the environment and ask Claude to list its MCP tools. Claude Code removes a denied tool from Claude’s context, so the denied tools are absent from its answer.
##
--- a/self-hosted-environments-deploy.md
+++ b/self-hosted-environments-deploy.md
@@ -54,6 +54,7 @@
`registry.npmjs.org`| 443| When a session installs a plugin, both for fetching npm-source plugin packages and for installing a plugin’s Node.js dependencies, or when an `npx`-launched MCP server runs
`http-intake.logs.us5.datadoghq.com`| 443| Anthropic operational metrics. Only when `CLAUDE_CODE_BYOC_ENABLE_DATADOG=1` is set; off by default in self-hosted environments.
`browser-intake-us5-datadoghq.com`| 443| Anthropic error-report uploads, sent only when [error reporting](</docs/en/data-usage#telemetry-services>) is enabled for the session’s account. Suppressed by `DISABLE_ERROR_REPORTING=1` or `DISABLE_TELEMETRY=1`.
+Your cloud provider’s endpoints for model requests, model lookups, and renewing credentials, such as `bedrock-runtime.us-east-1.amazonaws.com` or `aiplatform.googleapis.com`| 443| Only when the runner [sends model requests to Amazon Bedrock or Google Cloud’s Agent Platform](</docs/en/self-hosted-environments-configuration#send-model-requests-to-bedrock-or-agent-platform>)
The runner doesn’t reach `statsig.anthropic.com`, `*.sentry.io`, `claude.ai`, or `platform.claude.com`. These hosts appear in some older enterprise network checklists, but you don’t need to allowlist them for runner or session traffic: feature-flag fetches go to `api.anthropic.com`, and the runner authenticates with the environment secret rather than interactive OAuth. Two host-side flows do reach `claude.ai`, so run them from a host whose egress allows it rather than widening session-container egress: the one-line installer fetches `install.sh` from `claude.ai` at install time, and interactive `claude auth login`, which the [guided setup](</docs/en/self-hosted-environments-quickstart#set-up-an-environment-and-runner>), `doctor`’s signed-in mode, and [CI dispatch](</docs/en/self-hosted-environments-testing#authenticate-from-ci>) use, signs in through `claude.ai`, `claude.com`, and `platform.claude.com`. `mcp-proxy.anthropic.com` isn’t required either: self-hosted sessions don’t use it, and delivery of your organization’s claude.ai connectors to sessions, when enabled for your organization, routes through `api.anthropic.com`. See [MCP servers](</docs/en/self-hosted-environments-configuration#mcp-servers>).
Show diff (113 lines)
--- a/settings-reference.md
+++ b/settings-reference.md
@@ -127,7 +127,7 @@
`modelOverrides`| [Map model IDs](</docs/en/model-config#override-model-ids-per-version>) to your provider’s IDs, such as Bedrock ARNs| Model and responses| Any file
`modelPicker`| Choose which models the [`/model` picker](</docs/en/model-config#available-models>) lists, in your own order and with your own labels| Model and responses| User or managed
`modelPricing`| Report spend at your organization’s contracted rates instead of list price| Model and responses| Managed
-`modelSettings`| Keep a saved [effort level](</docs/en/model-config#adjust-effort-level>) per model, or cap one model’s effort| Model and responses| Any file
+`modelSettings`| Keep a saved [effort level](</docs/en/model-config#adjust-effort-level>) or [auto-compact window](</docs/en/model-config#set-the-auto-compact-window>) per model, or cap one model’s effort| Model and responses| Any file
`otelHeadersHelper`| Generate rotating [OpenTelemetry](</docs/en/monitoring-usage#dynamic-headers>) headers with your own command| Authentication and providers| Any file
`outputStyle`| Change Claude’s role, tone, and output format with an [output style](</docs/en/output-styles>)| Model and responses| Any file
`parentSettingsBehavior`| Apply or drop restrictions an [SDK or IDE host](</docs/en/managed-settings#let-an-embedding-host-add-policy>) passes when you deploy [managed settings](</docs/en/managed-settings>)| Enterprise and managed settings| Managed
@@ -701,7 +701,10 @@
Save an [effort level](</docs/en/model-config#adjust-effort-level>) for each model you use. Requires Claude Code v2.1.251 or later. In an interactive session on your machine, when you save `low`, `medium`, `high`, or `xhigh` as your default with `/effort` or the `/model` picker’s effort slider, Claude Code writes that level here under the model you’re using, so you rarely edit this key yourself. When you pick one of those levels in the [VS Code extension’s model picker](</docs/en/vs-code#use-the-prompt-box>), Claude Code saves it here the same way. The `effortLevel` entry lists the sessions where `/effort` applies to that session only. Edit the key by hand to change or remove a level you saved. A model’s `effortLevel` here takes precedence over the top-level `effortLevel` in the same settings file. Across files, Claude Code resolves each model separately: the highest-precedence [settings file](</docs/en/settings#settings-precedence>) that sets either an `effortLevel` for that model or a top-level `effortLevel` that applies to that model decides, so an `effortLevel` in managed settings outranks a level you saved in user settings. [Adjust effort level](</docs/en/model-config#adjust-effort-level>) lists what else can override a saved level, such as `--effort` at launch. To cap one model’s effort rather than set its level, add a `maxEffortLevel` field to that model’s entry. The field requires Claude Code v2.1.267 or later.
* **Scope** : `Any file`
- * **Type** : object mapping a model name to an object with an `effortLevel` field, one of `"low"`, `"medium"`, `"high"`, or `"xhigh"`, a `maxEffortLevel` field, or both
+ * **Type** : object mapping a model name to an object with any of these fields:
+ * `effortLevel`: one of `"low"`, `"medium"`, `"high"`, or `"xhigh"`
+ * `maxEffortLevel`: the highest effort level the model may run at
+ * `autoCompactWindow`: a number of tokens from `100000` to `1000000`, or `"auto"` for the window tuned for the model. [`/autocompact`](</docs/en/model-config#set-the-auto-compact-window>) saves here. For that model, the value takes precedence over a top-level `autoCompactWindow` in the same settings file. Requires Claude Code v2.1.288 or later
* **Default** : unset
Claude Code writes each entry under the model’s canonical name, such as `claude-opus-5-5`, and matches that model’s alias, date-suffixed, `[1m]`, and recognized provider-specific IDs to the same entry. This example keeps Opus 5.5 at `high` while other models use their own saved or default levels:
@@ -1931,7 +1934,7 @@
`sandbox.credentials.envVars`
-Protect environment variables from sandboxed commands. With `"mode": "deny"`, Claude Code removes the variable from the environment of sandboxed commands. With `"mode": "mask"`, sandboxed commands see a per-session sentinel value, and the sandbox proxy substitutes the real value on outbound requests to that entry’s `injectHosts`, so tools such as `gh` and `npm` keep authenticating without ever holding the real credential. `"mode": "mask"` requires Claude Code v2.1.199 or later.
+Protect environment variables from sandboxed commands. With `"mode": "deny"`, Claude Code removes the variable from the environment of sandboxed commands. With `"mode": "mask"`, sandboxed commands see a per-session sentinel value, and the sandbox proxy substitutes the real value on outbound requests to that entry’s `injectHosts`, so tools such as `gh` and `npm` keep authenticating without ever holding the real credential.
* **Scope** : `Any file`. Claude Code drops `mask` entries from project `.claude/settings.json` and local `.claude/settings.local.json`.
* **Type** : array of objects, each with `name` and a `mode` of `"deny"` or `"mask"`, plus the optional mask fields for environment variables
@@ -1952,7 +1955,7 @@
}
}
-The `name` must start with a letter or underscore and contain only letters, digits, and underscores. Claude Code merges the arrays from every settings scope the session loads, and applies `deny` when the same variable appears with both modes. [Protect credentials](</docs/en/sandboxing#protect-credentials>) covers what still applies from sources you exclude with `--setting-sources`. `mask` entries require Claude Code v2.1.199 or later. `mask` substitution runs only through the sandbox proxy, so set `sandbox.network.tlsTerminate`, or `allowPlaintextInject` for plain-HTTP test networks; see [Mask credentials](</docs/en/sandboxing#mask-credentials>). Claude Code accepts but ignores the `mask` fields on a `deny` entry.
+The `name` must start with a letter or underscore and contain only letters, digits, and underscores. Claude Code merges the arrays from every settings scope the session loads, and applies `deny` when the same variable appears with both modes. [Protect credentials](</docs/en/sandboxing#protect-credentials>) covers what still applies from sources you exclude with `--setting-sources`. `mask` substitution runs only through the sandbox proxy, so set `sandbox.network.tlsTerminate`, or `allowPlaintextInject` for plain-HTTP test networks; see [Mask credentials](</docs/en/sandboxing#mask-credentials>). Claude Code accepts but ignores the `mask` fields on a `deny` entry.
####
@@ -1968,7 +1971,7 @@
`onExtractNoMatch`| `"warn"`, `"deny"`, or `"error"`; default `"warn"`. On an entry with `decode`, only `"warn"` is accepted| What happens when `extract` matches nothing. `warn` passes the variable through unmasked, `deny` unsets it inside the sandbox, and `error` stops sandbox setup until you fix the configuration. Requires v2.1.224 or later
`decode`| the string `"jwt"`| Verify the whole value is a JWT and replace it with a structurally valid fake token, so code inside the sandbox that decodes the token keeps working; the proxy substitutes the whole real token on egress. A value that doesn’t verify passes through unmasked with a warning. Requires v2.1.224 or later
`maskClaims`| array of strings, at least one claim name; requires `decode`| Mask only the named top-level payload claims inside the decoded JWT and rebuild the token around the modified payload, so the other claims stay readable. When no named claim matches, the variable passes through unmasked with a warning. Requires v2.1.224 or later
-`injectHosts`| array of strings, each a host that `sandbox.network.allowedDomains` also admits| Narrow the hosts where the sandbox proxy substitutes the real value. When unset, the proxy substitutes it on requests to every host in `sandbox.network.allowedDomains`. Write an IPv6 destination as the bare compressed address, such as `"::1"`, not the bracketed form; see [IPv6 destinations in `injectHosts`](</docs/en/sandboxing#ipv6-destinations-in-injecthosts>). Requires v2.1.199 or later
+`injectHosts`| array of strings, each a host that `sandbox.network.allowedDomains` also admits| Narrow the hosts where the sandbox proxy substitutes the real value. When unset, the proxy substitutes it on requests to every host in `sandbox.network.allowedDomains`. Write an IPv6 destination as the bare compressed address, such as `"::1"`, not the bracketed form; see [IPv6 destinations in `injectHosts`](</docs/en/sandboxing#ipv6-destinations-in-injecthosts>)
This masks only the password inside `DATABASE_URL`, unsets the variable if the pattern matches nothing, and masks a JWT in `SERVICE_JWT` while leaving every claim except `api_key` readable:
@@ -2001,7 +2004,7 @@
`sandbox.credentials.allowPlaintextInject`
-Allow `mask` substitution on plain HTTP requests as well as TLS-terminated HTTPS. On plain HTTP the upstream identity is unverified and the credential travels in cleartext, so leave this off outside trusted test networks. Requires Claude Code v2.1.199 or later.
+Allow `mask` substitution on plain HTTP requests as well as TLS-terminated HTTPS. On plain HTTP the upstream identity is unverified and the credential travels in cleartext, so leave this off outside trusted test networks.
* **Scope** : `User or managed`
* **Type** : Boolean
@@ -2018,8 +2021,6 @@
}
}
}
-
-Requires Claude Code v2.1.199 or later.
###
@@ -2388,7 +2389,7 @@
}
}
-When more than one honored source sets it, Claude Code uses the value from the highest-precedence source: managed settings, then the `--settings` flag, then user settings. Requires Claude Code v2.1.199 or later.
+When more than one honored source sets it, Claude Code uses the value from the highest-precedence source: managed settings, then the `--settings` flag, then user settings.
##
@@ -2440,7 +2441,7 @@
"autoCompactWindow": 500000
}
-Set it with the [`/autocompact`](</docs/en/commands#all-commands>) command, which writes this key to your user settings. [Set the auto-compact window](</docs/en/model-config#set-the-auto-compact-window>) covers how the command, flag, variable, and setting interact.
+The [`/autocompact`](</docs/en/commands#all-commands>) command saves a window for the current model under `modelSettings`, which takes precedence over this key in the same file for that model. [Set the auto-compact window](</docs/en/model-config#set-the-auto-compact-window>) covers how the command, flag, variable, and setting interact.
###
@@ -2722,7 +2723,7 @@
`askUserQuestionTimeout`
-Let an unanswered [`AskUserQuestion`](</docs/en/tools-reference>) dialog auto-continue after a period of idle time, submitting whatever options you had already selected. Set it when you step away and want Claude to continue without you. With the default, questions wait until you answer them. Requires Claude Code v2.1.200 or later.
+Let an unanswered [`AskUserQuestion`](</docs/en/tools-reference>) dialog auto-continue after a period of idle time, submitting whatever options you had already selected. Set it when you step away and want Claude to continue without you. With the default, questions wait until you answer them. For when the timer pauses or never starts, see [Question auto-continue timeout](</docs/en/tools-reference#question-auto-continue-timeout>). Requires Claude Code v2.1.200 or later.
* **Scope** : `User or managed`
* **Type** : string, one of `"60s"`, `"5m"`, `"10m"`, or `"never"`
@@ -4411,7 +4412,7 @@
Rule| `strictKnownMarketplaces`| `blockedMarketplaces`
---|---|---
Matching source spellings| `owner/repo` form only. A git URL that clones the same repository doesn’t match| Any spelling, including git URLs that resolve to the same github.com repository
-Owner case| Case-sensitive, like exact-entry matching| Case-insensitive
+Owner case| Case-sensitive| Case-insensitive
`ref`| Follows the exact-entry rules: an entry with a `ref` matches only sources with that exact ref, and an entry without one matches only sources that don’t specify a ref| An entry without a `ref` blocks all refs of the repositories it matches
`path`| Looser than the exact-entry rules: an entry with a `path` requires that exact value, while an entry without one matches any path inside the repository| An entry without a `path` blocks all paths of the repositories it matches
@@ -5270,7 +5271,7 @@
`worktree.bgIsolation`
-Choose how [background sessions](</docs/en/agent-view#how-file-edits-are-isolated>) isolate their file edits. With `"worktree"`, Claude Code blocks `Edit` and `Write` in the main checkout until the session calls `EnterWorktree`; with `"none"`, background jobs edit the working copy directly. Set `"none"` for a repository where git worktrees are impractical.
+Choose how [background sessions](</docs/en/agent-view#how-file-edits-are-isolated>) isolate their file edits. If you moved a session to the background with `←` or `/background`, that session edits files in place whatever this key says. With `"worktree"`, Claude Code blocks `Edit` and `Write` in the main checkout until the session calls `EnterWorktree`; with `"none"`, background jobs edit the working copy directly. Set `"none"` for a repository where git worktrees are impractical.
* **Scope** : `Any file`
* **Type** : string, one of:
--- a/setup.md
+++ b/setup.md
@@ -183,7 +183,7 @@
"autoUpdatesChannel": "stable"
}
-For enterprise deployments, you can enforce a consistent release channel across your organization using [managed settings](</docs/en/managed-settings>). Homebrew installations choose a channel by cask name instead of this setting: `claude-code` tracks stable and `claude-code@latest` tracks latest.
+A newly launched model can require a Claude Code version newer than the stable channel serves. To run the model now, move to the latest channel. For enterprise deployments, you can enforce a consistent release channel across your organization using [managed settings](</docs/en/managed-settings>). Homebrew installations choose a channel by cask name instead of this setting: `claude-code` tracks stable and `claude-code@latest` tracks latest. Installations from the apt, dnf, and apk repositories choose a channel by repository instead of this setting. To switch one, follow Install with Linux package managers.
###
--- a/sub-agents.md
+++ b/sub-agents.md
@@ -192,7 +192,7 @@
For security reasons, plugin subagents don’t support the `hooks`, `mcpServers`, or `permissionMode` frontmatter fields. These fields are ignored when loading agents from a plugin. If you need them, copy the agent file into `.claude/agents/` or `~/.claude/agents/`. You can also add rules to [`permissions.allow`](</docs/en/settings-reference#permissions-allow>) in `settings.json` or `settings.local.json`, but these rules apply to the entire session, not only the plugin subagent.If you’re the plugin’s author, ship the hooks in the plugin’s [`hooks/hooks.json`](</docs/en/plugins/components#hooks>) and the MCP servers in its [`.mcp.json`](</docs/en/plugins/components#mcp-servers>) instead. They apply whenever the plugin is enabled rather than only inside the subagent.
-Subagent definitions from any of these scopes are also available to [agent teams](</docs/en/agent-teams#use-subagent-definitions-for-teammates>): when spawning a teammate, you can reference a subagent type, and Claude Code applies parts of that definition to the teammate. See [agent teams](</docs/en/agent-teams#use-subagent-definitions-for-teammates>) for which parts apply in each display mode.
+You can also reuse a subagent definition as an [agent team](</docs/en/agent-teams>) teammate: name the subagent type when you ask Claude to spawn the teammate, and Claude Code applies parts of that definition to it. [Use subagent definitions for teammates](</docs/en/agent-teams#use-subagent-definitions-for-teammates>) says which scopes and which parts apply in each display mode.
###
@@ -807,7 +807,7 @@
API errors in subagents
-When something [cuts off a subagent’s response mid-stream](</docs/en/errors#the-response-above-may-be-incomplete>), and the partial response contains text but no tool calls, Claude Code prompts the subagent to continue rather than ending the run. This happens in interactive sessions too. The run ends on the error only once those continuations are used up. As of v2.1.199, a subagent whose run ends on an API error, such as a usage limit or a repeated server error, reports that failure back to Claude instead of returning the error text as if it were the subagent’s findings. What Claude receives depends on where the subagent ran:
+When something [cuts off a subagent’s response mid-stream](</docs/en/errors#the-response-above-may-be-incomplete>), and the partial response contains text but no tool calls, Claude Code prompts the subagent to continue rather than ending the run. This happens in interactive sessions too. The run ends on the error only once those continuations are used up. A subagent whose run ends on an API error, such as a usage limit or a repeated server error, reports that failure back to Claude. What Claude receives depends on where the subagent ran:
* **Foreground** : if a rate limit, overload, or server error cuts off a subagent that already produced text output, the Agent tool returns that partial output with a note that the subagent was cut off and didn’t finish its task. A subagent that produced nothing, or whose only output was tool calls, fails with [`Agent terminated early due to an API error`](</docs/en/errors#agent-terminated-early-due-to-an-api-error>), followed by the error detail. In v2.1.199, a rate limit, overload, or server error that cut off the tool-calls-only shape returned an empty partial result containing only the cut-off note instead.
* **Background** : the subagent is marked failed, and the message Claude receives when it ends names the API error and includes the subagent’s last output, so partial work isn’t lost.
@@ -973,7 +973,7 @@
Continue that code review and now analyze the authorization logic
[Claude resumes the subagent with full context from previous conversation]
-When Claude sends a completed subagent a message with the `SendMessage` tool, the subagent resumes in the background without a new `Agent` invocation. The same applies to a subagent that Claude stopped with the `TaskStop` tool, once its stopped run has exited. The resumed run keeps the tool set from where the subagent first ran and can keep reading the [prompt cache the original run warmed](</docs/en/prompt-caching#subagents-and-the-cache>). A subagent that has the `SendMessage` tool can send that message too. In an interactive session, the resumed agent then reports back to the subagent that resumed it, not to your main conversation. That subagent waits for the result before finishing its own work. When a subagent messages an agent it reports to, such as its own launcher, Claude Code resumes that agent without redirecting its results. A subagent you stopped yourself, with `x` in `/tasks` or an SDK `stop_task` request, doesn’t auto-resume. If Claude sends it a message, the message is refused and Claude is told the agent was cancelled. While that subagent’s row is still in the subagent panel, type into its transcript to resume it yourself. After that, a message from Claude can auto-resume it again. Resuming starts a new run of the agent under the same ID, so a subagent that had already failed or completed shows as running again in the task list and in the Agent SDK’s task events. Before v2.1.205, it kept showing its earlier failed or completed status while the resumed run was working. As of v2.1.199, `SendMessage` checks that a name still refers to the same agent it reached earlier in the conversation. If a newer agent has taken the name, such as a re-spawned background agent that reused it, Claude Code refuses the send rather than delivering it to the wrong agent, and the error reports which agent the name now reaches so Claude can retarget. To reach the earlier agent while it’s still running, Claude addresses it by the agent ID it received when it spawned that agent. The check is scoped to the current conversation and resets on `/clear`. A subagent treats messages from the agent that launched it as normal task direction, including mid-task course corrections, and acts on them within its own permission settings. Two limits hold regardless of who sent the message: no message from any agent counts as your approval for a pending permission prompt, and no agent message can change a subagent’s permission settings, `CLAUDE.md`, or configuration. Only the permission system or your own messages can grant approval. You can also ask Claude for the agent ID if you want to reference it explicitly, or find IDs in the transcript files at `~/.claude/projects/{project}/{sessionId}/subagents/`. Each transcript is stored as `agent-{agentId}.jsonl`. Subagent transcripts persist independently of the main conversation:
+When Claude sends a completed subagent a message with the `SendMessage` tool, the subagent resumes in the background without a new `Agent` invocation. The same applies to a subagent that Claude stopped with the `TaskStop` tool, once its stopped run has exited. The resumed run keeps the tool set from where the subagent first ran and can keep reading the [prompt cache the original run warmed](</docs/en/prompt-caching#subagents-and-the-cache>). A subagent that has the `SendMessage` tool can send that message too. In an interactive session, the resumed agent then reports back to the subagent that resumed it, not to your main conversation. That subagent waits for the result before finishing its own work. When a subagent messages an agent it reports to, such as its own launcher, Claude Code resumes that agent without redirecting its results. A subagent you stopped yourself, with `x` in `/tasks` or an SDK `stop_task` request, doesn’t auto-resume. If Claude sends it a message, the message is refused and Claude is told the agent was cancelled. While that subagent’s row is still in the subagent panel, type into its transcript to resume it yourself. After that, a message from Claude can auto-resume it again. Resuming starts a new run of the agent under the same ID, so a subagent that had already failed or completed shows as running again in the task list and in the Agent SDK’s task events. Before v2.1.205, it kept showing its earlier failed or completed status while the resumed run was working. `SendMessage` checks that a name still refers to the same agent it reached earlier in the conversation. If a newer agent has taken the name, such as a re-spawned background agent that reused it, Claude Code refuses the send rather than delivering it to the wrong agent, and the error reports which agent the name now reaches so Claude can retarget. To reach the earlier agent while it’s still running, Claude addresses it by the agent ID it received when it spawned that agent. The check is scoped to the current conversation and resets on `/clear`. A subagent treats messages from the agent that launched it as normal task direction, including mid-task course corrections, and acts on them within its own permission settings. Two limits hold regardless of who sent the message: no message from any agent counts as your approval for a pending permission prompt, and no agent message can change a subagent’s permission settings, `CLAUDE.md`, or configuration. Only the permission system or your own messages can grant approval. You can also ask Claude for the agent ID if you want to reference it explicitly, or find IDs in the transcript files at `~/.claude/projects/{project}/{sessionId}/subagents/`. Each transcript is stored as `agent-{agentId}.jsonl`. Subagent transcripts persist independently of the main conversation:
* **Main conversation compaction** : when the main conversation compacts, subagent transcripts are unaffected. They’re stored in separate files.
* **Session persistence** : subagent transcripts persist within their session. You can resume a subagent after restarting Claude Code by resuming the same session.
--- a/tool-search.md
+++ b/tool-search.md
@@ -34,7 +34,7 @@
`auto:N`| Same as `auto` with a custom percentage. `auto:5` activates when those definitions reach 5% of the context window. Lower values activate sooner.
`false`| Tool search is off. All tool definitions are loaded into context on every turn.
-Setting [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS`](</docs/en/env-vars>) keeps tool search off. You can’t override it by setting `ENABLE_TOOL_SEARCH` yourself. Your organization can keep tool search on through [managed settings](</docs/en/managed-settings>), on Claude Code v2.1.227 or later. [Disable pre-release capabilities](</docs/en/llm-gateway-protocol#disable-pre-release-capabilities>) covers where the override applies and what the variable strips. Tool search applies to all registered tools, whether they come from remote MCP servers or [custom SDK MCP servers](</docs/en/agent-sdk/custom-tools>). When you use `auto`, the SDK counts every definition that tool search can defer toward one combined threshold: each MCP tool that isn’t marked [`alwaysLoad`](</docs/en/mcp#exempt-a-server-from-deferral>), from any server, plus the built-in tools that load on demand. The SDK always loads core built-in tools such as Bash, Read, and Edit upfront and doesn’t count them toward the threshold. Set the value in the `env` option on `query()`. In TypeScript, `env` replaces the subprocess environment, so spread `...process.env` to keep inherited variables. In Python, `env` is merged on top of the inherited environment. This example connects to a remote MCP server that exposes many tools, pre-approves all of them with a wildcard, and uses `auto:5` so tool search activates when the definitions it can defer reach 5% of the context window:
+Setting [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS`](</docs/en/env-vars>) keeps tool search off. You can’t override it by setting `ENABLE_TOOL_SEARCH` yourself. Your organization can keep tool search on through [managed settings](</docs/en/managed-settings>), on Claude Code v2.1.227 or later. [Disable pre-release capabilities](</docs/en/llm-gateway-protocol#disable-pre-release-capabilities>) covers where the override applies and what the variable strips. Tool search applies to all registered tools, whether they come from remote MCP servers or [custom SDK MCP servers](</docs/en/agent-sdk/custom-tools>). When you use `auto`, the SDK counts every definition that tool search can defer toward one combined threshold: each MCP tool that isn’t marked [`alwaysLoad`](</docs/en/mcp#exempt-a-server-from-deferral>), from any server, plus the built-in tools that load on demand. The SDK loads core built-in tools such as Bash, Read, and Edit upfront and doesn’t count them toward the threshold. A [mod](</docs/en/plugins/mods/reference#tools>) in one of your plugins can also defer a tool or load it upfront, which changes that count. Set the value in the `env` option on `query()`. In TypeScript, `env` replaces the subprocess environment, so spread `...process.env` to keep inherited variables. In Python, `env` is merged on top of the inherited environment. This example connects to a remote MCP server that exposes many tools, pre-approves all of them with a wildcard, and uses `auto:5` so tool search activates when the definitions it can defer reach 5% of the context window:
TypeScript
--- a/tools-reference.md
+++ b/tools-reference.md
@@ -114,7 +114,7 @@
Question auto-continue timeout
-Questions stay open until you answer them. If you want a question you leave unanswered to eventually close and let Claude continue without you, set the [`askUserQuestionTimeout`](</docs/en/settings-reference#askuserquestiontimeout>) setting to `60s`, `5m`, or `10m`, either in your user `settings.json` or from the **Question auto-continue timeout** row in `/config`. After a question sits that long with no input, the dialog closes on its own: it submits any options you’d already selected and tells Claude you may be away from your keyboard, so Claude proceeds on its own judgment and can re-ask later. You see a countdown for the last 20 seconds. Press any key to restart the timer; on terminals that report focus, switching to the window restarts it too. The timeout applies only to `AskUserQuestion`’s multiple-choice questions; permission prompts, including plan approval, never auto-resolve on idle.
+Questions stay open until you answer them. If you want a question you leave unanswered to eventually close and let Claude continue without you, set the [`askUserQuestionTimeout`](</docs/en/settings-reference#askuserquestiontimeout>) setting to `60s`, `5m`, or `10m`, either in your user `settings.json` or from the **Question auto-continue timeout** row in `/config`. After a question sits that long with no input, the dialog closes on its own: it submits any options you’d already selected and tells Claude you may be away from your keyboard, so Claude proceeds on its own judgment and can re-ask later. You see a countdown for the last 20 seconds. Press any key to restart the timer. While your terminal reports that its window is focused, the timer doesn’t count down. The timer never starts for a question Claude asks in a [background session](</docs/en/agent-view>), in [screen reader mode](</docs/en/accessibility>), or while the session is connected to [Remote Control](</docs/en/remote-control>). Those questions wait until you answer them. The timeout applies only to `AskUserQuestion`’s multiple-choice questions; permission prompts, including plan approval, never auto-resolve on idle.
##
@@ -150,7 +150,7 @@
* `BASH_DEFAULT_TIMEOUT_MS` — the default when Claude passes no timeout; two minutes out of the box
* `BASH_MAX_TIMEOUT_MS` — with the default, sets the ceiling that caps whatever Claude requests: the effective ceiling is the larger of the two, ten minutes out of the box
-For a command that Claude starts in the background, `timeout` instead sets how long the command may run there, with the separate default and maximum described under Time limit for background commands. The PowerShell tool follows the same timeout rules and reads the same two variables.
+In a session that has a time limit for background commands, `timeout` on a command that Claude starts in the background instead sets how long the command may run there, with that limit’s separate default and maximum. The PowerShell tool follows the same timeout rules and reads the same two variables.
####
@@ -189,10 +189,10 @@
Time limit for background commands
-Background Bash and PowerShell commands have a time limit, counted from the moment the command enters the background:
+In a session that runs unattended, such as a run with the `-p` flag, an Agent SDK application, a CI job, or a cloud session, background Bash and PowerShell commands have a time limit. A local session you work in from a terminal, the desktop app, or the VS Code extension has no time limit on background commands. The time limit requires Claude Code v2.1.285 or later. Before v2.1.288, it applied in every session. The time limit counts from the moment the command enters the background:
* A command that Claude starts in the background gets 30 minutes, or the `timeout` Claude passes with `run_in_background`, up to a maximum of 2 hours
- * A command that starts in the foreground and then moves to the background, for example with `Ctrl+B` or at its timeout, gets 30 minutes from the move
+ * A command that starts in the foreground and then moves to the background, for example at its timeout, gets 30 minutes from the move
When a background command reaches its time limit, Claude Code stops it and tells Claude why, and Claude can start the command again with a longer `timeout` if the work still needs it. The stop notice reads `Background command "<description>" was stopped after reaching its background time limit`.
--- a/typescript.md
+++ b/typescript.md
@@ -265,7 +265,7 @@
`options.version`| `string`| Optional version string
`options.instructions`| `string`| Optional server instructions, returned from `initialize` and surfaced to the model as an MCP instructions block
`options.tools`| `Array<SdkMcpToolDefinition>`| Array of tool definitions created with `tool()`
-`options.alwaysLoad`| `boolean`| When `true`, every tool from this server stays in the initial prompt and is never deferred behind [tool search](</docs/en/agent-sdk/tool-search>). Combines with per-tool `alwaysLoad` in `tool()`
+`options.alwaysLoad`| `boolean`| When `true`, every tool from this server stays in the initial prompt instead of being deferred behind [tool search](</docs/en/agent-sdk/tool-search>). Combines with per-tool `alwaysLoad` in `tool()`
`options.timeout`| `number`| Timeout in milliseconds for this server’s tool calls. Claude Code applies it to this server in place of [`MCP_TOOL_TIMEOUT`](</docs/en/env-vars>). Pass a whole number of at least 1000. Claude Code ignores other values. Requires TypeScript Agent SDK v0.3.248 or later
###
@@ -2008,7 +2008,7 @@
Stream event emitted when the permission system denies a tool call without an interactive prompt. Use it to render the denial in your UI as it happens, rather than only observing the `is_error` tool result that follows. Which denials it reports depends on how the run handles permission prompts:
* **With a`canUseTool` callback** and the default `permissionPrompts: 'host'`: permission prompts go to your callback, and this event reports the denials Claude Code decides on its own without calling it.
- * **With neither** : a bare `-p` run, or `query()` that sets neither `canUseTool` nor `permissionPromptToolName`, denies any tool call that would have prompted, and this event reports those denials as well as the ones Claude Code decides on its own. Before v2.1.223, Claude Code didn’t emit this event in runs without a callback.
+ * **With neither** : a bare `-p` run, or `query()` that sets neither `canUseTool` nor `permissionPromptToolName`, denies any tool call that would have prompted unless a [`PermissionRequest` hook](</docs/en/hooks-guide#limitations>) allows it, and this event reports those denials as well as the ones Claude Code decides on its own. Before v2.1.223, Claude Code didn’t emit this event in runs without a callback.
* **With an MCP prompt tool** , set with `permissionPromptToolName` or the [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>) flag, and the default `permissionPrompts: 'host'`: Claude Code doesn’t emit this event at all, not even for the rule denials it decides on its own.
* **With`permissionPrompts: 'none'`**: Claude Code denies the calls that would have prompted, even when `canUseTool` or an MCP prompt tool is also set, and this event reports those denials as well as the ones Claude Code decides on its own. Requires Claude Code v2.1.259 or later.
--- a/ultrareview.md
+++ b/ultrareview.md
@@ -100,18 +100,12 @@
---|---|---
Pro| 3 free runs| billed as [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>)
Max| 3 free runs| billed as [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>)
-Team and Enterprise| none| billed as [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>)
* **Free runs** : the three Pro and Max runs are a one-time allotment per account and don’t refresh.
* **Cost per review** : after you use the free runs, typically $5 to $25 in usage credits depending on the size of the change, matching the estimate the launch dialog shows before each run.
* **When a run counts** : once the cloud session starts. A review you stop early or that fails to complete still uses a free run; a paid review bills only for the portion that ran.
-Because ultrareview always bills as usage credits outside the free runs, your account or organization must have usage credits turned on before you can launch a paid review. If usage credits aren’t turned on, Claude Code blocks the launch, and how you turn them on depends on your billing access:
-
- * If you can manage billing for your account, Claude Code links you to the billing settings where you can turn on usage credits.
- * On Team and Enterprise plans, members without billing access send a request from the CLI asking their admin to turn on usage credits.
-
-You can also run `/usage-credits` to check or change your usage-credits setting. Claude Code asks you to confirm usage-credits billing once per conversation: when you start a new conversation, for example with `/clear`, Claude Code shows the confirmation again for the next paid review.
+Because ultrareview always bills as usage credits outside the free runs, your account or organization must have usage credits turned on before you can launch a paid review. If usage credits aren’t turned on, Claude Code blocks the launch. If you can manage billing for your account, Claude Code links you to the billing settings where you can turn on usage credits. You can also run `/usage-credits` to check or change your usage-credits setting. Claude Code asks you to confirm usage-credits billing once per conversation: when you start a new conversation, for example with `/clear`, Claude Code shows the confirmation again for the next paid review.
##
--- a/voice-dictation.md
+++ b/voice-dictation.md
@@ -150,7 +150,8 @@
Common issues when voice dictation does not activate or record:
- * **`Voice mode requires a Claude.ai account`** : you are authenticated with an API key or a third-party provider. Run `/login` to sign in with a claude.ai account.
+ * **`Unknown command: /voice`** : `/voice` is available only while a claude.ai account is your active sign-in. If you aren’t signed in with one, run `/login`. If `ANTHROPIC_API_KEY`, `ANTHROPIC_AUTH_TOKEN`, an `apiKeyHelper` setting, or a third-party provider is in use, it takes precedence over a claude.ai sign-in, so remove it and restart Claude Code.
+ * **`Voice mode requires a Claude.ai account`** : Claude Code couldn’t find a usable claude.ai sign-in when you ran `/voice` or started recording. Run `/login` to sign in again.
* **`Voice mode is disabled by your organization's policy`** : an administrator policy for your organization turns off voice dictation. Contact your organization administrator to confirm whether voice dictation is available for your organization.
* **`Microphone access is denied`** : grant microphone permission to your terminal in system settings. On macOS, go to System Settings → Privacy & Security → Microphone and enable your terminal app, then run `/voice` again. On Windows, go to Settings → Privacy & security → Microphone and turn on microphone access for desktop apps, then run `/voice` again. If your terminal isn’t listed in the macOS settings, see Terminal not listed in macOS Microphone settings.
* **`Voice mode requires SoX for audio recording` on Linux**: the native audio module could not load and no fallback is installed. Install SoX with the command shown in the error message, for example `sudo apt-get install sox`.
--- a/vs-code.md
+++ b/vs-code.md
@@ -599,7 +599,7 @@
Move a running command or subagent to the background
-When Claude is waiting on a command or a [subagent](</docs/en/sub-agents>) that is taking longer than you want, click **Run in background** below its tool call in the conversation. The action appears once a command has been running for about two seconds, or as soon as a subagent starts. Claude stops waiting and continues the turn, while the command or subagent keeps running as a [background task](</docs/en/tools-reference#background-commands>) that notifies Claude when it finishes. Requires Claude Code v2.1.287 or later. To check on the task or stop it in the meantime, type `/tasks` in the prompt box to open the agent map. A subagent keeps its place in the tree of agents there, and a command is listed below the agents with its latest output on its card. A command you move to the background this way is subject to the [time limit for background commands](</docs/en/tools-reference#time-limit-for-background-commands>).
+When Claude is waiting on a command or a [subagent](</docs/en/sub-agents>) that is taking longer than you want, click **Run in background** below its tool call in the conversation. The action appears once a command has been running for about two seconds, or as soon as a subagent starts. Claude stops waiting and continues the turn, while the command or subagent keeps running as a [background task](</docs/en/tools-reference#background-commands>) that notifies Claude when it finishes. Requires Claude Code v2.1.287 or later. To check on the task or stop it in the meantime, type `/tasks` in the prompt box to open the agent map. A subagent keeps its place in the tree of agents there, and a command is listed below the agents with its latest output on its card.
###
--- a/workflows.md
+++ b/workflows.md
@@ -190,8 +190,8 @@
* **Permission rule** : `Workflow` in your allow rules approves every workflow, and `Workflow(<name>)` approves one saved workflow by name.
* **Auto permission mode** : the [classifier](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) reviews the call and can approve it.
* **Bypass permissions mode** : Claude Code approves the call.
- * **A`PreToolUse` hook**: a [hook](</docs/en/hooks#pretooluse>) that returns `allow` for the call approves it.
- * **Your host** : a [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>) approves it, or, with the Agent SDK, a [`canUseTool`](</docs/en/agent-sdk/permissions>) callback or a [`PermissionRequest` hook](</docs/en/hooks#permissionrequest>) approves it.
+ * **A hook** : a [`PreToolUse`](</docs/en/hooks#pretooluse>) hook that allows the call approves it.
+ * **Your host** : a [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>) or, with the Agent SDK, a [`canUseTool`](</docs/en/agent-sdk/permissions>) callback approves it.
In the Desktop app, an approval card shows the workflow name, the phase list, and a token-usage caution, with **Once** , **Always** , and **Deny** actions. The progress view appears in the Background tasks side pane. The subagents the workflow spawns use your [permission rules](</docs/en/settings-reference#permission-settings>), and Claude Code picks their permission mode by the rules under [which permission mode a subagent runs in](</docs/en/sub-agents#permission-modes>). To avoid prompts on a long run, add the tools the agents need to your allow rules before starting.