Changes on
95 changes detected
--- a/admin.md
+++ b/admin.md
@@ -11,7 +11,7 @@
## Stop user-installed mods from loading
-To keep every mod your users bring from running its hooks, set the `allowManagedModsOnly` option on the built-in guard, a policy mod that Claude Code loads ahead of every mod a user installs. The option goes in managed settings under `pluginConfigs`, keyed by `cc-plugin-sec-default@builtin`:
+To refuse users’ mods, set the `allowManagedModsOnly` option on the built-in guard, a policy mod that Claude Code loads ahead of every mod a user installs. The option goes in managed settings under `pluginConfigs`, keyed by `cc-plugin-sec-default@builtin`:
managed-settings.json
@@ -27,7 +27,7 @@
With the option set in managed settings:
- * **No mod a user brings runs its hooks** : that covers a mod in a plugin the user installed, a mod loaded with `--plugin-dir`, and a mod [Claude wrote during a session](</docs/en/plugins/mods/create#ask-claude-for-a-mod>)
+ * **The guard refuses these mods** : a mod in a plugin only the user enabled, a mod loaded with `--plugin-dir`, and a mod [Claude wrote during a session](</docs/en/plugins/mods/create#ask-claude-for-a-mod>)
* **Your organization’s mods still run** : a mod that counts as your organization’s isn’t checked. Every other mod counts as a user’s and is refused. That includes a mod your organization turns on for its members on claude.ai. If none counts as yours, no installed mod runs its hooks.
* **Claude Code ignores the option in other settings files** : if someone sets it in a user, project, local, or `--settings` file, your value still applies
* **A file or MDM policy covers every provider** : when you deliver the option as a file or through MDM, it works the same way on Amazon Bedrock, Google Cloud’s Agent Platform, and Microsoft Foundry. For delivery from the claude.ai admin console, see [Platform availability](</docs/en/server-managed-settings#platform-availability>)
@@ -162,7 +162,7 @@
What you want| Settings
---|---
-No installed mod runs, with settings hooks untouched| Set `allowManagedModsOnly` and deploy no mods of your own
+No installed mod runs, with settings hooks untouched| In managed settings, set `allowManagedModsOnly` and don’t enable a plugin that contains a mod
No installed mods and no hooks at all, your managed hooks included| Set `disableAllHooks` to `true`
Only your organization’s mods| Set the guard’s `allowManagedModsOnly` option, and install your mods so that they count as yours
Any mod from marketplaces you approve outside claude.ai| Set a [marketplace allowlist](</docs/en/plugins/org#restrict-what-users-can-install>) without `skills-dir`, set `disableSideloadFlags` to `true`, and set [`syncClaudeAiPlugins`](</docs/en/settings-reference#syncclaudeaiplugins>) to `false`
@@ -222,7 +222,7 @@
* **Give one group a different policy, such as a pilot** : [Plan for what managed settings can’t enforce](</docs/en/plugins/org#plan-for-what-managed-settings-can%E2%80%99t-enforce>)
* **Check which apps and session kinds apply the plugin keys** : [When each surface applies the plugin keys](</docs/en/plugins/org#when-each-surface-applies-the-plugin-keys>)
* **Set up CI and containers** : [Seed containers and CI](</docs/en/plugins/org#seed-containers-and-ci>)
- * **Offer mods your users may install** : [Host a marketplace](</docs/en/plugins/host-marketplace>). A mod that Claude Code copies from a GitHub, git, URL, or npm source counts as a user’s unless you install it as your organization’s.
+ * **Offer mods your users may install** : [Host a marketplace](</docs/en/plugins/host-marketplace>)
### Set options on the built-in guard
@@ -285,7 +285,7 @@
]
}
-An installed plugin that meets neither set of conditions counts as a user’s, even when managed `enabledPlugins` enables it. Its mod runs among users’ mods, `prependPlugins` and `appendPlugins` skip it, `allowManagedModsOnly` refuses it, and `allowManagedHooksOnly` keeps it from loading. When managed settings enable it, the user’s debug log has a line that starts with the plugin’s id and `is enabled by managed settings, but`. Claude Code fires an event each time it’s about to act, such as run a tool, and passes it to each mod in turn. A mod that meets the directory conditions [runs before users’ mods](</docs/en/plugins/mods/events#the-order-mods-run-in>) even when you list it nowhere. To set its place, list its id in one of two settings. The id is the plugin’s name, `@`, and the marketplace’s name, such as `acme-guard@acme-tools`.
+A plugin you enable in managed `enabledPlugins` can still count as a user’s, as a directory plugin that misses a condition does. Its mod then runs among users’ mods, `prependPlugins` and `appendPlugins` skip it, `allowManagedModsOnly` refuses it, and `allowManagedHooksOnly` keeps it from loading. To see why, search the user’s debug log for a line that starts with the plugin’s id and `is enabled by managed settings, but`. Claude Code fires an event each time it’s about to act, such as run a tool, and passes it to each mod in turn. A mod that meets the directory conditions [runs before users’ mods](</docs/en/plugins/mods/events#the-order-mods-run-in>) even when you list it nowhere. To set its place, list its id in one of two settings. The id is the plugin’s name, `@`, and the marketplace’s name, such as `acme-guard@acme-tools`.
* **`prependPlugins`** : your mod sees an event before any user’s mod, and the event’s result after them. It can change the event, refuse it, or skip the users’ mods. On v2.1.323 or later, check that your hooks still [reach other mods’ controls and drawings](</docs/en/plugins/mods/events#hook-other-mods-drawings-and-controls>).
* **`appendPlugins`** : your mod runs after every user’s mod, so it sees only the events those mods pass on, in the form they pass them
--- a/agent-teams.md
+++ b/agent-teams.md
@@ -67,7 +67,7 @@
Agent teams support two display modes:
- * **In-process** : all teammates run inside your main terminal. Use the up and down arrow keys in the agent panel to select a teammate, then press Enter to view it and type to message it directly. Works in any terminal, no extra setup required.
+ * **In-process** : all teammates run inside your main terminal. Use the up and down arrow keys in the agent panel to select a teammate, then press Enter to view it and type to message it directly. Works in any terminal.
* **Split panes** : each teammate gets its own pane. You can see everyone’s output at once and click into a pane to interact directly. Requires tmux, or iTerm2.
`tmux` has known limitations on certain operating systems and traditionally works best on macOS. Using `tmux -CC` in iTerm2 is the suggested entrypoint into `tmux`.
@@ -253,7 +253,7 @@
Each teammate has its own context window. When spawned, a teammate loads the same project context as a regular session: CLAUDE.md, MCP servers, and skills. If you start the lead with [`--setting-sources`](</docs/en/cli-reference#cli-flags>), teammates load from the same restricted list of sources. Before v2.1.281, split-pane teammates loaded every settings source. A teammate also receives the spawn prompt from the lead. The lead’s conversation history does not carry over. **How teammates share information:**
- * **Automatic message delivery** : when teammates send messages, they’re delivered automatically to recipients. The lead doesn’t need to poll for updates.
+ * **Automatic message delivery** : when teammates send messages, they’re delivered automatically to recipients.
* **Idle notifications** : when a teammate finishes and stops, it automatically notifies the lead and includes its final answer in the notification. A teammate whose turn ends on an API error notifies the lead that it failed and includes the error text.
* **Shared task list** : [agents that have the Task tools](</docs/en/tools-reference#task-tool-availability>) can see task status and claim available work.
* **Teammate messaging** : send a message to one specific teammate by name. To reach everyone, send one message per recipient.
--- a/agent-view.md
+++ b/agent-view.md
@@ -42,7 +42,7 @@
In a regular `claude` session, pressing `←` on an empty prompt opens agent view, and a `←` hint in the footer reports on your background sessions:
- * **Hint** : the footer shows `← for agents` for ten seconds after the session opens. Pressing `←` still works after the hint disappears
+ * **Hint** : the footer shows `← for agents` for ten seconds after the session opens
* **Waiting count** : while background sessions wait on your input, the same spot counts them, such as `← 2 agents`, or `← 99+ agents` when more than 99 wait. The count refreshes about every ten seconds while the terminal is focused and immediately when focus returns
* **Finished count** : when background sessions finish successfully while none wait on your input, the footer briefly shows how many finished, such as `← 2 done` for two
@@ -613,7 +613,7 @@
### The supervisor process
-The supervisor is a background service that runs your background sessions so they keep working after you close agent view or your terminal. Claude Code starts it the first time you background a session or open agent view, and you don’t need to manage it yourself. Each session is its own Claude Code process under the supervisor, and what happens to that process depends on the session’s state:
+The supervisor is a background service that runs your background sessions so they keep working after you close agent view or your terminal. Claude Code starts it the first time you background a session or open agent view. Each session is its own Claude Code process under the supervisor, and what happens to that process depends on the session’s state:
* **Working, paused on a permission prompt or other dialog, or attached** : the process keeps running. A running subagent, workflow, or monitor counts as working, and so does a pending [session-scoped scheduled task](</docs/en/scheduled-tasks>), such as a `/loop` wakeup.
* **Finished or waiting for your next message, and unattached for about an hour** : the supervisor stops the process to free resources. A session that ended its turn by asking you a question counts as waiting for your next message. The conversation stays on disk, and the next time you attach or reply, the session resumes where it left off. Pin a session with `Ctrl+T` to keep its process running.
@@ -670,7 +670,7 @@
### The conversation says a background agent `was carried into this session and not resumed`
-This notice names a background [subagent](</docs/en/sub-agents>) that isn’t running in this session. Claude sees the notice and replies on its own, so you don’t need to prompt it. If you still need that subagent’s work after reading Claude’s reply, ask Claude for it.
+This notice names a background [subagent](</docs/en/sub-agents>) that isn’t running in this session. Claude sees the notice and replies on its own. If you still need that subagent’s work after reading Claude’s reply, ask Claude for it.
### Prompt rejected as too short
@@ -683,7 +683,7 @@
* Within 48 hours, the session shows as failed. Attach or reply to it and it restarts from its saved conversation. To pick the interrupted work back up, send it a reply asking it to continue.
* Past 48 hours, such as after the machine was off for days, the session shows as stopped with `ended while the background service was off`. Press `Enter` on the row and the footer shows `Press enter again to resume this session (it ended while the background service was off), or ctrl+x to remove it.` Press `Enter` on the same row again to resume its saved conversation. A reply, or `claude attach <id>`, resumes it without that footer prompt.
-When [transcript cleanup](</docs/en/settings-reference#cleanupperioddays>) has removed a stopped session’s saved conversation, Claude Code refuses to open the row: the message says there is nothing to resume. `claude rm <id>` deletes the row, unless Claude Code refuses, and `claude respawn <id>` runs its original prompt again. See [This session’s saved conversation is no longer on disk](</docs/en/errors#this-sessions-saved-conversation-is-no-longer-on-disk>). Sleep alone doesn’t stop sessions. Sessions are preserved across sleep and the supervisor reconnects to them on wake.
+When [transcript cleanup](</docs/en/settings-reference#cleanupperioddays>) has removed a stopped session’s saved conversation, Claude Code refuses to open the row: the message says there is nothing to resume. `claude rm <id>` deletes the row, unless Claude Code refuses, and `claude respawn <id>` runs its original prompt again. See [This session’s saved conversation is no longer on disk](</docs/en/errors#this-sessions-saved-conversation-is-no-longer-on-disk>). Sessions are preserved across sleep and the supervisor reconnects to them on wake.
### Opening a session says the conversation is already open
@@ -730,13 +730,13 @@
`was not sent SIGKILL`| macOS, Linux| Run the stop command again. If the process remains, check it with `ps -ww -o args= -p <pid>`: Claude Code started with `daemon` is a supervisor, so run `kill -9 <pid>`. Leave anything else; if `claude agents` then can’t start a supervisor, delete `~/.claude/daemon.lock`.
`supervisor (pid=<pid>) is still running`| Windows| End the process with `taskkill /PID <pid>`
-### Dispatch fails with `Could not resolve authentication method`
-
-If a background dispatch fails with `Could not resolve authentication method` while interactive sessions authenticate normally, the worker that received the dispatch didn’t pick up credentials. Background sessions get their credentials from the supervisor, so this error means no stored credential was available to the supervisor process itself. Confirm you have run `/login` or configured an API key, then stop the supervisor:
+### A background session shows `Not logged in`
+
+If a background session shows [`Not logged in`](</docs/en/errors#not-logged-in>) while interactive sessions authenticate normally, confirm you have run `/login` or configured an API key, then stop the supervisor:
claude daemon stop --any --keep-workers
-Within about a minute, run `claude agents` or `claude --bg` in your shell to start a fresh supervisor that reads your stored credentials. If you authenticate with an environment variable such as `ANTHROPIC_API_KEY` rather than `/login`, run that next command from a shell where the variable is set. See the [error reference](</docs/en/errors#could-not-resolve-authentication-method>) for the full list of causes and fixes.
+Within about a minute of stopping it, run `claude agents` in your shell to start a fresh supervisor. If you authenticate with an environment variable such as `CLAUDE_CODE_OAUTH_TOKEN`, run `claude agents` from a shell where the variable is set. Then run `claude respawn <id>` to restart the session, and resend your message.
### A background session shows `No LLM gateway`
--- a/approvals.md
+++ b/approvals.md
@@ -0,0 +1,86 @@
+Claude Approvals is a check on GitHub pull requests that reports who still has to approve. It follows a [policy](</docs/en/approvals-policy>), a file in your repository that can set how many people have to approve a change to a path and where Claude may approve.
+
+To turn on Claude Approvals in a repository, follow [Set up Claude Approvals](</docs/en/approvals-setup>).
+
+To evaluate a pull request, Approvals reads the policy, finds the rules that apply, and counts approvals: Use Approvals to set how many people have to approve a change, with more on risky changes and fewer on routine ones. For example, billing code can need two people, and test fixtures can need one person once [Code Review](</docs/en/code-review>) passes.
+
+For permission prompts in a Claude Code session, see [Configure permissions](</docs/en/permissions>).
+
+## Find Claude Approvals on a pull request
+
+Approvals adds a check named **Claude Approvals** to the pull requests that it evaluates. The check’s title says what’s still needed, such as **Waiting on human review from any person (1/2)**. A title that starts with **(observe mode)** means that the policy wasn’t enforced when the check ran. In observe mode, the check shows what your policy would decide. Claude also posts a comment with the reasons. Where the policy allows it, Claude can post an approving review. For the common titles and what to do about each, see [Find your approval status and what to do next](</docs/en/approvals-pull-requests#find-your-approval-status-and-what-to-do-next>). If a pull request has no check, see [No Claude Approvals check appeared](</docs/en/approvals-troubleshooting#no-claude-approvals-check-appeared>).
+
+## Example policy
+
+You write a policy as a list of rules in `.claude/approvals.yml`. This policy has one rule, which asks for two people on every change:
+
+ # .claude/approvals.yml
+ version: 1
+ mode: observe
+ rules:
+ - purpose: "A change takes two people, and Claude doesn't approve."
+ paths: ["**"]
+ verdict: { claude: comments, seats: 2 }
+ advisory: [claude/code_review]
+
+Each part of the policy sets one thing:
+
+ * **`mode: observe`** : starts the policy in observe mode
+ * **`purpose`** : says why the rule exists
+ * **`paths`** : names the files that the rule matches, which here is every file
+ * **`seats: 2`** : asks for two people, one of whom [can be the author](</docs/en/approvals-policy#whether-a-pull-request%E2%80%99s-author-counts>)
+ * **`claude: comments`** : means that Claude doesn’t approve
+ * **`advisory`** : keeps automatic Code Reviews
+
+You can also give a rule a condition, which can read facts about the pull request and classifiers’ answers:
+
+ * **[Facts](</docs/en/approvals-policy#if>) about the pull request**: such as how many lines changed, who opened it, and which branch it targets
+ * **A[classifier’s](</docs/en/approvals-classifiers>) answer**: a model’s judgment on a question such as how risky the change is
+
+A condition can’t read CI results, so keep CI as its own required check in GitHub.
+
+## Before you turn on Approvals
+
+Before you add a policy file to a repository, check that your organization qualifies and who can turn Approvals on or off. Then see what Approvals changes for merges, Code Review, and billing.
+
+### Availability
+
+Approvals is in public beta for Claude organizations on [Team and Enterprise](</docs/en/feature-availability#features-that-require-a-claude-subscription>) plans, as part of [Claude Ship](</docs/en/claude-ship>). It works on github.com, including GitHub Enterprise Cloud. Compliance settings limit who can use it:
+
+ * **Not available** : with [Zero Data Retention](</docs/en/zero-data-retention>) enabled, the [HIPAA configuration](</docs/en/hipaa-setup>) applied, or customer-managed encryption keys (CMEK)
+ * **Can’t start Approvals** : with FERPA or Access Transparency settings
+
+### Who can turn Approvals on or off
+
+Once the [prerequisites](</docs/en/approvals-setup#prerequisites>) are met, anyone who can merge a policy file into the default branch can turn Approvals on. An Owner of the Claude organization can [turn Approvals off](</docs/en/approvals-setup#turn-off-approvals>) for the whole organization, and it then stays off when a policy file merges.
+
+### Merges without human review
+
+A pull request can merge when nobody but its author has looked at it. Check your policy and your GitHub rules for cases such as these:
+
+ * **The check isn’t required** : the **Claude Approvals** check blocks a merge only where you make it a required check in GitHub, and normally not in observe mode
+ * **The policy asks for nobody else** : the author can fill a seat, so with `seats: 1` nobody else has to look. With `seats: 0`, a pull request that a bot wrote can merge when no person has looked at it
+ * **GitHub counts Claude’s approval** : where a GitHub branch rule requires one approval, Claude’s approving review can be that approval
+ * **Claude approves with no review** : a rule with `claude: approves` starts no Code Review by itself, so Claude can approve a change that nothing has reviewed. To get a review first, [let Claude approve only when Code Review passes](</docs/en/approvals-setup#let-claude-approve-when-code-review-passes>)
+
+For the other cases, and a rule that asks for a person who isn’t an author, see [Merges without human review](</docs/en/approvals-github-rules#merges-without-human-review>).
+
+### Keep automatic Code Reviews
+
+[Code Review](</docs/en/code-review>), another Claude Ship agent, can review each pull request automatically. Adding a policy file can stop those reviews. Where every file that a pull request changes lies under a policy file, automatic reviews normally stop, unless a rule for those files names `claude/code_review`. That holds in observe mode and when the policy is enforced. To keep automatic reviews, [list `claude/code_review` in a rule](</docs/en/approvals-policy#advisory>), as the example policy does under `advisory`.
+
+### Billing for Approvals
+
+Approvals bills your organization’s [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>), by tokens, for the Code Reviews and classifier runs that a policy starts. See [what starts a charge](</docs/en/approvals-setup#what-approvals-costs>).
+
+## Set up Claude Approvals
+
+To set up Approvals, start your policy in observe mode, where the **Claude Approvals** check shows what your policy would decide. Reviews and classifier runs are billed in observe mode. For starter policies and the steps, see [Set up Claude Approvals](</docs/en/approvals-setup>).
+
+## Related resources
+
+ * [Work with Claude Approvals on a pull request](</docs/en/approvals-pull-requests>): check titles and comment commands
+ * [Approvals and your GitHub rules](</docs/en/approvals-github-rules>): required reviews, CODEOWNERS, and merge queues
+ * [Policy file reference](</docs/en/approvals-policy>): keys and an example policy
+ * [Troubleshoot Claude Approvals](</docs/en/approvals-troubleshooting>): when no check appears or a policy file is refused
+ * [Configure permissions](</docs/en/permissions>): permission prompts in Claude Code
Show diff (256 lines)
--- a/approvals-classifiers.md
+++ b/approvals-classifiers.md
@@ -0,0 +1,253 @@
+In [Claude Approvals](</docs/en/approvals>), the rules in your [policy file](</docs/en/approvals-policy>) decide who has to approve a pull request. A classifier lets a rule depend on a judgment about the change, such as whether Code Review passed or how risky the change is. For example, a rule can ask for two people, and for only one when a classifier rates the change as low risk. A rule can decide from paths, facts, and classifiers:
+
+ * **Paths** : which files the pull request changes
+ * **[Facts](</docs/en/approvals-policy#if>)** : details of the pull request itself, such as how many lines changed or who opened it
+ * **Classifiers** : the answer to a question about the change. Use one for what paths and facts can’t express
+
+Claude Approvals is in [public beta](</docs/en/approvals#availability>) for organizations on Team and Enterprise plans.
+
+## How a classifier works
+
+A classifier has a name, a question, and the answers that it can give. Its answer reaches a rule in these steps:
+
+ 1. **Choose or define a classifier** : `claude/code_review` and `claude/diff` come with Claude Approvals. A custom classifier is a folder in your repository, `.claude/classifiers/<name>/`, on the default branch
+ 2. **Name it in a rule** : write the classifier’s name in a rule’s condition in your policy file, `.claude/approvals.yml`. For a custom classifier in the folder `change_risk`, the name is `repo/change_risk`, as in `"repo/change_risk = low"`
+ 3. **Approvals runs it on a pull request** : for example, when a pull request opens ready for review and changes a file that the rule matches. See When a classifier runs. Each run that calls a model is billed to your organization’s usage credits
+ 4. **The rule uses the answer** : the answer helps decide who has to approve. It shows under **Classifier results** in Claude’s comment on the pull request, unless a [`reuse`](</docs/en/approvals-policy#reuse>) condition reads it
+
+## Example classifier definition
+
+You define a custom classifier in a file named `def.yml`. The file holds the question for the model, in `prompt`, and the answers that the model can pick, in `outputs`. This example defines a classifier named `change_risk`. Its `prompt` asks the model to rate how risky a change is, and its `outputs` lets the model answer `low`, `medium`, or `high`:
+
+ # .claude/classifiers/change_risk/def.yml
+ version: 1
+ description: "How risky is this change to ship?"
+ model: opus
+ prompt: |
+ Rate how risky this change is to ship.
+ high: it touches sign-in, billing or a data migration.
+ medium: it changes behavior a user can see.
+ low: anything else.
+ When two ratings fit, pick the higher.
+ outputs:
+ risk: { type: ordinal, values: [low, medium, high] }
+
+Each key in the example does one job:
+
+Key| In this example
+---|---
+`version`| The format’s version, `1`
+`description`| One line that says what the classifier asks
+`model`| The Claude model that answers, here the newest Opus model
+`prompt`| The question. It says what each rating means, and which one to pick when two fit
+`outputs`| The answers that the model picks from. This classifier has one output, `risk`, and its `values` run from least to most
+
+A definition can also set `inputs`, `tools`, and `budget`. See Classifier definition file keys.
+
+### Use the example’s rating in a rule
+
+A classifier takes its name from its folder. The example is saved at `.claude/classifiers/change_risk/def.yml`, so you write `repo/change_risk` in your policy file’s rules. To use the rating, compare it with a value in a rule’s condition. For example, `if: "repo/change_risk = low"` is true when the model answered `low`. For a rule that asks for fewer people under that condition, see Read a classifier’s answer from a rule.
+
+## Classifiers Anthropic provides
+
+Claude Approvals comes with prebuilt classifiers, `claude/code_review` and `claude/diff`. To use one, write its name in a condition in one of your rules.
+
+### `claude/code_review`
+
+`claude/code_review` tells a rule whether [Code Review](</docs/en/code-review>) passed. For example, `if: "claude/code_review = pass"` is true while its answer is `pass`. `claude/code_review` gives one of these answers:
+
+Answer| When
+---|---
+`pass`| A review finished with no [Important finding](</docs/en/code-review-pull-requests#severity-levels>) open
+`fail`| A review finished with an Important finding open
+
+You can read it in any condition, or list it under [`advisory`](</docs/en/approvals-policy#advisory>).
+
+ * **To read the severity of its open findings** : write `claude/code_review.severity`, which is `none`, `minimal`, or `high`
+ * **To let people turn`fail` into `pass`**: name them in your policy’s [`findings`](</docs/en/approvals-policy#findings>) lists. They do it by closing the Important findings
+
+### `claude/diff`
+
+`claude/diff` tells a rule how much a pull request changed since an approval or an earlier answer. It answers `trivial`, `same_intent`, or `different`. Read it in a condition under [`reuse`](</docs/en/approvals-policy#reuse>), which says what continues to count after a push.
+
+## Add a custom classifier
+
+With a custom classifier, you write a question about a pull request, and a Claude model answers it. You define the classifier in a file in your repository, then name it in a rule:
+
+ 1. **Define the classifier** : create a folder under `.claude/classifiers/`, named in lower-case letters, digits, and `_`. In it, save a `def.yml` that holds the question and the answers to pick from. In a rule, you write the folder `change_risk` as `repo/change_risk`.
+ 2. **Name it under`advisory`**: in the root `.claude/approvals.yml`, pick a rule that has a `verdict` and whose `paths` match the files that you want judged, and list the classifier under that rule’s [`advisory`](</docs/en/approvals-policy#advisory>). Under `advisory`, the classifier runs and is billed, and decides nothing.
+ 3. **Merge both files** : open one pull request with both, and Claude comments on the pull request. If the rule that you edited is enforced, expect a warning that says “rules still hold on these files”, which doesn’t block the merge. Merge the pull request once the **Policy files in this change** section of that comment reports no refusal.
+ 4. **Read its answers** : open a pull request that changes those files, and look for the answer in Claude’s comment.
+ 5. **Let a rule depend on it** : once you trust the answers, read them from a rule.
+
+### When a classifier’s answer appears
+
+After you merge a classifier’s definition and the rule that names it, wait five minutes. Then open a pull request that isn’t a draft and that changes a file that rule’s `paths` match. Look for the classifier’s line in one of these places:
+
+ * **Claude’s comment** : under **Classifier results**
+ * **The Claude Approvals check’s summary** : under **Advisory classifiers (not counted toward this verdict)**
+
+At first, the line reads “no result recorded yet”. A run can take up to 10 minutes, or longer where the classifier’s `def.yml` sets a longer time limit. Under an enforced rule, the line stays as it is when the run ends. The answer shows the next time Approvals evaluates the pull request, for example when someone approves it or requests changes. The line then reads, for example, “`repo/change_risk`: reported `low` (advisory)”.
+
+ * **The line still shows no result** : wait until the run’s time limit is up, then have someone approve the pull request or request changes
+ * **Your classifier has no line** : check that the rule that names the classifier has a `verdict`, and that its `paths` match the file you changed
+
+## Read a classifier’s answer from a rule
+
+To make a rule depend on a classifier’s answer, write the classifier’s name in a condition: the rule’s own `if`, or the `if` of an [`override`](</docs/en/approvals-policy#override>). Once `repo/change_risk` answers well under `advisory`, move its name into an override’s `if`. Keep the strict verdict on the rule itself, because the rule’s verdict applies when a run gives no answer. This rule asks for two people, and for one while `repo/change_risk` answers `low`:
+
+ # .claude/approvals.yml
+ version: 1
+ rules:
+ - purpose: "Two people. One is enough when the risk is low."
+ paths: ["**"]
+ verdict: { claude: comments, seats: 2 }
+ override:
+ - { if: "repo/change_risk = low", verdict: { claude: comments, seats: 1 } }
+
+### Ways to read a classifier in a condition
+
+A condition can read a classifier in these forms:
+
+Form| Example| Reads
+---|---|---
+Name alone| `"repo/change_risk <= medium"`| The only output
+`.output`| `"repo/api_review.breaking = yes"`| One output by name. Required when the classifier’s definition has several
+`.severity`| `"repo/api_review.severity >= high"`| The worst open finding, from `none`, `minimal`, `low`, `medium`, `high`, or `critical`. Needs `findings` in `tools`
+`(input=value)`| `"claude/code_review(level=deep) = pass"`| A run with that input. Code Review’s `level` is `quick`, `standard`, or `deep`
+`= error`, `= incomplete`| `"repo/change_risk = error"`| How a run ended with no answer
+
+## Classifier definition file keys
+
+Write a classifier’s definition in `def.yml`, which can be up to 64 KiB. For a whole file, see Example classifier definition. You can write these keys in `def.yml`:
+
+Key| Required| Values
+---|---|---
+`version`| Yes| `1`, as a bare number
+`description`| Yes| One line, up to 1,000 characters
+`model`| Yes| A model family in lower case, such as `opus` or `sonnet`, or the exact Claude API ID of a generally available model from the [models overview](<https://platform.claude.com/docs/en/about-claude/models/overview>). The model has to [support auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>)
+`prompt`| This or `prompt.md`| The question. For a long one, save `prompt.md` beside `def.yml`, up to 512 KiB
+`outputs`| No| A map of output names to their types and values
+`inputs`| No| A map of input names that a rule can set
+`tools`| No| A list
+`budget`| No| `{ time, cost }`
+
+If you name a model family, the classifier uses that family’s newest model, so cost and answers can change with no pull request. If you name an exact ID, the classifier stops loading when that model is retired. Your organization’s list of allowed models applies to these runs.
+
+### `outputs`
+
+Give each output a `type`, and write names and values in lower-case letters, digits, and `_`. Don’t name an output `severity`, and don’t use `true`, `false`, `error`, `incomplete`, or `complete` as a value. Put quotes around `"yes"` and `"no"`.
+
+`type`| Also needs| [Operators](</docs/en/approvals-policy#if>) in a condition
+---|---|---
+`criteria`| `values`, a list of words| `=`, `!=`
+`ordinal`| `values`, least first| All six
+`numeric`| `min` and `max`, whole numbers| All six
+
+### `inputs`
+
+An input is a value that a rule can set for a run. Define each input under `inputs` in `def.yml`, then set it from a rule in parentheses after the classifier’s name, as in `repo/change_risk(rigor=thorough)`. Give each input a `default`, and either `values` or `min` and `max`, as in `rigor: { values: [quick, thorough], merge: right, default: quick }`. Say in your prompt what each value changes. An input’s `merge` says what happens when rules ask for different values on one pull request:
+
+`merge`| What runs
+---|---
+`left`, `right`| One run, with the word that stands earlier or later in `values`
+`min`, `max`| One run, with the smaller or larger number
+`list`| One run, with every word asked for
+Omitted| A separate billed run for each value
+
+### `tools`
+
+List an entry under `tools` to let a run do more:
+
+Entry| Lets a run| Limit
+---|---|---
+`findings`| Read parts of the pull request’s review threads, report findings as new ones, and resolve or reopen its own| 16 open threads
+`comment`| Post one comment| 5,000 characters
+`code`| Read files beyond the diff| Read-only
+`labels`| Add labels that the repository already has, and remove the ones it added| 8 labels. None whose name starts with `approvals:` or `claude-`
+`reviewers`| Add reviewers, and remove the ones it added| 8 reviewers
+
+Approvals holds back some of a run’s `tools` in observe mode and on some pull requests:
+
+ * **In observe mode** : a run keeps only `findings` and `code` from its `tools`. Approvals can list the findings in its own comment, and opens no new review threads. That holds while your policy file, or every rule that names the classifier and matches a changed file, says [`mode: observe`](</docs/en/approvals-policy#rule-keys>).
+ * **On some pull requests** : a run adds no comment, label, review thread, or GitHub review request. Examples are a pull request from a fork, and one where an author lacks write access
+
+#### `labels`
+
+Don’t grant `labels` where a label gates a merge, a deploy, or a workflow. A label that a run adds is a real label on the pull request, and anything that reads labels can act on it.
+
+#### `reviewers`
+
+Say in your prompt whom to add, by login. Where a rule that [applies](</docs/en/approvals-policy#how-rules-combine-into-one-verdict>) reads the classifier’s answer, the **Claude Approvals** check can wait for their approval, on top of [`seats`](</docs/en/approvals-policy#verdict>). Name people who have write access. With a policy file in a subdirectory, [list the classifier only under `advisory`](</docs/en/approvals-policy#policy-files-in-subdirectories>). To drop a reviewer who can’t approve, first merge a change to the prompt if it names that person, and allow five minutes. Then comment [`@claude approvals rerun`](</docs/en/approvals-pull-requests#comment-commands-for-approvals>) on the pull request.
+
+### `budget`
+
+Set `time`, `cost`, or both under `budget`, as in `budget: { time: 300, cost: 5 }`. A run that reaches either limit stops, and a condition then reads `incomplete`. If you ask for more than the maximum, the run gets the maximum and Approvals warns you.
+
+Key| Unit| Default| Maximum
+---|---|---|---
+`time`| Whole seconds| `600`| `3600`
+`cost`| Whole US dollars| `10`| `10`
+
+Approvals stops a run when its estimated spend reaches `cost`, and the bill can be higher. Under $5, a run on a large pull request can stop before it answers.
+
+## How a classifier run behaves
+
+A rule’s result can turn on when its classifier runs, what the run can read, and what happens when it gives no answer.
+
+### When a classifier runs
+
+A `repo/` classifier runs on a pull request only if you name it in a matching rule: in an `if`, an override’s `if`, a `reuse` condition, or `advisory`. On a [pull request from a fork](</docs/en/approvals-pull-requests#pull-requests-from-forks-and-outside-contributors>), `repo/` classifiers don’t start before a maintainer vouches for the commit. For `claude/code_review`, see [when Approvals starts a review](</docs/en/approvals-setup#what-approvals-costs>).
+
+ * **What can start a run** : a pull request opens ready for review, is marked ready, or is reopened. A push that changes the diff, a change of base branch, and a [rerun of the Claude Approvals check](</docs/en/approvals-pull-requests#comment-commands-for-approvals>) can also start one. After [your policy stops observing](</docs/en/approvals-setup#enforce-your-policy-and-require-claude-approvals>), Approvals evaluates some open pull requests by itself, which can start a run.
+ * **Which definition runs** : the default branch’s copy of the definition and prompt. A pull request’s own copy doesn’t run. The folder’s files are [protected files](</docs/en/approvals-policy#protected-files>).
+ * **A changed definition ends earlier answers** : an edit to `def.yml` or `prompt.md` counts once it’s on the default branch. An open pull request keeps its check until its next evaluation, such as a push or a rerun. That evaluation drops the earlier answer, and the classifier can run again.
+ * **After a push that changes the diff** : an earlier answer can count where [`reuse`](</docs/en/approvals-policy#reuse>) keeps it, or where the push changes only covered files whose rules don’t name the classifier
+ * **Order** : with `run: sequential`, the default, an override’s classifiers normally wait for the overrides above it. With `run: parallel`, they can all start at once, which can bill runs that no verdict needed.
+
+### What a classifier run can read and change
+
+A `repo/` classifier’s run is a Claude Code cloud session on Anthropic’s infrastructure. If your organization requires self-hosted compute, a condition reads `error` in place of that run’s answer. Check what the session can read and what it can change:
+
+ * **What it can read** : the pull request’s title, description, labels, author, changed files, diff, approvals, and required reviewers, the classifier’s earlier runs, your policy files, and the files under `.claude/classifiers/`. With `findings` in `tools`, it reads parts of the review threads
+ * **What`code` adds**: read-only copies of files at the pull request’s head and on the default branch, without some files, such as `CLAUDE.md`, `AGENTS.md`, `.claude/`, `.mcp.json`, and files whose names end in `.pdf`
+ * **What it can change** : the session’s GitHub access is read-only. Where `tools` lists an entry that writes, the run records what it asks for, and Approvals can carry it out after the run.
+
+A run reads text that the pull request’s author wrote, and that text can try to steer the classifier’s answer. On paths that matter, [ask for a person](</docs/en/approvals-github-rules#ask-for-a-person-who-isn%E2%80%99t-an-author>) in a rule that reads no classifier.
+
+### What a rule sees when a classifier run gives no answer
+
+When a run ends with no answer, a condition normally reads one of these values:
+
+A condition reads| When
+---|---
+`incomplete`| The run began and ended with no answer
+`error`| The run couldn’t start, was broken off, or outlasted the check’s wait
+
+In both cases, an override that needs the answer leaves the rule’s own `verdict` in place. A rule’s own `if` that needs the answer fails the **Claude Approvals** check, with the title **A classifier had no result**. To choose another verdict, put [an override](</docs/en/approvals-policy#override>) on `= error` or `= incomplete` above the overrides that read the answer. An override can’t choose another verdict for a missing answer in a rule’s own `if`. Move the comparison that reads the classifier from the rule’s `if` into an override.
+
+## What a classifier run costs
+
+A run that calls a model is billed to your organization’s usage credits, by tokens:
+
+Classifier| What’s billed
+---|---
+A custom classifier, `repo/<name>`| Each run. That includes runs in observe mode, runs under `advisory`, and runs that end with no answer. After an error, Approvals can start the run again by itself, more than once, and each of those runs is billed
+`claude/diff`| Each answer that calls a model
+`claude/code_review`| Billed as [Code Review](</docs/en/code-review-costs>)
+
+### Limit what a custom classifier costs
+
+You can cap one run, cap the month, pick a lower-cost model, or start fewer runs:
+
+ * **Cap one run** : in the classifier’s `def.yml`, add `budget: { cost: 5 }`. Approvals stops a run when its estimated spend reaches that many US dollars, and the bill can be higher. With no `budget`, the cap is $10
+ * **Cap the month** : set a [spend limit for classifier runs](</docs/en/approvals-setup#limit-what-a-policy-costs>) at [**Organization settings > Usage**](<https://claude.ai/admin-settings/usage>), which takes an Owner role
+ * **Pick a lower-cost model** : in `def.yml`, change `model`, for example from `opus` to `sonnet`
+ * **Start fewer runs** : make your edits to `def.yml` and `prompt.md` in one pull request. After each merged edit, the classifier runs again at each open pull request’s next evaluation
+
+## Related resources
+
+ * [Claude Approvals policy file reference](</docs/en/approvals-policy>): conditions, overrides, `reuse`, and `findings`
+ * [Set up Claude Approvals](</docs/en/approvals-setup>): observe mode, enforcement, and spend limits
+ * [Troubleshoot Claude Approvals](</docs/en/approvals-troubleshooting>): when a classifier gives no answer
+ * [Data usage](</docs/en/data-usage>): how Anthropic handles data from Claude Code
--- a/approvals-github-rules.md
+++ b/approvals-github-rules.md
@@ -0,0 +1,88 @@
+[Claude Approvals](</docs/en/approvals>) adds a check to the GitHub pull requests that it evaluates. The check reports who has to approve a pull request, following a [policy](</docs/en/approvals-policy>), a file in your repository. The check blocks a merge only where you make it a required check in GitHub, and your branch rules decide what merges. If you administer a repository or review its security, check how your policy and your GitHub settings work together before you [enforce the policy](</docs/en/approvals-setup#enforce-your-policy-and-require-claude-approvals>):
+
+ * **Merges without human review** : settings that let a pull request merge with no review but its author’s, and a rule that asks for a person who isn’t an author
+ * **Required reviews and CODEOWNERS** : how GitHub’s own review rules count Claude’s approving review, and what to set
+ * **Auto-merge and merge queues** : what can merge without anyone acting
+ * **Who can change or loosen a policy** : who can edit the policy file, stop requiring the check, or steer a classifier’s answer
+
+## Merges without human review
+
+With Approvals on, a pull request can merge with no person but its author looking at it, or with no person at all if a bot wrote it. That can happen if GitHub doesn’t require the **Claude Approvals** check. It can also happen if the check passes with no person besides the author, for example with:
+
+ * `seats: 0`
+ * `seats: 1`, which the author can fill
+ * A [`from` list](</docs/en/approvals-policy#people-lists>) that admits bots
+ * A machine user, a user account that a script or an agent drives, which [can count as a person](</docs/en/approvals-policy#whether-a-pull-request%E2%80%99s-author-counts>)
+ * A [`reuse`](</docs/en/approvals-policy#reuse>) that keeps seats after a push
+ * Files that no rule covers, where GitHub counts the neutral result as passing
+ * A condition that reads a [classifier’s](</docs/en/approvals-classifiers>) answer, in a rule’s `if`, an override’s `if`, or a `reuse`. That answer is one that a pull request’s text can steer
+
+A push directly to the default branch gets no check. Require pull requests there in GitHub. Claude’s [approving review](</docs/en/approvals#find-claude-approvals-on-a-pull-request>) can meet a GitHub branch rule that requires one approval.
+
+### Ask for a person who isn’t an author
+
+To have the **Claude Approvals** check ask for one person who isn’t an author on every path, add this file’s rule to a root [policy file](</docs/en/approvals-policy>) that you [enforce](</docs/en/approvals-setup#enforce-your-policy-and-require-claude-approvals>):
+
+ # .claude/approvals.yml
+ version: 1
+ rules:
+ - purpose: "A change takes one person who isn't an author."
+ paths: ["**"]
+ nested: inherit
+ verdict:
+ claude: comments
+ seats: [{ count: 1, from: [humans, "!pr/authors"] }]
+ advisory: [claude/code_review]
+
+Each part of that rule does a job:
+
+Part of the rule| What it does
+---|---
+No `if` or `override`| No classifier’s answer changes the rule
+`claude: comments`| Approvals doesn’t post Claude’s approval
+`nested: inherit`| The rule also applies under [policy files in subdirectories](</docs/en/approvals-policy#policy-files-in-subdirectories>)
+`humans`| A [machine user](</docs/en/approvals-policy#whether-a-pull-request%E2%80%99s-author-counts>), a user account that a script or an agent drives, can fill this seat. To keep one out, add its login, as in `[humans, "!pr/authors", "!acme-ci"]`
+`"!pr/authors"`| Excludes the pull request’s authors. On a [fork’s pull request](</docs/en/approvals-pull-requests#pull-requests-from-forks-and-outside-contributors>), no approval counts toward this seat
+`advisory`| [Keeps automatic Code Reviews](</docs/en/approvals#keep-automatic-code-reviews>)
+
+For paths that need more people, copy the rule, narrow `paths`, and raise `count`.
+
+## Required reviews and CODEOWNERS
+
+Check how each GitHub setting works beside your policy, and what to set:
+
+GitHub setting| How it works with Approvals| What to do
+---|---|---
+Required approvals| GitHub can count Claude’s approving review as one approval. GitHub doesn’t count an author who fills a seat, or an [`@claude approve`](</docs/en/approvals-pull-requests#comment-commands-for-approvals>) comment| Where you require the **Claude Approvals** check, require no more than one approval in GitHub, and ask for more people in `seats`. Otherwise a pull request can stay blocked after the **Claude Approvals** check passes
+CODEOWNERS| A branch rule can require a Code Owner’s review| To name owners in your policy, use a [people list](</docs/en/approvals-policy#people-lists>) in `seats` on their paths
+Stale approvals| Claude posts its approving review on one commit, and GitHub can continue to count that review until it’s dismissed. Approvals normally asks GitHub to dismiss the review when Approvals evaluates the next push, and GitHub can [refuse](</docs/en/approvals-pull-requests#approvals-waits-for-people>)| Where GitHub requires approvals, turn on **Dismiss stale pull request approvals when new commits are pushed** or **Require approval of the most recent reviewable push**
+
+## Auto-merge and merge queues
+
+If you use GitHub auto-merge or a merge queue with a policy that doesn’t require a person’s approval, a change can merge without anyone acting. To have the check ask for a person who isn’t an author on every path, add this rule, and require the **Claude Approvals** check. Approvals doesn’t evaluate the commits that a merge queue creates:
+
+ * **The queue’s commits** : Approvals normally marks them as passed, with the title **Stamped for merge queue** , except for a pull request that was evaluated only in [observe mode](</docs/en/approvals-pull-requests#approvals-in-observe-mode>)
+ * **Entry to the queue** : GitHub’s own rule decides it, normally after the pull request’s required checks pass. A pull request can also enter while the check is still running. If the check doesn’t pass after that, remove the pull request from the queue
+ * **Pull requests that were only observed** : after you start enforcing the policy, [rerun the check](</docs/en/approvals-setup#enforce-your-policy-and-require-claude-approvals>) on each open pull request before you queue it. Until its latest commit passes under the policy, its commit in the queue normally gets no check, and where the check is required, it can wait there
+ * **The app’s permission** : ask an owner of your GitHub organization to accept the Claude GitHub App’s [**Merge queues** permission](</docs/en/github-actions#github-app-permissions>). Without it, the queue’s commits get no check, so where GitHub requires the check, entries wait
+
+## Who can change or loosen a policy
+
+A policy is a file in your repository, so your GitHub permissions decide who can change it.
+
+Who| What they can do
+---|---
+Anyone who can merge into the default branch| Change a policy file. A policy file is a [protected file](</docs/en/approvals-policy#protected-files>): a pull request that changes it can need a person with write access, who can be the pull request’s author. A [machine user](</docs/en/approvals-policy#whether-a-pull-request%E2%80%99s-author-counts>) counts as a person
+A GitHub repository admin| Stop requiring the **Claude Approvals** check in the repository’s own branch rules
+Anyone who can bypass every rule that requires the check| Merge past the check
+An [Owner role](</docs/en/server-managed-settings#access-control>) in the Claude organization| [Turn off Approvals](</docs/en/approvals-setup#turn-off-approvals>) for a GitHub organization, a repository whose **Edit** dialog shows **Claude Approvals** , or the whole Claude organization
+
+### Classifier answers that a pull request can steer
+
+Approvals applies the policy files and your classifier definitions from the default branch. A pull request’s [author’s text](</docs/en/approvals-classifiers#what-a-classifier-run-can-read-and-change>) can steer a classifier’s answer. Where a rule’s `if`, an override’s `if`, or a `reuse` condition reads an answer, a steered answer can lower what the pull request needs. To ask for one person who isn’t an author on every path, add this rule.
+
+## Related resources
+
+ * [Set up Claude Approvals](</docs/en/approvals-setup>): enforce a policy and require the **Claude Approvals** check
+ * [Claude Approvals policy file reference](</docs/en/approvals-policy>): seats, people lists, and protected files
+ * [Claude Approvals classifiers](</docs/en/approvals-classifiers>): what a classifier’s run can read and change
Show diff (365 lines)
--- a/approvals-policy.md
+++ b/approvals-policy.md
@@ -0,0 +1,362 @@
+A policy file, `.claude/approvals.yml`, tells [Claude Approvals](</docs/en/approvals>) who has to approve a pull request and when Claude may approve it. Look up its keys here, how its rules combine, and how approvals are counted.
+
+To set up Approvals and require the **Claude Approvals** check, see [Set up Claude Approvals](</docs/en/approvals-setup>). To find out what a check’s title means, see [Work with Claude Approvals on a pull request](</docs/en/approvals-pull-requests>). For a file that the check refuses, see [Fix a policy file that Approvals refuses](</docs/en/approvals-troubleshooting#fix-a-policy-file-that-approvals-refuses>). To define a `repo/<name>` classifier, see [Claude Approvals classifiers](</docs/en/approvals-classifiers>).
+
+## How a policy file works
+
+A policy file is a list of rules. Each rule names the files that it’s about, in `paths`, and says what a pull request that changes them needs:
+
+ * **`seats`** : how many people have to approve
+ * **`claude`** : whether Claude `approves`, `comments`, or `blocks`
+ * **`override`** : another verdict, which replaces the rule’s own while its `if` is true
+
+This policy file is the one that [Set up Claude Approvals](</docs/en/approvals-setup#let-claude-approve-when-code-review-passes>) starts from. It asks for two people to approve a change, or one person when Claude’s review passes. In both cases, the pull request’s author can count as one person:
+
+ # .claude/approvals.yml
+ version: 1
+ mode: observe
+ rules:
+ - purpose: "A change takes two people. When Claude's review passes, one is enough and Claude approves."
+ paths: ["**"]
+ verdict: { claude: comments, seats: 2 }
+ override:
+ - { if: "claude/code_review = pass", verdict: { claude: approves, seats: 1 } }
+ - purpose: "A change to the review rules takes two people."
+ paths: ["**/.claude/**"]
+ nested: inherit
+ verdict: { claude: comments, seats: 2 }
+
+Each line of that file does one job:
+
+Line| What it does
+---|---
+`mode: observe`| The **Claude Approvals** check shows what the rules would decide. Delete the line to enforce them
+`purpose`| Says why the rule exists
+`paths: ["**"]`| The first rule matches every file
+`verdict`| Two people have to approve, and the author can count as one. Claude comments and doesn’t approve
+`override`| While [`claude/code_review`](</docs/en/approvals-classifiers#classifiers-anthropic-provides>) reads `pass`, one person, who can be the author, is enough and Claude can approve
+`paths: ["**/.claude/**"]`| The second rule matches the files under any `.claude/` directory, which include the policy file
+`nested: inherit`| Once you enforce the policy, keeps the second rule in force in subdirectories that have their own policy file
+
+A file under `.claude/` matches both rules. Approvals takes the strictest of the verdicts that apply, so once you enforce the policy, a change to that file needs two people, because the second rule has no `override`.
+
+## Where to put a policy file
+
+Save the policy file as `.claude/approvals.yml` in your repository’s root, and merge it into the default branch. Approvals reads policy files from the default branch, so the file’s rules apply once it’s merged. You can also name the file `.claude/approvals.yaml`, which Approvals reads where the `.yml` file is absent. To give a directory rules of its own, add a policy file there.
+
+### When a change to a policy file takes effect
+
+While a change to a policy file is in an open pull request, Approvals can check the changed file for errors, and applies none of its rules. The rules on the default branch decide for that pull request. Once the change merges, new pull requests get the new rules, and open ones get them from their next evaluation. Approvals can read the earlier copy for a few minutes more. To evaluate an open pull request now, comment [`@claude approvals rerun`](</docs/en/approvals-pull-requests#comment-commands-for-approvals>).
+
+### Policy files in subdirectories
+
+To give a directory its own rules beside the root policy file, add a `.claude/approvals.yml` inside it, such as `services/billing/.claude/approvals.yml`. For each changed file, Approvals walks up from that file’s directory. The first enforcing policy file that covers the changed file, and in which a rule with a `verdict` applies, decides for it. A `nested: inherit` rule in a policy file higher up counts as one of the deciding policy file’s rules.
+
+ * **The nearest policy file decides** : it can ask for less than the root policy file. Above it, only rules marked `nested: inherit` still count.
+ * **`paths` start at the directory**: in `services/billing/.claude/approvals.yml`, write `api/**` to match the files under `services/billing/api/`
+ * **`locals` reach down**: in a policy file, you can use the locals of the policy files above it
+ * **Each policy file has its own`mode`**: while the root policy file observes, none of its rules count under a directory’s enforcing policy file, the `nested: inherit` rules included
+ * **Some custom classifiers go only under`advisory`**: that’s a classifier whose [`tools`](</docs/en/approvals-classifiers#tools>) list `reviewers` or `labels`, or that has an [input](</docs/en/approvals-classifiers#inputs>) with no `merge`. List it in an enforced rule with no `if`. If a rule reads its result, the check on pull requests under a directory’s policy file can read **Cannot evaluate: classifier outside advisory**
+
+## Top-level keys
+
+Approvals refuses a file that has an unknown key. Write keys, and fixed words such as `observe` and `approves`, in lower case. Put double quotes around every purpose, pattern, condition, and `"!"` item. Keep the file to one YAML document, quote each `!` item, and indent with spaces, or Approvals refuses the file. Anchors, aliases, and `!!` tags draw a warning. Write these keys at the top level of the file:
+
+Key| Required| Values| Default| Description
+---|---|---|---|---
+`version`| Yes| `1`| | The schema version, as a bare number
+`rules`| Yes| List of rules| | Rule order doesn’t matter
+`mode`| No| `enforce`, `observe`| `enforce`| `observe` shows what the rules would decide and holds for every rule in the file. For the checks that still aren’t neutral, and for pull requests into other branches, see [Approvals in observe mode](</docs/en/approvals-pull-requests#approvals-in-observe-mode>)
+`nested`| No| `overwrite`, `inherit`| `overwrite`| The default for this file’s rules. See Policy files in subdirectories
+`run`| No| `sequential`, `parallel`| `sequential`| The default for this file’s rules. See [When a classifier runs](</docs/en/approvals-classifiers#when-a-classifier-runs>)
+`locals`| No| Map of names to values| | Values to reuse. See `locals` and `use`
+
+## Rule keys
+
+Give each rule a `purpose`, `paths`, and at least one of `verdict`, `advisory`, `findings`, and `reuse`. If `reuse` is the only one of the four that a rule has, the value of `reuse` has to be `false` or name a classifier. A rule with no `verdict` asks nobody and covers no file. You can write these keys on a rule:
+
+Key| Type| Default| Description
+---|---|---|---
+`purpose`| One line of text| Required| Why the rule exists
+`paths`| List of patterns| Required| The changed files that the rule matches
+`verdict`| Map| | What Claude does and who has to approve
+`if`| Condition| `true`| The rule applies only while the condition is true
+`override`| List| | Other verdicts, each under a condition
+`advisory`| List of classifiers| | Classifiers that run and decide nothing
+`reuse`| Condition or map| Keep nothing| What still counts after a push that changes the diff
+`findings`| Map| No list| Who may close a classifier’s finding
+`use`| List of `"@name"`| | Locals whose keys are copied into the rule
+`mode`| `enforce`, `observe`| The file’s| A rule that observes neither applies nor covers a file
+`nested`| `overwrite`, `inherit`| The file’s| `inherit` keeps the rule in force under the policy files below
+`run`| `sequential`, `parallel`| The file’s| Whether the rule’s own classifiers start in turn or together
+
+### `paths`
+
+Write each pattern as a path from the directory that holds the `.claude` folder. A moved file counts at its old path and its new one.
+
+Pattern| Matches
+---|---
+`*`| Any characters within one folder
+`**`| Any number of folders, dot folders too. It has to be a whole segment, as in `**/*.go`
+`{a,b}`, `[ab]`, `?`| Alternatives, one character of a set, and any one character
+`infra/**`| Every file in the folder. A bare `infra` matches no file in it
+`*.md`| Markdown files beside the policy file’s `.claude` folder. For any depth, write `**/*.md`
+`"!docs/**"`| Takes the files out of this rule only. A rule needs at least one pattern with no `!`
+
+### `if`
+
+Write a condition as `true`, `false`, or one double-quoted string with a fact’s or a classifier’s name on the left, such as `"pr/files_changed > 50"`. When you give a rule an `if`, keep another rule with no `if` on the same paths. While the `if` is false, the rule that has it doesn’t apply. Where rules cover a file and none applies, the Claude Approvals check fails.
+
+ * **Operators** : `=`, `!=`, `<`, `<=`, `>`, `>=`
+ * **Joining** : `AND` and `OR` in capitals. Use parentheses to mix the two.
+ * **Lists** : write `ANY` or `ALL` before `pr/authors` and `pr/approved_by`. Where the condition leads to a lighter verdict, use `ALL`: with `ANY`, one listed author relaxes the rule for everyone else’s commits. Where it leads to a stricter one, use `ANY`: with `ALL`, one unlisted author switches it off.
+ * **Quotes** : single quotes around a login or a branch pattern, and none around a team, a `bot:` name, or a fact, as in `"ALL pr/authors = ['ana-acme', acme/payments]"`
+ * **Classifiers** : `claude/code_review = pass`, `repo/change_risk <= medium`, and the other forms under [Read a classifier’s answer from a rule](</docs/en/approvals-classifiers#read-a-classifier%E2%80%99s-answer-from-a-rule>)
+
+A fact comes from the pull request itself:
+
+Fact| Example| Holds
+---|---|---
+`pr/files_changed`, `pr/files_added`, `pr/files_removed`| `"pr/files_changed > 50"`| Counts over the whole pull request
+`pr/diff_lines`| `"pr/diff_lines <= 20"`| Changed lines in the whole pull request
+`rule/files_changed`, `rule/files_added`, `rule/files_removed`| `"rule/files_changed = pr/files_changed"`| Counts among the files that this rule’s `paths` match
+`pr/authors`| `"ALL pr/authors = bot:dependabot"`| Accounts that wrote or pushed a commit, and the account that opened the pull request
+`pr/opened_by`| `"pr/opened_by = acme/release"`| The account that opened the pull request. After someone else pushes to a bot’s pull request, an override on `pr/opened_by = bot:dependabot` stops lowering what the rule asks for
+`pr/approved_by`| `"ANY pr/approved_by = acme/security"`| People with write access who approved the current diff. Authors and bots aren’t among them. Also takes `= empty` and `!= empty`
+`pr/base`| `"pr/base = 'release/**'"`| The branch that the pull request targets
+
+### `verdict`
+
+A `verdict` says what Claude does and who has to approve. In a rule’s `verdict`, write `claude`, and write `seats` unless `claude` is `blocks`.
+
+Field| Values| Description
+---|---|---
+`claude`| `approves`, `comments`, `blocks`| `approves`: Claude can post an approving review once the **Claude Approvals** check passes, if every rule that applies says so and every changed file is covered. The field starts no review, so where the rule reads no classifier, Claude can approve a change that no review has read. `comments`: Claude doesn’t approve. `blocks`: the check fails, whoever approves
+`seats`| `0` to `16`, or a list of up to eight sets| How many people have to approve. A number `N` is short for `[{ count: N, from: humans }]`. Refused beside `blocks`
+`max_age`| A whole number and `s`, `m`, `h`, or `d`, from `1m` to `83d`| How long an evaluation’s results count. After that, the check fails with the title **Results are older than the policy allows**
+
+Give each set in `seats` a `count`, from `1` to `16`, and a `from`, which is a people list. Every set has to be filled, and one person can fill a seat in several sets.
+
+### People lists
+
+A people list names accounts. Write one as a set’s `from` under `seats`, or under `findings`, as one item or as a list in brackets. Only accounts with write access to the repository count.
+
+Item| Means
+---|---
+`humans`| Every person, authors included. A machine user, which is a user account that a script or an agent drives, counts as a person. The `claude` user account, which Claude’s cloud sessions commit as, doesn’t
+`bots`| Every bot and GitHub App, Claude’s apps and `github-actions` included
+`everyone`| `humans` and `bots` together. Write it alone, with no brackets
+`nobody`| Nobody. Write it alone, under `findings` only
+`ana-acme`| One login. In a condition, put it in single quotes
+`acme/payments`| A team of the repository’s GitHub organization
+`bot:dependabot`| One bot, with no `[bot]` suffix. `bot:claude` means Claude’s apps
+`pr/authors`, `pr/opened_by`| The accounts that the fact holds
+`"!pr/authors"`| Takes accounts away. Quote it, and put it beside an item with no `!`
+
+If a set’s `from` admits Claude, for example through `bots`, `everyone`, or `bot:claude`, and every rule that applies says `approves`, Approvals counts a seat in that set as filled before Claude approves. The **Claude Approvals** check can then pass with no person’s approval.
+
+### `override`
+
+An override changes its rule’s verdict while the override’s own `if` is true. Approvals reads the `override` list from the top, and the first true override applies.
+
+Key| Required| Description
+---|---|---
+`if`| Yes| A condition
+`verdict`| At least one of these three| Each field that it writes replaces the rule’s. `seats` is replaced as a whole
+`reuse`, `findings`| At least one of these three| Replaces the rule’s whole value
+`purpose`, `use`| No| As on a rule. Here `use` can copy `verdict` and `findings`
+
+When an override’s `if` reads a classifier, the **Claude Approvals** check waits for the classifier’s run:
+
+ * **The run is still going** : the check stays in progress. It can finish early when the approvals already meet every verdict that the rule could still pick, unless the classifier’s `tools` list [`reviewers`](</docs/en/approvals-classifiers#reviewers>). With a policy file in a subdirectory, list such a classifier only under `advisory`
+ * **The run ended with no answer** : reading stops at that override, and the rule’s own `verdict` applies. Put the strict verdict on the rule for this reason.
+ * **You want to catch a missing answer** : put an override on `= error` or `= incomplete` above the ones that read the answer
+
+In a rule’s own `if`, a comparison with no answer fails the check, whoever approves, unless another part of the condition settles it.
+
+### `advisory`
+
+Under `advisory`, list classifier names or calls, such as `[claude/code_review, repo/change_risk]`. A `repo/` classifier listed here [can run](</docs/en/approvals-classifiers#when-a-classifier-runs>), and each run is billed. List it in a rule that has a `verdict`. To keep Code Review’s automatic reviews, list `claude/code_review` here, or read it in an `if`, in a rule that has a `verdict` and matches the files you want reviewed.
+
+### `reuse`
+
+`reuse` says which earlier approvals and classifier answers continue to count after a push that changes the diff, under a condition that usually reads [`claude/diff`](</docs/en/approvals-classifiers#classifiers-anthropic-provides>). When `claude/diff`’s answer is at most `same_intent` and Claude’s review of the new commit passes, this example can keep people’s approvals:
+
+ # in .claude/approvals.yml, on a rule
+ reuse:
+ seats: "claude/diff <= same_intent AND claude/code_review = pass"
+
+Write `reuse` in one of these forms:
+
+Form| Can keep
+---|---
+`seats: <condition>`| People’s approvals
+`<classifier>: <condition>`| That classifier’s earlier answer
+`reuse: <condition>`| Both: the seats and the classifiers that the rule reads
+`false`| Nothing. `unset`, in an override, removes the rule’s value
+
+Before you rely on `reuse`, check these cases:
+
+ * **Every rule that matches the files** : write `reuse` on each of them
+ * **When`claude/diff` gives no answer**: a condition that reads it keeps nothing
+ * **After a dismissal or a force-push** : the example keeps no approval that GitHub dismissed, and normally none given before a force-push. `reuse` can keep them under a `seats` condition that reads `claude/diff` and no other classifier, such as `"claude/diff <= same_intent"`.
+ * **Earlier authors count too** : where `reuse` keeps `seats`, people who held the author’s seat at an earlier commit can continue to count. Two of them can fill `seats: 2` with nobody approving. To prevent that, exclude authors from the set with `"!pr/authors"`.
+ * **Files that a push left alone** : in a policy file that writes `reuse`, an approval can outlast a push to other files only. Those can be files that no rule covers, or whose rules couldn’t count that person. An approval that GitHub dismissed normally doesn’t
+
+### `findings`
+
+A classifier can report findings as review threads, and a condition can read their severity as `.severity`. Use `findings` to say who may close a finding, by resolving its thread or with [`@claude approvals resolve`](</docs/en/approvals-pull-requests#comment-commands-for-approvals>). Until a rule’s `findings` lists who may close findings, a person’s resolve alone doesn’t lower `.severity`. A classifier needs no list to close its own finding, as Code Review can when a later review finds it fixed. This example lets the `acme/leads` team, less the pull request’s authors, close Code Review’s findings:
+
+ # in .claude/approvals.yml, on a rule with no if, beside verdict
+ findings:
+ resolution:
+ claude/code_review: [acme/leads, "!pr/authors"]
+
+Under `findings`, write `resolution` with one of these values:
+
+Value| Meaning
+---|---
+A people list| One list for every classifier’s findings. `resolution: humans` lets people with write access close them, the author included
+A map of classifier names to lists| A list for each classifier
+A list of sets, each `{ if, from }`| Each `if` can read `finding/severity`, as in `{ if: "finding/severity >= high", from: acme/leads }`. Where each `if` reads `finding/severity` alone, the first set whose `if` is true decides. End with a set that has no `if`
+`nobody`| No person’s resolve alone closes a finding. A classifier can close its own findings
+
+To let people close findings, put a list on a rule that has no `if` and covers the finding’s file. Put that rule in the policy file that decides for the file. For a resolve alone to count, every list that applies to that file has to admit the person who resolves. A failed `claude/code_review` is one answer for the whole pull request. Check every changed file under a rule that compares that answer, as in `claude/code_review = pass`:
+
+ * **Every file’s lists admit the person who resolves** : once every Important finding of the review is closed, it can read `pass`, with no new review
+ * **One file’s lists don’t admit the person who resolves, or that file has`nobody` or no list**: that person’s resolve leaves the review `fail`. Write a list for that file that admits the person.
+
+Closing a finding changes no code, so people can lower `.severity` and pass a failed review with nothing fixed. Keep the lists short.
+
+### `locals` and `use`
+
+To reuse a value, name it under `locals` at the top of the policy file. Then write `"@name"` where the value belongs, or copy a whole map into a rule with `use`. In this example, `payments_owner` names one set of people, and `strict` names a whole verdict that the first rule copies with `use`:
+
+ # .claude/approvals.yml
+ version: 1
+ locals:
+ payments_owner: { count: 1, from: [acme/payments, "!pr/authors"] }
+ strict:
+ verdict: { claude: comments, seats: [{ count: 2, from: humans }, "@payments_owner"] }
+ rules:
+ - purpose: "The payments API takes two people, one of them a payments owner."
+ paths: ["services/payments/api/**"]
+ use: ["@strict"]
+ - purpose: "Everything else takes two people."
+ paths: ["**"]
+ verdict: { claude: comments, seats: 2 }
+
+Check what a local can hold and where you can use it:
+
+ * **What a local holds** : text, a number, `true` or `false`, a list, or one map
+ * **Where`"@name"` can stand**: for the whole of `paths`, a people list, `seats`, `verdict`, or `override`, and for one item of `paths`, a people list, or `seats`. Inside a condition it takes no quotes of its own, as in `"pr/files_changed > @many"`.
+ * **What`use` copies**: `verdict`, `override`, `if`, `paths`, `reuse`, `advisory`, and `findings`. What the rule writes itself wins: key by key inside `verdict`, `findings`, and a `reuse` map, and whole for any other key.
+
+## How rules combine into one verdict
+
+Approvals takes the strictest of the verdicts that apply: `blocks` outranks `comments`, which outranks `approves`, and every rule’s seats have to be filled. Which verdicts apply turns on whether a rule matches, applies to, or covers a changed file:
+
+ * **Matches** : a rule matches a changed file when its `paths` include the file and no `"!"` item takes it out
+ * **Applies** : a rule applies to a changed file when it matches, its `mode` is `enforce`, and its `if` is true or absent
+ * **Covers** : a rule covers a changed file when it matches, its `mode` is `enforce`, and it has a `verdict`, whatever its `if` says
+
+Approvals picks a policy file, then rules, then verdicts:
+
+ 1. **The policy file** : for each changed file, the nearest enforcing one that covers it and in which a rule with a `verdict` applies. `nested: inherit` rules in policy files higher up count as its rules.
+ 2. **The rules** : the ones that apply to each changed file.
+ 3. **Each rule’s verdict** : its own, or its first true `override`.
+ 4. **One verdict for the pull request** : the strictest across all changed files. One person can fill a seat in several rules, and the shortest `max_age` applies.
+
+Under an enforced policy, these cases end another way:
+
+Case| What happens
+---|---
+No rule covers a changed file| Nobody is asked to review that file. A protected file can still need a person. Claude doesn’t approve the pull request
+No rule covers any changed file| Normally no check appears. Where GitHub requires the check on the default branch, it normally ends neutral, with the title **Nothing ran, not blocking: no file is covered**. GitHub counts that as passing. With no root policy file, a pull request that changes no file under a directory’s policy file can get no check, so a required check waits
+Rules cover a changed file, and none applies| The check fails, with a title that starts **No rule applies to**
+A file moves between a path that rules cover and one that they don’t| No check appears, and Claude comments that Approvals did not run. Where GitHub requires the check, the pull request waits
+
+To avoid these, cover every path with root rules that have no `if`, as the first rule of the starter policy does.
+
+## How people’s approvals are counted
+
+An approval can count when an account with write access gives it in a GitHub review or an [`@claude approve`](</docs/en/approvals-pull-requests#comment-commands-for-approvals>) comment. It has to be on the latest commit, or on an earlier one that still counts. While a person with write access requests changes on a pull request that has a covered file, the **Claude Approvals** check normally reads **Changes requested** once nothing else holds it.
+
+### Whether a pull request’s author counts
+
+On a pull request that a person with write access opened, the author can fill one seat without approving, in a set that admits them. Except on [a fork’s or an outside contributor’s pull request](</docs/en/approvals-pull-requests#pull-requests-from-forks-and-outside-contributors>), the author alone can meet `seats: 1`. `seats: 2` can be the author and one more person.
+
+ * **Who holds the author’s seat** : at the commit that the pull request was opened with, the person who opened it. After a later push, normally the person who both wrote and pushed the latest commit.
+ * **When nobody holds it** : for example, after a push of a commit that one person wrote and another pushed. The **Claude Approvals** check’s summary gives the reason, and if you opened the pull request, you can then comment [`@claude approve`](</docs/en/approvals-pull-requests#comment-commands-for-approvals>).
+ * **To exclude authors** : write `seats: [{ count: 1, from: [humans, "!pr/authors"] }]`. In a set of named people, name at least one more than `count`, or an author’s own pull request can wait. On a [fork’s pull request](</docs/en/approvals-pull-requests#pull-requests-from-forks-and-outside-contributors>), no approval counts toward a set that excludes `pr/authors`.
+ * **What`"!pr/authors"` goes by**: the accounts that GitHub names as having written or pushed a commit or opened the pull request. It doesn’t read `Co-authored-by` lines, and an agent’s commits under another account don’t make a person an author.
+ * **Bots** : a bot fills the seat only in a set that admits it, on a pull request that it opened and whose latest commit it pushed
+ * **Machine users** : an agent that works under a user account other than `claude` holds the seat as a person does, and can be the one person that a protected file needs. To keep it out, take its login out of the rule’s set with `"!"`, as in `[humans, "!acme-ci"]`. For protected files, put that set in a rule whose `paths` name them, marked `nested: inherit`.
+
+### Earlier approvals after a new push
+
+After a push, an earlier approval counts or stops counting by what the push changed:
+
+ * **The diff’s text stays identical** : an earlier approval that GitHub hasn’t dismissed can count.
+ * **The diff’s text changes** : earlier approvals normally stop counting. Where the policy writes `reuse`, some can continue to count
+
+Approvals normally [asks GitHub to dismiss](</docs/en/approvals-github-rules#required-reviews-and-codeowners>) Claude’s own approval when it evaluates the push, and Claude approves the new commit only if the **Claude Approvals** check passes again.
+
+## Protected files
+
+A protected file is Approvals’ term for a file that controls how pull requests are reviewed, such as the policy file itself. An edit to one can weaken the review of later pull requests. For example, an edit to the policy file can lower the number of people that they need. Where a rule covers a changed file, Approvals normally asks for a person on a change to a protected file. The list of protected files is built in:
+
+ * **Policy and classifier files** : every policy file, and everything under `.claude/classifiers/`
+ * **Review instructions** : `REVIEW.md` at the repository’s root
+ * **Git files** : `.gitmodules`, `.gitattributes`, symlinks, and submodule pointers
+ * **Code owners** : any file named `CODEOWNERS`
+
+Don’t rely on other files being protected. Write a rule for the ones that matter to you, such as `.github/`, `CLAUDE.md`, `AGENTS.md`, `.mcp.json`, and the rest of `.claude/`.
+
+### Who has to approve a change to a protected file
+
+The person that Approvals asks for can be the pull request’s author:
+
+Pull request| Who has to approve
+---|---
+A rule covers a changed file| Normally at least one person with write access. That person can be the pull request’s author, and isn’t a bot
+No rule covers any changed file| Can need one person, who can be the author, or nobody
+It changes a policy or classifier file in [observe mode](</docs/en/approvals-pull-requests#approvals-in-observe-mode>)| Can need one person, who can be the author
+
+### When Claude approves a change to a protected file
+
+Claude approves a pull request that changes a protected file only if a rule applies to that file and every rule that applies says `approves`. A rule on `"**"` can count. Claude doesn’t approve a pull request that changes a `.gitattributes` file, a symlink, or a submodule pointer, whatever the rules say.
+
+## Policy file size and count limits
+
+Keep each file within these limits, or Approvals refuses it:
+
+What| Limit
+---|---
+One policy file| 448 KiB
+Policy files in a repository| 1,024 files, 8 MiB together. Past either, Approvals reads none of them
+Rules in a file| 512
+Locals in a file| 512
+Patterns in a rule, not counting `"!"` items| 256
+Overrides| 16 in a rule, 128 in a file
+Entries in any list| 1,024
+`purpose`| 1,000 characters
+A condition| 4,096 characters, eight levels of parentheses
+`seats` as a number, or a set’s `count`| 16
+Sets in one `seats`| 8
+Sets under `resolution`| 16
+Teams in one list, or in all the sets of one `seats`| 10
+Names under one `use`| 8
+Custom classifiers that a file names| 16
+Different classifier runs that a file asks for| 32
+
+A pull request has limits too. Past them, GitHub lists the **Claude Approvals** check as **Action required** :
+
+ * **Changed files** : 2,000 or more. The check’s title reads **Change too large to evaluate**. Split the pull request.
+ * **Commits** : more than 250, where a set excludes authors with `"!pr/authors"`. The title reads **Too many commits to tell who wrote it**. Have an author squash it to 250 commits or fewer and force-push.
+
+## Related resources
+
+ * [Set up Claude Approvals](</docs/en/approvals-setup>): turn on observe mode, enforce the policy, and require the **Claude Approvals** check
+ * [Troubleshoot Claude Approvals](</docs/en/approvals-troubleshooting>): fix a policy file that the check refuses
+ * [Claude Approvals classifiers](</docs/en/approvals-classifiers>): the classifiers that a condition can read, and how to define your own
Show diff (121 lines)
--- a/approvals-pull-requests.md
+++ b/approvals-pull-requests.md
@@ -0,0 +1,118 @@
+Where [Claude Approvals](</docs/en/approvals>) is on, it adds a check named **Claude Approvals** to the pull requests that it evaluates. The check reports who still has to approve the pull request, following a [policy file](</docs/en/approvals-policy>) in the repository. Where your repository requires the check, GitHub can block the merge until it passes. If your pull request has no check, for example because it’s a draft, see [No Claude Approvals check appeared](</docs/en/approvals-troubleshooting#no-claude-approvals-check-appeared>).
+
+## Get your pull request through Claude Approvals
+
+Approvals evaluates your pull request after events such as a push or an approval. It reports the result in two places on the pull request:
+
+ * **The Claude Approvals check** : in the list of checks at the bottom of the **Conversation** tab. The text beside its name, called its title, gives the approval status, such as **Waiting on human review from any person (1/2)**
+ * **Claude’s comment** : in the conversation, with the reasons for the result. Approvals edits the same comment as the result changes, so it stays where it first appeared
+
+To get to a passing check:
+
+ 1. **Read the approval status** : the check’s title says where your pull request stands, for example who still has to approve
+ 2. **Do what the status calls for** : find the title to see what that is. For example, ask someone with write access to approve, fix the findings that Code Review posted, or wait for a review to finish
+ 3. **Read the status again** : the title can change at the next evaluation, such as when someone approves or you push. After a push that changes the diff, [earlier approvals can stop counting](</docs/en/approvals-policy#earlier-approvals-after-a-new-push>)
+ 4. **Merge** : once the check passes, merge as your repository’s GitHub rules allow. Where the policy allows it, Claude can also post an approving review
+
+## Find your approval status and what to do next
+
+The **Claude Approvals** check gives your pull request’s approval status in its title, the text beside its name in the list of checks. Find your check’s title in these tables to see what it means and what to do next. For a title that isn’t here, open the **Claude Approvals** check’s summary, which gives the cause and the next step. To find who maintains the policy file, `.claude/approvals.yml`, see who last changed it on the default branch.
+
+### Approvals waits for people
+
+With these titles, Approvals is waiting for a person. Outside observe mode, GitHub lists the **Claude Approvals** check among its pending checks, marked **Action required**.
+
+Title| What to do
+---|---
+**Waiting on human review from any person (1/2)**| Ask someone with write access to approve. The numbers are the approvals counted so far and the approvals that the policy asks for, and the author usually [counts as one](</docs/en/approvals-policy#whether-a-pull-request%E2%80%99s-author-counts>) already. In place of “any person”, the title can name the people or the team that a rule asks for, or name nobody
+**Changes requested**| Have the reviewer who requested changes approve, or have a person dismiss their review
+**Claude’s approval still stands; dismiss it**| [Dismiss Claude’s review](<https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/dismissing-a-pull-request-review>), or ask someone who may dismiss reviews on the branch. GitHub didn’t let Approvals dismiss it
+
+### Approvals waits for Code Review or a classifier
+
+With these titles, Approvals is waiting for an answer from [Code Review](</docs/en/code-review-pull-requests>) or a [classifier](</docs/en/approvals-classifiers>), or didn’t get one:
+
+Title| What to do
+---|---
+**Waiting for Code Review** , **Waiting for repo/change_risk** , **Waiting for classifiers**| Nothing yet
+**A classifier had no result** , **A classifier has not run** , or a name in place of “A classifier”, as in **repo/change_risk has not run**| Rerun the Claude Approvals check. See [when a run gives no answer](</docs/en/approvals-classifiers#what-a-rule-sees-when-a-classifier-run-gives-no-answer>)
+
+### A rule or a policy file keeps Approvals from passing
+
+With these titles, a rule holds the pull request, no rule applies to a changed file, or a policy file can’t be used:
+
+Title| What to do
+---|---
+**Held by Code Review’s findings**| Fix the findings that Code Review posted on the pull request, then push. If the policy’s [`findings`](</docs/en/approvals-policy#findings>) list names you, you can resolve the findings’ threads. If the **Claude Approvals** check doesn’t pass after you resolve them, push a fix
+**Held by** and a rule’s purpose in quotes, **Held by a policy rule**| Ask whoever maintains the policy file what the rule in the check’s summary needs, then push a fix
+**No rule applies to** and a file’s name in quotes, **No rule applies to a changed file**| Ask whoever maintains the policy file for a rule with no `if` that covers the file. Rerun the check once that rule merges
+**This change breaks a policy file** , **Default branch policy file cannot be used**| [Fix the policy file](</docs/en/approvals-troubleshooting#fix-a-policy-file-that-approvals-refuses>)
+
+A failed Code Review from an earlier commit can still hold the check after you push a fix. If no new review starts, post a new comment with only [`@claude review`](</docs/en/code-review-pull-requests#comment-commands>), which takes write access.
+
+### Approvals passed or nothing ran
+
+With these titles, Approvals passed or didn’t evaluate the pull request:
+
+Title| What to do
+---|---
+**Passed; no approval from Claude**| If GitHub requires an approval, ask a person
+**Nothing ran, not blocking: no file is covered**| Nothing. If someone should review the files that the pull request changes, ask whoever maintains the [policy file](</docs/en/approvals-policy>) to cover them
+**Observe mode ended: not evaluated yet**| Push a commit or rerun the Claude Approvals check. If it passes, a pull request with auto-merge on or in a merge queue can merge at once
+
+Under **Passed; no approval from Claude** , Claude posts no approval in cases such as these:
+
+ * A rule says `claude: comments`
+ * A changed file has no rule, or is a [symlink, submodule pointer, or `.gitattributes` file](</docs/en/approvals-policy#protected-files>)
+ * `claude[bot]` opened the pull request, unless the Claude Approvals GitHub App is installed and linked
+
+## Approvals in observe mode
+
+In observe mode, the **Claude Approvals** check ends neutral, which GitHub counts as passing, with a title that starts **(observe mode)**. The check isn’t neutral in cases such as these:
+
+Case| What the check does
+---|---
+The pull request changes a policy or classifier file| It can wait for one person, who can be the author. It fails if the change breaks one of those files
+The default branch’s policy file can’t be used| It fails until you [fix the policy file](</docs/en/approvals-troubleshooting#fix-a-policy-file-that-approvals-refuses>)
+The title says Withheld| Approvals holds back a passing check, for example because another open pull request has the same latest commit. The check’s summary says what clears it
+The pull request targets another branch than the default| No check appears, unless the pull request changes a policy or classifier file
+
+## Comment commands for Approvals
+
+To use a command, post it as a new comment on the pull request. You need write access to the repository. A 😕 reaction on your comment means that the command wasn’t carried out in full.
+
+Command| What it does
+---|---
+`@claude approvals rerun`| Evaluates the latest commit again. Classifiers can run again, and are billed. Put it alone on the comment’s first line. On a fork’s pull request, read the change first, then add the latest commit’s full SHA and make that the comment’s only text
+`@claude approve`| Can count as your approval of the latest commit, for the **Claude Approvals** check. To name a commit, add its full SHA, which a pull request from a fork requires. Make it the comment’s only text
+`@claude approvals resolve <ids>`| Can close the findings with those IDs, if the policy’s [`findings`](</docs/en/approvals-policy#findings>) list names you. Put it alone on the first line, with one to eight finding IDs such as `f-1a2b3c4d`
+
+Approvals can also act on `@claude approvals rerun` from a GitHub App’s bot account. That comment starts an evaluation, where classifiers can run and are billed, and doesn’t vouch for a fork’s commit. Comment `@claude approve` on your own pull request when the check’s summary says that you [don’t count as an approval](</docs/en/approvals-policy#whether-a-pull-request%E2%80%99s-author-counts>). To withdraw that approval, edit or delete each of your `@claude approve` comments. Approvals doesn’t count an edited comment as an approval, so to approve again, post a new comment.
+
+## Pull requests from Claude, forks, and outside contributors
+
+A pull request that `claude[bot]` opened needs a second GitHub App before Claude can approve it. A pull request from a fork, or from a person without write access, can need a maintainer.
+
+### Pull requests that Claude opens
+
+GitHub doesn’t let the account that opened a pull request approve it. Without a second app, Claude gives no approval on a pull request that `claude[bot]` opened, and the **Claude Approvals** check can pass with the title **Passed; no approval from Claude**. To get Claude’s approval on those pull requests, add a second app:
+
+ 1. **Install it** : ask an owner of your GitHub organization to install the [Claude Approvals GitHub App](<https://github.com/apps/claude-approvals/installations/new>) on the repository.
+ 2. **Link it** : [link the app to your Claude organization](<https://claude.ai/settings/claude-approvals/github/finish>). That takes someone who is an owner of the GitHub organization and an Owner or Primary Owner of the Claude organization. If nobody is both, contact [Anthropic support](<https://support.claude.com>).
+
+Then rerun the check on an open pull request that `claude[bot]` opened. Leave the required check’s source as it is, because the [Claude GitHub App](<https://github.com/apps/claude>) still reports the check.
+
+### Pull requests from forks and outside contributors
+
+Approvals can’t confirm that someone with write access pushed a fork’s commits. On a fork’s pull request, Approvals can wait for a maintainer, meaning someone with write access:
+
+ * **Until a maintainer vouches for a commit** : no classifier’s answer counts, Code Review’s included. Where a rule depends on one, the **Claude Approvals** check’s title can read **No classifier result counts on this commit**.
+ * **To vouch for a commit** : outside observe mode, if you have write access, read the change. Then comment `@claude approvals rerun` followed by the latest commit’s full SHA, as the comment’s only text. Classifiers can then run for that commit. With no SHA, the command can cover the commit that was latest when you commented.
+ * **A pass waits for a maintainer** : outside observe mode, where a rule covers a changed file, the check also needs approval from someone with write access who didn’t open the pull request. That applies to a fork’s pull request, and to one that a person without write access opened. Until then, Claude doesn’t approve
+ * **A rule with`"!pr/authors"`**: no approval counts toward it on a fork’s pull request, and once someone approves, the check’s title can read **Cannot tell who wrote this change**. The check’s summary says what whoever maintains the policy file can change
+
+## Related resources
+
+ * [Claude Approvals](</docs/en/approvals>): what a policy is and what it affects
+ * [Troubleshoot Claude Approvals](</docs/en/approvals-troubleshooting>): when no check appears, or the check doesn’t pass
+ * [Claude Approvals policy file reference](</docs/en/approvals-policy>): the keys that a check’s summary names
Show diff (191 lines)
--- a/approvals-setup.md
+++ b/approvals-setup.md
@@ -0,0 +1,188 @@
+[Claude Approvals](</docs/en/approvals>) is a check on GitHub pull requests that reports who still has to approve. To turn it on in a repository, commit a [policy file](</docs/en/approvals-policy>) at `.claude/approvals.yml` in the repository’s root, on its default branch. Once the file is on the default branch, Approvals can start billing.
+
+## Prerequisites
+
+Setting up and enforcing Approvals takes each of these:
+
+ * A Claude organization that [qualifies](</docs/en/approvals#availability>), with [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) to pay for the model runs that a policy starts
+ * The [Claude GitHub App](<https://github.com/apps/claude>), installed on the repository and [linked to your Claude organization](</docs/en/admin-setup#connected-github-accounts>)
+ * Permission to merge into the default branch
+ * Admin access to the repository on GitHub, to require the **Claude Approvals** check. A private repository also needs a [paid GitHub plan](<https://docs.github.com/en/get-started/learning-about-github/githubs-plans>)
+ * Two people with write access, before you enforce either policy on this page. With only one, the check can’t pass on a change under `.claude/`, or where Claude’s review fails or gives no result. Under the policy that keeps two people on each change, it can’t pass on any change
+
+## Plan your first policy
+
+A [policy file](</docs/en/approvals-policy>) tells Approvals who has to approve a pull request. For your first one, decide whether Claude can approve, then copy the starter policy that matches:
+
+ * **Let Claude approve when Code Review passes** : a pull request that passes Claude’s review usually needs no approval from another person
+ * **Keep two people on each change** : a pull request usually needs one person besides the author, and Claude doesn’t approve
+
+Both policies start in observe mode, where the **Claude Approvals** check shows what the policy would decide, Claude doesn’t approve, and the check [normally counts as passing](</docs/en/approvals-pull-requests#approvals-in-observe-mode>). Both also name `claude/code_review`. Keep it in your policy file. Once the file is on the default branch, in observe mode or enforced, automatic Code Reviews normally stop where no matching rule names it.
+
+### Let Claude approve when Code Review passes
+
+Once this starter policy is enforced, a pull request that passes Claude’s review usually needs no approval from another person, except for changes under `.claude/`. Other pull requests usually need one person [besides the author](</docs/en/approvals-policy#whether-a-pull-request%E2%80%99s-author-counts>). In this policy, the first rule asks for two people on a change. Its `override` lowers that to one and lets Claude approve when `claude/code_review` reads `pass`. The second rule asks for two people on a change under `.claude/`:
+
+ # .claude/approvals.yml
+ version: 1
+ mode: observe
+ rules:
+ - purpose: "A change takes two people. When Claude's review passes, one is enough and Claude approves."
+ paths: ["**"]
+ verdict: { claude: comments, seats: 2 }
+ override:
+ - { if: "claude/code_review = pass", verdict: { claude: approves, seats: 1 } }
+ - purpose: "A change to the review rules takes two people."
+ paths: ["**/.claude/**"]
+ nested: inherit
+ verdict: { claude: comments, seats: 2 }
+
+This policy can start a billed Code Review at each push, and observe mode is billed. If your [Code Review settings](</docs/en/code-review-setup#set-when-reviews-run>) ask for fewer reviews, the policy adds to them.
+
+### Keep two people on each change
+
+This starter policy asks for two people on each change. Once the policy is enforced, a pull request usually needs one person besides the author, and Claude doesn’t approve. In this policy, both rules ask for two people. The first rule lists `claude/code_review` under [`advisory`](</docs/en/approvals-policy#advisory>), so reviews follow your Code Review settings:
+
+ # .claude/approvals.yml
+ version: 1
+ mode: observe
+ rules:
+ - purpose: "A change takes two people."
+ paths: ["**"]
+ verdict: { claude: comments, seats: 2 }
+ advisory: [claude/code_review]
+ - purpose: "A change to the review rules takes two people."
+ paths: ["**/.claude/**"]
+ nested: inherit
+ verdict: { claude: comments, seats: 2 }
+
+## Turn on Approvals in observe mode
+
+Add your policy file in a pull request of its own, then open a second pull request to see the **Claude Approvals** check:
+
+1
+
+Add the policy file
+
+In a pull request of its own, from a branch in the repository, add the policy at `.claude/approvals.yml` in the repository’s root.
+
+2
+
+Merge the pull request
+
+Merge when Claude comments that it “found the policy file in this change valid”. If the file is invalid, a failed check titled **This change breaks a policy file** appears. [Fix it](</docs/en/approvals-troubleshooting#fix-a-policy-file-that-approvals-refuses>) in this pull request.
+
+3
+
+Open another pull request
+
+Open one into the default branch that isn’t a draft. A **Claude Approvals** check appears with a title that starts **(observe mode)**.
+
+If nothing appears, see [No Claude Approvals check appeared](</docs/en/approvals-troubleshooting#no-claude-approvals-check-appeared>).
+
+## Enforce your policy and require Claude Approvals
+
+Enforce the policy once the **Claude Approvals** check titles that you see in observe mode match what your reviewers decide. From then on, the check can block a merge, and [Claude can approve](</docs/en/approvals-github-rules#merges-without-human-review>) where the policy allows it.
+
+### Decide which files and branches to protect
+
+Before you switch your policy from observe mode to enforcement, decide which files need a person, which branches the check gates, and when to change GitHub’s required approvals:
+
+ * **Files** : decide which ones need a person’s approval whatever Claude finds, then copy [this rule](</docs/en/approvals-github-rules#ask-for-a-person-who-isn%E2%80%99t-an-author>) and narrow its `paths`
+ * **Branches** : an enforced policy also covers pull requests into branches other than the default branch, so list each branch whose merges the **Claude Approvals** check should gate. On those branches, a pull request with no covered file gets no check, so a required check waits
+ * **GitHub’s required approvals** : [change the number of approvals that GitHub requires](</docs/en/approvals-github-rules#required-reviews-and-codeowners>) only after the last step of the switch
+
+### Switch from observe mode to enforcement
+
+A policy file’s [`mode`](</docs/en/approvals-policy#top-level-keys>) is one of these:
+
+ * **`observe`** : the **Claude Approvals** check shows what the policy would decide, Claude doesn’t approve, and the check [normally counts as passing](</docs/en/approvals-pull-requests#approvals-in-observe-mode>)
+ * **`enforce`** : the check can block a merge, and Claude can approve where the policy allows it. This is the default, so a policy file with no `mode` line is enforced
+
+To enforce your policy, follow these steps. After the first step, an open pull request can keep a check that GitHub counts as passing until you rerun Approvals on it. Keep open pull requests out of the merge queue until you have rerun Approvals on them in step 2.
+
+1
+
+Delete the mode: observe line
+
+Delete `mode: observe` and merge that change.
+
+2
+
+Rerun Approvals on open pull requests
+
+Five minutes after the merge, comment `@claude approvals rerun` on each one whose check title starts with **(observe mode)** or **Observe mode ended**. On a pull request from a fork, [read the change first and add the latest commit’s full SHA](</docs/en/approvals-pull-requests#pull-requests-from-forks-and-outside-contributors>).
+
+3
+
+Require Claude Approvals in GitHub
+
+For the default branch and each branch you listed, [require status checks to pass](<https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/managing-protected-branches/about-protected-branches#require-status-checks-before-merging>) and add **Claude Approvals**. As its source, select the Claude app that reported it.
+
+4
+
+Confirm that Approvals blocks a merge
+
+Open a pull request that changes a file under `.claude/`. When the check finishes, the title reads **Waiting on human review from any person (1/2)** , and GitHub’s merge box lists the check as required.
+
+Approvals later evaluates some of the pull requests that you didn’t rerun, which can start billed runs.
+
+### Set the source that GitHub accepts for Claude Approvals
+
+Set the required check’s source to the Claude app. With **any source** , GitHub accepts a check named **Claude Approvals** from elsewhere. To set the source through GitHub’s API, put the Claude app’s ID, `1236702`, in `integration_id` in a ruleset or `app_id` in a branch protection rule.
+
+## Control what Approvals spends
+
+Approvals bills your organization’s usage credits for the model runs that a policy starts, and observe mode is billed. Billing can start, and [continues, while usage credits are turned off](</docs/en/claude-ship#how-each-claude-ship-agent-is-billed>). To keep any policy file from starting billing, an Owner can turn off Approvals for the whole organization.
+
+### What Approvals costs
+
+A policy with `claude/code_review` in an `if` condition can start a [billed Code Review](</docs/en/code-review-costs>) when a pull request opens and at each push. To stop those reviews, move it from the conditions to `advisory`. When `claude/code_review` is only under `advisory`, with no [`level`](</docs/en/approvals-classifiers#read-a-classifier%E2%80%99s-answer-from-a-rule>), reviews follow your Code Review settings. A rule can also read other [classifiers](</docs/en/approvals-classifiers>). For `claude/diff` and custom classifiers, each [run that calls a model](</docs/en/approvals-classifiers#what-a-classifier-run-costs>) is billed. To limit each run of a custom classifier, set its [`budget`](</docs/en/approvals-classifiers#budget>).
+
+### Limit what a policy costs
+
+To cap what your organization pays for the Code Reviews and classifier runs that a policy starts, set a spend limit. Set any of these limits at [**Organization settings > Usage**](<https://claude.ai/admin-settings/usage>), which takes an Owner role:
+
+ * **Your organization’s spend limit for usage credits** : covers Approvals
+ * **Code Review’s spend limit** : covers a policy’s reviews together with Code Review’s other reviews. Under **Services** , open the **Claude Code Review** row’s menu and select **Edit spend limit**
+ * **Classifier runs’ spend limit** : under **Services** , open the Approvals row’s menu and select **Edit spend limit**. The row has no limit when it appears
+
+On that page, the **Claude Code Review** row under **Services** can start without a limit:
+
+ * **The row shows a dash where the limit goes** : a monthly limit is set for you when a policy’s first billed review starts. Change it once the amount shows
+ * **Code Review was turned on before your policy** : the row has no limit until you set one
+
+If a reseller bills your organization, ask your reseller for a limit. At Code Review’s limit, a check that needs Claude’s review can stop passing. Raise the limit or wait for the [next billing period](</docs/en/code-review-costs#limit-your-spend>).
+
+## Turn off Approvals
+
+You can turn off Approvals for one repository, for a GitHub organization, or for your whole Claude organization.
+
+Suspend or uninstall the Claude GitHub App, or unlink your GitHub organization, only after you turn off Approvals. If you do it first, new commits get no check, so a required check can block merges. GitHub can also continue to count Claude’s approving reviews that are left on open pull requests.
+
+Follow this order:
+
+ 1. **Check how GitHub treats stale approvals** : where GitHub requires approvals, turn on [**Dismiss stale pull request approvals when new commits are pushed**](</docs/en/approvals-github-rules#required-reviews-and-codeowners>). Otherwise, GitHub can continue to count Claude’s approving review after a new push, until you dismiss the review in the last step.
+ 2. **Stop requiring the check** : in GitHub, remove **Claude Approvals** from the required checks of each branch protection rule and ruleset.
+ 3. **Turn Approvals off** : choose how, by the scope that you want.
+ 4. **Dismiss Claude’s reviews** : on open pull requests that Claude approved, dismiss that review in GitHub.
+
+To stop the check from blocking without turning Approvals off, first stop requiring it on branches other than the default branch. Then put `mode: observe` in every policy file. The check then normally stops blocking, and classifiers still run and bill. Pull requests into those other branches get no check unless they change a policy or classifier file.
+
+### Ways to turn off Approvals
+
+To turn off Approvals, find the scope that you want in this table:
+
+Scope| How to turn off Approvals
+---|---
+One repository, without an Owner| Delete every policy file from the default branch
+A GitHub organization, or a repository whose **Edit** dialog shows **Claude Approvals**| With an [Owner role](</docs/en/server-managed-settings#access-control>), go to [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-ship>), click **Edit** on its row, and turn off **Claude Approvals**
+The whole Claude organization| With an Owner role, go to [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-ship>) and click **Block globally** in the **Approve** row. To turn it back on, click **Allow policy files** in the same row
+
+What you turn off for the whole Claude organization stays off when a policy file merges later. If you’re turning off Code Review too, turn off Approvals first, because a policy can start billed reviews where Code Review is off.
+
+## Related resources
+
+ * [Claude Approvals policy file reference](</docs/en/approvals-policy>): keys and an example policy
+ * [Approvals and your GitHub rules](</docs/en/approvals-github-rules>): what can merge without a person, and who can change the policy
+ * [Troubleshoot Claude Approvals](</docs/en/approvals-troubleshooting>): when no check appears, or the check refuses a policy file
--- a/approvals-troubleshooting.md
+++ b/approvals-troubleshooting.md
@@ -0,0 +1,86 @@
+[Claude Approvals](</docs/en/approvals>) is a check on GitHub pull requests that reports who still has to approve. Start here when the check didn’t appear or doesn’t pass, when Approvals refuses a policy file, or when a classifier gives no answer. If the **Claude Approvals** check on your pull request has a title that isn’t covered here, see [Find your approval status and what to do next](</docs/en/approvals-pull-requests#find-your-approval-status-and-what-to-do-next>).
+
+## No Claude Approvals check appeared
+
+When [Claude Approvals](</docs/en/approvals>) can’t run, it can post nothing at all.
+
+### Check your pull request and policy file
+
+Start with the causes that you can check yourself:
+
+Cause| What to do
+---|---
+The pull request is a draft| Mark it ready for review
+The [policy file](</docs/en/approvals-policy#where-to-put-a-policy-file>) isn’t where Approvals looks| Put it at `.claude/approvals.yml` in the repository’s root, on the default branch, with `version: 1`
+Nothing has happened since the file merged| Push a commit to the pull request
+The policy is in observe mode, and the pull request targets a branch other than the default branch| Expect no check, unless the pull request changes a policy or classifier file
+The policy is enforced, and no rule covers any file that the pull request changes| See [what happens when no rule covers a file](</docs/en/approvals-policy#how-rules-combine-into-one-verdict>)
+
+### Claude left a comment and no Approvals check
+
+Find the words of Claude’s comment, then take the step beside them:
+
+Comment says| What to do
+---|---
+Approvals “did not run on this change”| Do what the comment says. One cause is a pull request that moves a file into or out of the paths that the policy’s rules cover. Make that move in two pull requests, one that adds the file under its new name and one that removes the old one
+”More than one Claude organization is connected to this GitHub account”| Ask an Owner of the Claude organization that should run Approvals to click **Connect** next to the repository’s GitHub organization on [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-ship>). Then push a commit
+”Claude Approvals can’t start in this repository yet”| Tell an Owner that the organization has no usage credits available
+
+### Ask an Owner to check your Claude organization
+
+Ask an Owner to check each of these for your Claude organization:
+
+What to check| Where
+---|---
+Whether the organization qualifies| [Availability](</docs/en/approvals#availability>)
+Whether the [Claude GitHub App](<https://github.com/apps/claude>) can access the repository and is linked| [**Organization settings > Git providers**](<https://claude.ai/admin-settings/source-control>)
+Whether Approvals is turned off here| The **Approvals** column and the **Approve** row on [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-ship>)
+
+## Approvals doesn’t pass after you resolve a review thread
+
+Check whether your policy’s [`findings`](</docs/en/approvals-policy#findings>) list names you. If your resolve doesn’t count, push a fix, or ask someone on the list to resolve the thread.
+
+## Approvals passed and GitHub still blocks merging
+
+Read the rule that GitHub’s merge box names. If it asks for a review, GitHub’s branch rules require one that the policy doesn’t, so have someone other than the author approve in a GitHub review. For what GitHub counts, see [Required reviews and CODEOWNERS](</docs/en/approvals-github-rules#required-reviews-and-codeowners>).
+
+## Fix a policy file that Approvals refuses
+
+Find the **Claude Approvals** check’s title in this table:
+
+Title| Copy at fault| Messages| What to do
+---|---|---|---
+**This change breaks a policy file**| The pull request’s own| **Policy files in this change** , in the check’s summary| Fix it in this pull request
+**Default branch policy file cannot be used** , **Default branch policy file must be version 1** , **Default branch policy file is too large**| The root policy file on the default branch| The check’s summary| Fix it in a new pull request from a branch of this repository. Its **Policy files in this change** shows whether the new copy loads. That pull request’s check fails, as every pull request’s check does, in observe mode or enforced. Where the branch requires the check, ask someone who can bypass the branch rules to merge it
+**A policy file cannot be used**| A directory’s policy file on the default branch| The check’s summary| Fix it as you would the root policy file
+
+After the fix merges, allow five minutes, then comment [`@claude approvals rerun`](</docs/en/approvals-pull-requests#comment-commands-for-approvals>) on each open pull request whose check hasn’t updated. On one from a fork, [read the change first and add the latest commit’s full SHA](</docs/en/approvals-pull-requests#pull-requests-from-forks-and-outside-contributors>).
+
+### Policy file refusal messages
+
+One refusal makes the whole policy file unusable, and a warning fails nothing. Find the beginning of your message here:
+
+Message| Fix
+---|---
+”no key of this name is read at this place”| Check the key’s spelling and its level against [Top-level keys](</docs/en/approvals-policy#top-level-keys>) and [Rule keys](</docs/en/approvals-policy#rule-keys>)
+”this names no fact and no usable classifier”| Check the name against the [facts](</docs/en/approvals-policy#if>). For `repo/<name>`, check that `.claude/classifiers/<name>/def.yml` loads, beside the policy file or in a directory above it
+”a condition has no NOT”| Write the opposite operator
+”no local has this name”| Define the local in this file or a policy file above it. Write a login or a team with no `@`
+”this is not YAML”| Look near the line that the message names for a quote or bracket that doesn’t close, or a tab. Indent with spaces
+
+## A classifier gave no answer or its definition is refused
+
+To see each [classifier](</docs/en/approvals-classifiers>) run’s state and the reason for a missing answer, open **Classifier results** in Claude’s comment on the pull request. If a run reached its budget, split the pull request, or raise a `time` or `cost` that is under its [maximum](</docs/en/approvals-classifiers#budget>). Then find the **Claude Approvals** check’s title here:
+
+Title| What to do
+---|---
+**A classifier definition is not valid** , or **This change breaks a policy file** where a policy file names the classifier| Fix the definition in this pull request. The refusal messages are under **Policy files in this change**
+**A classifier’s definition cannot be used**| Fix the definition on the default branch. A pull request that changes it shows why it’s refused
+**Cannot evaluate: classifier outside advisory**| With a policy file in a subdirectory, some custom classifiers [belong only under `advisory`](</docs/en/approvals-policy#policy-files-in-subdirectories>). Move the classifier there
+**repo/change_risk reached its run limit** , with your classifier’s name, or **A classifier reached its run limit**| Push a change to the diff. Or comment `@claude approvals rerun` for one more run, which can drop every classifier’s result, passing ones too
+
+## Related resources
+
+ * [Work with Claude Approvals on a pull request](</docs/en/approvals-pull-requests>): check titles and comment commands
+ * [Set up Claude Approvals](</docs/en/approvals-setup>): requirements, the starter policy, and the required check
+ * [Claude Approvals policy file reference](</docs/en/approvals-policy>): the policy file’s keys
--- a/artifacts.md
+++ b/artifacts.md
@@ -57,7 +57,7 @@
Add a per-region breakdown below the summary chart and republish.
-Anyone with the page open sees the update in place. Each publish becomes a version, and from the **Share** control in the page header you can choose which version viewers see. To update an artifact from a different session, give Claude its URL, or attach it with `/artifacts`. Without either, a new session creates a new artifact instead of updating one.
+To update an artifact from a different session, give Claude its URL, or attach it with `/artifacts`. Without either, a new session creates a new artifact instead of updating one.
Update https://claude.ai/code/artifact/5fbea6f3-... with today's numbers.
--- a/champion-kit.md
+++ b/champion-kit.md
@@ -101,7 +101,7 @@
---|---|---
A dedicated channel| Create a `#claude-code` channel (or a recurring thread in an existing one), pin the [Quickstart](</docs/en/quickstart>) link and one strong example, and answer questions publicly so each answer benefits everyone watching.| About five minutes to set up, then ambient
A weekly show-and-tell thread| Each Friday, post “What did Claude help you with this week?” No preparation, slides, or meeting are required; screenshots and short descriptions are sufficient.| About two minutes per week
-Share a custom skill| Post your most useful `.claude/skills/<name>/SKILL.md` file, for example a `/ship` skill that runs tests and lint before committing, with a one-line description. Because skills are plain Markdown, colleagues can adopt them immediately.| About five minutes per skill
+Share a custom skill| Post your most useful `.claude/skills/<name>/SKILL.md` file, for example a `/precommit` skill that runs tests and lint before committing, with a one-line description. Because skills are plain Markdown, colleagues can adopt them immediately.| About five minutes per skill
Generate a setup guide from your own usage| Run `/team-onboarding` in a project you have spent real time in. Claude scans your recent sessions, commands, and MCP servers, then produces a guide a new teammate can paste as their first message to replay your setup. Pin it in the channel.| About two minutes
Pair on a first task| Offer a single fifteen-minute pairing session to anyone getting started. One successful outcome on their own code is more persuasive than any presentation.| About fifteen minutes per person
Identify the next champion| The colleague who asks you the most questions is usually ready to take on this role. Forward them this page and divide the channel responsibilities between you.| Negligible
--- a/channels-reference.md
+++ b/channels-reference.md
@@ -22,7 +22,7 @@
## What you need
-The only hard requirement is the [`@modelcontextprotocol/sdk`](<https://www.npmjs.com/package/@modelcontextprotocol/sdk>) package and a Node.js-compatible runtime. [Bun](<https://bun.sh>), [Node](<https://nodejs.org>), and [Deno](<https://deno.com>) all work. The pre-built plugins in the research preview use Bun, but your channel doesn’t have to. Your server needs to:
+The only hard requirement is the [`@modelcontextprotocol/sdk`](<https://www.npmjs.com/package/@modelcontextprotocol/sdk>) package and a Node.js-compatible runtime. [Bun](<https://bun.sh>), [Node](<https://nodejs.org>), and [Deno](<https://deno.com>) all work. Your server needs to:
1. Declare the `claude/channel` capability so Claude Code registers a notification listener
2. Emit `notifications/claude/channel` events when something happens
@@ -205,7 +205,7 @@
## Expose a reply tool
-If your channel is two-way, like a chat bridge rather than an alert forwarder, expose a standard [MCP tool](<https://modelcontextprotocol.io/docs/concepts/tools>) that Claude can call to send messages back. Nothing about the tool registration is channel-specific. A reply tool has three components:
+If your channel is two-way, like a chat bridge rather than an alert forwarder, expose a standard [MCP tool](<https://modelcontextprotocol.io/docs/concepts/tools>) that Claude can call to send messages back. A reply tool has three components:
1. A `tools: {}` entry in your `Server` constructor capabilities so Claude Code discovers the tool
2. Tool handlers that define the tool’s schema and implement the send logic
--- a/chrome.md
+++ b/chrome.md
@@ -58,7 +58,7 @@
If Claude Code asks for permission before a browser action, approve it. The dialog starts with `Claude in Chrome wants to` and offers an option to allow all actions on that site for the session. Claude opens a new tab and starts the task.
-Run `/chrome` at any time to check the connection status, manage permissions, reconnect the extension, or choose which connected browser to use. The integration is working when the status panel shows “Status: Enabled” and “Extension: Installed”. If more than one browser is connected, you choose which one Claude uses. When a browser action starts before you’ve chosen, Claude prompts you to pick one. To switch browsers later, run `/chrome` and choose another browser. Claude keeps using your choice even when another browser connects. For VS Code, see [browser automation in VS Code](</docs/en/vs-code#automate-browser-tasks-with-chrome>).
+Run `/chrome` at any time to check the connection status, manage permissions, reconnect the extension, or choose which connected browser to use. If more than one browser is connected, you choose which one Claude uses. When a browser action starts before you’ve chosen, Claude prompts you to pick one. To switch browsers later, run `/chrome` and choose another browser. Claude keeps using your choice even when another browser connects. For VS Code, see [browser automation in VS Code](</docs/en/vs-code#automate-browser-tasks-with-chrome>).
### Install the extension when Claude asks
@@ -78,6 +78,8 @@
To connect Chrome without passing `--chrome` each time, run `/chrome` in a CLI session and select the option that turns Chrome on by default. In the [VS Code extension](</docs/en/vs-code#automate-browser-tasks-with-chrome>), type `/chrome` in the prompt box and turn on the **Enabled by default** switch. The CLI and VS Code share one setting, so turning it on in either place turns it on for both. With the setting on and Claude Code v2.1.287 or later, each VS Code session connects to your browser as it starts, so Claude can use it before you type `@browser`. On earlier versions, or with the setting off, a VS Code session connects when you type `@browser`. Claude Code starts normally when Chrome isn’t running.
Enabling Chrome by default increases context usage since the browser tools and their instructions are always loaded. If you notice increased context consumption, turn the setting off and connect only when needed, with `--chrome` in the CLI or by typing [`@browser`](</docs/en/vs-code#automate-browser-tasks-with-chrome>) in the VS Code prompt box.
+
+To start one CLI session without Chrome and leave the setting on, run [`claude --no-chrome`](</docs/en/cli-reference#cli-flags>) in your terminal.
### Answer the startup dialog
modified
Claude apps gateway for Amazon Bedrock, Claude Platform on AWS, Google Cloud, and Microsoft Foundry
View current →
--- a/claude-apps-gateway.md
+++ b/claude-apps-gateway.md
@@ -41,7 +41,7 @@
You need| Details
---|---
-Claude Code v2.1.195 or later| The `claude gateway` subcommand and the gateway sign-in flow ship in v2.1.195. Earlier public builds don’t include them. Both the machine running the gateway server and each developer’s machine must be on v2.1.195 or later; run `claude update` to get the latest release. The [Claude Platform on AWS upstream](</docs/en/claude-apps-gateway-config#claude-platform-on-aws>) requires Claude Code v2.1.198 or later on the gateway server.
+Claude Code v2.1.195 or later| The `claude gateway` subcommand and the gateway sign-in flow ship in v2.1.195. Both the machine running the gateway server and each developer’s machine must be on v2.1.195 or later; run `claude update` to get the latest release. The [Claude Platform on AWS upstream](</docs/en/claude-apps-gateway-config#claude-platform-on-aws>) requires Claude Code v2.1.198 or later on the gateway server.
OpenID Connect (OIDC) identity provider| Okta, Microsoft Entra ID, Google Workspace, Keycloak, or Dex, or any other OIDC-compliant IdP such as PingFederate. The gateway runs standard OIDC discovery and the authorization-code flow against it. SAML and LDAP aren’t supported.
PostgreSQL 11 or later| Backs the device sign-in flow and rate-limit counters. A managed PostgreSQL service works, including the smallest tier; see [which databases are supported](</docs/en/claude-apps-gateway-deploy#postgres>). With [spend limits](</docs/en/claude-apps-gateway-spend-limits>), it also holds durable spend, audit, and identity tables that should be backed up. TLS via `?sslmode=require` is recommended. PostgreSQL 11, 12, and 13 require Claude Code v2.1.290 or later on the gateway server. The PostgreSQL project no longer maintains those versions, so use a newer one where you can.
Model upstream| Amazon Bedrock credentials, Claude Platform on AWS credentials, Google Cloud credentials, a Microsoft Foundry resource, or an Anthropic API key. Multiple upstreams are supported with failover.
@@ -114,13 +114,13 @@
Run it
-Build a container image around the `claude` binary that meets the [image requirements](</docs/en/claude-apps-gateway-deploy#container-image>), then run it alongside Postgres. The Compose file references the image as `registry.example.com/claude-gateway:2.1.198`; substitute your own registry and image tag:
+Build a container image around the `claude` binary that meets the [image requirements](</docs/en/claude-apps-gateway-deploy#container-image>), then run it alongside Postgres. The Compose file references the image as `registry.example.com/claude-gateway:<version>`; substitute your own registry and image tag:
docker-compose.yaml
services:
gateway:
- image: registry.example.com/claude-gateway:2.1.198
+ image: registry.example.com/claude-gateway:<version>
ports: ["8080:8080"]
volumes: ["./gateway.yaml:/etc/claude/gateway.yaml:ro"]
environment:
@@ -153,7 +153,7 @@
[gateway] 2026-06-10T17:03:21.431Z info migration 6 applied
[gateway] 2026-06-10T17:03:21.512Z info claude gateway listening on http://0.0.0.0:8080
-The gateway also logs a warning that `access_control.allow_cidrs` is empty. That’s expected here, because nothing limits which client addresses the gateway serves until you set an allow list. The [`access_control` reference](</docs/en/claude-apps-gateway-config#http-tuning>) has the recommended ranges.If boot exits before the `claude gateway listening on` line, the last line of stderr names the problem:
+The startup banner reminds you each time to keep the gateway on your private network. With this config, the gateway serves any client address. To limit which addresses it serves, set `access_control`; the [`access_control` reference](</docs/en/claude-apps-gateway-config#http-tuning>) has the recommended ranges.If boot exits before the `claude gateway listening on` line, the last line of stderr names the problem:
* an unreachable Postgres
* a Postgres role without DDL permission
--- a/claude-apps-gateway-config.md
+++ b/claude-apps-gateway-config.md
@@ -1176,10 +1176,10 @@
To change what the picker offers, use one of these:
- * **Start users on the 1M option** : set `modelPrefer1mContext: true` in the policy’s `desktop` block. Users who haven’t yet chosen a model start on the 1M option when the first listed model has one. Users who already chose a model keep their choice.
+ * **Show only the 1M option** : set [`modelPrefer1mContext`](<https://claude.com/docs/third-party/claude-desktop/configuration#modelprefer1mcontext>) to `true` in the policy’s `desktop` block. You need Claude Desktop 2.31226.0 or later on members’ machines.
* **Offer the option by hand** : do this if your gateway server runs a version older than v2.1.284, or an entry names no Claude model. List the model twice in `models`, once with its plain ID and once with `[1m]` appended, both with the same `upstream_model` map. Claude Desktop shows the pair as one model with a 1M option. The gateway serves a `[1m]` entry without checking it, so add one only for a model your upstreams serve at 1M.
-This example offers the option by hand for a custom alias routed to an application inference profile, and starts new users on it:
+This example lists a custom alias and its `[1m]` variant, both routed to an application inference profile, and sets `modelPrefer1mContext`:
models:
- id: corp-sonnet
@@ -1325,10 +1325,16 @@
`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>).
`rate_limits`| `device_verify.max` / `.window_seconds`| 10 / 600| Per-IP rate limit on `user_code` submissions at `/device`. It is what stops someone from guessing another developer’s code. [Large rollouts](</docs/en/claude-apps-gateway-deploy#large-rollouts>) shows how far to raise it.
-If you leave both `access_control` lists empty, which is the default, the gateway serves any client address, so only your network restricts who can reach it. That matters because a gateway can push managed settings that run commands on developer machines. While `allow_cidrs` is empty, the gateway warns in two places, without changing how it answers any request:
-
- * **At boot** : a warning in the operational log recommends allowing only the private ranges `10.0.0.0/8`, `172.16.0.0/12`, `192.168.0.0/16`, `100.64.0.0/10`, `127.0.0.0/8`, `::1/128`, and `fc00::/7`, plus any other internal ranges your developers connect from. If you bind the gateway to a loopback address and set neither `trusted_proxies` nor `public_url`, as in local development, the warning doesn’t appear.
- * **At runtime** : the first time a request arrives from an address outside those private ranges, the gateway logs a warning and emits an [`access.public_client` audit event](</docs/en/claude-apps-gateway-deploy#logs>) carrying the client IP. Both fire once per process. Link-local addresses, `169.254.0.0/16` and `fe80::/10`, don’t count as public. The gateway answers `/healthz` and `/readyz` before this check runs, so health probes from public ranges don’t trigger it.
+If you leave both `access_control` lists empty, which is the default, the gateway serves any client address, so only your network restricts who can reach it. That matters because a gateway can push managed settings that run commands on developer machines. To refuse clients from outside your network, set `allow_cidrs` to these private ranges, plus any other internal ranges your developers connect from:
+
+ * **IPv4** : `10.0.0.0/8`, `172.16.0.0/12`, `192.168.0.0/16`, `100.64.0.0/10`, and `127.0.0.0/8`
+ * **IPv6** : `::1/128` and `fc00::/7`
+
+While `allow_cidrs` is empty, the gateway watches for requests from outside the private ranges above, without changing how it answers them:
+
+ * **Once per process** : when it serves such a request, the gateway logs a warning and emits an [`access.public_client` audit event](</docs/en/claude-apps-gateway-deploy#logs>) carrying the client IP.
+ * **Not counted as public** : link-local addresses, `169.254.0.0/16` and `fe80::/10`.
+ * **Not checked** : health probes to `/healthz` and `/readyz`, which the gateway answers before this check runs.
Both signals use the client address as the gateway resolves it. If a load balancer, port-forward, or tunnel relays traffic and isn’t listed in `listen.trusted_proxies`, the gateway sees the relay’s address, which is usually private, so neither the runtime warning nor a private allow list catches traffic relayed through it. If the relay belongs in `listen.trusted_proxies`, list it there. Keep the gateway and everything in front of it unreachable from the public internet regardless.
--- a/claude-apps-gateway-deploy.md
+++ b/claude-apps-gateway-deploy.md
@@ -130,7 +130,7 @@
{"severity":"INFO","time":"2026-11-04T17:03:21.512Z","message":"claude gateway listening on http://0.0.0.0:8080"}
-`severity` is the log level in capitals, with `warn` written as `WARNING`. A failed start is an `ERROR` line. Audit events, which also go to stderr, don’t change. They carry `ts` and `evt`, and no `severity`.
+`severity` is the log level in capitals, with `warn` written as `WARNING`. A failed start is an `ERROR` line. On every start, the gateway also writes one `WARNING` line reminding you to keep it off the public internet, whatever your network setup. To hide it, set `CLAUDE_GATEWAY_LOG_LEVEL=error` in the gateway’s environment; your collector then gets only the operational log’s `ERROR` lines. Audit events, which also go to stderr, don’t change. They carry `ts` and `evt`, and no `severity`.
### Health
@@ -337,8 +337,8 @@
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.
Log: a warning that contains `upstream <name>: Google issued an access token that expires in <N>s`, on an upstream whose Google credentials file has type `external_account`| Requests succeed until that access token expires, then fail unless the token `credential_source` points to was renewed first.| If a process writes that token to a file, have it write a new one more than five minutes before the old one expires
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.
-On an upstream other than `provider: anthropic`, a turn with a long thinking pause fails. The proxy in front of the gateway logs one request that stays open for about 12.5 minutes, then a run of `504` errors| Claude Code ended a stream that had delivered its first response event and then carried only keepalive pings. It re-sent the request without streaming, and each reply takes longer than the proxy’s timeout.| Raise `CLAUDE_STREAM_IDLE_TIMEOUT_MS` for your developers. See Long thinking ends in proxy timeouts.
-On `provider: anthropic`, a turn with a long thinking pause fails. The proxy logs one request open for about 20 minutes, then `502` or `504` errors| Claude Code ended a stream that had delivered its first response event and then carried only keepalive pings. It re-sent the request without streaming, and each reply takes longer than the gateway’s wait on the upstream, `timeouts.upstream_ttfb_ms`, or the proxy’s timeout.| Raise `CLAUDE_STREAM_IDLE_TIMEOUT_MS` for your developers. See Long thinking on an Anthropic API upstream.
+On an upstream other than `provider: anthropic`, a turn with a long thinking pause fails. The proxy in front of the gateway logs one or two requests, each open for about 12.5 minutes, then a run of `504` errors| Claude Code ended a stream that had delivered its first response event and then carried only keepalive pings. It re-sent the request without streaming, and each reply takes longer than the proxy’s timeout.| Raise `CLAUDE_STREAM_IDLE_TIMEOUT_MS` for your developers. See Long thinking ends in proxy timeouts.
+On `provider: anthropic`, a turn with a long thinking pause fails. The proxy logs one or two requests, each open for about 20 minutes, then `502` or `504` errors| Claude Code ended a stream that had delivered its first response event and then carried only keepalive pings. It re-sent the request without streaming. Each reply takes longer than the gateway’s `timeouts.upstream_ttfb_ms` wait or the proxy’s timeout.| Raise `CLAUDE_STREAM_IDLE_TIMEOUT_MS` for your developers. See Long thinking on an Anthropic API upstream.
A developer’s requests fail with `API Error: 400 you aren't in a group that can use this gateway. Ask your administrator to add you to one`| Every upstream has a [`groups` list](</docs/en/claude-apps-gateway-config#what-happens-when-a-developer-is-in-no-listed-group>), and the developer’s session carries none of the listed groups.| Add the developer to a listed group in your IdP, or list an upstream with no `groups` last to serve everyone else. The gateway reads groups again at the developer’s next token refresh. If the IdP left groups out and its userinfo endpoint returns them, set [`oidc.userinfo_fallback: true`](</docs/en/claude-apps-gateway-config#oidc>).
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`.
Sessions don’t silently renew after setting `oidc.scopes`| `offline_access` was dropped from the override| Add `offline_access` back if your IdP supports it. Without a refresh token, developers re-run the browser login every `session.ttl_hours`.
@@ -371,10 +371,10 @@
### Long thinking ends in proxy timeouts
-If your upstream is `provider: anthropic`, use Long thinking on an Anthropic API upstream instead: you raise `CLAUDE_STREAM_IDLE_TIMEOUT_MS` there too, but the times and errors differ. If turns fail after long thinking and your proxy logs one request open for about 12.5 minutes, then a run of `504` errors, raise [`CLAUDE_STREAM_IDLE_TIMEOUT_MS`](</docs/en/env-vars>) in a gateway policy. For example, with a 240-second idle timeout on the proxy, the run is 10 requests, each cut at 240 seconds.
-
- * **The first request** : a stream that delivers its first response event, `message_start`, and then only pings while Claude thinks. With default settings, Claude Code ends that stream after about 12.5 minutes.
- * **The other 10** : the same request, sent [without streaming](</docs/en/errors#streaming-response-ended-before-any-complete-data-was-received>) and then retried, 10 sends in all by default. They get no pings, so a slow reply hits the proxy’s timeout.
+If your upstream is `provider: anthropic`, use Long thinking on an Anthropic API upstream instead: you raise `CLAUDE_STREAM_IDLE_TIMEOUT_MS` there too, but the times and errors differ. If turns fail after long thinking and your proxy logs one or two roughly 12.5-minute requests followed by a run of `504` errors, raise [`CLAUDE_STREAM_IDLE_TIMEOUT_MS`](</docs/en/env-vars>) in a gateway policy.
+
+ * **Each long request** : a stream that delivers its first response event, `message_start`, and then only pings while Claude thinks. With default settings, Claude Code ends that stream after about 12.5 minutes.
+ * **The`504` errors**: Claude Code re-sends the request [without streaming](</docs/en/errors#streaming-response-ended-before-any-complete-data-was-received>), then retries. Those requests get no pings, so a slow reply hits the proxy’s timeout. For example, with a 240-second idle timeout on the proxy, each one ends at 240 seconds.
You don’t need a longer proxy timeout for this fix. If you raise only the proxy’s timeout, requests without streaming still fail once a reply takes longer than Claude Code’s own wait, 300 seconds by default.
@@ -396,7 +396,7 @@
`900000`| About 22.5 minutes
`1800000`| About 37.5 minutes
-If an upstream hangs while the gateway keeps sending pings, your developers also wait that long before Claude Code gives up on the stream.
+If an upstream hangs while the gateway keeps sending pings, plan for up to two streams of that length before Claude Code gives up on streaming.
#### Deliver the value in a policy
@@ -413,9 +413,9 @@
### Long thinking on an Anthropic API upstream
-If `provider: anthropic` is the model’s only upstream and your proxy logs one request open for about 20 minutes, then `502` or `504` errors, raise [`CLAUDE_STREAM_IDLE_TIMEOUT_MS`](</docs/en/env-vars>) in a gateway policy.
-
- * **The long request** : a stream that delivers `message_start` and then only pings while Claude thinks. Claude Code ends it after about 20 minutes with default settings, and later once you raise the variable.
+If `provider: anthropic` is the model’s only upstream and your proxy logs one or two roughly 20-minute requests followed by `502` or `504` errors, raise [`CLAUDE_STREAM_IDLE_TIMEOUT_MS`](</docs/en/env-vars>) in a gateway policy.
+
+ * **Each long request** : a stream that delivers `message_start` and then only pings while Claude thinks. Claude Code ends it after about 20 minutes with default settings, and later once you raise the variable.
* **The errors** : requests that Claude Code then sends [without streaming](</docs/en/errors#streaming-response-ended-before-any-complete-data-was-received>). Each one fails with a `502` from the gateway, or with your proxy’s `504` if the proxy’s timeout is shorter than the gateway’s wait. That wait is [`timeouts.upstream_ttfb_ms`](</docs/en/claude-apps-gateway-config#http-tuning>), which you don’t need to raise for this fix.
To confirm the cause, see Confirm the cause. Pick the value whose time covers your longest thinking pause: about 20 minutes at the default, 30 at `900000`, and 45 at `1800000`. Then follow Deliver the value in a policy.
--- a/claude-apps-gateway-on-gcp.md
+++ b/claude-apps-gateway-on-gcp.md
@@ -105,7 +105,7 @@
--ranges="google-managed-services-${VPC}" --network="$VPC"
gcloud sql instances create claude-gateway-db \
- --database-version=POSTGRES_16 --tier=db-g1-small --region="$REGION" \
+ --database-version=POSTGRES_16 --edition=enterprise --tier=db-g1-small --region="$REGION" \
--network="projects/${PROJECT_ID}/global/networks/${VPC}" --no-assign-ip
gcloud sql databases create claude_gateway --instance=claude-gateway-db
PGPASS="$(openssl rand -hex 24)"
@@ -245,7 +245,7 @@
kubectl annotate serviceaccount gateway -n claude-gateway \
iam.gke.io/gcp-service-account="claude-gateway@${PROJECT_ID}.iam.gserviceaccount.com"
-Deploy the gateway as a standard Deployment plus a Service and an internal Ingress, class `gce-internal`, as described in [Kubernetes deployment](</docs/en/claude-apps-gateway-deploy#kubernetes>), with:
+An internal Ingress needs a proxy-only subnet in `$REGION` on the VPC, and a firewall rule that allows traffic from that subnet to port `8080` on the gateway pods. Create both as Google’s [internal Ingress guide](<https://cloud.google.com/kubernetes-engine/docs/how-to/internal-load-balance-ingress>) describes.Deploy the gateway as a standard Deployment plus a Service and an internal Ingress, class `gce-internal`, as described in [Kubernetes deployment](</docs/en/claude-apps-gateway-deploy#kubernetes>), with:
* `serviceAccountName: gateway`
* the Secret Manager CSI driver mounting secrets at `/secrets`
--- a/claude-code-on-the-web.md
+++ b/claude-code-on-the-web.md
@@ -213,7 +213,7 @@
### Manage context
-Cloud sessions support [built-in commands](</docs/en/commands>) that produce text output. Commands that only run in the terminal interface, such as `/plugin` or `/resume`, aren’t available. Commands that open a picker or panel in the terminal behave differently in cloud sessions:
+Cloud sessions support [built-in commands](</docs/en/commands>) that produce text output. Commands that only run in the terminal interface, such as `/resume`, aren’t available. Commands that open a picker or panel in the terminal behave differently in cloud sessions:
* **`/model`, `/effort`, `/color`, and `/rename`**: pass the value as an argument, for example `/model sonnet`, instead of opening the terminal picker or slider. The argument forms follow each command’s [availability notes](</docs/en/commands#all-commands>).
* **`/fast`** : toggles [fast mode](</docs/en/fast-mode#use-fast-mode-in-cloud-sessions>) for the session when fast mode is [available on your account](</docs/en/fast-mode#requirements>). Requires Claude Code v2.1.271 or later in the session’s environment.
@@ -259,27 +259,7 @@
### Share sessions
-To share a session, toggle its visibility according to the account types below. After that, share the session link as-is. Recipients see the latest state when they open the link, but their view doesn’t update in real time.
-
-#### Share from an Enterprise or Team account
-
-Sharing works as follows for Enterprise and Team accounts:
-
- * **Visibility options** : **Private** and **Team**. Team visibility makes the session visible to other members of your claude.ai organization
- * **Repository access** : verification is enabled by default, based on the GitHub account connected to the recipient’s account
- * **Your name** : your account’s display name is visible to all recipients with access
- * **Slack sessions** : [Claude in Slack](</docs/en/slack>) sessions are automatically shared with Team visibility
-
-#### Share from a Max, Ultra, or Pro account
-
- * **Visibility options** : **Private** and **Public**. Public visibility makes the session visible to any user logged into claude.ai
- * **Repository access** : verification isn’t enabled by default
- * **Sensitive content** : check your session before sharing. Sessions may contain code and credentials from private GitHub repositories
-
-To require recipients to have repository access, or to hide your name from shared sessions, open Settings on claude.ai, then:
-
- * **If the Settings menu shows Code instead of Claude Code** : go to [**Privacy**](<https://claude.ai/settings/data-privacy-controls>), which has these settings
- * **Otherwise** : go to [**Claude Code > Sharing settings**](<https://claude.ai/settings/claude-code>)
+See [Share a cloud or Remote Control session](</docs/en/share-sessions>) for how to share a session by link, what recipients can read, and how to stop sharing.
### Archive sessions
@@ -312,7 +292,7 @@
* **From the mobile app** : tell Claude to auto-fix the PR, for example “watch this PR and fix any CI failures or review comments”
* **Any existing PR** : paste the PR URL into a session and tell Claude to auto-fix it
-To stop monitoring, turn off **Auto-fix** in the pull request’s **⋮** menu in the session’s **Changes** card, or tell Claude to stop watching the PR.
+To stop monitoring, turn off **Auto-fix** in the pull request’s **⋮** menu in the session’s **Changes** card, or tell Claude to stop watching the PR. In a repository where PR Steward works on your pull requests, the **Auto-fix** toggle is unavailable. A request to auto-fix a pull request that PR Steward is watching fails. See [Auto-fix is unavailable](</docs/en/pr-steward-troubleshooting#auto-fix-is-unavailable>).
### How Claude responds to PR activity
Show diff (242 lines)
--- a/claude-projects.md
+++ b/claude-projects.md
@@ -15,7 +15,7 @@
* **One goal across many repositories** : “Bring every service up to the new lint config.” Claude can run a thread per repository, each with its own pull request, and the Overview pane shows which ones are ready for review.
* **An area you keep feeding** : the bugs, stack traces, and review requests for one service, pasted into the conversation as they reach you. A pitfall you tell Claude to remember after one fix is in project memory for the next.
* **A build or migration bigger than a session** : “Build what `docs/spec.md` describes” or “Move the app off the deprecated ORM.” The work splits into threads that each take a part, decisions you ask Claude to remember early on reach the later cloud threads, and the spec changes and bugs you find during the build go into the same conversation.
- * **Work that isn’t code** : a folder of contracts or a support-ticket export you keep coming back to with new questions, such as “find the ten most common integration mistakes in these tickets.” Upload the documents instead of adding a repository, and threads deliver each write-up as a file in the project’s **Library**.
+ * **Work that isn’t code** : a folder of contracts or a support-ticket export you keep coming back to with new questions, such as “find the ten most common integration mistakes in these tickets.” Upload the documents instead of adding a repository, and threads deliver each write-up as a file in the project’s **Context** tab.
In any of them you can send a batch of tasks, tell Claude to start without asking you to confirm, and walk away. When you’re back, you can find the threads that need you under **Waiting on you**. You can also ask Claude to put part of the work on a schedule as a [cloud scheduled task](</docs/en/routines>). If one of these is your situation, create a project.
@@ -28,7 +28,7 @@
* **One task that repeats on a schedule with no conversation around it** : “Post a dependency report every Monday.” Create a [cloud scheduled task](</docs/en/routines>) on its own.
* **Several people giving Claude work and steering it together in a Slack channel** : see [Claude Tag](<https://claude.com/docs/claude-tag/overview>).
-A project draws on the same plan limits as your other Claude Code sessions and uses them faster. Usage and cost covers what draws on your plan and how to keep it down.
+A project uses your plan faster than a single session does. Usage and cost covers what draws on your plan and how to keep it down.
## How a project is organized
@@ -58,7 +58,7 @@
Before you create a project, check your plan, your GitHub setup, and what the work needs to reach:
- * **Plan** : you’re on Pro, Max, or Ultra, and **Projects** shows in your sidebar, directly or under **More**. Select **Projects** and check that it offers **New project** or **Get started**.
+ * **Plan** : you’re on Pro, Max, or Ultra, and **Projects** shows in your sidebar, directly or under **More**. Select **Projects** and check that it offers **New project**.
* **GitHub, if the project will work on code** : your code is on github.com rather than GitHub Enterprise Server, GitLab, or Bitbucket, your connected GitHub account has push access to it, and the Claude GitHub App is installed on it. If you connected GitHub with [`/web-setup`](</docs/en/web-quickstart#connect-from-your-terminal>), that token lets your other cloud sessions reach a repository but isn’t enough for a project’s cloud threads, which need the Claude GitHub App. Set up GitHub access has the steps.
* **Network access, secrets, and tools** : for cloud threads, these come from the project’s cloud environment. The default environment already reaches [common package registries](</docs/en/cloud-environments#default-allowed-domains>), so check this only if the work needs other domains, a secret, or a tool that isn’t preinstalled. If the work needs an MCP server, check that it shows as connected in your [claude.ai connectors](<https://claude.ai/customize/connectors>).
@@ -70,7 +70,7 @@
Open Projects
-At [claude.ai/code](<https://claude.ai/code>) or in the Code tab of the desktop app, select **Projects** in the left sidebar, or under **More** there. In a browser you can also go straight to [claude.ai/code/projects/browse](<https://claude.ai/code/projects/browse>). Then select **New project**. If the button reads **Get started** instead, select it and first upgrade or archive the existing claude.ai projects it lists.
+At [claude.ai/code](<https://claude.ai/code>) or in the Code tab of the desktop app, select **Projects** in the left sidebar, or under **More** there. In a browser you can also go straight to [claude.ai/code/projects/browse](<https://claude.ai/code/projects/browse>). Then select **New project**.
2
@@ -143,7 +143,7 @@
1. Write project instructions: the brief every thread starts from, such as which branch to target, how a thread checks its work, and what needs your go-ahead.
2. Send one small piece of the real work, or start one of the threads Claude suggested if it offered any, and open the thread when it finishes to see how it reports back and what it did on its branch. If it assumed something wrong or couldn’t reach what it needed, Threads guessed or stalled instead of asking covers where to fix that.
- 3. Check **Thread model** and **Thread effort** in **Project settings > General**. A new project runs every thread on Opus at high effort, which draws on your plan fastest; Choose models and let Claude manage context covers the alternatives.
+ 3. Check **Threads** in **Project settings > General**, which sets the model and effort for new threads. A new project runs every thread on Opus at medium effort; Choose models and let Claude manage context covers the alternatives.
4. Ask Claude to propose threads before starting them and to run a few at a time, and drop those limits once a few threads come back the way you want.
### Send work and read results
@@ -154,7 +154,7 @@
* New work goes to a new thread or to a thread already working in that area, and Claude tells you which. Each new thread shows up in the conversation, and you click it to open the thread.
* Several unrelated tasks in one message become separate threads.
-If Claude routes something differently than you wanted, say so. Tune how Claude runs a project lists things you can tell it, such as reusing an existing thread for follow-ups or answering in place instead of starting a thread. A thread’s full results stay in the thread, so open the thread to read them. Files a thread produced are also in the project’s **Library**. Sometimes Claude proposes threads instead of starting them, in a **Suggested threads** list. Click the arrow on a suggestion to start that thread. When several are listed, a button under the list starts all of them.
+If Claude routes something differently than you wanted, say so. Tune how Claude runs a project lists things you can tell it, such as reusing an existing thread for follow-ups or answering in place instead of starting a thread. A thread’s full results stay in the thread, so open the thread to read them. Files a thread produced are also in the project’s **Context** tab. Sometimes Claude proposes threads instead of starting them, in a **Suggested threads** list. Click the arrow on a suggestion to start that thread. When several are listed, a button under the list starts all of them.
### Review a thread’s pull request
@@ -168,7 +168,7 @@
### See what needs you in Overview
-The Overview pane beside the conversation tracks the project’s threads. It’s already open the first time you open a new project. To reopen it after you close it, click the **Threads** button in the project header. The button shows a dot when a thread is waiting on you. In the desktop app, a notification appears by default when Claude posts in the conversation, a thread hits an error, or a thread needs your input. None appears while you’re viewing the project. To also get one each time a thread finishes a turn, or to turn them off for a project, choose **Notifications** in the project’s sidebar menu. In a browser, check the dot on the **Threads** button. The pane’s **Threads** view groups threads by state:
+The Overview pane beside the conversation tracks the project’s threads. It’s already open the first time you open a new project. To reopen it after you close it, click the side panel button at the top right of the project. While the pane is closed, the button shows a dot when a thread is waiting on you. In the desktop app, a notification appears by default when Claude posts in the conversation, a thread hits an error, or a thread needs your input. None appears while you’re viewing the project. To also get one each time a thread finishes a turn, or to turn them off for a project, choose **Notifications** in the project’s sidebar menu. In a browser, check the dot on that side panel button. The pane’s **Threads** tab groups threads by state:
Group| What’s in it
---|---
@@ -179,14 +179,14 @@
**Idle**| Threads that finished and aren’t waiting on anything
**Resolved**| Threads marked done: by you from the thread’s menu, by Claude once you’ve taken the last step, such as merging its pull request, or automatically after a week with no activity. You can reopen one from the same menu
-Open the project’s files and scheduled tasks in the pane from the project header:
-
- * **Library** : the files and folders you added and the files that threads produced. Click the **Library** button beside **Threads**.
- * **Scheduled tasks** : the [cloud scheduled tasks](</docs/en/routines>) Claude set up from this project. Select it in the header’s **⋯** menu.
+Open the project’s files and scheduled tasks in the pane:
+
+ * **Context** : the files and folders you added and the files that threads produced. Click the **Context** tab beside **Threads**.
+ * **Scheduled tasks** : the [cloud scheduled tasks](</docs/en/routines>) Claude set up from this project. Select it from the **+** after the tabs.
### Open a thread when you need control
-Click a thread in the conversation or its row in Overview to open the thread in the Overview pane. From there you can:
+Click a thread in the conversation or its row in the **Threads** tab to open the thread in the Overview pane. From there you can:
* Read Claude’s messages and see what the thread is working on now.
* Steer the task by writing in the thread’s own message box. A message there goes straight to that thread, while a follow-up in the project conversation reaches it only when Claude matches the follow-up to that thread.
@@ -195,10 +195,10 @@
### Choose models and let Claude manage context
-Set models and effort in **Project settings > General**. A new project runs Opus everywhere, with high [effort](</docs/en/model-config#adjust-effort-level>) for threads and low effort for the conversation:
-
- * **Thread model** and **Thread effort** apply to threads. To use a different model for one task, ask for it in the task; for a thread already running, use that thread’s model picker.
- * **Coordinator model** and **Coordinator effort** apply to Claude in the project conversation.
+Set models and thread effort in **Project settings > General**. A new project runs Opus everywhere, with medium [effort](</docs/en/model-config#adjust-effort-level>) for threads and low effort for the conversation:
+
+ * **Threads** sets the model and effort for new threads. To use a different model for one task, ask for it in the task; for a thread already running, use that thread’s model picker.
+ * **Coordinator** sets the model for Claude in the project conversation.
You don’t manage context windows in a project. Threads compact automatically, and the conversation works from recent messages, recent threads, and project memory rather than its full history, so it keeps going for as long as the project runs. Put anything that must never be dropped in project memory. If one thread outgrows its context, it shows Claude ran out of context on this turn.
@@ -263,13 +263,13 @@
---|---|---
Project memory| Notes Claude keeps about the project, such as requirements, decisions, and pitfalls, stored as files. Every cloud thread reads the index file `MEMORY.md` when it starts and opens the other files when it needs them| Ask Claude in the project conversation or any cloud thread to remember a requirement, a decision, or a pitfall, or to forget one. Read, edit, and delete the files in **Project settings > Memory**
Project instructions| Text sent to each new thread and to Claude in the project conversation, up to 16,000 characters. Write project instructions covers what to put in it| **Project settings > Memory > Project instructions**, or ask Claude to change the instructions
-Repositories, files, and environment| The repositories every cloud thread clones, the folders and files it can read under `/mnt/project-files`, and the cloud environment it runs in| Repositories and environment in **Project settings > Environment**, or ask Claude in the conversation to add a repository to the project. Files and folders from **Add** in the project’s **Library**
-
-**Project settings > Memory** lists these files under **Auto memory** , because Claude writes them itself as it works in the project. They’re separate from the [auto memory](</docs/en/memory>) Claude Code keeps on your machine, even though both use a `MEMORY.md` index. Project memory is also separate from the `CLAUDE.md` files in the project’s repositories. Each cloud thread still reads those `CLAUDE.md` files from its clone when it starts, so put instructions about a repository in its `CLAUDE.md` and notes about the project in project memory.
+Repositories, files, and environment| The repositories every cloud thread clones, the folders and files it can read under `/mnt/project-files`, and the cloud environment it runs in| Repositories and environment in **Project settings > Environment**, or ask Claude in the conversation to add a repository to the project. Files and folders from **Add context** in the project’s **Context** tab
+
+**Project settings > Memory** lists these files under **Auto memory** , because Claude writes them itself as it works in the project. They’re separate from the [auto memory](</docs/en/memory>) Claude Code keeps on your machine, even though both use a `MEMORY.md` index. Project memory is also separate from the `CLAUDE.md` files in the project’s repositories. Each cloud thread still reads those `CLAUDE.md` files from its clone when it starts, so put instructions about a repository in its `CLAUDE.md` and notes about the project in project memory. If memory is off in your [claude.ai settings](<https://claude.ai/settings/capabilities?highlight=memory>), Claude can’t read or save project memory. Turn it on there, then restart Claude and start a new thread.
### Write project instructions
-Project instructions are the brief every new thread starts from. Select **Settings** in the **⋯** menu in the project header to open **Project settings** , then go to **Memory > Project instructions**. A useful brief covers:
+Project instructions are the brief every new thread starts from. Click the gear in the project header to open **Project settings** , then go to **Memory > Project instructions**. A useful brief covers:
* What the project is for
* Where the work happens: which repositories, which branch to start from, how to name pull requests
@@ -295,11 +295,11 @@
* **Add it to the project** , in the **New project** dialog, in **Project settings > Environment**, or by asking Claude in the conversation to add it to the project. Every cloud thread from then on clones it and starts with its `CLAUDE.md` loaded, whether or not the task touches it.
* **Leave it off and let threads add it when needed.** A cloud thread whose task needs a repository the project doesn’t have can add it to itself, and a note in the thread says it was added to this thread only. The clone happens partway through the task, so that repository’s `CLAUDE.md` wasn’t there when the thread started. The next thread starts without it. A repository added this way needs the same prerequisites as a project repository: the Claude GitHub App installed on it and push access from your GitHub account.
-A project doesn’t need a repository at all. Its cloud threads can still research, write documents, and write and run code in their own sandbox. They deliver files to the project’s **Library**. Any of its cloud threads can still add a repository to itself when a task calls for one. Once the project has repositories, Claude can only add repositories from a GitHub owner the project already uses, whether it adds one to the project or a thread adds one to itself. To bring in a repository from a different owner, add it to the project yourself in **Project settings > Environment**. For a project that spans many repositories, such as one feature with server, web, mobile, and desktop code, add the one or two repositories nearly every task touches and name the others in project instructions so Claude knows where the rest of the code lives. Cloud threads then start small and pull in the other repositories only for the tasks that need them.
+A project doesn’t need a repository at all. Its cloud threads can still research, write documents, and write and run code in their own sandbox. They deliver files to the project’s **Context** tab. Any of its cloud threads can still add a repository to itself when a task calls for one. Once the project has repositories, Claude can only add repositories from a GitHub owner the project already uses, whether it adds one to the project or a thread adds one to itself. To bring in a repository from a different owner, add it to the project yourself in **Project settings > Environment**. For a project that spans many repositories, such as one feature with server, web, mobile, and desktop code, add the one or two repositories nearly every task touches and name the others in project instructions so Claude knows where the rest of the code lives. Cloud threads then start small and pull in the other repositories only for the tasks that need them.
### Add files and folders
-Add the files and folders you want threads to read in the **New project** dialog’s **Context** field, or afterward with **Add** in the project’s **Library**. These limits apply to what you add:
+Add the files and folders you want threads to read in the **New project** dialog’s **Context** field, or afterward with **Add context** in the project’s **Context** tab. These limits apply to what you add:
* **Files you upload at claude.ai/code or in the desktop app** : up to 1,000 files and 2 GB at a time, with a single file up to 480 MB.
* **Folders you upload** : hidden files and `node_modules` aren’t added. A project holds up to 10 folders and Google Drive folders combined, and single files don’t count toward that limit.
@@ -314,7 +314,6 @@
`CLAUDE.md`, `.claude/CLAUDE.md`, and `.claude/rules/` at the repository root| Loaded from every repository when the thread starts. [Path-specific rules](</docs/en/memory#path-specific-rules>) don’t load at the start
Skills, agents, and commands under `.claude/`| Loaded from every repository, except in threads that skip them
MCP servers in `.mcp.json`| Not loaded. Use the connectors on your claude.ai account instead, as Get skills, plugins, connectors, and tools into threads describes
-Plugins enabled in `.claude/settings.json`| Not loaded. Add the plugin in **Project settings > Plugins** instead
Permission rules in `.claude/settings.json`| Not applied. Approve tool calls inside the thread, as Unblock a thread waiting on approval describes, or run the thread on your own computer
Hooks in `.claude/settings.json`| Not run. To use your hooks, run the thread on your own computer
`env` in `.claude/settings.json`| Not applied. Set environment variables in the cloud environment
@@ -336,7 +335,7 @@
Cloud threads don’t have the skills, MCP servers, plugins, and tools installed only on your machine. A thread that Claude runs on your machine through [Remote Control](</docs/en/remote-control>) uses what’s installed there. To make each of these available to cloud threads:
* Skills: enable them for your claude.ai account, and cloud threads load the [skills you enable there](</docs/en/skills#skills-in-cowork-and-cloud-sessions>), apart from [some threads in a self-hosted environment](</docs/en/self-hosted-environments-configuration#how-each-session%E2%80%99s-config-is-assembled>). For skills committed to a repository, see What threads pick up from your repositories.
- * Plugins: add them in **Project settings > Plugins**; they load into each new cloud thread. Plugins that a repository declares in its `.claude/settings.json` [don’t load in cloud threads](</docs/en/cloud-environments#what-carries-over-from-your-setup>).
+ * Plugins: enable them for your claude.ai account at [claude.ai/customize/plugins](<https://claude.ai/customize/plugins>), and the cloud threads that Claude starts load them.
* MCP servers: cloud threads get their MCP tools from the connectors on your claude.ai account, which are MCP servers you connect once at [claude.ai/customize/connectors](<https://claude.ai/customize/connectors>). Every cloud thread can use all of them with no per-project setup. The project conversation itself has no connectors, so send work that needs one as a task for a cloud thread. [How connectors reach Claude Code](</docs/en/mcp#how-connectors-reach-claude-code>) lists the rules for cloud sessions and the settings that turn connectors off.
* Command-line tools and packages: install them in the environment’s [setup script](</docs/en/cloud-environments#setup-scripts>).
@@ -344,26 +343,26 @@
## Project settings reference
-You change project settings at claude.ai/code or in the desktop app, not in `settings.json`. Open **Project settings** from **Settings** in the project’s sidebar menu or in the project header’s **⋯** menu. Settings save as you change them; a text field you’re editing, such as the goal or instructions, shows **Save changes** and **Discard** until you leave it. Changes to instructions, repositories, plugins, and environment in **Project settings** reach new threads, not threads already running.
+You change project settings at claude.ai/code or in the desktop app, not in `settings.json`. Open **Project settings** from **Settings** in the project’s sidebar menu or from the gear in the project header. Settings save as you change them; a text field you’re editing, such as the goal or instructions, shows **Save changes** and **Discard** until you leave it. Changes to instructions, repositories, and environment in **Project settings** reach new threads, not threads already running.
Setting| Section| What it controls
---|---|---
Name, icon, and goal| General| The project’s name and icon in the sidebar, and its one-line goal
-Coordinator model and effort| General| The model and [effort level](</docs/en/model-config#adjust-effort-level>) for Claude in the project conversation
-Thread model and effort| General| The model and effort level for threads
+Coordinator| General| The model for Claude in the project conversation
+Threads| General| The model and [effort level](</docs/en/model-config#adjust-effort-level>) for new threads
Project instructions| Memory| Standing rules every new thread receives
Project repositories| Environment| The repositories new cloud threads clone
Cloud environment| Environment| The cloud environment new cloud threads run in
-Plugins| Plugins| The plugins that load into each new cloud thread
-Usage| Usage| Token use by thread and by model
+Usage| Usage| Token use by thread
Memory| Memory| The project’s memory files
-Auto-continue when usage limits reset| General| Whether a thread or the project conversation that stops at a usage limit continues on its own when the limit resets. On by default.
-Restart Claude| General| Restarts the project conversation when Claude stops responding there
-Pause, Archive, Delete| General| Stops, hides, or removes the project; see Pause, archive, or delete a project
+Continue threads automatically when usage limits reset| General| Whether a thread or the project conversation that stops at a usage limit continues on its own when the limit resets. On by default.
+Restart Claude| Advanced| Restarts the project conversation when Claude stops responding there
+Pause| Advanced| Pauses the project; see Pause, archive, or delete a project
+Archive, Delete| General| Hides or removes the project; see Pause, archive, or delete a project
### Pause, archive, or delete a project
-All three controls are at the bottom of **Project settings > General**:
+**Pause** is in **Project settings > Advanced**. **Archive** and **Delete** are at the bottom of **General** :
* **Pause** : stops everything at once. Every running thread and the conversation are interrupted, no new threads start, scheduled tasks don’t run, and the project doesn’t accept messages until you resume it. Click **Resume** in the same place or on the banner above the project’s message box; a paused thread continues when you send it a message after that.
* **Archive** : hides the project from the sidebar and archives its threads, which stops any thread that was running or watching a pull request. Scheduled tasks in the project don’t run while it’s archived. To bring the project back, open it from the Projects page and click **Unarchive**. Its threads stay archived until you unarchive them individually from the session list.
@@ -371,7 +370,7 @@
## Usage and cost
-Project usage counts against the same [plan limits](</docs/en/errors#youve-hit-your-session-limit>) as your other Claude Code sessions, and a project can’t spend past those limits on its own. A thread that stops at your plan’s limit waits and by default continues on its own when the limit resets. Its work then counts against your next usage window. To keep threads from continuing, see A thread hit the usage limit. Work goes past your plan’s limits only if you have turned on [usage credits](</docs/en/costs#add-usage-credits-to-your-subscription>) for your account. A thread can’t turn them on for you.
+A thread that stops at your plan’s limit waits and by default continues on its own when the limit resets. Its work then counts against your next usage window. To keep threads from continuing, see A thread hit the usage limit. Work goes past your plan’s limits only if you have turned on [usage credits](</docs/en/costs#add-usage-credits-to-your-subscription>) for your account.
### What draws on your plan
@@ -385,10 +384,10 @@
### See and reduce a project’s usage
-Open **Usage** in **Project settings** to see token use by thread and by model, and how much went to the project conversation. To bring it down:
+Open **Usage** in **Project settings** to see token use by thread and how much went to the project conversation. To bring it down:
* On Pro, Max, and Ultra within your plan’s limits, the [cache lifetime](</docs/en/prompt-caching#cache-lifetime>) is an hour. A thread that has been idle longer than that re-reads its whole conversation before doing anything when a follow-up reaches it. For new work, ask Claude to start a fresh thread, which can use less than reviving a large old one.
- * For work that doesn’t need the largest model, choose a smaller model or a lower effort level for threads, the conversation, or both.
+ * For work that doesn’t need the largest model, choose a smaller model, or a lower effort level for threads.
* Ask Claude in the project conversation to run fewer threads at a time, or to answer small questions itself instead of starting a thread.
## How projects relate to other Claude Code features
@@ -413,7 +412,7 @@
* 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, though you can bring its work into one. A project reaches your machine 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 project belongs to one user. You can’t share a project or its threads with another user, and thread transcripts don’t have the share option other cloud sessions have. There are no organization-level controls for projects during the beta.
+ * A project belongs to one user. You can’t share a project with another user. There are no organization-level controls for projects during the beta.
* A thread belongs to the one project that started it. You can’t move or copy a thread to another project, or move it out to stand alone. **Continue in project** goes the other way only: it brings a cloud session’s work into a project. You can’t merge two projects into one.
## Troubleshooting
@@ -429,12 +428,12 @@
When several threads come back having assumed something wrong, worked around missing access, or stopped with “blocked”, the cause is usually the same gap in the project’s setup rather than a problem with each task. Sort out which threads are sound before you fix anything:
1. Ask Claude in the conversation: “For every open thread, list what you asked it to do, what it assumed or couldn’t reach, and what it’s waiting on.” Claude reads each thread and answers in the conversation.
- 2. For threads that started from a wrong assumption, open the thread from Overview and mark it resolved from its menu, or tell it what to do instead. Its branch and any pull request stay on GitHub until you delete them.
+ 2. For threads that started from a wrong assumption, open the thread from the **Threads** tab and mark it resolved from its menu, or tell it what to do instead. Its branch and any pull request stay on GitHub until you delete them.
3. Fix the gap once, in project instructions or the environment, then send one thread before sending the rest of the work again as new threads.
-### Claude hasn’t responded
-
-The project conversation shows a “Claude hasn’t responded” banner when Claude is running but its replies aren’t reaching the project. Click **Restart Claude** on the banner, or go to **Project settings > General** and click **Restart** in the **Restart Claude** row. Claude reconnects to the conversation; any reply it was in the middle of writing is lost, and threads aren’t affected.
+### Claude’s replies aren’t getting through
+
+If the project conversation shows a “Claude’s replies aren’t getting through” banner, click **Restart Claude** on it. You can also go to **Project settings > Advanced** and click **Restart** in the **Restart Claude** row. Claude reconnects to the conversation; any reply it was in the middle of writing is lost, and threads aren’t affected.
### Repository access errors
@@ -448,7 +447,7 @@
### A thread hit the usage limit
-When a thread or the project conversation stops at your plan’s five-hour or weekly limit, it waits and by default continues on its own when the limit resets. To keep a thread or conversation from continuing at the reset time its message shows, turn off **Auto-continue when usage limits reset** in **Project settings > General** before then. The setting is for the whole project, not only the thread you’re looking at. To continue with the setting off, send the thread or conversation a message after the reset. [Usage limit errors](</docs/en/errors#youve-hit-your-session-limit>) explain the limits and when they reset.
+When a thread or the project conversation stops at your plan’s five-hour or weekly limit, it waits and by default continues on its own when the limit resets. To keep a thread or conversation from continuing, turn off **Continue threads automatically when usage limits reset** in **Project settings > General** before the reset. The setting is for the whole project. To continue with the setting off, send the thread or conversation a message after the reset. [Usage limit errors](</docs/en/errors#youve-hit-your-session-limit>) explain the limits and when they reset.
### Additional usage credits are required
--- a/claude-ship.md
+++ b/claude-ship.md
@@ -0,0 +1,76 @@
+Claude Ship is a set of agents that help get your team’s GitHub pull requests ready to merge:
+
+ * [Code Review](</docs/en/code-review>): looks for issues such as logic errors, security vulnerabilities, and broken edge cases
+ * [PR Steward](</docs/en/pr-steward>): works on review feedback and failing checks
+ * [Claude Approvals](</docs/en/approvals>): checks pull requests against an approval policy that you write
+
+Together, they can take a pull request through review, fixes, and an approval decision, so your team doesn’t have to manage each step manually. Your settings and GitHub branch rules determine what merges. Claude Ship is available on Team and Enterprise plans. To turn on the agents, go to Set up Claude Ship.
+
+To get a review and fixes locally, on one of your own pull requests, run [`/ship`](</docs/en/ship-command>) in Claude Code.
+
+## Claude Ship agents
+
+This diagram shows each agent’s part in a pull request, and the parts that stay with you and GitHub:
+
+Claude Ship uses AI and may miss bugs, security vulnerabilities, or other issues.
+
+### Code Review finds problems
+
+[Code Review](</docs/en/code-review>) reads a change alongside the surrounding code. Findings arrive as inline comments on the lines concerned, ranked by severity.
+
+### PR Steward pushes fixes
+
+[PR Steward](</docs/en/pr-steward>) works on failing checks, merge conflicts, and review comments from people and from review bots such as Code Review. It pushes commits with its fixes. Steward is designed not to approve or merge pull requests. Use branch protection to require the approvals you want before anything merges. See [Limits on approvals and merges](</docs/en/pr-steward-security#limits-on-approvals-and-merges>).
+
+### Claude Approvals applies your policy
+
+[Claude Approvals](</docs/en/approvals>) is a check that reports who still has to approve. You write its policy file, which can set how many people have to approve changes to a path, and where Claude can post an approving review. The check blocks a merge only where you [make it a required check in GitHub](</docs/en/approvals-setup#enforce-your-policy-and-require-claude-approvals>), and normally not in observe mode.
+
+If you use GitHub auto-merge or a merge queue with a policy that doesn’t require a person’s approval, a change can merge without anyone acting. See [Merges without human review](</docs/en/approvals-github-rules#merges-without-human-review>).
+
+## Set up Claude Ship
+
+Go to [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-ship>) for Claude Ship’s settings. You need an [Owner role](</docs/en/server-managed-settings#access-control>). Turn on one agent at a time in one repository, in this order:
+
+ 1. [Set up Code Review](</docs/en/code-review-setup>)
+ 2. [Set up PR Steward](</docs/en/pr-steward-setup>). For the setting that chooses when PR Steward starts, begin with [**Manual (@claude steward)**](</docs/en/pr-steward-setup#choose-when-pr-steward-starts-in-each-repository>). PR Steward has no spend limit of its own until you set one.
+ 3. [Set up Claude Approvals](</docs/en/approvals-setup>). A policy file in the repository starts it, so see [who can turn it on](</docs/en/approvals#who-can-turn-approvals-on-or-off>). Start in observe mode, where the **Claude Approvals** check reports what your policy would decide. Observe mode is billed. See [what Approvals costs](</docs/en/approvals-setup#what-approvals-costs>).
+
+### If you already use Code Review
+
+Code Review’s settings moved to [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-ship>). A Claude Approvals policy file, `.claude/approvals.yml`, changes which pull requests Code Review reviews automatically. Once the file is on the default branch, in observe mode or enforced, automatic reviews normally stop where no matching rule names `claude/code_review`. To keep them, [add `claude/code_review` to a rule](</docs/en/approvals-policy#advisory>).
+
+## Plans and billing
+
+Claude Ship is for organizations on Team and Enterprise plans.
+
+### Who can use Claude Ship
+
+Code Review is generally available. PR Steward and Claude Approvals are in public beta. The agents aren’t available to organizations with [Zero Data Retention](</docs/en/zero-data-retention>) enabled, the [HIPAA configuration](</docs/en/hipaa-setup>) applied, or customer-managed encryption keys. Approvals has [more limits](</docs/en/approvals#availability>).
+
+### How each Claude Ship agent is billed
+
+Each agent is billed on token usage through your organization’s [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>), separately from your plan’s included usage. Approvals bills for [classifier](</docs/en/approvals-classifiers>) runs and the Code Reviews that a policy asks for.
+
+Eligible Enterprise organizations can claim promotional Claude Ship credits. For who qualifies, the amount, and the dates, see the [credit terms](<https://support.claude.com/en/articles/17603594-free-code-review-promotional-credits-for-claude-enterprise>).
+
+If you turn off usage credits in [**Organization settings > Usage**](<https://claude.ai/admin-settings/usage>), an agent that’s on keeps running and billing your organization. To stop its charges, follow Turn off Claude Ship. See each agent’s costs:
+
+ * [Code Review](</docs/en/code-review-costs>)
+ * [PR Steward](</docs/en/pr-steward-setup#set-pr-steward%E2%80%99s-spend-limits>)
+ * [Claude Approvals](</docs/en/approvals-setup#what-approvals-costs>)
+
+## Turn off Claude Ship
+
+Turn off Approvals before Code Review, because a policy can start billed reviews where Code Review is off:
+
+ 1. [Turn off Approvals](</docs/en/approvals-setup#turn-off-approvals>)
+ 2. [Turn off PR Steward](</docs/en/pr-steward-setup#turn-off-pr-steward>)
+ 3. [Turn off Code Review](</docs/en/code-review-setup#turn-off-code-review-or-remove-a-repository>)
+
+These steps leave the `/ship` and `/steward` commands on. See [how to turn them off](</docs/en/ship-command#turn-off-%2Fship-and-%2Fsteward-for-your-organization>).
+
+## Related resources
+
+ * [GitHub Actions](</docs/en/github-actions>) and [GitLab CI/CD](</docs/en/gitlab-ci-cd>): run Claude Code in your own CI
+ * [Review code locally](</docs/en/code-review-local>): get a review in your terminal before you push
--- a/cloud-environments.md
+++ b/cloud-environments.md
@@ -234,7 +234,7 @@
### What carries over from your setup
-A cloud thread in a [project](</docs/en/claude-projects>) loads less of the repository configuration in this table. It starts without `.mcp.json` servers or `.claude/settings.json` hooks and permission rules, and it can skip skills, agents, and commands. See [What threads pick up from your repositories](</docs/en/claude-projects#what-threads-pick-up-from-your-repositories>).
+A cloud thread in a [project](</docs/en/claude-projects>) loads less of the repository configuration in this table. It starts without `.mcp.json` servers or `.claude/settings.json` hooks and permission rules, and it can skip skills, agents, and commands. See [What threads pick up from your repositories](</docs/en/claude-projects#what-threads-pick-up-from-your-repositories>).[PR Steward](</docs/en/pr-steward-pull-requests#save-pr-steward-instructions-for-everyone-in-a-repository>) sessions and [Approvals classifier runs](</docs/en/approvals-classifiers#what-a-classifier-run-can-read-and-change>) load less of it too.
Cloud sessions start from a fresh clone of your repository. Anything you commit to the repo is available. Anything you’ve installed or configured only on your own machine isn’t available in the session. Your organization’s policy arrives separately through [server-managed settings](</docs/en/server-managed-settings>).
@@ -245,7 +245,7 @@
Your repo’s `.mcp.json` MCP servers| Yes, in a session with one repository| Part of the clone, found from the session’s working directory. For a self-hosted environment, see [which repository’s settings apply](</docs/en/self-hosted-environments-configuration#repository-settings-in-sessions-with-several-repositories>)
Your repo’s `.claude/rules/`| Yes| Part of the clone
Your repo’s `.claude/skills/`, `.claude/agents/`, `.claude/commands/`| Yes| Part of the clone
-Plugins and marketplaces declared in your repo’s `.claude/settings.json`| No| A cloud session doesn’t install the plugins a repository turns on under [`enabledPlugins`](</docs/en/settings-reference#enabledplugins>), including ones from the marketplaces it lists under [`extraKnownMarketplaces`](</docs/en/settings-reference#extraknownmarketplaces>)
+Marketplaces declared in your repo’s `.claude/settings.json`| No, in an Anthropic-hosted environment| The session doesn’t add the marketplaces a repository lists under [`extraKnownMarketplaces`](</docs/en/settings-reference#extraknownmarketplaces>). For a self-hosted environment, see [which repository’s settings apply](</docs/en/self-hosted-environments-configuration#repository-settings-in-sessions-with-several-repositories>)
Your organization’s [server-managed settings](</docs/en/server-managed-settings>)| Yes, except in [Claude Tag](<https://claude.com/docs/claude-tag/overview>) sessions| Fetched from Anthropic’s servers when the session starts. See [Surface coverage](</docs/en/model-config#surface-coverage>) for how `availableModels` is enforced in cloud sessions. Settings deployed to your device through MDM or managed settings files don’t apply, because the session runs on an Anthropic-managed VM; in a [self-hosted environment](</docs/en/self-hosted-environments>), sessions also read the managed settings file in the runner image, per [how Claude Code combines managed sources](</docs/en/managed-settings#how-claude-code-combines-managed-sources>)
Your user `~/.claude/CLAUDE.md`| No| Lives on your machine, not in the repo. See Add personal preferences without committing to the repo
Your user `~/.claude/skills/`, `~/.claude/agents/`, `~/.claude/commands/`| No| Live on your machine, not in the repo. Commit them to the repo’s `.claude/` directory instead. Cloud sessions automatically load [skills you enable on claude.ai](</docs/en/skills#skills-in-cowork-and-cloud-sessions>)
--- a/code-mode.md
+++ b/code-mode.md
@@ -40,10 +40,11 @@
* **Model** : Claude Opus 5.5, Sonnet 5.5, Haiku 5.5, or Fable 5.2
* **Surface** : an interactive `claude` session in a terminal. Code Mode doesn’t work with the VS Code panel, the Desktop app, or cloud sessions
* **Agent teams** : to use Code Mode with [agent teams](</docs/en/agent-teams>) on, you need v2.1.326 or later. Teammates run in Code Mode in the default [in-process display mode](</docs/en/agent-teams#choose-a-display-mode>), and start without it in split panes
+ * **Telemetry settings** : to use Code Mode with [feature-flag fetching off](</docs/en/env-vars#features-that-need-feature-flag-fetching>) or [OpenTelemetry](</docs/en/monitoring-usage>) events and metrics on, you need v2.1.329 or later. Keep [tracing](</docs/en/monitoring-usage#traces-beta>) off on any version
* **Installation** : the [native build](</docs/en/setup>) of Claude Code
* **Windows** : [Git for Windows](<https://git-scm.com/downloads/win>) is installed
-You also can’t start Code Mode with some settings on, such as an API key helper, OpenTelemetry export, or `DISABLE_TELEMETRY`. For the fix for each, see Code Mode doesn’t start.
+You also can’t start Code Mode with some settings on, such as an API key helper. For the fix for each, see Code Mode doesn’t start.
## Try Code Mode
@@ -123,6 +124,14 @@
}
Users who are in a Code Mode session stay in it until they exit or restart Claude Code. After that, your users start without Code Mode and can’t resume their Code Mode sessions while the `0` is in place. You can’t turn on Code Mode for your users from managed settings.
+
+### Monitor Code Mode with OpenTelemetry
+
+If you collect [OpenTelemetry events](</docs/en/monitoring-usage#events>), your backend receives `tool_decision` and `tool_result` events for the tool calls in the code that Claude writes, under each tool’s usual name, such as `Bash`. Update your queries and settings for these calls:
+
+ * **Find calls from code** : filter on `tool_use_id` values that start with `repl_` or `toolu_cc_`. The `REPL` tool, which runs the code, has events of its own without either prefix
+ * **Read classifier verdicts** : in auto mode, a call that the classifier’s review of the code covers has no `classifier_verdict`. Look for the verdict on the `REPL` tool’s `tool_decision` events that have that call’s `request_id`. If you find more than one, the events don’t show which piece of code made the call
+ * **Keep secrets out of your backend** : code can read a value, such as a token in a file, and pass it to another call. Leave `OTEL_LOG_TOOL_DETAILS` unset if your backend shouldn’t receive those values
## Permissions and long-running code
@@ -255,12 +264,14 @@
Reason includes| What to do
---|---
`it isn't open to your account in this version` or `it isn't open to your account yet`| If your version is older than v2.1.323, update. Otherwise, check your network connection and start again. If the reason stays, try again another day
+`Anthropic has turned it off for now`| [Update Claude Code](</docs/en/setup#update-claude-code>), or start again later
`it only works directly with the Anthropic API` or `it only works with the Anthropic API`| Remove the settings that route requests through a cloud provider, a gateway, or a custom `ANTHROPIC_BASE_URL`
`it doesn't work with an API key helper`| Remove `apiKeyHelper`, `ANTHROPIC_AUTH_TOKEN`, and any `Authorization` or `X-Api-Key` header in `ANTHROPIC_CUSTOM_HEADERS`. Then sign in or set `ANTHROPIC_API_KEY`
`it only works with Opus 5.5, Sonnet 5.5 and later models`| Start with a supported model, for example with `--model opus`. Haiku 5.5 and Fable 5.2 also work
`it doesn't work in background jobs`| Start in the foreground, without `--remote-control`. If the reason shows in a teammate’s split pane, use the [in-process display mode](</docs/en/agent-teams#choose-a-display-mode>) to run teammates in Code Mode
-`it needs settings that Claude Code downloads from Anthropic`| Unset the variable that [turns off feature-flag fetching](</docs/en/env-vars#features-that-need-feature-flag-fetching>), such as `DISABLE_TELEMETRY`
-`OpenTelemetry is on`| Unset `CLAUDE_CODE_ENABLE_TELEMETRY` and `ENABLE_BETA_TRACING_DETAILED` if you can work without [OpenTelemetry export](</docs/en/monitoring-usage>)
+`it needs settings that Claude Code downloads from Anthropic`| [Update Claude Code](</docs/en/setup#update-claude-code>) to meet the telemetry settings requirement. To stay on your version, unset the variable that [turns off feature-flag fetching](</docs/en/env-vars#features-that-need-feature-flag-fetching>), such as `DISABLE_TELEMETRY`
+`OpenTelemetry tracing is on`| Unset `CLAUDE_CODE_ENHANCED_TELEMETRY_BETA`, `ENABLE_ENHANCED_TELEMETRY_BETA`, and `ENABLE_BETA_TRACING_DETAILED` if you can work without [traces](</docs/en/monitoring-usage#traces-beta>)
+`OpenTelemetry is on`| To keep events and metrics on, [update Claude Code](</docs/en/setup#update-claude-code>) and meet the telemetry settings requirement. To stay on your version, unset `CLAUDE_CODE_ENABLE_TELEMETRY` and `ENABLE_BETA_TRACING_DETAILED` if you can work without [OpenTelemetry export](</docs/en/monitoring-usage>)
`it doesn't yet work with the plugin`| In a session, run `/plugin` and disable each plugin that the reason names. If your organization turned one on, ask your administrator to turn it off
`it doesn't yet work with an installed mod`| Turn off the [mod](</docs/en/plugins/mods/overview>) that checks tool calls
`it can't be used together with agent teams yet`| To keep agent teams on, [update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.326 or later. To stay on your version, unset `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS`
--- a/code-review.md
+++ b/code-review.md
@@ -1,4 +1,4 @@
-With Code Review, Claude reviews the pull requests in your GitHub repositories. Several agents read each change alongside the surrounding code, looking for issues such as logic errors, security vulnerabilities, or broken edge cases. A verification step checks findings against the code before they’re reported. Findings arrive as inline comments on the lines concerned, ranked by [severity](</docs/en/code-review-pull-requests#severity-levels>), with a summary and a check run on the pull request. A review never approves or blocks the pull request, so the decision to merge stays with your team.
+With Code Review, Claude reviews the pull requests in your GitHub repositories. Several agents read each change alongside the surrounding code, looking for issues such as logic errors, security vulnerabilities, or broken edge cases. A verification step checks findings against the code before they’re reported. Findings arrive as inline comments on the lines concerned, ranked by [severity](</docs/en/code-review-pull-requests#severity-levels>), with a summary and a check run on the pull request. By itself, a review doesn’t approve or block the pull request. Its result counts toward approvals in a repository whose [Claude Approvals](</docs/en/approvals>) policy file uses it.
Code Review uses AI to review code and may miss bugs, security vulnerabilities, or other issues. A review with no findings doesn’t mean your code is error-free or secure.
--- a/code-review-costs.md
+++ b/code-review-costs.md
@@ -22,13 +22,15 @@
* **`@claude review`** : runs a single review without subscribing to future pushes
* **Drafts and pull requests from forks** : [automatic reviews skip both](</docs/en/code-review-pull-requests#review-drafts-and-pull-requests-from-forks>), so pushes to them don’t add reviews
+In a repository with a [Claude Approvals](</docs/en/approvals-setup#what-approvals-costs>) policy file, reviews can start that the **Review runs** setting wouldn’t start, and [automatic ones can stop](</docs/en/approvals-policy#advisory>).
+
## Estimate your spend
Before a wide rollout, run a small pilot to estimate monthly spend from your own pull requests.
1. Set a monthly spend limit for the pilot.
2. Turn on Code Review for a few representative repositories with **Review runs** set to **Once after PR creation** or **Manual (@claude review)**.
- 3. After several reviews have run, read each repository’s average cost per review in the **Average cost** column of the **Repositories** table, in the **Code review** section of [**Admin settings > Claude Code**](<https://claude.ai/admin-settings/claude-code#code-review>).
+ 3. After several reviews have run, go to [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-code#code-review>) and click **Edit** on each repository’s row in the **Repositories** table. Read its average cost per review under **Cost**.
4. Multiply that average by the number of pull requests the repository opens in a month. For **After every push** , multiply again by the typical number of pushes per pull request.
A repository’s average moves with the size of its pull requests and with the review level you choose.
--- a/code-review-pull-requests.md
+++ b/code-review-pull-requests.md
@@ -1,4 +1,4 @@
-Code Review is a managed service that an Owner in your Claude organization turns on for a set of GitHub repositories. Once it’s on, Claude reviews pull requests in those repositories and posts its findings as inline comments, a summary in the review body, and a check run named **Claude Code Review**. A review never approves or blocks your pull request, and the check run never concludes as a failure. An Owner controls [when reviews run](</docs/en/code-review-setup#set-when-reviews-run>) and [how thorough they are](</docs/en/code-review-setup#set-the-default-review-level>) for each repository.
+Code Review is a managed service that an Owner in your Claude organization turns on for a set of GitHub repositories. Once it’s on, Claude reviews pull requests in those repositories. It posts its findings as inline comments, a summary in the review body, and a check run named **Claude Code Review**. An Owner controls [when reviews run](</docs/en/code-review-setup#set-when-reviews-run>) and [how thorough they are](</docs/en/code-review-setup#set-the-default-review-level>) for each repository. By itself, a review doesn’t approve or block your pull request, and the check run doesn’t conclude as a failure. Where a repository has a [Claude Approvals](</docs/en/approvals#keep-automatic-code-reviews>) policy file, the policy can use a review’s result to decide who has to approve. It can also change which pull requests get an automatic review.
If your plan doesn’t include Code Review, you can still have Claude review your branch from a Claude Code session: see [Review locally with `/code-review`](</docs/en/code-review-local>).
@@ -18,8 +18,8 @@
You can merge without responding to a finding, unless your repository’s own rules require it. If its branch protection [requires conversation resolution](<https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/managing-protected-branches/about-protected-branches#require-conversation-resolution-before-merging>), resolve each finding’s thread before you merge. To clear a finding, resolve its thread or push a fix.
- * **Dismiss it without a code change** : resolve the thread yourself on GitHub. Replying alone doesn’t dismiss a finding.
- * **Fix the issue** : change the code and push. The next review of the pull request resolves its earlier thread when it judges the issue fixed, whether that review runs automatically on your push or you request it.
+ * **Dismiss it without a code change** : resolve the thread yourself on GitHub. Replying alone doesn’t dismiss a finding. If your pull request has a **Claude Approvals** check, that check [may not count your resolve](</docs/en/approvals-troubleshooting#approvals-doesn%E2%80%99t-pass-after-you-resolve-a-review-thread>).
+ * **Fix the issue** : change the code and push. The next review of the pull request resolves its earlier thread when it judges the issue fixed, whether that review runs automatically on your push or you request it. Where [PR Steward](</docs/en/pr-steward#what-pr-steward-fixes>) works on the pull request, it can push its own fix for an Important finding, so pull the branch before you start.
* **Explain or disagree** : reply to the comment. Claude doesn’t respond right away, and a reply doesn’t start a review. The next review of the pull request reads the replies on its earlier findings, and can resolve the thread or post one follow-up reply. If the same kind of finding keeps coming back, ask a maintainer to add a rule to [`REVIEW.md`](</docs/en/code-review-customize#choose-what-to-write-in-review-md>).
To get that next review without pushing, comment `@claude review` as a top-level pull request comment.
@@ -40,7 +40,7 @@
If the check run has one of these titles after you push, Code Review kept the result of an earlier review instead of starting a new one:
* **Code review skipped — no new changes** : no Important finding from the earlier review is still open, so you don’t need a new review
- * **Code review not repeated — earlier findings still open** : to start a new review, push a fix for an open Important finding, or resolve its thread and push again
+ * **Code review not repeated — earlier findings still open** : to start a new review, push a fix for an open Important finding, or resolve its thread and push again. If Claude Approvals reopens the thread, the title stays after your next push. Push a fix, or ask someone [whose resolve counts](</docs/en/approvals-policy#findings>) to resolve it, then push again.
On github.com, Code Review can keep a result when both of these hold:
--- a/code-review-setup.md
+++ b/code-review-setup.md
@@ -1,4 +1,4 @@
-As an Owner of your Claude organization, you turn on Code Review in [**Admin settings > Claude Code**](<https://claude.ai/admin-settings/claude-code#code-review>) on claude.ai. Reviews run on Anthropic infrastructure, so you don’t add workflow files to your repositories. After setup, you choose how thorough reviews are and when they run in each repository. You spend more at a higher review level and when reviews run more often. See [Code Review costs](</docs/en/code-review-costs#pricing>).
+An Owner of your Claude organization turns on Code Review in [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-code#code-review>) on claude.ai. Reviews run on Anthropic infrastructure, so you don’t add workflow files to your repositories. After setup, an Owner chooses how thorough reviews are and when they run in each repository. You spend more at a higher review level and when reviews run more often. See [Code Review costs](</docs/en/code-review-costs#pricing>).
## What you need to turn on Code Review
@@ -14,9 +14,9 @@
1
-Click the Allow code review switch
+Turn on the switch under Review
-Go to the **Code review** section of [**Admin settings > Claude Code**](<https://claude.ai/admin-settings/claude-code#code-review>) and click the **Allow code review** switch.If Code Review turns on right away with no dialog, your organization already has the Claude GitHub App linked or repositories added. Go to Add more repositories, then come back for the last step.
+Go to [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-code#code-review>) and turn on the switch under **Review**. In the **Turn on Code review** dialog, click **Turn on**.If your organization already has the Claude GitHub App linked or repositories added, no other dialog follows and Code Review is on. Go to Add more repositories, then come back for the last step.
2
@@ -45,9 +45,9 @@
5
-Click Finish
+Click Turn on
-A **Code review is set up** dialog follows. Click **Finish** to turn Code Review on. If you close the dialog any other way, your repositories stay added but **Allow code review** stays off, and you turn it on from the switch.Each repository starts set to review after every push, which runs the most reviews. To run fewer, set when reviews run.
+In the **Choose what Claude does on these repositories** dialog, leave **Code review** selected. If **Steward** is selected and you can change it, clear it unless you also want PR Steward on these repositories. Then click **Turn on** , which is the click that turns Code Review on.If you close the dialog any other way, your repositories stay added and nothing is turned on. To turn Code Review on then, use the switch under **Review** again.Each repository starts set to review after every push, which runs the most reviews. To run fewer, set when reviews run.
6
@@ -57,7 +57,7 @@
## Set defaults for your organization
-As an Owner, you decide how thorough reviews are and how often they run. Both are in the **Code review** section of [**Admin settings > Claude Code**](<https://claude.ai/admin-settings/claude-code#code-review>).
+An Owner decides how thorough reviews are and how often they run. Set both in [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-code#code-review>): the default review level for your Claude organization, and when reviews run for each repository or for a whole GitHub organization.
### Set the default review level
@@ -82,10 +82,11 @@
* **After every push** : a review runs on pushes to the pull request branch, catching new issues as the pull request evolves and auto-resolving threads when you fix flagged issues
* **Manual (@claude review)** : opening or pushing to a pull request doesn’t start a review. Comment [`@claude review`](</docs/en/code-review-pull-requests#comment-commands>) to request one, or `@claude review always` to also subscribe the pull request to reviews on subsequent pushes.
-Manual is useful for high-traffic repositories where you want to opt specific pull requests into review, or to start reviewing pull requests only once they’re ready. To compare what each option does to spend, see [How often reviews run](</docs/en/code-review-costs#how-often-reviews-run>). To change the setting, click **Edit** on the repository’s row in the **Repositories** table and select a **Review runs** option. The choice saves as soon as you select it, and the table’s **Review runs** column shows it shortened to Once per PR, Every push, or Manual.
+Manual is useful for high-traffic repositories where you want to opt specific pull requests into review, or to start reviewing pull requests only once they’re ready. To compare what each option does to spend, see [How often reviews run](</docs/en/code-review-costs#how-often-reviews-run>). To change the setting, click **Edit** on the repository’s row in the **Repositories** table and select a **Review runs** option. The choice saves as soon as you select it. The table’s **Code review** column shows it shortened to Once per PR, Every push, or Manual.
* **Drafts and pull requests from forks** : whichever option you choose, [automatic reviews skip both](</docs/en/code-review-pull-requests#review-drafts-and-pull-requests-from-forks>)
* **New repositories** : a repository you add from the **Add a repository** dialog starts at **After every push**. If its GitHub organization is covered as a whole, it takes that organization row’s setting instead.
+ * **A[Claude Approvals](</docs/en/approvals>) policy file**: in a repository that has one, [reviews can start](</docs/en/approvals-setup#what-approvals-costs>) that this setting wouldn’t start, and [automatic ones can stop](</docs/en/approvals-policy#advisory>)
### Turn tip comments on or off
@@ -114,10 +115,12 @@
### Add more repositories
-To add repositories after setup, click **Add** above the **Repositories** table in the **Code review** section. The **Add a repository** dialog opens. Select repositories and click the button that adds them, which reads **Add 2 repositories** when you’ve selected two.
+To add repositories after setup, click **Add** above the **Repositories** table in [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-code#code-review>). The **Add a repository** dialog opens. Select repositories and click the button that adds them, which reads **Add 2 repositories** when you’ve selected two.
+ * **A Connect GitHub dialog opens first** : follow the step Connect your GitHub account, which ends with **Add a repository** open
* **A repository isn’t listed** : see [A repository isn’t listed in Add a repository](</docs/en/code-review-troubleshooting#a-repository-isn%E2%80%99t-listed-in-add-a-repository>).
* **You want every repository in a GitHub organization** : cover the organization instead of selecting repositories one at a time
+ * **These are your organization’s first repositories** : the **Choose what Claude does on these repositories** dialog follows. Set its checkboxes as in the step Click Turn on, then click its button, which reads **Turn on** or **Done**. Either way, Code Review is on afterward.
### Cover a whole GitHub organization
@@ -136,12 +139,14 @@
### Turn off Code Review or remove a repository
-In the **Code review** section of [**Admin settings > Claude Code**](<https://claude.ai/admin-settings/claude-code#code-review>), pick the control that matches what you want to stop:
+In [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-code#code-review>), pick the control that matches what you want to stop:
* **One repository, keeping it in the list** : click **Edit** on its row and turn off **Code review**. The table shows the repository as Off.
* **One repository, removing it** : click **Edit** on its row, then **Remove repository** at the bottom of the dialog. Reviews stop there, and another Claude organization can then set that repository up. While the repository’s GitHub organization is covered as a whole, you can’t remove it; turn off its **Code review** switch instead.
* **A whole GitHub organization** : click **Edit** on the organization’s row and select **Off**. This also turns off repositories in that organization that you added one at a time.
- * **Everything** : turn off **Allow code review**. No new reviews start in any repository, and your repository list stays so you can turn it back on later.
+ * **Everything** : turn off the switch under **Review**. No new reviews start in any repository, and your repository list stays so you can turn it back on later.
+
+With a repository’s **Code review** switch off, or with **Allow code review** off, a [Claude Approvals](</docs/en/approvals-setup#what-approvals-costs>) policy can start billed reviews. To stop those, change the policy or [turn off Approvals](</docs/en/approvals-setup#turn-off-approvals>). Code Review’s spend limit applies to them.
## Related resources
--- a/code-review-troubleshooting.md
+++ b/code-review-troubleshooting.md
@@ -12,21 +12,26 @@
**Code review skipped — no new changes**| An automatic review didn’t run on your latest push| To get a review anyway, comment `@claude review`
**Code review not repeated — earlier findings still open**| An automatic review didn’t run on your latest push, and Important findings from the earlier review are still open| Push a fix, or to get a review anyway, comment `@claude review`. See [When a push keeps the earlier result](</docs/en/code-review-pull-requests#when-a-push-keeps-the-earlier-result>)
**Code review failed** or **Code review timed out**| The review didn’t finish| To run it again, see Retrigger a failed or timed-out review
+**Code review not run: no policy rule uses it**| An automatic review didn’t run, because of the repository’s Claude Approvals policy| See Code review not run: no policy rule uses it
**Code review declined**| The review didn’t run| Read the check run’s summary. If it names a budget or a spend limit, see Review didn’t run and the PR shows a budget message
No check run| No review started| Comment `@claude review`. If no check run appears after that, see A comment command didn’t start a review
## A review didn’t start
-Check these cases when no **Claude Code Review** check run appears, or when Claude posts a comment saying the review was skipped.
+Check these cases when no **Claude Code Review** check run appears, or when Claude posts a comment saying the review was skipped. One case covers a check run whose title says that no review ran.
### A comment command didn’t start a review
After you comment `@claude review`, look for a **Claude Code Review** check run titled **Code review queued…** or **Code review in progress…** on the pull request. An 👀 reaction on your comment doesn’t confirm a review is coming. If no check run appears, check for each of these causes:
- * **Code Review isn’t on for this repository** : Claude posts no comment and no check run in response to the command. Ask an Owner to [add the repository](</docs/en/code-review-setup#add-more-repositories>).
+ * **Code Review isn’t on for this repository** : Claude posts no comment and no check run in response to the command. Ask an Owner to [add the repository](</docs/en/code-review-setup#add-more-repositories>). Where a [Claude Approvals](</docs/en/approvals>) policy reads Claude’s review, a new comment with only `@claude review` can still start one.
* **The comment doesn’t meet a condition** : it was an inline comment or a review body rather than a new top-level comment, or the command wasn’t at the start of the comment. Editing an earlier comment instead of posting a new one doesn’t count either, and the pull request has to be open. See the [conditions for comment commands](</docs/en/code-review-pull-requests#comment-commands>) and post a new comment that meets them.
* **You don’t have write access** : you need write, maintain, or admin permission on the repository. On a pull request from a fork, the permission that counts is on the base repository. Unless the pull request is yours, Claude can reply with a [tip](</docs/en/code-review-setup#turn-tip-comments-on-or-off>): “No review was started: manual reviews can only be requested by someone with write access to this repository.” Ask someone with write access to comment instead.
* **The budget ran out** : Claude posts a comment that begins with “⚠️ Code review skipped”. See Review didn’t run and the PR shows a budget message.
+
+### Code review not run: no policy rule uses it
+
+This title on the **Claude Code Review** check means that the repository has a [Claude Approvals](</docs/en/approvals>) policy file, and the policy asks for no review on this pull request. To get a review anyway, comment `@claude review` on the pull request. To bring automatic reviews back, [name Code Review in a rule that has a `verdict` and matches the changed files](</docs/en/approvals-policy#advisory>).
### Review didn’t run and the PR shows a budget message
@@ -76,7 +81,7 @@
### No check run appears on the test pull request
-Confirm that **Allow code review** is on, that the repository is listed under **Repositories** in the **Code review** section, and that the Claude GitHub App has access to it. Automatic reviews skip draft pull requests, and a repository set to **Manual (@claude review)** needs an `@claude review` comment to start the first review.
+In [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-code#code-review>), confirm that the switch under **Review** is on and that the repository is listed under **Repositories**. Also confirm that the Claude GitHub App has access to it. Automatic reviews skip draft pull requests, and a repository set to **Manual (@claude review)** needs an `@claude review` comment to start the first review.
## Related resources
--- a/commands.md
+++ b/commands.md
@@ -55,7 +55,7 @@
`/doctor [prompt-audit [path]]`| **[Skill](</docs/en/skills#bundled-skills>).** Run a setup checkup that diagnoses installation, settings, extension, and `CLAUDE.md` problems and proposes fixes that Claude applies after you confirm. For what the checkup covers, or to audit your instructions with `prompt-audit` instead, see [Check your setup with `/doctor`](</docs/en/skills#check-your-setup-with-/doctor>). The `prompt-audit` subcommand requires Claude Code v2.1.283 or later. Alias: `/checkup`
`/effort [level|auto|status|ultracode [on|off]]`| Set the [effort level](</docs/en/model-config#adjust-effort-level>): `low` to `xhigh`, `max`, or `auto`; `status` prints it. `ultracode` or `ultracode on` turns [ultracode](</docs/en/workflows#let-claude-decide-with-ultracode>) on for the session, and `ultracode off` turns it off; the [`ultracode`](</docs/en/settings-reference#ultracode>) key persists. `max` is session-only. The `on` and `off` arguments require Claude Code v2.1.284 or later. If you run `/effort` while Claude is working, see [when the new level starts](</docs/en/model-config#when-a-new-effort-level-starts>). Works in `-p` on v2.1.205 or later
`/exit`| Exit the CLI. In an attached [background session](</docs/en/agent-view#attach-to-a-session>), this detaches and the session keeps running. Alias: `/quit`
-`/export [filename]`| Export the current conversation as plain text. With a filename, writes directly to that file. Without, opens a dialog to copy to clipboard or save to a file
+`/export [filename]`| Export the current conversation as plain text. With a filename, writes directly to that file, and on v2.1.327 or later refuses one that already exists. Without, opens a dialog to copy to clipboard or save to a file
`/fast [on|off]`| Toggle [fast mode](</docs/en/fast-mode>) on or off. Run it while Claude is responding and Claude Code toggles fast mode without waiting for the turn to end, though the running turn finishes at its original speed. Before v2.1.242, Claude Code decided from a feature flag it fetched from Anthropic whether to run the command mid-turn or queue it until the turn finished, and always queued it in a session that doesn’t [fetch feature flags](</docs/en/env-vars#features-that-need-feature-flag-fetching>). Availability in non-interactive mode with `-p` is limited; see [Toggle fast mode](</docs/en/fast-mode#toggle-fast-mode>)
`/feedback [report]`| Send product feedback about Claude Code. Opens the same dialog as `/bug`, with the same consent step, sending rules, and mid-turn behavior. In sessions with [Claude-drafted feedback](</docs/en/tools-reference#sendfeedback-tool-behavior>), `/feedback` with no argument opens the drafts queue instead, where you review, edit, send, or discard the drafts Claude queued; the queue includes an option to write a new report in the dialog. With an argument, and for `/bug` always, the dialog opens directly
`/fewer-permission-prompts`| **[Skill](</docs/en/skills#bundled-skills>).** Scan your transcripts for common read-only Bash and MCP tool calls, then add a prioritized allowlist to project `.claude/settings.json` to reduce permission prompts
@@ -110,6 +110,8 @@
`/security-review`| Analyze the changes on your current branch for security vulnerabilities. Reviews the diff between your branch and origin’s default branch, identifying risks like injection, auth issues, and data exposure. Needs an `origin` remote; if the review fails with an `ambiguous argument` error, see the [error reference](</docs/en/errors#security-review-fails-without-origin-head>)
`/setup-bedrock`| Configure [Amazon Bedrock](</docs/en/amazon-bedrock>) authentication, region, and model pins through an interactive wizard. Hidden from the command menu until `CLAUDE_CODE_USE_BEDROCK=1` is set; type it in full. First-time Amazon Bedrock users can also access this wizard from the login screen
`/setup-vertex`| Configure [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>) authentication, project, region, and model pins through an interactive wizard. Hidden from the command menu until `CLAUDE_CODE_USE_VERTEX=1` is set; type it in full. First-time Google Cloud’s Agent Platform users can also access this wizard from the login screen
+`/ship [level] [pr] [+bot]`| **[Skill](</docs/en/skills#bundled-skills>).** Commit and push your work and open a GitHub pull request, if your branch has none. Then review the change. Claude then watches the pull request in this session and pushes fixes for review feedback and failing checks. `/ship stop` ends the watch. See [Get a pull request ready with `/ship`](</docs/en/ship-command>). If the command is missing, see [Troubleshooting](</docs/en/ship-command-troubleshooting>)
+`/ship:review`| Alias for [`/code-review`](</docs/en/code-review-local>)
`/simplify [target]`| **[Skill](</docs/en/skills#bundled-skills>).** Review the changed code for cleanup opportunities and apply the fixes. Four review [agents](</docs/en/sub-agents>) run in parallel, covering reuse of existing helpers, simplification, efficiency, and whether the change is at the right level of abstraction. The review doesn’t look for correctness bugs. Use `/code-review` to find bugs. Pass a path or PR reference to review a specific target
`/skill-doctor`| Show what each of your [skills](</docs/en/skills>) costs in context and how often it gets used, so you can [find skills to turn off](</docs/en/skills#find-unused-skills>). Requires Claude Code v2.1.252 or later and [feature-flag fetching](</docs/en/env-vars#features-that-need-feature-flag-fetching>)
`/skills`| List available [skills](</docs/en/skills>). Type to filter the list by name, description, or source. Press `t` to sort by token count, `Space` or `Enter` to [cycle a skill’s visibility to Claude and the `/` menu](</docs/en/skills#override-skill-visibility-from-settings>), and `Esc` to save and close. You can’t cycle plugin skills, skills whose frontmatter sets `disable-model-invocation: true`, or skills with a `skillOverrides` entry in managed settings or the `--settings` flag
@@ -117,6 +119,7 @@
`/stats`| Alias for `/usage`. Opens on the Stats tab
`/status`| Open the Settings interface on the Status tab, showing version, model, account, and connectivity. A `Session kind` row reads `background job · attached` or `background job · unattended` in a [background session](</docs/en/agent-view>), depending on whether a terminal is attached, and `interactive` in any other session. Works while Claude is responding
`/statusline`| Configure Claude Code’s [status line](</docs/en/statusline>). Describe what you want, or run without arguments to auto-configure from your shell prompt
+`/steward [pr] [+bot]`| **[Skill](</docs/en/skills#bundled-skills>).** Watch your open GitHub pull request in this session and push fixes for review feedback and failing checks, without the review that [`/ship`](</docs/en/ship-command>) runs first. `/steward stop` ends the watch. See [Watch without a review using `/steward`](</docs/en/ship-command#start-a-watch-with-%2Fsteward>). If the command is missing, see [Troubleshooting](</docs/en/ship-command-troubleshooting>). Alias: `/ship:steward`
`/stickers`| Check Claude Code sticker availability
`/stop`| Stop the [background session](</docs/en/agent-view>) you’re attached to, or the one you send it to as a [peek reply](</docs/en/agent-view#peek-and-reply>); the transcript and any worktree are kept. To detach without stopping, use `/exit` or press `←`
`/subtask <task>`| Spawn a [forked subagent](</docs/en/sub-agents#fork-the-current-conversation>): a background subagent that inherits the full conversation and works on the task while you keep working. Its result returns to this conversation when it finishes. To copy the conversation into a separate background session instead, use `/fork`. When [agent view is turned off](</docs/en/agent-view#turn-off-agent-view>), `/subtask` isn’t available and `/fork` spawns the forked subagent instead
--- a/communications-kit.md
+++ b/communications-kit.md
@@ -465,7 +465,7 @@
Write tests| ”write tests for [file] that cover the edge cases around [scenario]“
Review before commit| ”look at my working diff and tell me what looks risky”
Open a PR| ”fix [issue], write a conventional commit, and open a PR with a summary”
-Make a skill| ”make me a /ship skill that runs tests and lint before commit”
+Make a skill| ”make me a /precommit skill that runs tests and lint before commit”
Debug a stack trace| ”here’s the stack trace, find the root cause, don’t just paper over it”
Claude Code ships frequently. Verify version-specific details against the [documentation home page](</docs/en/overview>) before distributing internally.
--- a/components.md
+++ b/components.md
@@ -197,7 +197,7 @@
The server takes its name from the `name` in the bundle’s manifest. A bundle’s own manifest can declare settings the server needs from the user in a `user_config` block. A bundled server with a required setting that has no saved value doesn’t start. The `/plugin` **Errors** tab shows `Bundled MCP server "<name>" was not started: it needs configuration`. Users supply the values in one of two ways:
- * **In`/plugin`**: select the plugin on the **Installed** tab and choose **Configure**
+ * **In`/plugin`**: for a plugin from a marketplace, select it on the **Installed** tab and choose **Configure**
* **At install, from the shell** : pass [`--config <server>.<key>=<value>`](</docs/en/plugins/cli-reference#plugin-install>) to `claude plugin install`. Requires Claude Code v2.1.285 or later, and works only for a bundle packaged inside the plugin.
For transports and authentication, see [MCP](</docs/en/mcp#plugin-provided-mcp-servers>).
--- a/costs.md
+++ b/costs.md
@@ -6,9 +6,9 @@
The Session block in `/usage` shows API token usage and is intended for API users. Claude Pro, Max, and Ultra subscribers have usage included in their subscription, so the session cost figure isn’t relevant for billing purposes. Subscribers see plan usage bars, activity stats, and a usage breakdown on the same screen.
-Run `/usage` at the Claude Code prompt and look under the **Session** heading for your current session’s token usage. Claude Code computes the dollar figure locally from token counts at list price, unless a [`modelPricing`](</docs/en/settings-reference#modelpricing>) table is in effect. An administrator sets one in your organization’s managed settings so the figure uses your contracted rates, and while a table is in effect the `Total cost` line carries the note `at your organization's configured rates`. The figure is an estimate, so for authoritative billing see Manage costs for your organization.
-
- Total cost: $0.55
+Run `/usage` at the Claude Code prompt and look under the **Session** heading for your current session’s token usage. Claude Code computes the dollar figure locally from token counts at list price, unless a [`modelPricing`](</docs/en/settings-reference#modelpricing>) table is in effect. An administrator sets one in your organization’s managed settings so the figure uses your contracted rates, and while a table is in effect the `Estimated cost` line carries the note `at your organization's configured rates`. The figure is an estimate, so for authoritative billing see Manage costs for your organization.
+
+ Estimated cost: $0.55
Total duration (API): 6m 20s
Total duration (wall): 6h 33m 10s
Total code changes: 0 lines added, 0 lines removed
@@ -136,7 +136,7 @@
Deliver it as [managed settings](</docs/en/managed-settings>): server-managed settings, an MDM policy, `managed-settings.json`, or a [policy helper](</docs/en/managed-settings#compute-the-policy-with-a-helper-program>). Claude Code ignores the key in user, project, and local settings and in `--settings`.
-To confirm the rates are in effect, run `/usage` in a session that has [received the managed settings](</docs/en/managed-settings#read-the-source-in-%2Fstatus>): the Session block’s `Total cost` line carries the note `at your organization's configured rates`. The figures are still estimates, not an invoice. The per-million-token prices in the `/model` picker stay at list price.
+To confirm the rates are in effect, run `/usage` in a session that has [received the managed settings](</docs/en/managed-settings#read-the-source-in-%2Fstatus>): the Session block’s `Estimated cost` line carries the note `at your organization's configured rates`. The figures are still estimates, not an invoice. The per-million-token prices in the `/model` picker stay at list price.
### Claude for Teams and Enterprise
--- a/deep-links.md
+++ b/deep-links.md
@@ -111,7 +111,7 @@
* Send anything to an interactive `claude` session, such as a message or `/help`. Starting one and sending nothing doesn’t register the handler.
* Start Claude Code in [agent view](</docs/en/agent-view>), such as with `claude agents`, in a folder you’ve [trusted](</docs/en/permissions#project-allow-rules-and-workspace-trust>)
-You don’t run a separate install command. Registration writes to user-level locations only:
+Registration writes to user-level locations only:
Platform| Handler location
---|---
--- a/desktop.md
+++ b/desktop.md
@@ -134,7 +134,7 @@
### Browse external sites
-The Browser pane is a tabbed browser, so you can open documentation, issue trackers, or any other site next to your running app. To open the Browser, press **Cmd+Shift+B** on macOS or **Ctrl+Shift+B** on Windows, or select **Browser**. You can sign in to sites in the pane, including popup sign-in flows such as Google OAuth. The first time you click an external link in the chat, a dialog asks whether links open in the Browser pane or in your default browser. To change your choice later, use **Open links in built-in browser** in the Browser pane’s **⋮** menu. **Cmd** -click on macOS or **Ctrl** -click on Windows opens a link in your default browser directly. Claude can read and interact with external pages using the same tools it uses to verify your app, with two additional safety checks:
+The Browser pane is a tabbed browser, so you can open documentation, issue trackers, or any other site next to your running app. To open the Browser, press **Cmd+Shift+B** on macOS or **Ctrl+Shift+B** on Windows, or select **Browser**. You can sign in to sites in the pane, including popup sign-in flows such as Google OAuth. The first time you click an external link in the chat, a dialog asks whether links open in the Browser pane or in your default browser. To change your choice later, use **Open links in built-in browser** in the Browser pane’s **⋮** menu. If it isn’t there, open **More settings** in that menu. **Cmd** -click on macOS or **Ctrl** -click on Windows opens a link in your default browser directly. Claude can read and interact with external pages using the same tools it uses to verify your app, with two additional safety checks:
* When auto mode is available for the session, its safety classifiers review Claude’s write actions on external pages, such as typing, in every permission mode. A flagged action is blocked, or prompts you after [repeated blocks](</docs/en/permission-modes#when-auto-mode-falls-back>).
* In permission modes other than Auto and Bypass permissions, a domain allowlist check also applies before Claude navigates to a new site.
@@ -164,7 +164,7 @@
To have Claude review your changes before you commit, enter `/code-review` in the prompt box. The findings arrive in the conversation when the review completes. In local, SSH, and [WSL](</docs/en/desktop-wsl>) sessions, the findings appear as a **Code review** card, grouped by file. Use the card to act on them:
- * Click **Walk through in Changes** to open the diff view and step through the findings one at a time. A finding in the current diff appears at its line, where you can click **Fix this one** or dismiss it.
+ * Click **Walk through in changes** to open the diff view and step through the findings one at a time. A finding in the current diff appears at its line, where you can click **Fix this one** or dismiss it.
* Click **Apply fixes** to ask Claude to fix the findings that are still open.
In any session, you can also ask Claude in the prompt box to fix what the review found. For what `/code-review` looks for and the arguments it takes, see [Review locally with `/code-review`](</docs/en/code-review-local>).
@@ -200,7 +200,7 @@
#### Hide or show the session details panel
-To hide or show the panel, click **Hide session rail** or **Show session rail** in the session’s title bar, or in the bar’s **⋮** menu. If you see neither name, click **Activity panel** in the title bar. If you still don’t see the panel, check which Code tab layout you have.
+To hide or show the panel, click **Hide session rail** or **Show session rail** in the session’s title bar, or in the bar’s **⋮** menu. If you see neither name, click **Activity panel** in the title bar. If you still don’t see the panel, check which Code tab layout you have. If the panel disappears when a mod’s [backdrop](</docs/en/plugins/mods/interface#put-a-backdrop-behind-the-conversation>) shows, click **Show session rail** or **Activity panel** to bring it back.
### Minimize a pane
@@ -432,7 +432,7 @@
### Ask a side question without derailing the session
-A side chat lets you ask Claude a question that uses your session’s context but doesn’t add anything back to the main conversation. Use it when you want to understand a piece of code, check an assumption, or explore an idea without steering the session off course. Press **Cmd+;** on macOS or **Ctrl+;** on Windows to open a side chat, or type `/btw` in the prompt box. The side chat can read everything in the main thread up to that point. When you’re done, close the side chat and continue the main session where you left off. Side chats are available in local, SSH, and WSL sessions. The desktop app doesn’t save side chats to disk, so you can’t return to one after you close the app.
+A side chat lets you ask Claude a question about your session. Claude’s answers in a side chat aren’t added to the main conversation automatically. Use a side chat to understand a piece of code, check an assumption, or explore an idea. Press **Cmd+;** on macOS or **Ctrl+;** on Windows to open a side chat, or type `/btw` in the prompt box. The side chat can read everything in the main thread up to that point. When you’re done, close the side chat and return to the main session. Side chats are available in local, SSH, and WSL sessions.
### Watch background tasks
@@ -542,7 +542,11 @@
* **Add plugins** : select it
* **Plugins** : select it, then **Browse plugins**. If that’s missing, select **Manage plugins**.
-To enable, disable, or uninstall plugins when the **+** menu shows **Plugins** , select **Plugins > Manage plugins**. In a local session, you can also click **Customize** or **Plugins** in the sidebar. You can scope plugins to your user account, a specific project, or local-only. If your organization manages plugins centrally, those plugins are available in desktop sessions the same way they are in the CLI, except the ones the desktop app [withholds under `disableSideloadFlags`](</docs/en/settings-reference#disablesideloadflags>). The plugin browser is not available in cloud sessions, and plugins you install from the desktop app aren’t available for cloud sessions. A cloud session also doesn’t install plugins that the repository’s `.claude/settings.json` declares, as [What carries over from your setup](</docs/en/cloud-environments#what-carries-over-from-your-setup>) explains. Plugins aren’t available in WSL sessions. For the full plugin reference including creating your own plugins, see [plugins](</docs/en/plugins/overview>).
+To enable, disable, or uninstall plugins when the **+** menu shows **Plugins** , select **Plugins > Manage plugins**. In a local session, you can also click **Customize** or **Plugins** in the sidebar. You can scope plugins to your user account, a specific project, or local-only. If your organization manages plugins centrally, those plugins are available in desktop sessions the same way they are in the CLI, except the ones the desktop app [withholds under `disableSideloadFlags`](</docs/en/settings-reference#disablesideloadflags>).
+
+Plugins you install on your computer at user or local scope aren’t available in cloud sessions. See [What carries over from your setup](</docs/en/cloud-environments#what-carries-over-from-your-setup>). Plugins aren’t available in WSL sessions.
+
+For the full plugin reference including creating your own plugins, see [plugins](</docs/en/plugins/overview>).
### Configure preview servers
@@ -564,7 +568,7 @@
#### Auto-verify changes
-When `autoVerify` is enabled, Claude automatically verifies code changes after editing files. It takes screenshots, checks for errors, and confirms changes work before completing its response. Auto-verify is on by default. Disable it per-project by adding `"autoVerify": false` to `.claude/launch.json`, or turn off **Auto-verify changes** in the Browser pane’s **⋮** menu.
+When `autoVerify` is enabled, Claude automatically verifies code changes after editing files. It takes screenshots, checks for errors, and confirms changes work before completing its response. Auto-verify is on by default. Disable it per-project by adding `"autoVerify": false` to `.claude/launch.json`, or turn off **Auto-verify changes** in the Browser pane’s **⋮** menu. If it isn’t there, open **More settings** in that menu.
{
"version": "0.0.1",
@@ -1990,7 +1994,7 @@
#### MCP servers from the Claude Desktop chat app
-The Desktop app loads MCP servers from `claude_desktop_config.json` into local Code tab sessions, alongside servers from `~/.claude.json` and `.mcp.json`. A server you define in `claude_desktop_config.json` is available in both the Desktop chat surface and local Code tab sessions.
+The Desktop app loads MCP servers from `claude_desktop_config.json` into local Code tab sessions, alongside servers from `~/.claude.json` and `.mcp.json`. The servers from `claude_desktop_config.json` also load in a [WSL session](</docs/en/desktop-wsl>), unless the session [lacks connectors](</docs/en/desktop-wsl#check-for-the-terminal-and-connectors>). In a WSL session, those servers run on Windows.
The standalone CLI does not read `claude_desktop_config.json`. On macOS and WSL, run `claude mcp add-from-claude-desktop` to copy those servers into `~/.claude.json`. See [Import MCP servers from Claude Desktop](</docs/en/mcp#import-mcp-servers-from-claude-desktop>) for the import flow and scope options.
--- a/desktop-linux.md
+++ b/desktop-linux.md
@@ -1,6 +1,6 @@
Linux support for the Claude desktop app is in beta.
-The desktop app on Linux gives you the same Chat, Cowork, and Claude Code experience as on macOS and Windows: parallel sessions, visual diff review, an integrated terminal and editor, and live app preview. See [Use Claude Code Desktop](</docs/en/desktop>) for the feature reference.
+The desktop app on Linux gives you Chat, Cowork, and Claude Code. In the desktop app, Claude Code has parallel sessions, visual diff review, an integrated terminal and editor, and live app preview. See [Use Claude Code Desktop](</docs/en/desktop>) for the feature reference.
## Requirements
@@ -131,6 +131,6 @@
* **Computer Use** : [app and screen control](</docs/en/desktop#let-claude-use-your-computer>) isn’t available on Linux.
* **Dictation** : voice input isn’t available in the Linux desktop app. Use [voice dictation](</docs/en/voice-dictation>) in the CLI instead.
* **Quick Entry global hotkey** : works on X11. On native Wayland it requires your desktop environment’s GlobalShortcuts portal.
- * **Fedora and RHEL** : only Debian-based distributions are supported today. Support for additional distributions is coming in the future.
+ * **Fedora and RHEL** : only Debian-based distributions are supported today.
For anything not yet available in the desktop app, the [CLI](</docs/en/quickstart>) runs the same Claude Code engine and supports a wider range of Linux distributions; see the [system requirements](</docs/en/setup#system-requirements>).
--- a/desktop-quickstart.md
+++ b/desktop-quickstart.md
@@ -94,7 +94,7 @@
## Now what?
-You’ve made your first edit. For the full reference on everything Desktop can do, see [Use Claude Code Desktop](</docs/en/desktop>). Here are some things to try next. **Interrupt and steer.** You can redirect Claude at any point. Click the stop button to interrupt immediately, or type a correction and press **Enter** to send it without stopping the running action. Either way, you don’t have to wait for it to finish or start over. **Give Claude more context.** Type `@filename` in the prompt box to pull a specific file into the conversation. The more context Claude has, the better the results. See [Add files and context](</docs/en/desktop#add-files-and-context-to-prompts>). **Use skills for repeatable tasks.** Type `/` or click **+** → **Slash commands** to browse [built-in commands](</docs/en/commands>), [custom skills](</docs/en/skills>), and plugin skills. Skills are reusable prompts you can invoke whenever you need them, like code review checklists or deployment steps. **Review changes before committing.** After Claude edits files, a `+12 -1` indicator appears. Click it to open the [diff view](</docs/en/desktop#review-changes-with-diff-view>), review modifications file by file, and comment on specific lines. Claude reads your comments and revises. To have Claude review the changes itself, enter [`/code-review`](</docs/en/desktop#review-your-code>) in the prompt box. **Adjust how much control you have.** Your [permission mode](</docs/en/desktop#choose-a-permission-mode>) sets how much Claude can do without asking for approval:
+You’ve made your first edit. For the full reference on everything Desktop can do, see [Use Claude Code Desktop](</docs/en/desktop>). Here are some things to try next. **Interrupt and steer.** You can redirect Claude at any point. Click the stop button to interrupt immediately, or type a correction and press **Enter** to send it without stopping the running action. **Give Claude more context.** Type `@filename` in the prompt box to pull a specific file into the conversation. The more context Claude has, the better the results. See [Add files and context](</docs/en/desktop#add-files-and-context-to-prompts>). **Use skills for repeatable tasks.** Type `/` or click **+** → **Slash commands** to browse [built-in commands](</docs/en/commands>), [custom skills](</docs/en/skills>), and plugin skills. Skills are reusable prompts you can invoke whenever you need them, like code review checklists or deployment steps. **Review changes before committing.** After Claude edits files, a `+12 -1` indicator appears. Click it to open the [diff view](</docs/en/desktop#review-changes-with-diff-view>), review modifications file by file, and comment on specific lines. Claude reads your comments and revises. To have Claude review the changes itself, enter [`/code-review`](</docs/en/desktop#review-your-code>) in the prompt box. **Adjust how much control you have.** Your [permission mode](</docs/en/desktop#choose-a-permission-mode>) sets how much Claude can do without asking for approval:
* **Auto** : a classifier reviews actions in the background and blocks the risky ones instead of asking you.
* **Manual** : Claude asks before editing files or running commands.
--- a/env-vars.md
+++ b/env-vars.md
@@ -238,6 +238,7 @@
`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_PROXY_SCHEME_REPAIR`| Set to `1` to have Claude Code stop at startup on a plain `host:port` in `HTTPS_PROXY` or `https_proxy` even when it starts with no terminal. Claude Code ignores it in project and local settings. Requires Claude Code v2.1.327 or later
`CLAUDE_CODE_DISABLE_REFUSAL_FALLBACK`| Set to `1` to turn off the [automatic model switch when a safety classifier flags a request](</docs/en/model-config#automatic-model-fallback>), the behavior the [`switchModelsOnFlag`](</docs/en/settings-reference#switchmodelsonflag>) setting controls
+`CLAUDE_CODE_DISABLE_SHELL_HEAD_START`| Set to `1` to turn off the head start that can run your shell startup files while Claude writes the session’s first Bash command, before that command’s permission prompt. Requires Claude Code v2.1.327 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>), and turns off [status reports to your terminal](</docs/en/terminal-config#see-session-status-in-your-terminal>)
@@ -277,7 +278,7 @@
`CLAUDE_CODE_FORCE_TERMINAL_IMAGES`| Set to `1` to draw [mod `Image` elements](</docs/en/plugins/mods/reference#elements>) as pictures when your terminal draws kitty graphics protocol images with Unicode placeholders and you still see an `Image`’s dimmed `alt` text. See [which terminals draw an `Image` and where not to set this variable](</docs/en/plugins/mods/gallery#image-and-client>)
`CLAUDE_CODE_FORK_SUBAGENT`| Controls fork mode, which is on by default and lets Claude start [forks](</docs/en/sub-agents#fork-the-current-conversation>) on its own. Set to `0` to turn fork mode off, for example to [let Claude wait for a subagent](</docs/en/sub-agents#let-claude-wait-for-a-subagent>). For versions, see [Turn fork mode off](</docs/en/sub-agents#turn-fork-mode-on-or-off>)
`CLAUDE_CODE_FORWARD_SUBAGENT_TEXT`| Set to `1` to emit [subagent](</docs/en/sub-agents>) text and thinking blocks in `claude -p --output-format stream-json` output, the same behavior as the [`--forward-subagent-text`](</docs/en/cli-reference#cli-flags>) flag. Use the variable when a harness invokes `claude` and can’t pass the flag itself. Unlike the flag, which exits with an error outside non-interactive mode with stream-json output, the variable is ignored there so that nested invocations keep working when it’s set process-wide. Requires Claude Code v2.1.211 or later
-`CLAUDE_CODE_FULL_SIGN_IN_LINK`| Set to `1` to print the full claude.ai login URL instead of a short one. Use it when the short URL shows an error or your script reads values from the URL. Set it in your shell or user settings. Requires Claude Code v2.1.330 or later
+`CLAUDE_CODE_FULL_SIGN_IN_LINK`| Set to `1` to print the full login URL. Use it when a short login URL shows an error or your script reads values from the URL. Set it in your shell or user settings. Requires Claude Code v2.1.330 or later
`CLAUDE_CODE_GATEWAY_HINT_HEADERS`| Set to `1` to send the [gateway hint headers](</docs/en/llm-gateway-protocol#gateway-hint-headers>), such as `x-claude-code-request-class` and `x-claude-code-compaction`, on a custom proxy or a third-party provider such as Amazon Bedrock or Claude Platform on AWS. Set to `0` to stop sending them on every connection, including a direct connection to the Anthropic API, where Claude Code sends them by default. Requires Claude Code v2.1.273 or later
`CLAUDE_CODE_GATEWAY_MODEL_DISCOVERY_TIMEOUT_MS`| Timeout in milliseconds for the [gateway model discovery](</docs/en/llm-gateway-protocol#model-discovery>) request that `CLAUDE_CODE_ENABLE_GATEWAY_MODEL_DISCOVERY` turns on (default: `3000`). Raise it when your gateway needs longer than three seconds to answer `/v1/models` at startup. Takes plain digits only; `0`, negative values, and other spellings keep the default. Requires Claude Code v2.1.269 or later
`CLAUDE_CODE_GIT_BASH_PATH`| Windows only: path to the Git Bash executable (`bash.exe`). Use when Git Bash is installed but not in your PATH. If the path doesn’t exist or the file isn’t named `bash.exe`, `sh.exe`, `bash`, or `sh`, Claude Code ignores the variable and auto-detects Git Bash as if it were unset, logging a warning visible with `--debug`. Before v2.1.219, Claude Code exited at startup when the path didn’t exist, and used any existing file as the shell without checking that it was bash or sh. See [Windows setup](</docs/en/setup#set-up-on-windows>)
@@ -549,18 +550,18 @@
* Run [`claude import` or the `/import` command](</docs/en/cli-reference#cli-commands>)
* Run [`/skill-doctor`](</docs/en/skills#find-unused-skills>) or open its report in the `/plugin` **Stats** tab
* Run [`/restart`](</docs/en/commands>) on Pro, Max, and Ultra plans
+ * Run [`/ship` or `/steward`](</docs/en/ship-command>)
* Sync the [skills](</docs/en/skills#where-synced-skills-load>) and [plugins](</docs/en/plugins/loading#synced-plugins>) enabled for your claude.ai account into your terminal sessions
* Turn on the [You should know mod](</docs/en/interactive-mode#you-should-know-suggestions>)
* Use [the advisor tool](</docs/en/advisor#requirements>), except with Claude Code v2.1.300 or later on Claude Platform on AWS or [Claude Models on Google Cloud (Anthropic managed)](</docs/en/feature-availability#availability-by-model-provider>)
* Use [MCP tasks](</docs/en/mcp#mcp-tasks-that-run-on-the-server>)
- * Turn on [Code Mode](</docs/en/code-mode#requirements>)
* Have Claude read [another organization’s public artifact](</docs/en/artifacts#read-an-artifact-shared-with-you>)
* 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
### First session after an install or upgrade
-In your first session after you install Claude Code, or upgrade to a version that adds a feature, a flag-gated feature can be missing. When Claude Code fetches its feature flags during that session, it saves them on the machine, so your next session on that machine has the feature. In setups such as these, sessions after the first also start without freshly fetched flags:
+In your first session after you install Claude Code, or upgrade to a version that adds a feature, a flag-gated feature can be missing. The same holds in your first session after Anthropic turns a feature on. When Claude Code fetches its feature flags during that session, it saves them on the machine, so you have the feature the next time you start Claude Code there. In setups such as these, sessions after the first also start without freshly fetched flags:
* **A clean environment on every run** : if each run starts in a CI container, or any other environment without the flags an earlier session saved, every run is a first session
* **A gateway token with no API key** : if you authenticate with `ANTHROPIC_AUTH_TOKEN` and no API key, and `ANTHROPIC_BASE_URL` points at a host other than Anthropic’s, such as an [LLM gateway](</docs/en/llm-gateway>), Claude Code has no credential to fetch the flags with
--- a/errors.md
+++ b/errors.md
@@ -1001,11 +1001,11 @@
### Could not resolve authentication method
-The session reached the API client without any credential. [Background sessions](</docs/en/agent-view>) and cloud sessions show this message when the worker starts without a credential. Interactive, `-p`, and Agent SDK runs report the same condition as Not logged in and write this string only to their debug log, so if you found it there, follow that entry instead.
+The session reached the API client without any credential. If an interactive, `-p`, or Agent SDK run showed Not logged in and this string is in its debug log, follow that entry.
Could not resolve authentication method. Expected one of apiKey, authToken, credentials, config, or profile to be set. Or for one of the "X-Api-Key" or "Authorization" headers to be explicitly omitted
-On current versions the error means no credential was available to the worker process. Before v2.1.174, a background session assigned to an idle pre-initialized worker could fail this way even when valid credentials were configured. Before v2.1.176, a cloud session that sat idle before being claimed could too. Upgrade to recover. **What to do:**
+Before v2.1.174, a background session assigned to an idle pre-initialized worker could fail this way even when valid credentials were configured. Before v2.1.176, a cloud session that sat idle before being claimed could too. Upgrade to recover. **What to do:**
* Upgrade to v2.1.176 or later if this appears in a background or cloud session and your credentials are already configured
* Confirm `ANTHROPIC_API_KEY`, `CLAUDE_CODE_OAUTH_TOKEN`, or your cloud provider credentials are set in the environment that launches the worker, not only in your interactive shell
@@ -4687,7 +4687,7 @@
Claude Code deletes a session’s backups in the [retention sweep](</docs/en/claude-directory#cleaned-up-automatically>), by default about 30 days after the session last saved one. If you resume a session after that, `/rewind` still lists its checkpoints, but rewinding to one of them can fail with this error. If the message also says `N paths were skipped for link safety`, see Restored the code, but skipped files for those paths. When you fork a session, for example with [`--fork-session`](</docs/en/cli-reference#cli-flags>) or [`/branch`](</docs/en/sessions#branch-a-session>), Claude Code copies the original session’s backups into the fork. When Claude Code can’t copy a backup, for example because the disk is full, that backup is missing in the fork. Rewinding to a checkpoint that needs it can fail with this error. **What to do:**
* Undo the changes another way: ask Claude to reverse its edits, or restore the files from version control. When the backups are gone, running `/rewind` again fails the same way.
- * If Claude Code couldn’t write or delete a file, fix what blocks the write, such as file permissions, then run `/rewind` again.
+ * If Claude Code couldn’t write or delete a file after you chose **Restore code** , fix what blocks the write, such as file permissions. Then run `/rewind` again.
* To keep backups longer in future sessions, raise [`cleanupPeriodDays`](</docs/en/settings-reference#cleanupperioddays>).
Before v2.1.260, Claude Code silently skipped files whose backups were missing, and the rewind appeared to succeed.
@@ -4710,7 +4710,7 @@
Before v2.1.217, Claude Code dropped the failing writes without a warning, and a later `--resume` missing recent messages was the first sign. **What to do:**
* Fix the condition the error code names: free disk space for `ENOSPC`; raise or clear the quota for `EDQUOT`; restore write access to the transcript location for `EACCES`, `EPERM`, or `EROFS`
- * The warning clears on its own at the next successful write; no restart is needed
+ * The warning clears on its own at the next successful write
* Messages sent while the warning was showing may still be missing when you resume the session later
### Transcript saving is off because CLAUDE_CODE_SKIP_PROMPT_HISTORY is set
--- a/feature-availability.md
+++ b/feature-availability.md
@@ -42,6 +42,8 @@
* [Cloud scheduled tasks](</docs/en/routines>) (`/schedule`)
* [Ultrareview](</docs/en/ultrareview>)
* [Code Review](</docs/en/code-review>): Team and Enterprise plans
+ * [PR Steward](</docs/en/pr-steward>): Team and Enterprise plans
+ * [Claude Approvals](</docs/en/approvals>): Team and Enterprise plans
* [Remote Control](</docs/en/remote-control>)
* [Chrome extension](</docs/en/chrome>)
* [Computer use](</docs/en/computer-use>): Pro, Max, and Ultra plans
@@ -154,6 +156,8 @@
[Computer use](</docs/en/computer-use>)| ✓| ✓| ✓| ✗| ✗
Dispatch ([Desktop](</docs/en/desktop#sessions-from-dispatch>))| Not available to new users| Not available to new users| Not available to new users| ✗| ✗
[Code Review](</docs/en/code-review>)| ✗| ✗| ✗| ✓| ✓
+[PR Steward](</docs/en/pr-steward>)| ✗| ✗| ✗| ✓| ✓
+[Claude Approvals](</docs/en/approvals>)| ✗| ✗| ✗| ✓| ✓
[Artifacts](</docs/en/artifacts>)| ✓| ✓| ✓| ✓| ✓
[Analytics dashboard and contribution metrics](</docs/en/analytics>)| ✗| ✗| ✗| ✓| ✓
[Enterprise Analytics API](</docs/en/analytics#access-data-programmatically>)| ✗| ✗| ✗| ✗| ✓
--- a/features-overview.md
+++ b/features-overview.md
@@ -42,7 +42,7 @@
### Build your setup over time
-You don’t need to configure everything up front. Each feature has a recognizable trigger, and most teams add them in roughly this order:
+Each feature has a recognizable trigger, and most teams add them in roughly this order:
Trigger| Add
---|---
--- a/fullscreen.md
+++ b/fullscreen.md
@@ -67,7 +67,7 @@
* **Click in the prompt input** to position your cursor anywhere in the text you’re typing.
* **Click a suggestion in the`/` command or `@` file list** to accept it. Hovering highlights the row under your cursor.
- * **Click an option in a select menu** to choose it. This covers permission prompts, `/model`, `/config`, and other dialogs that show a list of options.
+ * **Click an option in a select menu** to choose it, such as in `/model` or a permission prompt. If a click doesn’t choose the option, click again or use the keyboard.
* **Click an option in a multi-select menu** to toggle it, and click the submit button to confirm your choices. Clicking a free-text row, such as the `Other` row in a multiple-choice question, focuses its input field so you can type an answer.
* **Click a setting’s value in the`/config` panel** to change it, and scroll the settings list with the mouse wheel. Requires Claude Code v2.1.271 or later.
* **Scroll a select or multi-select menu with the mouse wheel** when it has more options than it shows at once, such as the `/model` list in a short terminal window. The wheel scrolls the list while the pointer is over its options. Requires Claude Code v2.1.280 or later.
@@ -131,7 +131,7 @@
### Scroll in the JetBrains IDE terminal
-In the JetBrains IDE terminal, Claude Code applies its own scroll handling and ignores `CLAUDE_CODE_SCROLL_SPEED`. The terminal sends scroll events at a much higher rate than other emulators, so a multiplier tuned elsewhere overshoots here. In 2025.2, the terminal also has scroll-wheel bugs that produce spurious arrow keys and wrong-direction events. Claude Code detects these at runtime and mitigates them automatically, so trackpad and mouse wheel scrolling work without configuration. For the best scroll experience, upgrade to 2025.3 or later. Claude Code shows a hint the first time you scroll if it detects the bug.
+In the JetBrains IDE terminal, Claude Code applies its own scroll handling and ignores `CLAUDE_CODE_SCROLL_SPEED`. The terminal sends scroll events at a much higher rate than other emulators, so a multiplier tuned elsewhere overshoots here. In 2025.2, the terminal also has scroll-wheel bugs that produce spurious arrow keys and wrong-direction events. Claude Code detects these at runtime and mitigates them automatically. For the best scroll experience, upgrade to 2025.3 or later. Claude Code shows a hint the first time you scroll if it detects the bug.
## Search and review the conversation
--- a/gallery.md
+++ b/gallery.md
@@ -225,7 +225,7 @@
onSubmit: noop,
})
-The terminal and the Desktop app draw the rows. In the VS Code extension, the field holds one line. `rows` requires Claude Code v2.1.301 or later. On earlier versions the field holds one line. The field takes up the number of rows you set, even when it’s empty, up to the height of the pane or band it’s drawn in. While the field has focus, longer text scrolls inside it.
+The terminal and the Desktop app draw the rows. In the VS Code extension, the field holds one line. `rows` requires Claude Code v2.1.301 or later. On earlier versions the field holds one line. The field takes up the number of rows you set, up to the height of the pane or band it’s drawn in. While the field has focus, longer text scrolls inside it.
* In the terminal, Enter still submits. There, the user starts a new line by typing a backslash and then pressing Enter, or by pressing Shift+Enter where [the terminal emulator supports it](</docs/en/terminal-config#enter-multiline-prompts>). Those are the same keys as in the prompt.
* In the terminal, Up and Down move between the field’s rows. From its first and last row they move to the control before or after.
--- a/github-enterprise-server.md
+++ b/github-enterprise-server.md
@@ -49,7 +49,7 @@
Enable Code Review
-Go to [claude.ai/admin-settings/claude-code](<https://claude.ai/admin-settings/claude-code>) and enable [Code Review](</docs/en/code-review-setup>) for your GHES repositories using the same configuration as github.com.
+Go to [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-code#code-review>) and enable [Code Review](</docs/en/code-review-setup>) for your GHES repositories using the same configuration as github.com.
### GitHub App permissions
@@ -79,7 +79,7 @@
## Developer workflow
-Claude Code detects your GHES hostname automatically from the git remote in your working directory. Clone a repository from your GHES instance as you normally would, replacing `github.example.com` and the repository path with your GHES hostname and repository:
+Claude Code detects your GHES hostname automatically from the git remote in your working directory. Clone a repository from your GHES instance, replacing `github.example.com` and the repository path with your GHES hostname and repository:
git clone git@github.example.com:platform/api-service.git
cd api-service
--- a/glossary.md
+++ b/glossary.md
@@ -4,7 +4,7 @@
### AGENTS.md
-A markdown file of project instructions you write for AI coding agents. If your repository has one and no CLAUDE.md, Claude reads it as your project instructions without you adding a second file. You can change the **Project instructions** setting in `/config` to have Claude read both files or only `CLAUDE.md`. Reading `AGENTS.md` directly requires Claude Code v2.1.277 or later. In some sessions Claude [can’t read `AGENTS.md`](</docs/en/memory#when-agents-md-support-is-unavailable>), so [import it from a `CLAUDE.md`](</docs/en/memory#share-one-file-with-other-coding-tools>) there instead. Learn more: [AGENTS.md](</docs/en/memory#agents-md>)
+A markdown file of project instructions you write for AI coding agents. If your repository has one and no CLAUDE.md, Claude reads it as your project instructions. You can change the **Project instructions** setting in `/config` to have Claude read both files or only `CLAUDE.md`. Reading `AGENTS.md` directly requires Claude Code v2.1.277 or later. In some sessions Claude [can’t read `AGENTS.md`](</docs/en/memory#when-agents-md-support-is-unavailable>), so [import it from a `CLAUDE.md`](</docs/en/memory#share-one-file-with-other-coding-tools>) there instead. Learn more: [AGENTS.md](</docs/en/memory#agents-md>)
### Agent teams
--- a/google-vertex-ai.md
+++ b/google-vertex-ai.md
@@ -97,8 +97,8 @@
# export ANTHROPIC_VERTEX_BASE_URL=https://aiplatform.googleapis.com
# When CLOUD_ML_REGION=global, override region for models that don't support global endpoints
- export VERTEX_REGION_CLAUDE_HAIKU_4_5=us-east5
- export VERTEX_REGION_CLAUDE_4_6_SONNET=europe-west1
+ # export VERTEX_REGION_CLAUDE_HAIKU_4_5=us-east5
+ # export VERTEX_REGION_CLAUDE_4_6_SONNET=europe-west1
Most model versions have a corresponding `VERTEX_REGION_CLAUDE_*` variable. See the [Environment variables reference](</docs/en/env-vars#variables>) for the full list. Check [Google Cloud’s Agent Platform Model Garden](<https://console.cloud.google.com/vertex-ai/model-garden>) to determine which models support global endpoints versus regional only. If a region value isn’t shaped like a region or location name, Claude Code treats it as unset. For example, Claude Code treats a value containing a slash, dot, or space as unset. Claude Code falls back to a different source for each variable:
--- a/headless.md
+++ b/headless.md
@@ -249,7 +249,7 @@
### Turn off permission prompts in unattended runs
-Pass `--permission-prompts none` when nobody is available to answer permission prompts, for example in a scheduled job. The flag matters most when your run has a permission host: an Agent SDK app with a [`canUseTool` callback](</docs/en/agent-sdk/user-input>), or an MCP tool you pass with [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>). Without the flag or the [`permissions.denyInsteadOfPrompting`](</docs/en/settings-reference#permissions-denyinsteadofprompting>) setting, your run waits for that host to answer each permission request. With the flag, your run doesn’t consult the host or wait on it. Anything that would prompt is denied unless a `PermissionRequest` hook allows it, Claude is told that nobody can approve the request and not to retry it, and the run continues. In a `-p` run with no host, these requests are denied either way, and the flag also tells Claude not to retry them. Permission rules, [`PermissionRequest` hooks](</docs/en/hooks#permissionrequest>), and the permission mode you set still decide every call first; Claude Code denies only the requests that nothing else resolves.
+Pass `--permission-prompts none` when nobody is available to answer permission prompts, for example in a scheduled job. The flag matters most when your run has a permission host: an Agent SDK app with a [`canUseTool` callback](</docs/en/agent-sdk/user-input>), or an MCP tool you pass with [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>). Without the flag or the [`permissions.denyInsteadOfPrompting`](</docs/en/settings-reference#permissions-denyinsteadofprompting>) setting, your run waits for that host to answer each permission request. With the flag, your run doesn’t consult the host or wait on it. Anything that would prompt is denied unless a `PermissionRequest` hook allows it, Claude is told that nobody can approve the request and not to retry it, and the run continues. Permission rules, [`PermissionRequest` hooks](</docs/en/hooks#permissionrequest>), and the permission mode you set still decide every call first; Claude Code denies only the requests that nothing else resolves.
The `--permission-prompts none` flag lasts for one run. To deny calls that would wait on a permission prompt in later runs too, set [`permissions.denyInsteadOfPrompting`](</docs/en/settings-reference#permissions-denyinsteadofprompting>) to `true` in your user or managed settings.
--- a/hooks.md
+++ b/hooks.md
@@ -149,7 +149,7 @@
`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`](</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
+`MessageDisplay`| No| Yes| An assistant message with text completes, once per message with the full message text| Reformat the displayed text without changing the transcript
`Stop`| Yes| Yes| Agent execution stop| Save session state before exit
`StopFailure`| No| Yes| The turn ends with an API error instead of a normal stop| Log failures or send alerts
`SubagentStart`| Yes| Yes| Subagent initialization| Track parallel task spawning
@@ -171,7 +171,7 @@
`ElicitationResult`| No| Yes| A user responds to an MCP elicitation| Modify or block the response before it returns to the server
`ConfigChange`| No| Yes| Configuration file changes| Reload settings dynamically
`InstructionsLoaded`| No| Yes| A `CLAUDE.md` or rules file is loaded into context| Audit which instruction files load
-`WorktreeCreate`| No| Yes| Git worktree created| Track isolated workspaces
+`WorktreeCreate`| No| Yes| Claude Code needs a worktree, and the hook creates it instead of git| Create the worktree and return its path in [`hookSpecificOutput.worktreePath`](</docs/en/hooks#worktreecreate-output>)
`WorktreeRemove`| No| Yes| A worktree created by a `WorktreeCreate` hook is being removed| Clean up workspace resources
`CwdChanged`| No| Yes| The working directory changes during a session| Reload environment variables per directory
`FileChanged`| No| Yes| A watched file is modified, created, or deleted| Reload configuration when project files change
@@ -299,7 +299,7 @@
}
};
-To test it, make the callback raise an error and ask Claude to run a Bash command. The tool result includes `failed; blocking because onFailure is "block"`, and Claude doesn’t see your error text. Return `{}` when the callback has no opinion. With `"block"` set, a path with no `return` blocks the action. A callback that catches its own error and returns `{}` isn’t failing, so let the error propagate from a guard.
+To test it, make the callback raise an error and ask Claude to run a Bash command. The tool result includes `failed; blocking because onFailure is "block"`, and Claude doesn’t see your error text. Return `{}` when the callback has no opinion. With `"block"` set, a path with no `return` blocks the action. A callback that catches its own error and returns `{}` isn’t failing, so let the error propagate from a guard. A `WorktreeCreate` callback must return `hookSpecificOutput.worktreePath`.
#### Events that behave differently
@@ -309,7 +309,7 @@
* **`PermissionRequest`** : the block counts only if it arrives before your `canUseTool` callback answers.
* **`PostToolUse`** : the tool has already run, so Claude receives the failure as feedback.
-A callback that exceeds its timeout follows Hook timeout. With `"block"` set, a timeout also blocks `PreCompact`, `Elicitation`, and `WorktreeCreate`.
+A callback that exceeds its timeout follows Hook timeout. With `"block"` set, a timeout also blocks `PreCompact` and `Elicitation`.
#### Startup errors for `onFailure`
@@ -791,7 +791,8 @@
* `Stop` and `SubagentStop`: the timed-out callback counts as returning no decision. The agent or subagent stops as if that callback had allowed it, and a decision from your other hooks on the event still applies. Before Claude Code v2.1.273, a timed-out `Stop` or `SubagentStop` callback counted as a failed hook run, and Claude Code discarded the decisions of your other hooks on the event.
* `SessionStart`: the timed-out callback counts as returning no output, and the session continues with the output of your other `SessionStart` hooks.
* `PreModelSwitch`: Claude Code blocks the model switch. A hook that doesn’t answer hasn’t approved the switch.
- * Other events, such as `Notification`, `PreCompact`, and `PostModelSwitch`: Claude Code logs the failure and continues. With `onFailure: "block"`, a timeout on `PreCompact`, `Elicitation`, or `WorktreeCreate` blocks the action.
+ * `WorktreeCreate`: worktree creation fails with an error.
+ * Other events, such as `Notification`, `PreCompact`, and `PostModelSwitch`: Claude Code logs the failure and continues. With `onFailure: "block"`, a timeout on `PreCompact` or `Elicitation` blocks the action.
The first time a `Stop` or `SessionStart` callback times out in the main session, Claude Code also adds an [`SDKInformationalMessage`](</docs/en/agent-sdk/typescript#sdkinformationalmessage>) to the message stream saying the app driving the session didn’t respond. Later timeouts don’t repeat that message while your app stays unresponsive. If you interrupt the query while a callback is pending, Claude Code cancels the pending tool call. Before v2.1.208, the tool call could still proceed if you interrupted during a pending `PreToolUse` callback. If your callback needs more time, set a higher `timeout` on its `HookMatcher`. In TypeScript, use the `AbortSignal` from the third callback argument to handle cancellation gracefully when the timeout fires.
--- a/hooks-guide.md
+++ b/hooks-guide.md
@@ -786,7 +786,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`](</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.
+ * [`PermissionRequest`](</docs/en/hooks#permissionrequest>) hooks fire when Claude Code is about to ask you for permission. In a [`-p` run](</docs/en/headless>) with no [permission host](</docs/en/headless#turn-off-permission-prompts-in-unattended-runs>), outside [`dontAsk` mode](</docs/en/permission-modes#allow-only-pre-approved-tools-with-dontask-mode>), a call that would prompt you is denied unless something approves it, such as one of these hooks.
* `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 input, Claude Code doesn’t merge the rewrites or guarantee which rewrite the tool runs with. Avoid having more than one hook rewrite the same tool’s input.
--- a/how-claude-code-works.md
+++ b/how-claude-code-works.md
@@ -68,7 +68,7 @@
### Work across branches
-Each Claude Code conversation is a session tied to your current directory. The `/resume` picker shows sessions from the current worktree by default, with keyboard shortcuts to widen the list to other worktrees or projects. See [Manage sessions](</docs/en/sessions#use-the-session-picker>) for the full list of picker shortcuts and how name resolution works. Claude sees your current branch’s files. When you switch branches, Claude sees the new branch’s files, but your conversation history stays the same. Claude remembers what you discussed even after switching. Since sessions are tied to directories, you can run parallel Claude sessions by using [git worktrees](</docs/en/worktrees>), which create separate directories for individual branches.
+Each Claude Code conversation is a session tied to your current directory. The `/resume` picker shows sessions from the current worktree by default, with keyboard shortcuts to widen the list to other worktrees or projects. See [Manage sessions](</docs/en/sessions#use-the-session-picker>) for the full list of picker shortcuts and how name resolution works. Claude sees your current branch’s files. When you switch branches, Claude sees the new branch’s files, but your conversation history stays the same. Since sessions are tied to directories, you can run parallel Claude sessions by using [git worktrees](</docs/en/worktrees>), which create separate directories for individual branches.
### Resume or fork sessions
@@ -131,7 +131,7 @@
### It’s a conversation
-Claude Code is conversational. You don’t need perfect prompts. Start with what you want, then refine:
+Claude Code is conversational, so start with what you want, then refine:
Fix the login bug
--- a/install.md
+++ b/install.md
@@ -61,7 +61,7 @@
The last sentence of the summary tells you whether the plugin is usable in this session yet:
- * **Active now** : `Plugin is now active.` No reload is needed.
+ * **Active now** : `Plugin is now active.`
* **Active, but a server needs setup** : `Plugin is now active.` is followed by a note that starts `Its bundled MCP server needs`. The plugin’s [bundled MCP server](</docs/en/plugins/components#include-a-packaged-mcpb-server>) can’t start until you set its options. Select the plugin on the **Installed** tab in `/plugin` and choose **Configure**.
* **Reload needed** : `Run /reload-plugins to apply.` The panel closes and Claude Code runs that reload for you. If the reload would [invalidate the prompt cache](</docs/en/prompt-caching#enabling-or-disabling-a-plugin>), it warns and leaves the plugin pending instead. Run `/reload-plugins --force` to activate it anyway, which costs one uncached request.
* **Load failed** : the summary includes `The plugin couldn't`. Open the **Errors** tab in `/plugin` for the reason, then see [After install: plugin not working](</docs/en/plugins/troubleshooting#plugin-installed-but-not-working>).
@@ -123,7 +123,7 @@
Your changes apply to open sessions without a restart. See [Manage plugins in VS Code](</docs/en/vs-code#manage-plugins>).
-A [cloud session](</docs/en/cloud-environments>), including [the browser at claude.ai/code](</docs/en/claude-code-on-the-web>), has no plugin browser and doesn’t load the plugins you installed on your own machine or the ones your repository’s `.claude/settings.json` turns on. For plugins your organization distributes through managed settings, see [Manage plugins for your organization](</docs/en/plugins/org>).See [which parts of your setup are also available in a cloud session](</docs/en/cloud-environments#what-carries-over-from-your-setup>) for the rest of your setup.
+Plugins you install on your computer at user or local scope aren’t available in a [cloud session](</docs/en/cloud-environments>), including one in [the browser at claude.ai/code](</docs/en/claude-code-on-the-web>). For plugins your organization distributes through managed settings, see [Manage plugins for your organization](</docs/en/plugins/org>).See [which parts of your setup are also available in a cloud session](</docs/en/cloud-environments#what-carries-over-from-your-setup>) for the rest of your setup.
### Choose an install scope
@@ -240,7 +240,7 @@
A plugin’s details menu offers **Disable plugin** or **Enable plugin** , **Update now** , and **Uninstall**. Two more items appear for plugins that take settings, and a plugin can show both:
* **Configure options** : shown when the plugin’s manifest declares [`userConfig` options](</docs/en/plugins/manifest-reference#user-configuration>). Opens the dialog for those options
- * **Configure** : shown when the plugin includes a [bundled MCP server](</docs/en/plugins/components#include-a-packaged-mcpb-server>). Sets that server’s own `user_config` settings
+ * **Configure** : shown when a marketplace plugin includes a [bundled MCP server](</docs/en/plugins/components#include-a-packaged-mcpb-server>). Sets that server’s own `user_config` settings
The tab can also show plugins at **Managed** scope. Your organization installed those through [managed settings](</docs/en/settings#settings-files>), and you can’t enable, disable, or uninstall them here. For a synced plugin that your organization requires on claude.ai, see Manage plugins synced from claude.ai. When you close the `/plugin` panel with pending changes you made in it, Claude Code runs `/reload-plugins` for you to apply them. If the reload would [invalidate the prompt cache](</docs/en/prompt-caching#enabling-or-disabling-a-plugin>), it warns and leaves the changes pending instead. Run `/reload-plugins --force` to apply them anyway.
--- a/interactive-mode.md
+++ b/interactive-mode.md
@@ -566,7 +566,7 @@
Claude answers a side question from what’s already in the conversation: your messages, its replies, and the tool results it has gathered. You can ask about code Claude has already read, decisions it made earlier, or anything else from the session. A later side question also sees your earlier side questions: Claude Code replays the newest 20 exchanges with each ask, until you clear them. The question and answer never enter the conversation history. In the terminal, they appear in a dismissible overlay. The terminal keeps the thread in memory: press `x` to clear the earlier exchanges, and it’s gone when you exit Claude Code. In the [VS Code extension](</docs/en/vs-code#use-the-prompt-box>)’s chat panel, `/btw` opens a panel rather than the overlay this section describes, and you ask follow-up questions right in the panel. The panel’s thread survives window reloads, on the retention schedule that page describes. You need the extension at v2.1.227 or later. Earlier extension versions don’t offer `/btw`.
- * **Available while Claude is working** : you can run `/btw` even while Claude is processing a response. The side question runs independently and doesn’t interrupt the main turn. It sees everything in the conversation so far, except the reply Claude is still writing.
+ * **Available while Claude is working** : you can run `/btw` while Claude is processing a response. The side question runs independently and doesn’t interrupt the main turn. It sees everything in the conversation so far, except the reply Claude is still writing.
* **No tool access** : side questions answer only from what is already in context. Claude can’t read files, run commands, or search when answering a side question. If Claude writes out tool calls as text anyway, the answer ends with a note that nothing was executed.
* **Single response** : there are no follow-up turns in the overlay. To continue the thread, ask another `/btw` question. To continue with full tool access in a local session, press `f` to fork this question and answer into a [background subagent](</docs/en/sub-agents#fork-the-current-conversation>).
* **Low cost** : while the conversation’s [prompt cache](</docs/en/prompt-caching>) is warm, a side question costs little beyond the answer itself.
--- a/large-codebases.md
+++ b/large-codebases.md
@@ -119,7 +119,7 @@
### Block reads of generated and vendored code
-Claude’s content searches respect `.gitignore` by default, so paths already listed there, such as `node_modules/`, `dist/`, and `build/`, stay out of search results without additional configuration. For paths that are checked in, such as a vendored SDK or committed generated code, add `Read` deny rules in `permissions.deny` to block Claude from opening those files. The deny rules can cover everyone working in the repository, only you, or every session on the machine, depending on which settings file you put them in:
+Claude’s content searches respect `.gitignore` by default, so paths already listed there, such as `node_modules/`, `dist/`, and `build/`, stay out of search results. For paths that are checked in, such as a vendored SDK or committed generated code, add `Read` deny rules in `permissions.deny` to block Claude from opening those files. The deny rules can cover everyone working in the repository, only you, or every session on the machine, depending on which settings file you put them in:
* **Everyone working in the repository** : commit the rules to `.claude/settings.json`, at the repository root if you start Claude there, or in each package’s `.claude/` if you start from subdirectories. Like other project settings on this page, that file isn’t inherited from parent directories.
* **Yourself only** : use `.claude/settings.local.json` at the repository root. It loads in every CLI session inside the repository regardless of starting directory, except in the cases where Claude Code [doesn’t use the repository root](</docs/en/settings#where-claude-code-looks-for-each-file>), such as on Windows. Relative patterns like the example’s `Read(./**/vendor/**/*)` still [anchor at the session’s current working directory](</docs/en/permissions#read-and-edit>) rather than the repository root. If you start sessions from subdirectories, write the rules in this file as `//`-absolute paths, such as `Read(//absolute/path/to/repo/**/vendor/**/*)`.
--- a/llm-gateway-protocol.md
+++ b/llm-gateway-protocol.md
@@ -1,4 +1,4 @@
-This page documents the requests Claude Code sends to a gateway, including the endpoints it calls, the headers and body fields the gateway must forward, and which features stop working when it doesn’t. It is written for operators configuring a gateway product to work with Claude Code. The [Claude apps gateway](</docs/en/claude-apps-gateway>), Anthropic’s self-hosted gateway, serves its own endpoint reference at `GET /protocol`, covering that gateway’s sign-in, inference, managed settings, model discovery, and telemetry endpoints. It is a separate document from this guide.
+This page documents the requests Claude Code sends to a gateway, including the endpoints it calls, the headers and body fields the gateway must forward, and which features stop working when it doesn’t. It is written for operators configuring a gateway product to work with Claude Code. The [Claude apps gateway](</docs/en/claude-apps-gateway>), Anthropic’s self-hosted gateway, serves its own endpoint reference at `GET /protocol`, covering that gateway’s sign-in, inference, managed settings, model discovery, and telemetry endpoints.
* To roll out an existing or third-party gateway for your organization, see [Roll out an LLM gateway](</docs/en/llm-gateway-rollout>)
* If you’re an individual developer authenticating Claude Code to a gateway with a credential you were given, see [Connect Claude Code to an LLM gateway](</docs/en/llm-gateway-connect>)
--- a/loading.md
+++ b/loading.md
@@ -55,7 +55,7 @@
### Plugins shared through a repository
-To share a plugin through a repository, list it under `enabledPlugins` in `.claude/settings.json` or place it under `.claude/skills/`. Claude Code doesn’t scan a project’s `.claude/plugins/` directory. A cloud session doesn’t add the marketplaces a repository lists under [`extraKnownMarketplaces`](</docs/en/settings-reference#extraknownmarketplaces>), because that requires the workspace trust dialog, which a cloud session never shows.
+To share a plugin through a repository, list it under `enabledPlugins` in `.claude/settings.json` or place it under `.claude/skills/`. Claude Code doesn’t scan a project’s `.claude/plugins/` directory. An Anthropic-hosted cloud session doesn’t add the marketplaces a repository lists under [`extraKnownMarketplaces`](</docs/en/settings-reference#extraknownmarketplaces>), because that requires the workspace trust dialog, which the session doesn’t show.
#### Trust check and component limits for repository plugins
--- a/managed-mcp.md
+++ b/managed-mcp.md
@@ -305,7 +305,7 @@
Three groups of servers skip the allowlist check, in addition to the in-process `type: "sdk"` servers that skip all three checks:
* The organization’s own servers: every `managedMcpServers` entry, and any `managed-mcp.json` entry whose values use no `${VAR}` expansion outside `env`.
- * Built-in servers, such as Claude in Chrome, the `ide` server Claude Code connects to in a running VS Code or JetBrains IDE, and servers the CLI itself configures.
+ * Some built-in servers, such as the `ide` server Claude Code connects to in a running VS Code or JetBrains IDE, and Claude in Chrome in terminal sessions.
* A [Claude Tag](</docs/en/claude-tag>) session’s Slack tools: the servers it uses to read the thread and post its replies load without an allowlist entry.
A `managed-mcp.json` server that uses `${VAR}` expansion in its command, arguments, URL, or headers is still checked. Claude Code also checks every server a user, a plugin, or claude.ai adds, and every server a user passes with `--mcp-config`. For the versions that changed which `managed-mcp.json` servers are checked, and how to keep one from loading, see How allowlists and denylists apply to the managed set.
--- a/marketplace-reference.md
+++ b/marketplace-reference.md
@@ -164,7 +164,7 @@
* It must itself be a relative path inside the marketplace.
* It has no effect on a source that already starts with `./`.
- * A source that contains a `/`, such as `team-a/formatter`, isn’t a bare name and still needs the `./` prefix, even when `metadata.pluginRoot` is set.
+ * A source that contains a `/`, such as `team-a/formatter`, isn’t a bare name and still needs the `./` prefix.
### github plugin source
--- a/mcp.md
+++ b/mcp.md
@@ -747,7 +747,7 @@
asyncio.run(main())
-A remote server’s status can also change after it reports `"connected"`. When the connection to it drops mid-session, Claude Code moves the server back to `"pending"` while [reconnecting](</docs/en/mcp#automatic-reconnection>). A later `mcpServerStatus()` call in TypeScript, or [`ClaudeSDKClient.get_mcp_status()`](</docs/en/agent-sdk/python#methods>) in Python, can then report `"pending"` for a server you saw connected earlier, with no configuration change on your side. After five reconnection attempts fail, the server reports `"failed"`, or `"needs-auth"` when it needs authorizing again. A `"failed"` HTTP or SSE server can still return to `"connected"` without a call from you, because Claude Code keeps [retrying in the background](</docs/en/mcp#mid-session-drops-of-a-remote-server>) after a transient error. To retry manually, call [`reconnectMcpServer()`](</docs/en/agent-sdk/typescript#methods>) in TypeScript or [`ClaudeSDKClient.reconnect_mcp_server()`](</docs/en/agent-sdk/python#methods>) in Python.
+A remote server’s status can also change after it reports `"connected"`. Claude Code moves the server back to `"pending"` while [reconnecting](</docs/en/mcp#automatic-reconnection>). A later `mcpServerStatus()` call in TypeScript, or [`ClaudeSDKClient.get_mcp_status()`](</docs/en/agent-sdk/python#methods>) in Python, can then report `"pending"` for a server you saw connected earlier, with no configuration change on your side. After five reconnection attempts fail, the server reports `"failed"`, or `"needs-auth"` when it needs authorizing again. A `"failed"` HTTP or SSE server can still return to `"connected"` without a call from you, because Claude Code keeps [retrying in the background](</docs/en/mcp#mid-session-drops-of-a-remote-server>) after a transient error. To retry manually, call [`reconnectMcpServer()`](</docs/en/agent-sdk/typescript#methods>) in TypeScript or [`ClaudeSDKClient.reconnect_mcp_server()`](</docs/en/agent-sdk/python#methods>) in Python.
## Troubleshooting
--- a/memory.md
+++ b/memory.md
@@ -419,7 +419,7 @@
### How it works
-While auto memory is on, the first 200 lines or 25KB of `MEMORY.md`, whichever comes first, load at session start. Content beyond that threshold is not loaded at session start. Claude keeps `MEMORY.md` concise by moving detailed notes into separate topic files. After Claude writes to `MEMORY.md`, Claude Code measures the file against the 200-line and 25KB read limits. If the file is near a limit, Claude Code reminds Claude to shorten it: keep one line per entry, move detail into topic files, and merge or drop stale entries. If the file is over a limit, the write still succeeds, but Claude Code returns an [error telling Claude to rewrite the index](</docs/en/errors#memory-index-is-over-its-read-limit>), because everything past the limit is dropped on the next load.
+While auto memory is on, the first 200 lines or 25KB of `MEMORY.md`, whichever comes first, load at session start. Claude keeps `MEMORY.md` concise by moving detailed notes into separate topic files. After Claude writes to `MEMORY.md`, Claude Code measures the file against the 200-line and 25KB read limits. If the file is near a limit, Claude Code reminds Claude to shorten it: keep one line per entry, move detail into topic files, and merge or drop stale entries. If the file is over a limit, the write still succeeds, but Claude Code returns an [error telling Claude to rewrite the index](</docs/en/errors#memory-index-is-over-its-read-limit>), because everything past the limit is dropped on the next load.
This limit applies only to `MEMORY.md`. Claude gets the whole of each CLAUDE.md file that loads at launch, as long as the file is 4 MiB or smaller. Claude Code skips a file over 4 MiB and loads none of it. Path-scoped rules and CLAUDE.md files in subdirectories have a smaller per-file limit of their own.
--- a/model-config.md
+++ b/model-config.md
@@ -267,14 +267,14 @@
* **`model`** : sets the initial model selection when a session starts
* **`ANTHROPIC_DEFAULT_SONNET_MODEL`** / **`ANTHROPIC_DEFAULT_OPUS_MODEL`** / **`ANTHROPIC_DEFAULT_HAIKU_MODEL`** / **`ANTHROPIC_DEFAULT_FABLE_MODEL`** : control what the `sonnet`, `opus`, `haiku`, and `fable` aliases resolve to, and which version the account-type default uses
-This example starts users on Sonnet 4.5, limits the picker to Sonnet and Haiku, and ensures Default resolves to a model on the allowlist rather than the tier default:
+This example starts users on Sonnet 5, limits the picker to Sonnet 5.x and Haiku, and ensures Default resolves to a model on the allowlist:
{
- "model": "claude-sonnet-4-5",
- "availableModels": ["claude-sonnet-4-5", "haiku"],
+ "model": "claude-sonnet-5",
+ "availableModels": ["claude-sonnet-5", "haiku"],
"enforceAvailableModels": true,
"env": {
- "ANTHROPIC_DEFAULT_SONNET_MODEL": "claude-sonnet-4-5"
+ "ANTHROPIC_DEFAULT_SONNET_MODEL": "claude-sonnet-5"
}
}
@@ -487,7 +487,7 @@
A level you pick from the effort control on a phone or browser connected through [Remote Control](</docs/en/remote-control#what-connected-devices-see>) applies to that session only.
-When you set a level with `/effort` in a [`-p` run](</docs/en/headless>), Claude Code applies it to that session only and doesn’t save it as your default. The `/effort` slider also has an **Ultracode** toggle. Ultracode is a Claude Code setting rather than a model effort level: with it on, Claude orchestrates [dynamic workflows](</docs/en/workflows>) for substantive tasks, at whichever effort level the session runs at. For where it can be set persistently, see the [`ultracode`](</docs/en/settings-reference#ultracode>) setting. Turning ultracode on or off with `/effort` or the `ultracode` setting leaves the effort level unchanged. The `--effort ultracode` flag and the Agent SDK `effortLevel: "ultracode"` value turn it on and also set the level to `xhigh`. Picking a level in the `/effort` slider or the `/model` picker leaves ultracode as it was. You can turn on ultracode through any of the following:
+When you set a level with `/effort` in a [`-p` run](</docs/en/headless>), Claude Code applies it to that session only. The `/effort` slider also has an **Ultracode** toggle. Ultracode is a Claude Code setting rather than a model effort level: with it on, Claude orchestrates [dynamic workflows](</docs/en/workflows>) for substantive tasks, at whichever effort level the session runs at. For where it can be set persistently, see the [`ultracode`](</docs/en/settings-reference#ultracode>) setting. Turning ultracode on or off with `/effort` or the `ultracode` setting leaves the effort level unchanged. The `--effort ultracode` flag and the Agent SDK `effortLevel: "ultracode"` value turn it on and also set the level to `xhigh`. Picking a level in the `/effort` slider or the `/model` picker leaves ultracode as it was. You can turn on ultracode through any of the following:
* **`/effort`** : run `/effort ultracode` to turn it on for the current session or `/effort ultracode off` to turn it off. In the `/effort` slider, press `Tab` to flip the **Ultracode** toggle, then `Enter` to apply it
* **`--effort` flag**: launch with `claude --effort ultracode`, which starts the session at `xhigh` effort with ultracode on
--- a/monitoring-usage.md
+++ b/monitoring-usage.md
@@ -691,7 +691,7 @@
* `event.sequence`: per-process counter for ordering events, described under Event correlation attributes
* `tool_name`: Name of the tool
* `tool_use_id`: Unique identifier for this tool invocation. Matches the `tool_use_id` passed to hooks, allowing correlation between OTel events and hook-captured data.
- * `request_id`: the `request_id` of the API response that contained this tool call, so you can join the call to that response’s API events. Absent when that response had no request ID, or when no API response contained the call. Requires Claude Code v2.1.310 or later
+ * `request_id`: the `request_id` of the API response that contained this tool call or the [Code Mode](</docs/en/code-mode#monitor-code-mode-with-opentelemetry>) code that made it. Use it to join the call to that response’s API events. Absent when that response had no request ID, or when no API response contained the call or its code. Requires Claude Code v2.1.310 or later
* `success`: `"true"` or `"false"`
* `duration_ms`: Execution time in milliseconds
* `error_type`: Error category string when the tool failed, such as `"Error:ENOENT"` or `"ShellError"`
@@ -819,7 +819,7 @@
* `event.sequence`: per-process counter for ordering events, described under Event correlation attributes
* `tool_name`: Name of the tool (for example, “Read”, “Edit”, “Write”, “NotebookEdit”)
* `tool_use_id`: Unique identifier for this tool invocation. Matches the `tool_use_id` passed to hooks, allowing correlation between OTel events and hook-captured data.
- * `request_id`: the `request_id` of the API response that contained this tool call, so you can join the call to that response’s API events. Absent when that response had no request ID, or when no API response contained the call. Requires Claude Code v2.1.310 or later
+ * `request_id`: the `request_id` of the API response that contained this tool call or the [Code Mode](</docs/en/code-mode#monitor-code-mode-with-opentelemetry>) code that made it. Use it to join the call to that response’s API events. Absent when that response had no request ID, or when no API response contained the call or its code. Requires Claude Code v2.1.310 or later
* `decision`: Either `"accept"` or `"reject"`
* `tool_source`: Always present. The tool’s provenance, as a closed set of CLI-authored values:
* `"builtin"`: the CLI’s own tools
@@ -849,6 +849,7 @@
The attribute also appears on plan mode calls when [the classifier reviews commands in plan mode](</docs/en/permission-modes#analyze-before-you-edit-with-plan-mode>). The attribute is absent in these cases:
* An allow or deny [permission rule](</docs/en/permissions#manage-permissions>) decided the call
* Claude Code approved the call in auto mode without asking the classifier
+ * In [Code Mode](</docs/en/code-mode#monitor-code-mode-with-opentelemetry>), the classifier’s review of the code covered the call
* The user answered the prompt Claude Code showed after [repeated blocks](</docs/en/permission-modes#repeated-block-thresholds>)
* In a `-p` run without `--permission-prompt-tool`, Claude Code denied the call after repeated blocks because there was nobody to answer a prompt. That event reports `decision` as `"reject"` and `source` as `"config"`
* `classifier_category` (when `OTEL_LOG_TOOL_DETAILS=1`): The name of the [policy](</docs/en/auto-mode-config#fix-a-policy-denial>) or [built-in rule](</docs/en/auto-mode-config#inspect-the-defaults-and-your-effective-config>) the classifier named when it blocked the call, in lowercase with underscores, such as `"data_exfiltration"` for the Data Exfiltration rule. Requires Claude Code v2.1.301 or later. The attribute is present when both of these hold:
--- a/network-config.md
+++ b/network-config.md
@@ -96,7 +96,7 @@
## Verify your configuration
-You usually find out about a wrong proxy address or a bad certificate path from a [connection or certificate error](</docs/en/errors#network-and-connection-errors>) on a later request, since Claude Code doesn’t validate most of these settings when it reads them. The one setting it checks at startup is the proxy URL: when it can’t parse the value, such as one missing the `http://` scheme, Claude Code stops launch with an error naming the variable to fix. With Claude Code v2.1.327 or later, some starts go ahead on an `HTTPS_PROXY` value that lacks `http://`, where neither standard input nor standard output is a terminal. That is so when Claude Desktop, an SDK, or cron starts Claude Code. Write the proxy value as a complete URL, such as `http://proxy.example.com:8080`, even if a plain `host:port` works in some of your sessions. To confirm your configuration loaded before you send a request, start Claude Code with debug logging:
+You usually find out about a wrong proxy address or a bad certificate path from a [connection or certificate error](</docs/en/errors#network-and-connection-errors>) on a later request. When Claude Code can’t parse a proxy URL from your shell or `~/.claude/settings.json`, it stops launch with an error naming the variable to fix. With Claude Code v2.1.327 or later, some starts go ahead on an `HTTPS_PROXY` value that lacks `http://`, where neither standard input nor standard output is a terminal. That is so when Claude Desktop, an SDK, or cron starts Claude Code. Write the proxy value as a complete URL, such as `http://proxy.example.com:8080`, even if a plain `host:port` works in some of your sessions. To confirm your configuration loaded before you send a request, start Claude Code with debug logging:
claude --debug
--- a/org.md
+++ b/org.md
@@ -73,7 +73,7 @@
---|---|---
Terminal, interactive| Applied at session start on every machine that receives the settings| `extraKnownMarketplaces` applied after trust; `enabledPlugins` applied at session start
`-p` and CI| Applied at session start, with installs running in the background| `extraKnownMarketplaces` in trusted folders only; `enabledPlugins` applied
-Cloud sessions| In an Anthropic-hosted environment, only server-managed settings reach the session, which waits for them before it installs plugins. MDM policies and managed settings files stay on the user’s machine. For a self-hosted environment, see [Where and when a policy applies](</docs/en/managed-settings#where-and-when-a-policy-applies>)| See the **Cloud session** tab under [Install a plugin](</docs/en/plugins/install#install-a-plugin>)
+Cloud sessions| In an Anthropic-hosted environment, only server-managed settings reach the session, which waits for them before it installs plugins. MDM policies and managed settings files stay on the user’s machine. For a self-hosted environment, see [Where and when a policy applies](</docs/en/managed-settings#where-and-when-a-policy-applies>)| See [What carries over from your setup](</docs/en/cloud-environments#what-carries-over-from-your-setup>)
In a `-p` or CI run, marketplaces and plugins install in the background, so a plugin can be missing from the first turn. Set `CLAUDE_CODE_SYNC_PLUGIN_INSTALL=1` to make the run wait for the install before its first query.
--- a/output-styles.md
+++ b/output-styles.md
@@ -37,7 +37,7 @@
### Explanatory
-In the Explanatory style, Claude does the task the way it does in the Default style and adds short explanations of why it made the choices it made. Each explanation appears in the conversation, before or after the code it’s about, in a block labeled `Insight`. The explanations aren’t written into your files as comments. An `Insight` block carries two or three points about your codebase or the code Claude wrote, such as this one after adding an API endpoint:
+In the Explanatory style, Claude does the task the way it does in the Default style and adds short explanations of why it made the choices it made. Each explanation appears in the conversation, before or after the code it’s about, in a block labeled `Insight`. An `Insight` block carries two or three points about your codebase or the code Claude wrote, such as this one after adding an API endpoint:
★ Insight ─────────────────────────────────────
- Every route in this repo goes through the withAuth wrapper, so the new endpoint gets session checks without its own middleware.
@@ -126,7 +126,7 @@
`name`| No| Name of the output style, shown in the `/config` picker. Default: the file name
`description`| No| Description of the output style, shown in the `/config` picker
`keep-coding-instructions`| No| Set to `true` to keep Claude Code’s section of built-in software engineering instructions, which only the full system prompt includes, alongside your style. See How output styles work. Default: `false`
-`force-for-plugin`| No| Plugin output styles only. Set to `true` to apply this style automatically whenever the plugin is enabled, without requiring users to select it. Overrides the user’s `outputStyle` setting. If multiple enabled plugins set this, Claude Code uses the first one loaded. Default: `false`
+`force-for-plugin`| No| Plugin output styles only. Set to `true` to apply this style automatically whenever the plugin is enabled. Overrides the user’s `outputStyle` setting. If multiple enabled plugins set this, Claude Code uses the first one loaded. Default: `false`
## Choose between an output style and other features
--- a/permission-modes.md
+++ b/permission-modes.md
@@ -444,6 +444,7 @@
* No allow rule approves recognized `rm` and `rmdir` critical-path removals
* MCP tools marked [`requiresUserInteraction`](</docs/en/mcp#require-approval-for-a-specific-tool>) prompt you directly even when an allow rule matches, and so do connector tools [your organization set to `ask`](</docs/en/mcp#organization-controls-on-connector-tools>) in sessions where that setting reaches Claude Code
* A shell command that carries [per-command allowed domains](</docs/en/sandboxing#per-command-allowed-domains-in-auto-mode>) also routes to the classifier even when an allow rule matches, because a rule approves the command, not its hosts
+ * Even in Manual, `acceptEdits`, and `dontAsk` modes, the classifier can review a [Claude in Chrome](</docs/en/chrome>) action that an allow rule matches
* Ask rules that match on a command’s content, such as `Bash(git push *)`, fall back to a permission prompt
* A write that the [symlink check](</docs/en/permissions#symlinks>) resolves to a protected path prompts you when the path Claude requested isn’t itself protected
* A read from a [network path](</docs/en/permissions#network-paths>) prompts you even when an allow rule matches
@@ -486,7 +487,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, though a [mod](</docs/en/plugins/mods/overview>) you installed can still approve some of those calls. To check which calls a mod can approve, see [Extend permissions with hooks](</docs/en/permissions#precedence-among-rules-hooks-and-mods>). Don’t rely on `dontAsk` to stop a [tool call a mod makes itself](</docs/en/plugins/mods/reference#mods-api-methods>). 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>). Actions matching your `permissions.allow` rules and calls approved by a [PreToolUse hook](</docs/en/permissions#extend-permissions-with-hooks>) run too. Use this mode for CI pipelines or restricted environments where you pre-define what Claude may do. The status bar shows `⏵⏵ don't ask on` in this mode. These calls are denied where you’d otherwise see a prompt:
+If you set `dontAsk` mode, Claude Code auto-denies every tool call that would otherwise prompt you, though a [mod](</docs/en/plugins/mods/overview>) you installed can still approve some of those calls. To check which calls a mod can approve, see [Extend permissions with hooks](</docs/en/permissions#precedence-among-rules-hooks-and-mods>). Don’t rely on `dontAsk` to stop a [tool call a mod makes itself](</docs/en/plugins/mods/reference#mods-api-methods>). 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>). Most calls that your `permissions.allow` rules or a [PreToolUse hook](</docs/en/permissions#extend-permissions-with-hooks>) approve run too. Use this mode for CI pipelines or restricted environments where you pre-define what Claude may do. The status bar shows `⏵⏵ don't ask on` in this mode. These calls are denied where you’d otherwise see a prompt:
* **Your`ask` rules**: Claude Code denies calls matching your explicit [`ask` rules](</docs/en/permissions#manage-permissions>).
* **`AskUserQuestion`** : Claude Code denies this built-in tool even if your allow rules match it.
--- a/pr-steward.md
+++ b/pr-steward.md
@@ -0,0 +1,50 @@
+PR Steward is an agent that works on your team’s open GitHub pull requests. It pushes commits to address review feedback, and attempts to fix failing checks and resolve merge conflicts. With it on, you can open a pull request and start your next change while PR Steward works on the failing checks, conflicts, and review comments that follow. It’s in public beta on Team and Enterprise plans.
+
+To turn on PR Steward, follow [Set up PR Steward](</docs/en/pr-steward-setup>), which takes an Owner role in your Claude organization.
+
+PR Steward picks up a problem on GitHub, works on it in a cloud session, and reports back on the pull request: To stop PR Steward on a pull request, remove the `claude-pr-steward-watching` label or [comment `@claude stop`](</docs/en/pr-steward-pull-requests#start-or-stop-pr-steward-on-one-pull-request>). Steward is designed not to approve or merge pull requests. Use branch protection to require the approvals you want before anything merges. See [Limits on approvals and merges](</docs/en/pr-steward-security#limits-on-approvals-and-merges>).
+
+## What PR Steward does on a pull request
+
+While PR Steward watches a pull request, it pushes commits and replies to comments without asking first, and the pull request has the `claude-pr-steward-watching` label. See [what PR Steward adds to a pull request](</docs/en/pr-steward-pull-requests#what-pr-steward-adds-to-a-pull-request>).
+
+### When PR Steward starts
+
+In a repository where an Owner set PR Steward to **On** , it starts when you open a pull request, reopen one, or mark a draft as ready for review. It also starts at the next push to an open pull request that it hasn’t started on before. PR Steward skips drafts, pull requests from forks, pull requests that a bot opened, and authors without write access to the repository. An Owner can [change the repository’s setting](</docs/en/pr-steward-setup#choose-when-pr-steward-starts-in-each-repository>) so that PR Steward includes drafts, or normally starts only when someone asks it to.
+
+### What PR Steward fixes
+
+PR Steward works on failing checks, merge conflicts, review feedback, and the Claude Approvals check:
+
+ * **A failing check** : attempts a fix when the cause is in code that the pull request touches
+ * **A merge conflict** : attempts to merge the base branch in and resolve the conflicts
+ * **A person’s review comment** : attempts small, specific changes and replies to the comment. Can reply without pushing when the request is large or about the design
+ * **A review bot’s finding** : works on the findings that [Code Review](</docs/en/code-review>) marks **Important**. For other bots, works on lint findings and bugs
+ * **The[Claude Approvals](</docs/en/approvals>) check**: where the check waits for something that a commit can fix, such as open Code Review findings, works on that. Where the check waits for people’s approvals, leaves it. After PR Steward pushes, the check can [ask for approvals again](</docs/en/approvals-policy#earlier-approvals-after-a-new-push>)
+
+### Stop or limit PR Steward
+
+To stop PR Steward on one pull request, remove the `claude-pr-steward-watching` label or [comment `@claude stop`](</docs/en/pr-steward-pull-requests#start-or-stop-pr-steward-on-one-pull-request>). To turn off or limit PR Steward on the pull requests that you open later, go to [**PR Steward**](<https://claude.ai/settings/claude-code#pr-steward>) in **Settings > Code** or **Settings > Claude Code**.
+
+## Decide whether PR Steward fits your team
+
+PR Steward is one of the [Claude Ship](</docs/en/claude-ship>) agents, alongside Code Review and Claude Approvals. Before you turn it on, compare it with auto-fix and `/steward`, check that your organization qualifies, and see how it’s billed.
+
+### How PR Steward differs from auto-fix and /steward
+
+[Auto-fix](</docs/en/claude-code-on-the-web#auto-fix-pull-requests>) and the [`/steward` command](</docs/en/ship-command#start-a-watch-with-%2Fsteward>) also work on failing checks and review comments. They run in your own sessions, and they act as you and count against your own usage. PR Steward acts as the [Claude GitHub App](<https://github.com/apps/claude>) and bills your organization. If you ask to auto-fix a pull request that PR Steward is watching, the request fails. See [Auto-fix is unavailable](</docs/en/pr-steward-troubleshooting#auto-fix-is-unavailable>).
+
+### Availability
+
+PR Steward works with repositories on github.com or a connected [GitHub Enterprise Server](</docs/en/github-enterprise-server>) instance on port 443. You need a Claude organization on a [Team or Enterprise plan](</docs/en/feature-availability#features-that-require-a-claude-subscription>). PR Steward isn’t available to organizations with [Zero Data Retention](</docs/en/zero-data-retention>) enabled, the [HIPAA configuration](</docs/en/hipaa-setup>) applied, or customer-managed encryption keys.
+
+### What PR Steward costs
+
+PR Steward’s usage is billed by tokens to your organization’s [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>). It has no spend limit of its own until you [set one](</docs/en/pr-steward-setup#set-pr-steward%E2%80%99s-spend-limits>), which takes an Owner role.
+
+## Next steps
+
+ * [Set up PR Steward](</docs/en/pr-steward-setup>), which takes an Owner
+ * [Work with PR Steward](</docs/en/pr-steward-pull-requests>) on your pull requests
+ * [What PR Steward can access](</docs/en/pr-steward-security>)
+ * [Troubleshoot PR Steward](</docs/en/pr-steward-troubleshooting>)
Show diff (196 lines)
--- a/pr-steward-pull-requests.md
+++ b/pr-steward-pull-requests.md
@@ -0,0 +1,193 @@
+[PR Steward](</docs/en/pr-steward>) is an agent that works on the GitHub pull requests that you open, in repositories where it’s on. It pushes commits to address review feedback, and attempts to fix failing checks and resolve merge conflicts. You can tell it what to work on or turn it off for yourself. To stop it on one pull request, remove the `claude-pr-steward-watching` label, or comment `@claude stop`.
+
+## What PR Steward adds to a pull request
+
+On github.com, PR Steward posts its comments as `claude[bot]`, the account of the [Claude GitHub App](<https://github.com/apps/claude>). PR Steward adds these labels, comments, and commits to a pull request: PR Steward adds each one at these times:
+
+What PR Steward adds| When
+---|---
+The `claude-pr-steward-watching` label| While it watches the pull request
+The `claude-pr-steward-is-working` label| While it works
+A comment headed **Claude PR Steward**| When it first starts on the pull request
+A progress comment| Before and after a piece of work
+Commits whose author and committer are `Claude <noreply@anthropic.com>`| When it pushes a fix
+
+The progress comment after a push names the commits to revert if you want to undo the push.
+
+### Example of a fix for a failing check
+
+In this example, you open a pull request in a repository where PR Steward starts by itself, and a test of the code that you changed fails. Claude writes the progress comments, so their wording varies.
+
+ 1. **PR Steward starts** : it adds the `claude-pr-steward-watching` label and posts a first comment. The emoji and the opening words change from one pull request to the next, and the rest reads like this:
+
+ 🛠️ Claude PR Steward — On it. I'll chase down CI failures, work through review comments, and push fixes until it's green. Ask me anything in a comment and I'll answer or take action. I'll check for a steward skill at .claude/skills/steward/SKILL.md for any repo-specific behavior I should follow.
+
+ Remove the claude-pr-steward-watching label any time to take over.
+
+ React with 👍 or 👎 to provide feedback · Settings
+
+ 2. **The test fails** : PR Steward adds the `claude-pr-steward-is-working` label and says what it plans to do:
+
+ The unit-tests check failed on test_parse_date. I'll find the cause and push a fix.
+
+ – Claude PR steward · Settings
+
+ 3. **PR Steward pushes a fix** : PR Steward can wait before it pushes, for example while other checks are still running, and says so in a comment. Then a commit by `Claude <noreply@anthropic.com>` appears on your branch. A second progress comment says what changed and how to undo it:
+
+ Pushed a1b2c3d: parse_date now accepts a date with no time zone, which is the case that test_parse_date covers. To undo it, revert a1b2c3d, or remove the claude-pr-steward-watching label to stop me entirely.
+
+ – Claude PR steward · Settings
+
+ 4. **The work ends** : PR Steward removes the `claude-pr-steward-is-working` label and continues to watch the pull request
+
+## Change what PR Steward does
+
+PR Steward starts from default instructions on how to handle failing checks, review comments, and the base branch. You can change what it does for one pull request, for every pull request that you open, or for a whole repository:
+
+ * **For one pull request that you opened** : start a comment with `@claude` on that pull request
+ * **For every pull request that you open** : in your settings on claude.ai, turn it off or limit it, choose what it works on, or enter instructions
+ * **For everyone’s pull requests in a repository** : save a file at `.claude/skills/steward/SKILL.md` in that repository
+
+### Default instructions for PR Steward
+
+PR Steward’s default instructions are instructions to Claude, so they describe what PR Steward aims to do. With no instructions from you, PR Steward follows defaults such as these:
+
+Work| By default
+---|---
+Failing checks| Fixes and pushes when the failure is in code that the pull request touches
+Flaky checks| Re-runs a failed job once, when the job failed before any test ran or passed earlier on the same commit
+Base branch| Merges the base branch into yours when there’s a conflict. Can also merge it when your branch is behind
+Lockfiles and generated files| Regenerates them
+Small review requests, such as a rename or an added test| Pushes the change and resolves the thread
+Large or design-level review requests| Replies, and doesn’t push or resolve the thread, unless the reviewer says which change to make
+Code Review’s optional findings| Replies and resolves the thread. Doesn’t push for these alone
+Choice of approach| Picks one itself, and doesn’t ask you which to take
+
+To change most of these defaults for everyone’s pull requests in a repository, save instructions at `.claude/skills/steward/SKILL.md` in that repository.
+
+### Give PR Steward instructions in a comment
+
+On a pull request that you opened, start a comment with `@claude` and say what you want. This comment asks PR Steward to fix one kind of failure:
+
+ @claude only fix the lint failures. I'm still working on the tests.
+
+### Turn off or limit PR Steward on all your pull requests
+
+Go to [**PR Steward**](<https://claude.ai/settings/claude-code#pr-steward>) in **Settings > Code** or **Settings > Claude Code** on claude.ai and select how much PR Steward does on the pull requests that you open. To change the setting, you need a [connected GitHub account](</docs/en/web-quickstart#connect-github>).
+
+Option| What PR Steward does on your pull requests
+---|---
+**Off**| Starts only when you add the `claude-pr-steward-watching` label or comment `@claude steward` yourself
+**Only when tagged**| Starts only when you or a teammate with write access adds the `claude-pr-steward-watching` label or comments `@claude steward`
+**Act on its own**| Starts on each [eligible pull request](</docs/en/pr-steward#when-pr-steward-starts>), including in repositories that an Owner [set to **Manual**](</docs/en/pr-steward-setup#choose-when-pr-steward-starts-in-each-repository>)
+**Customize**| Follows each repository’s own setting for when to start. You choose what it works on
+
+Before you choose an option, the settings page shows **Act on its own** as selected. Until you choose one, PR Steward follows each repository’s own setting. PR Steward reads your settings when it starts on a pull request, so a change applies to later starts.
+
+### Choose what PR Steward works on
+
+To tell PR Steward what to work on, for every pull request that you open, use the toggles in your settings. A repository’s `.claude/skills/steward/SKILL.md` can say something else, so see which instructions take priority.
+
+ 1. Go to [**PR Steward**](<https://claude.ai/settings/claude-code#pr-steward>) in **Settings > Code** or **Settings > Claude Code** on claude.ai
+ 2. For **How much should Steward do on its own?** , select **Customize**
+ 3. Turn off the toggle for each thing that you don’t want PR Steward to do. Each toggle is on until you turn it off:
+ * **Failing CI and merge conflicts**
+ * **Issues found by Code Review and other review bots**
+ * **Comments from human reviewers**
+ * **Reply to reviewers and resolve their threads** , which needs **Comments from human reviewers** on
+ * **Include my draft PRs**
+
+With **Customize** selected, the settings look like this:
+
+**Customize** also changes when PR Steward starts: it follows each repository’s own setting. If you had **Off** or **Only when tagged** selected before, it can then start by itself.
+
+While **Include my draft PRs** is on, PR Steward works on your drafts in repositories that an Owner set to include drafts. PR Steward also works on your drafts in a repository that an Owner set to **Manual** , when someone asks for it on the draft. While it’s off, PR Steward doesn’t start on your drafts. While **Failing CI and merge conflicts** is on, you can also say when PR Steward merges the base branch into yours. Set **Updating my branch from the base branch** to **Whenever my branch falls behind** , **Only when there is a conflict** , or **Never, I update it myself**.
+
+### Save PR Steward instructions for every pull request you open
+
+To give PR Steward the same instructions on every pull request that you open, go to [**PR Steward**](<https://claude.ai/settings/claude-code#pr-steward>) in **Settings > Code** or **Settings > Claude Code** on claude.ai. Under **My instructions for Steward** , enter up to 1,000 characters. These instructions ask for small commits and no replies to reviewers:
+
+ Keep commits small.
+ Don't reply to reviewers for me.
+
+### Save PR Steward instructions for everyone in a repository
+
+To set how PR Steward behaves for everyone in a repository, save a file at `.claude/skills/steward/SKILL.md` and merge it to the default branch. This example tells PR Steward which work to take on, and how to handle one file and one flaky check:
+
+ ---
+ name: steward
+ description: House rules for PR Steward in this repository
+ user-invocable: false
+ disable-model-invocation: true
+ ---
+
+ - Work on failing checks, merge conflicts, and Important findings from Code Review.
+ - Leave comments from human reviewers to the author.
+ - Regenerate `package-lock.json` with `npm install`. Don't edit it directly.
+ - The `e2e-nightly` check is flaky. Re-run it once before you look for a cause.
+
+To check that PR Steward follows the file:
+
+ 1. Open a test pull request after the file reaches the default branch.
+ 2. If the `claude-pr-steward-watching` label doesn’t appear by itself, comment `@claude steward`.
+ 3. Once the label is on, have a teammate leave a review comment.
+
+The example leaves comments from human reviewers to the author, so PR Steward should push no fix for that review comment. PR Steward also reads instructions from files such as `CLAUDE.md`, `.claude/CLAUDE.md`, `.claude/rules/`, and `AGENTS.md` at the repository’s root. It reads them from the default branch.
+
+The `/ship` and `/steward` commands in Claude Code read the same file. During a watch, Claude [follows the copy in your checkout](</docs/en/ship-command#save-instructions-for-watches-in-a-repository>).
+
+### Which PR Steward instructions take priority
+
+Your settings, the repository’s file, and your comments can disagree. PR Steward settles that this way:
+
+ * **Whether PR Steward starts** : the option that you select and **Include my draft PRs** are checked before PR Steward reads any instructions
+ * **What PR Steward does after it starts** : where your own settings and the repository’s `.claude/skills/steward/SKILL.md` disagree, that file applies. Your comments on the pull request override your own settings there, and a comment that asks PR Steward to stop or hold off also overrides that file
+
+## Start or stop PR Steward
+
+Use a comment or a label to start or stop PR Steward on one pull request. To turn it off or limit it on every pull request that you open, change your settings.
+
+### Start or stop PR Steward on one pull request
+
+To stop PR Steward on a pull request, remove the `claude-pr-steward-watching` label, or comment `@claude stop`. To start or stop PR Steward with a comment, put one of these commands at the start of a top-level comment on an open pull request:
+
+Comment| What it does
+---|---
+`@claude stop`| Stops PR Steward. Make the command the whole comment
+`@claude steward stop` or `@claude unwatch`| Stops PR Steward
+`@claude steward`| Starts PR Steward
+`@claude babysit`, `@claude watch`, `@claude babysit stop`, `@claude watch stop`| Other spellings of the start and stop commands
+
+After a stop command, PR Steward removes its labels and confirms in a comment. After you remove the label, it stops without a comment. PR Steward stays stopped when you push or comment later. To restart it, comment `@claude steward` or add the label again. If it doesn’t start, see [PR Steward didn’t start on a pull request](</docs/en/pr-steward-troubleshooting#pr-steward-didn%E2%80%99t-start-on-a-pull-request>).
+
+### Undo a fix that PR Steward pushed
+
+After a revert, PR Steward can make the same fix again, so take these steps in order:
+
+ 1. **Hold PR Steward back** : stop it.
+ 2. **Revert the commits** : revert the commits by `Claude <noreply@anthropic.com>` that you don’t want.
+
+### Keep PR Steward off a pull request from the start
+
+Include this marker in the description when you open the pull request:
+
+ <!-- claude-pr-steward-disable -->
+
+To start PR Steward on that pull request later, remove the marker first.
+
+### Who can start and stop PR Steward
+
+Starting or stopping PR Steward takes this access to the repository:
+
+Action| Who can do it
+---|---
+Start or stop PR Steward with a comment| A person with write access to the repository
+Start PR Steward by adding the `claude-pr-steward-watching` label| A person with write access
+Stop PR Steward by removing the label| Any person GitHub allows to remove labels
+
+## Related resources
+
+ * [PR Steward](</docs/en/pr-steward>)
+ * [Troubleshoot PR Steward](</docs/en/pr-steward-troubleshooting>)
+ * [What PR Steward can access](</docs/en/pr-steward-security>)
+ * [Set up PR Steward](</docs/en/pr-steward-setup>)
--- a/pr-steward-security.md
+++ b/pr-steward-security.md
@@ -0,0 +1,55 @@
+[PR Steward](</docs/en/pr-steward>) is an agent that works on your team’s open GitHub pull requests. It acts on GitHub as the [Claude GitHub App](<https://github.com/apps/claude>) and works on each pull request in a [cloud session](</docs/en/claude-code-on-the-web>). On GitHub Enterprise Server, it acts as [the app that your organization created](</docs/en/github-enterprise-server#admin-setup>). The access and limits here are those of a session in an Anthropic-hosted environment. For a self-hosted one, see [Run PR Steward in a self-hosted environment](</docs/en/pr-steward-setup#run-pr-steward-in-a-self-hosted-environment>). For how session data is handled, see [Data usage](</docs/en/data-usage>).
+
+## PR Steward’s identity and permissions
+
+Check what a PR Steward session can reach on GitHub, then how the session itself is set up.
+
+### PR Steward’s GitHub access
+
+As its GitHub App, a PR Steward session acts on GitHub with these repositories, permissions, and token:
+
+Topic| What PR Steward uses
+---|---
+Repositories| A session starts with the pull request’s own repository, which it reads and writes. GitHub search on github.com can return results from other github.com repositories that your organization has added for PR Steward. A session can fetch public repositories on github.com
+Permissions| Read and write on contents, pull requests, and issues. Where your installation of the app grants them, it also has read on checks and statuses and write on Actions. On github.com, the installation can also grant write on workflows, which lets PR Steward push changes to workflow files. See the app’s [permission list](</docs/en/github-actions#github-app-permissions>)
+Token| The app’s token is kept outside the session’s sandbox. By default, the session’s `gh` and `git` requests go through Anthropic’s service, which adds the token
+
+### PR Steward’s session environment
+
+Check where a PR Steward session runs, how it handles permission prompts, and which comments and instruction files it reads:
+
+Topic| How a session works
+---|---
+Where the code runs| In a [cloud session](</docs/en/claude-code-on-the-web>). See [the environment that PR Steward runs in](</docs/en/pr-steward-setup#choose-the-environment-pr-steward-runs-in>)
+Permission prompts| The session is started in [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>), and a request for permission is denied
+Comments| Anthropic’s service sends a session the comments and reviews of the pull request’s author, people with write access to the repository, and bots. When a session reads the pull request directly, it can also see what anyone else wrote there
+Instruction files| PR Steward [reads them from the default branch](</docs/en/pr-steward-pull-requests#save-pr-steward-instructions-for-everyone-in-a-repository>)
+
+## Limits on approvals and merges
+
+Steward is designed not to approve or merge pull requests. Use branch protection to require the approvals you want before anything merges. In an Anthropic-hosted environment, Anthropic’s service refuses some requests that a PR Steward session makes as its GitHub App, and leaves others to GitHub’s branch rules.
+
+### Requests that Anthropic’s service refuses
+
+Anthropic’s service refuses these requests from a PR Steward session that acts as its GitHub App:
+
+ * Approving a pull request
+ * Changing branch protection, rulesets, or statuses, or writing check runs
+ * Deleting a branch
+ * Pushing tags
+
+### Requests left to GitHub’s branch rules
+
+Anthropic’s service allows requests such as these. GitHub’s branch rules control them, on the branches that have rules:
+
+ * **Merging, turning on auto-merge, and force-pushing** : before GitHub’s branch rules apply, two checks run on the commands that Claude runs
+ * **Pushing to a branch other than the pull request’s** : a session can push to any branch in that repository that GitHub lets the Claude GitHub App push to
+ * **Dismissing a review** : to limit who can do it, use GitHub’s branch rules, for example **Restrict who can dismiss pull request reviews** in a classic branch protection rule
+
+Two checks run on a command that merges, turns on auto-merge, or force-pushes. Permission rules deny the usual commands for these actions. [Auto mode’s check](</docs/en/permission-modes#how-auto-mode-evaluates-actions>) judges commands that no rule matches. The rules match a command’s text and the check is a model’s judgment, so a command that’s written another way can pass both. To have GitHub enforce reviews on what PR Steward pushes, [require reviews with branch rules](</docs/en/pr-steward-setup#require-reviews-with-branch-rules>) and keep the Claude GitHub App off each ruleset’s bypass list. In a classic branch protection rule, keep it off the **Allow specified actors to bypass required pull requests** list.
+
+## Related resources
+
+ * [Set up PR Steward](</docs/en/pr-steward-setup>)
+ * [PR Steward](</docs/en/pr-steward>)
+ * [Data usage](</docs/en/data-usage>)
Show diff (168 lines)
--- a/pr-steward-setup.md
+++ b/pr-steward-setup.md
@@ -0,0 +1,165 @@
+To set up [PR Steward](</docs/en/pr-steward>), turn it on for your Claude organization and then for each repository. You need an [Owner role](</docs/en/server-managed-settings#access-control>). Once it’s on in a repository, PR Steward pushes commits to pull requests there to address review feedback, and attempts to fix failing checks and resolve merge conflicts. It starts by itself or when someone asks for it, as you choose for each repository.
+
+## Prerequisites
+
+Check that your organization [qualifies for PR Steward](</docs/en/pr-steward#availability>). In your Claude organization, which you manage at [claude.ai](<https://claude.ai/admin-settings>), you need:
+
+ * An [Owner role](</docs/en/server-managed-settings#access-control>)
+ * [Usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>), which pay for PR Steward’s work
+ * The GitHub connector, turned on at [**Organization settings > Connectors**](<https://claude.ai/admin-settings/connectors>). With it on, people in your organization can [connect their GitHub accounts](</docs/en/web-quickstart#connect-github>) to Claude
+
+On GitHub, you need this access, or someone who has it:
+
+ * Owner of the GitHub organization, to install the [Claude GitHub App](<https://github.com/apps/claude>) and [link it to your Claude organization](</docs/en/admin-setup#connected-github-accounts>)
+ * Admin of the repository, to add branch rules. A private repository also needs a [paid GitHub plan](<https://docs.github.com/en/get-started/learning-about-github/githubs-plans>)
+ * Push access to the repository, from the GitHub account that you connect to Claude
+
+## Require reviews with branch rules
+
+Add these rules in GitHub before you turn on PR Steward.
+
+1
+
+Require an approval
+
+Add a ruleset rule on the default branch that requires a pull request with at least one approval.
+
+2
+
+Require a new approval after a push
+
+In that rule, dismiss stale approvals when new commits are pushed, or require approval of the most recent push.
+
+3
+
+Check the ruleset's bypass list
+
+Keep the Claude GitHub App off the ruleset’s bypass list. On GitHub Enterprise Server, that’s [the app that your organization created](</docs/en/github-enterprise-server#admin-setup>). If PR Steward runs in a self-hosted environment, keep the runner’s git identity off it.
+
+4
+
+Protect other branches
+
+Add rules to any other branch that PR Steward shouldn’t push to, and block force pushes where you don’t want them.
+
+Where a [Claude Approvals policy lets Claude approve](</docs/en/approvals-github-rules#merges-without-human-review>), Claude’s review can count as the approval in step 1. An approval from a session in a self-hosted environment can count as well.
+
+## Turn on PR Steward and add repositories
+
+Start on [**Organization settings > Claude Ship**](<https://claude.ai/admin-settings/claude-ship>). The **Repositories** table on that page lists each repository with its **Steward** setting:
+
+Adding a repository can start [Code Review](</docs/en/code-review-setup>) there, which is billed.
+
+ * **No repository is listed yet** : a dialog asks what Claude does on the repositories that you add, and **Code review** is selected by default. If you select **Steward** in the dialog, PR Steward turns on for the organization and those repositories before you’ve set a spend limit.
+ * **Others are already listed** : no dialog opens, and the new one is set up for review at every push by default.
+
+To change that, [set when reviews run](</docs/en/code-review-setup#set-when-reviews-run>) or [turn off Code Review](</docs/en/code-review-setup#turn-off-code-review-or-remove-a-repository>) for the repository.
+
+1
+
+Add a repository
+
+If the repository is already listed under **Repositories** , skip this step. Otherwise, click **Add** , connect your GitHub account if asked, and select the repository. If a dialog then asks what Claude does on it, click **Not now** , which keeps the repository listed.
+
+2
+
+Set which authors PR Steward works for
+
+Under the **Steward** switch, use **Runs for** to set whose pull requests PR Steward works on. Select **All eligible authors** , or select **Listed users only** to pilot with a few people, and enter their GitHub usernames.On GitHub Enterprise Server, select **All eligible authors** , because PR Steward doesn’t start there with a list.
+
+3
+
+Turn on PR Steward for the organization
+
+Click the **Steward** switch, then click **Turn on**.
+
+4
+
+Set PR Steward's monthly limit
+
+Go to [**Organization settings > Usage**](<https://claude.ai/admin-settings/usage>). Under **Services** , set the limit in the **PR Steward** row. PR Steward has no spend limit of its own until you set one.
+
+5
+
+Turn on PR Steward for the repository
+
+On the **Claude Ship** page, click **Edit** beside the repository. Set **Steward** to **Manual (@claude steward)**. Click **Change** beside **Steward spend cap** and enter the cap, in US dollars. See how the cap works.
+
+6
+
+Test PR Steward
+
+Open a pull request from an account that has write access and that **Runs for** covers. Comment `@claude steward`. The `claude-pr-steward-watching` label and a comment headed **Claude PR Steward** appear.
+
+If they don’t appear, see [Troubleshoot PR Steward](</docs/en/pr-steward-troubleshooting>).
+
+## Roll out PR Steward to more pull requests
+
+When PR Steward’s fixes match what your reviewers would do, set the repository to **On**. For each repository that you add later, require reviews there first. Then repeat these steps from Turn on PR Steward and add repositories: add the repository, turn on PR Steward for it, and test PR Steward. PR Steward can be on in up to 256 repositories.
+
+### Choose when PR Steward starts in each repository
+
+On the **Claude Ship** page, click **Edit** beside a repository and set **Steward** :
+
+Option| When PR Steward starts
+---|---
+**Manual (@claude steward)**| When a person with write access comments `@claude steward` or adds the `claude-pr-steward-watching` label
+**On**| When a pull request that [PR Steward doesn’t skip](</docs/en/pr-steward#when-pr-steward-starts>) is opened, reopened, or marked ready for review. Also at the next push to an open one that it hasn’t started on before
+**On (including drafts)**| The same as **On** , and on draft pull requests
+**Off**| PR Steward doesn’t start in the repository
+
+In a **Manual** repository, a comment or the label can start PR Steward on [a draft](</docs/en/pr-steward-pull-requests#choose-what-pr-steward-works-on>). It doesn’t start PR Steward on the other pull requests that [PR Steward skips](</docs/en/pr-steward#when-pr-steward-starts>). PR Steward also starts there on the pull requests of a developer who selects [**Act on its own**](</docs/en/pr-steward-pull-requests#turn-off-or-limit-pr-steward-on-all-your-pull-requests>).
+
+### Limit which authors PR Steward works for
+
+To skip an author, add their GitHub username to **Excluded users** , under the **Steward** switch.
+
+## Control what PR Steward spends
+
+Billing [continues while usage credits are turned off](</docs/en/claude-ship#how-each-claude-ship-agent-is-billed>).
+
+### See what PR Steward spent
+
+To see the average for each merged pull request, open a repository’s **Edit** dialog. For your organization’s total over the last 30 days, go to [claude.ai/analytics/pr-steward](<https://claude.ai/analytics/pr-steward>).
+
+### Set PR Steward’s spend limits
+
+Change the monthly limit in [**Organization settings > Usage**](<https://claude.ai/admin-settings/usage>), under **Services** , in the **PR Steward** row. The row appears after you first turn on PR Steward. Change the spend cap in the repository’s **Edit** dialog. When PR Steward reaches a limit, look for its comment on the pull request:
+
+ * **Its monthly limit, or your organization’s usage-credit limit** : PR Steward pauses. It picks up again at the next push or comment once usage credits can pay again
+ * **The spend cap** : PR Steward stops on that pull request. Spend can pass the cap before it stops. A person with write access can start it again, with the full cap. When PR Steward works on a pull request for more than about a week, it can start a new [cloud session](</docs/en/claude-code-on-the-web>), and the full cap then applies again
+
+With no usage credits left to spend, PR Steward doesn’t start, and the **Claude Ship** page shows **Steward cannot start on pull requests**. Add usage credits or raise the limit on the **Usage** page.
+
+## Set up PR Steward’s build environment
+
+Choose an environment for PR Steward when it needs more to build and test your code.
+
+### Choose the environment PR Steward runs in
+
+To add a setup script, environment variables, or different network access, use an [organization-shared environment](</docs/en/cloud-environments#organization-shared-environments>). On the **Claude Ship** page, select a **Default environment** under **Where it runs**. To override it for one repository, click **Change** beside **Environment** in the **Edit** dialog. With neither set, PR Steward can use your organization’s [default environment](</docs/en/cloud-environments#the-default-environment>). Without one, it runs in an Anthropic-hosted environment with no setup script and no environment variables.
+
+### Run PR Steward in a self-hosted environment
+
+For the environment that PR Steward runs in, you can select a [self-hosted environment](</docs/en/self-hosted-environments>). The [limits on approvals and merges](</docs/en/pr-steward-security#limits-on-approvals-and-merges>) are described for Anthropic-hosted sessions only. On a runner without [Anthropic-managed git](</docs/en/self-hosted-environments-deploy#use-the-anthropic-git-proxy>), PR Steward pushes with the runner’s own git credentials.
+
+In a self-hosted environment, Claude can reach GitHub directly with [any GitHub credential that a session can read](</docs/en/self-hosted-environments-deploy#harden-your-deployment>). Anthropic’s service can’t refuse an approval that’s made that way. GitHub can count it toward the approvals that you require.
+
+In a self-hosted environment, PR Steward doesn’t load a `CLAUDE.md` or rules file from the runner or from the runner’s checkout of the pull request. It doesn’t load a [managed `CLAUDE.md`](</docs/en/memory#deploy-organization-wide-claude-md>). Put what PR Steward should follow [on the repository’s default branch](</docs/en/pr-steward-pull-requests#save-pr-steward-instructions-for-everyone-in-a-repository>).
+
+## Turn off PR Steward
+
+When you turn off PR Steward, new starts stop. It keeps working for a time on pull requests that already have the `claude-pr-steward-watching` label. When you turn it off for one author, that time can be about a week. To stop PR Steward there as well, first remove the label from the pull requests that the change covers. Then turn off PR Steward on the **Claude Ship** page:
+
+To turn off PR Steward for| Then
+---|---
+The organization| Click the **Steward** switch
+One repository| Click **Edit** beside the repository and set **Steward** to **Off**
+One author| Add their GitHub username to **Excluded users**
+
+If you turned it off first, remove the labels afterward to stop PR Steward, unless your GitHub organization is linked to more than one Claude organization.
+
+## Next steps
+
+ * [Work with PR Steward](</docs/en/pr-steward-pull-requests>)
+ * [What PR Steward can access](</docs/en/pr-steward-security>)
--- a/pr-steward-troubleshooting.md
+++ b/pr-steward-troubleshooting.md
@@ -0,0 +1,95 @@
+When [PR Steward](</docs/en/pr-steward>) doesn’t do what you expect on a pull request, look for a comment from it first. If PR Steward posted one, match the comment. If it left nothing on the pull request, check why it didn’t start.
+
+## PR Steward didn’t start on a pull request
+
+Some causes leave nothing on the pull request, so check each of these sections.
+
+### PR Steward didn’t respond to your comment
+
+If you commented `@claude steward` on github.com and PR Steward didn’t start, look at your comment:
+
+What you see| What to check
+---|---
+No 👀 reaction| That it’s a new comment and not an edit, and that you have write access
+A 👀 reaction, and no `claude-pr-steward-watching` label after it| That the command is at the start of a top-level comment. Then check the other sections under PR Steward didn’t start on a pull request
+
+### Pull requests that PR Steward doesn’t start on
+
+Check whether your pull request is one that PR Steward skips:
+
+Cause| What to do
+---|---
+The pull request is a draft| Mark it ready for review. For work on drafts, see [**Include my draft PRs**](</docs/en/pr-steward-pull-requests#choose-what-pr-steward-works-on>)
+The pull request comes from a fork, a bot opened it, or its author lacks write access to the repository| PR Steward doesn’t start on these
+The description contains `<!-- claude-pr-steward-disable -->`| Remove the marker from the description, then comment `@claude steward`
+Another Claude session is already watching the pull request, for example a cloud session with [auto-fix](</docs/en/claude-code-on-the-web#auto-fix-pull-requests>) on| Turn off auto-fix in that session, then comment `@claude steward` again
+
+### A setting keeps PR Steward off
+
+A setting can keep PR Steward from starting:
+
+Cause| What to do
+---|---
+The repository is [set to **Manual**](</docs/en/pr-steward-setup#choose-when-pr-steward-starts-in-each-repository>), or [your own option](</docs/en/pr-steward-pull-requests#turn-off-or-limit-pr-steward-on-all-your-pull-requests>) is **Off** or **Only when tagged**| Comment `@claude steward`
+The pull request is a teammate’s, and their own option is **Off**| Ask them to comment `@claude steward`
+PR Steward is off for the repository or for the author’s GitHub account| Ask an [Owner](</docs/en/server-managed-settings#access-control>) of your Claude organization to [add the repository](</docs/en/pr-steward-setup#turn-on-pr-steward-and-add-repositories>) or to change [which authors PR Steward works for](</docs/en/pr-steward-setup#limit-which-authors-pr-steward-works-for>)
+
+To confirm the last cause, have the author open their [PR Steward settings page](<https://claude.ai/settings/claude-code#pr-steward>). It shows a banner when your organization has turned off PR Steward. It also shows one when the GitHub account that they connected there is excluded.
+
+### Many pull requests opened in a short time
+
+If PR Steward started on many pull requests in your organization in a short time, comment `@claude steward`. If the `claude-pr-steward-watching` label still doesn’t appear, comment again later.
+
+## PR Steward posted a comment that says why
+
+Find the words of PR Steward’s comment in one of these tables.
+
+### Comments when PR Steward can’t start
+
+If PR Steward commented and didn’t start, find the comment’s words here:
+
+Comment says| What to do
+---|---
+`PR Steward didn't start: only someone with write access`| Have a person with write access add the `claude-pr-steward-watching` label or comment `@claude steward`
+`PR Steward hasn't started: your organization has no extra usage available`| Ask an Owner to add usage credits or raise the spend limit in [**Organization settings > Usage**](<https://claude.ai/admin-settings/usage>). If you asked PR Steward to start, it then starts when you ask again. Otherwise, it starts at the next push
+`PR Steward hasn't started: billing for PR Steward isn't set up`| Ask an Owner to pick a repository where PR Steward is on and [change its **Steward** setting](</docs/en/pr-steward-setup#choose-when-pr-steward-starts-in-each-repository>) to another option than **Off**. They can change it back straight away
+`Claude PR Steward couldn't start, so it isn't watching this pull request`| Add the label or comment `@claude steward` to try again
+`Claude PR Steward couldn't start on this pull request because the setup script`| Ask someone who can edit the [environment that PR Steward runs in](</docs/en/pr-steward-setup#choose-the-environment-pr-steward-runs-in>) to fix its setup script, then start PR Steward again
+`this repository has PR Steward enabled in more than one Claude workspace`| Ask the Owners to keep the repository in one Claude organization and remove it from the others
+
+### Comments when PR Steward stops or pauses
+
+If PR Steward commented and then stopped or paused, find the comment’s opening words here:
+
+Comment says| What it means| What to do
+---|---|---
+`PR Steward is paused on this pull request`| Usage credits ran out while PR Steward was working, or billing setup is unfinished, as the comment says| Ask an Owner to add usage credits or raise the spend limit, or to finish billing setup as the comment describes. PR Steward picks up again at the next push or comment
+`Claude PR Steward stopped watching this pull request: this session's spend reached the repository's PR Steward budget`| This session reached the [spend cap](</docs/en/pr-steward-setup#set-pr-steward%E2%80%99s-spend-limits>) that’s set for the repository| Finish the remaining work yourself, or add the `claude-pr-steward-watching` label again to start a new session
+`Claude PR Steward stopped watching this pull request because your organization's PR Steward settings no longer cover it`| An Owner turned off PR Steward, or removed the repository or the author| After the settings cover the pull request again, add the label or comment `@claude steward`
+`Claude PR Steward stopped watching this pull request because for <N> days no person has commented or reviewed here`| No person has commented or reviewed, and nobody but PR Steward has pushed, for the number of days that the comment gives| Add the label or comment `@claude steward`
+
+## Auto-fix is unavailable
+
+In a repository where PR Steward works on your pull requests, the **Auto-fix** toggle on a cloud session is unavailable. If you ask to auto-fix a pull request that PR Steward is watching, the request fails. At claude.ai/code, the message is `PR Steward is already watching this PR.` To use [auto-fix](</docs/en/claude-code-on-the-web#auto-fix-pull-requests>) in that repository, turn PR Steward off for yourself:
+
+ * **Later pull requests** : set [your own PR Steward option](</docs/en/pr-steward-pull-requests#turn-off-or-limit-pr-steward-on-all-your-pull-requests>) to **Off** , which covers your pull requests in every repository
+ * **A pull request that PR Steward is already watching** : also [stop PR Steward there](</docs/en/pr-steward-pull-requests#start-or-stop-pr-steward-on-one-pull-request>)
+
+## Messages while you set up PR Steward
+
+While you [set up PR Steward](</docs/en/pr-steward-setup>), you can see these messages on the [**Claude Ship**](<https://claude.ai/admin-settings/claude-ship>) page:
+
+What you see| What to do
+---|---
+**The GitHub connector is not enabled for your organization.**| Turn on the connector at [**Organization settings > Connectors**](<https://claude.ai/admin-settings/connectors>)
+A repository is missing from the list of repositories when you click **Add**| Go to [**Organization settings > Git providers**](<https://claude.ai/admin-settings/source-control>), install the [Claude GitHub App](<https://github.com/apps/claude>) on your GitHub organization, and include the repository
+A message that says your GitHub account “cannot push to that repository”, or that adding it “needs write access”| Connect an account that can push, or ask an Owner who can push to do it
+`PR Steward can't be enabled right now: billing setup is temporarily unavailable`| Try again in a few minutes
+**PR Steward isn’t available for your organization.**| Check the [requirements](</docs/en/pr-steward#availability>). If [**Runs for**](</docs/en/pr-steward-setup#turn-on-pr-steward-and-add-repositories>) is **Listed users only** , add a username
+**PR Steward is on but not watching any repositories yet.**| [Turn on PR Steward for a repository](</docs/en/pr-steward-setup#turn-on-pr-steward-and-add-repositories>)
+
+## Related resources
+
+ * [Work with PR Steward on a pull request](</docs/en/pr-steward-pull-requests>)
+ * [Set up PR Steward](</docs/en/pr-steward-setup>)
+ * [PR Steward](</docs/en/pr-steward>)
--- a/prompt-caching.md
+++ b/prompt-caching.md
@@ -122,7 +122,7 @@
### Compacting the conversation
-[Compaction](</docs/en/context-window#what-survives-compaction>) replaces your message history with a summary. By design, this invalidates the conversation layer: the next request has a new, shorter history that doesn’t share a prefix with the old one.
+[Compaction](</docs/en/context-window#what-survives-compaction>) replaces your message history with a summary. This invalidates the conversation layer: the next request has a new, shorter history that doesn’t share a prefix with the old one.
* **System prompt** : when the conversation’s prompt is current, the next request reads this layer from the cache. If that prompt is out of date, such as after you resume the conversation, Claude Code switches to the current prompt and the next request rebuilds this layer’s cache once.
* **Project context** : Claude Code reloads this layer from disk. It’s cached together with the conversation, so after `/compact` or automatic compaction its cache is rebuilt even if its files are unchanged.
--- a/python.md
+++ b/python.md
@@ -2327,7 +2327,7 @@
"resolvedModel": str | None, # Model in use at the backgrounding transition
"modelsUsed": list[str] | None, # Models used before backgrounding, in order, with consecutive repeats collapsed
"prompt": str, # The prompt the agent runs
- "outputFile": str, # File path where the agent's output is written
+ "outputFile": str, # Path to the task output file
"canReadOutputFile": bool | None, # Whether the output file can be read directly
}
--- a/remote-control.md
+++ b/remote-control.md
@@ -3,7 +3,7 @@
* **Use your full local environment remotely** : your filesystem, [MCP servers](</docs/en/mcp>), tools, and project configuration all stay available, and typing `@` autocompletes file paths from your local project.
* **Work from both surfaces at once** : the conversation and the progress of [subagents](</docs/en/sub-agents>) and [dynamic workflows](</docs/en/workflows>) stay in sync across all connected devices, so you can send messages from your terminal, browser, and phone interchangeably.
* **Send images and files from your phone or browser** : attach a photo or file in the Claude app or at claude.ai/code, with or without a caption. Claude sees attached photos directly as part of your message. Claude Code downloads other files to your machine and passes them to Claude as `@` file references.
- * **Survive interruptions** : if your laptop sleeps or your network drops, Claude Code reconnects automatically when your machine comes back online.
+ * **Survive interruptions** : if your laptop sleeps or your network drops, Claude Code reconnects automatically when your machine comes back online, except in the cases under Limitations.
Unlike [cloud sessions](</docs/en/claude-code-on-the-web>), which run on cloud infrastructure, Remote Control sessions run directly on your machine and interact with your local filesystem. The web and mobile interfaces are a window into that local session, so your computer has to stay on and the `claude` process has to keep running.
@@ -132,7 +132,7 @@
A connected device shows the conversation in your terminal as it happens. These cases go beyond ordinary messages:
* **Compaction and`/clear`**: while Claude Code [compacts the conversation](</docs/en/context-window#what-survives-compaction>), connected devices show the progress and then where the conversation was compacted. When you run `/clear`, the conversation resets on connected devices too.
- * **Disconnecting after`/resume` or `/teleport`**: if the connected session has a [share link](</docs/en/claude-code-on-the-web#share-sessions>), or Claude Code can’t check for one, Remote Control disconnects when either command opens another conversation. People with the link would otherwise see that conversation. To connect the new conversation, run `/remote-control` in your terminal. The share link check requires Claude Code v2.1.324 or later.
+ * **Disconnecting after`/resume` or `/teleport`**: if the connected session has a [share link](</docs/en/share-sessions>), or Claude Code can’t check for one, Remote Control disconnects when either command opens another conversation. People with the link would otherwise see that conversation. To connect the new conversation, run `/remote-control` in your terminal. The share link check requires Claude Code v2.1.324 or later.
* **Switching conversations with`/resume`**: the connected device doesn’t receive the switched-to conversation’s title or earlier history, but new messages in both directions go to and from whichever conversation is open in your terminal. To work on the original conversation from the device again, run `/resume` in your terminal and switch back to it.
* **Pulling a session with`/teleport`**: when you pull a [cloud session](</docs/en/claude-code-on-the-web#from-cloud-to-terminal>) into your terminal with `/teleport`, the connected device doesn’t receive the pulled conversation’s earlier history. New messages in both directions go to and from the pulled conversation, which is now the one open in your terminal.
* **Messages from your other sessions** : with [cross-session messaging](</docs/en/cross-session-messaging>), the same connection carries messages between your own sessions on different machines.
@@ -291,11 +291,11 @@
* **One remote session per interactive process** : outside of server mode, each Claude Code instance supports one remote session at a time. Use server mode to run multiple concurrent sessions from a single process.
* **Local process must keep running** : Remote Control runs as a local process. If you close the terminal, quit the Desktop app or VS Code that runs the session on your machine, or otherwise stop the `claude` process, the session goes offline until you bring it back. If you run `claude` from a terminal on a remote machine, start it inside `tmux` or `screen` to keep the session running after you disconnect from SSH.
- * **Crashed sessions in server mode** : if a session served by `claude remote-control` crashes, send it a message from a connected device. Claude Code serves it again. You don’t have to restart the server. Requires Claude Code v2.1.238 or later.
+ * **Crashed sessions in server mode** : if a session served by `claude remote-control` crashes, send it a message from a connected device. Claude Code serves it again. Requires Claude Code v2.1.238 or later.
* **HTTP 403 refusals on a connected session** : once an interactive session is connected, Claude Code keeps retrying for up to three minutes when something between your machine and Anthropic’s servers answers with HTTP 403, as can happen after a VPN or network change. If the refusals last longer, Claude Code disconnects, and the reason names what refused: a network edge, or a proxy, VPN, or firewall on your own network.
* **Extended network outage** : if your machine is awake but can’t reach the network, what you do next depends on the mode:
* **Server mode** : Claude Code gives up after roughly 10 minutes and the `claude remote-control` process exits. To restart the server, see Resume sessions after stopping the server.
- * **Interactive session** : keep working locally. Claude Code retries for as long as the outage lasts and reconnects on its own when the network returns.
+ * **Interactive session** : keep working locally. Until your terminal shows a Remote Control failure, Claude Code keeps retrying and reconnects on its own when the network returns. If your terminal shows a failure, wait until the network is back, then follow the steps to reconnect after a failure.
* **Attachments that don’t download** : if a file you attach from your phone or browser can’t be downloaded to your machine, Claude still receives your message and the files that were downloaded. In place of the missing files, Claude Code adds a note such as `[1 of 3 attachments did not arrive]` to the message.
* **Presence heartbeats failing** : if an interactive session disconnects with `could not reach the Remote Control server for about 30 minutes`, run `/remote-control` to reconnect.
* **Forwarded dialogs expire** : Claude Code keeps permission prompts and `AskUserQuestion` questions open until you answer them. When Claude Code forwards another kind of dialog to the remote session, such as the model-choice prompt shown after a safety refusal, it waits five minutes by default, then closes the dialog and continues with the dialog’s no-action default. Set [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) to adjust or disable the deadline. Requires Claude Code v2.1.224 or later.
--- a/routines.md
+++ b/routines.md
@@ -81,13 +81,13 @@
Select repositories
-Expand **Advanced settings**. Under **Repository** on the **General** tab, select one or more GitHub repositories for Claude to work in.Each repository is cloned at the start of a run. Claude creates `claude/`-prefixed branches for its changes.
+In the **Repository** row below **Trigger** , select one or more GitHub repositories for Claude to work in. If the row isn’t there, expand **Advanced settings** and find **Repository** on the **General** tab.Each repository is cloned at the start of a run. Claude creates `claude/`-prefixed branches for its changes.
5
Select an environment
-After you select a repository, **Cloud environment** appears below it. Pick a [cloud environment](</docs/en/cloud-environments>) for the task. If an environment is already selected, you can keep it or select a different one. Environments control what the cloud session has access to:
+Find **Cloud environment** below **Trigger** , or under **Advanced settings > General** if it isn’t there, and pick a [cloud environment](</docs/en/cloud-environments>) for the task. If an environment is already selected, you can keep it or select a different one. Environments control what the cloud session has access to:
* **Network access** : set the level of internet access available during each run
* **Environment variables** : provide values Claude can use during each run. They’re [visible to anyone who uses the environment](</docs/en/cloud-environments#what-carries-over-from-your-setup>), so in an Anthropic-hosted environment, store keys for the APIs Claude calls during a run as [network secrets](</docs/en/cloud-environments#add-network-secrets>) instead. That section also lists the requests that never get a secret
@@ -105,7 +105,7 @@
Review connectors
-Switch to the **Connectors** tab of **Advanced settings**. All of your connected [MCP connectors](</docs/en/mcp>) are included by default. Remove any the task doesn’t need: Claude can use an included connector during a run, including writes. For when a run stops to ask you first, see Permission prompts during a run.
+Expand **Advanced settings** and open the **Connectors** tab. All of your connected [MCP connectors](</docs/en/mcp>) are included by default. Remove any the task doesn’t need: Claude can use an included connector during a run, including writes. For when a run stops to ask you first, see Permission prompts during a run.
8
@@ -375,7 +375,7 @@
Open the environment selector
-Go to **Advanced settings > General > Cloud environment**, expanding **Advanced settings** first if it’s collapsed. Click the cloud icon showing your environment’s name, such as **Default**.
+Find **Cloud environment** below **Trigger** , or under **Advanced settings > General** if it isn’t there. Click the cloud icon showing your environment’s name, such as **Default**.
3
@@ -413,7 +413,7 @@
## Where the name routines still appears
-Scheduled tasks were previously called routines, and these places keep the earlier name. Each one refers to the same feature:
+Scheduled tasks were previously called routines, and these places keep the earlier name:
* **App** : in some accounts the sidebar entry and page title read **Routines** , the button reads **New routine** , and other labels say routine. To create a task there, see Full-page form.
* **Web address** : `claude.ai/code/routines`
--- a/security-guidance.md
+++ b/security-guidance.md
@@ -13,11 +13,11 @@
/plugin install security-guidance@claude-plugins-official
-`/plugin` opens an interactive panel in the terminal CLI. If Claude replies that `/plugin` isn’t available in this environment, install another way:
+`/plugin` opens an interactive panel in the terminal CLI. Outside the terminal, install another way:
* **Claude desktop app, local or SSH session** : use the **Desktop app** tab under [Install a plugin](</docs/en/plugins/install#install-a-plugin>)
* **VS Code extension** : install from the [**Manage plugins** dialog](</docs/en/vs-code#manage-plugins>)
- * **Cloud sessions** : a cloud session doesn’t load plugins from your user settings or from the repository’s `.claude/settings.json`, as [What carries over from your setup](</docs/en/cloud-environments#what-carries-over-from-your-setup>) explains. For plugins your organization distributes through managed settings, see [Manage plugins for your organization](</docs/en/plugins/org>)
+ * **Cloud sessions** : a cloud session doesn’t load plugins from your user settings, as [What carries over from your setup](</docs/en/cloud-environments#what-carries-over-from-your-setup>) explains. For plugins your organization distributes through managed settings, see [Manage plugins for your organization](</docs/en/plugins/org>)
The terminal install prompts for a scope. Choose user scope to write the plugin to your user settings, so it loads in every new local session you start on this machine. If the install fails, match the message Claude Code reports:
--- a/self-hosted-environments-configuration.md
+++ b/self-hosted-environments-configuration.md
@@ -706,12 +706,16 @@
### How each session’s config is assembled
-The runner gives each session its own config directory, seeded from a snapshot of the host’s `~/.claude/` that the runner captures once at startup: `settings.json`, `CLAUDE.md`, hooks, agents, commands, and skills in your runner image apply to every session as the user-level baseline. If you change config on a running host, the change takes effect only after you restart the runner. Set `SELF_HOSTED_RUNNER_HOST_CONFIG_DIR` to seed from a different path, or point it at an empty directory to disable seeding. Sessions also read these settings files:
+A self-hosted runner gives each session its own config directory, seeded from a snapshot of the host’s `~/.claude/` that the runner captures once at startup. The `settings.json`, `CLAUDE.md`, hooks, agents, commands, and skills in your runner image apply to sessions as the user-level baseline. If you change config on a running host, the change takes effect only after you restart the runner. Set `SELF_HOSTED_RUNNER_HOST_CONFIG_DIR` to seed from a different path, or point it at an empty directory to disable seeding. Sessions also read these settings files:
* **Project settings** : outside a [project](</docs/en/claude-projects#what-threads-pick-up-from-your-repositories>) thread, a repository-committed `.claude/settings.json` layers on top of the user-level baseline. In a session with several repositories, at most one repository’s file takes effect.
* **Managed settings** : sessions read [`managed-settings.json`](</docs/en/settings#where-settings-live>) from the standard system path in your runner image. For whether its keys apply alongside [server-managed settings](</docs/en/server-managed-settings>), see [how Claude Code combines managed sources](</docs/en/managed-settings#how-claude-code-combines-managed-sources>).
-For the order these sources apply in, see [settings precedence](</docs/en/settings#settings-precedence>). When Anthropic’s control plane supplies a session with [Claude Code hooks](</docs/en/hooks>), the runner installs them alongside, not over, your own configuration. Requires Claude Code v2.1.229 or later; older runners ignore supplied hooks. The supplied hooks run `python3`, so install `python3` in your [runner image](</docs/en/self-hosted-environments-deploy#build-the-runner-image>).
+For the order these sources apply in, see [settings precedence](</docs/en/settings#settings-precedence>).
+
+In a [PR Steward](</docs/en/pr-steward-setup#choose-the-environment-pr-steward-runs-in>) session, Claude Code loads no `CLAUDE.md` or rules file from the runner. That covers your runner image and the repository’s checkout. PR Steward reads the repository’s instruction files [from its default branch](</docs/en/pr-steward-pull-requests#save-pr-steward-instructions-for-everyone-in-a-repository>), so put what it should follow there.
+
+When Anthropic’s control plane supplies a session with [Claude Code hooks](</docs/en/hooks>), the runner installs them alongside, not over, your own configuration. Requires Claude Code v2.1.229 or later; older runners ignore supplied hooks. The supplied hooks run `python3`, so install `python3` in your [runner image](</docs/en/self-hosted-environments-deploy#build-the-runner-image>).
* **Where they land** : the runner writes each supplied hook script to a reserved `hooks/.ccr-launcher/` subdirectory of the session’s config directory and registers the scripts in a separate settings file it passes to the session with `--settings`, leaving the seeded `settings.json` and your own scripts at `hooks/<name>` untouched. The runner recreates the reserved subdirectory for each session and doesn’t seed host content at `~/.claude/hooks/.ccr-launcher/` into sessions.
* **Who authors them** : the control plane populates the scripts from fixed constants in its own deployment, never from per-session or third-party input.
--- a/self-hosted-environments-quickstart.md
+++ b/self-hosted-environments-quickstart.md
@@ -79,7 +79,7 @@
claude self-hosted-runner --environment-secret-file '/etc/claude/environment-secret' --base-dir '<writable-dir>'
-The runner logs `Registered: runner_id=<runner-id>` once it has registered with your environment, then begins polling for work. Started with this command, it exits by design after serving one session, not after each turn. To serve more sessions, start the runner again each time it exits. See If the runner exits for when that happens and what the runner logs.
+The runner logs `Registered: runner_id=<runner-id>` once it has registered with your environment, then begins polling for work. Started with this command, it exits after serving one session, not after each turn. To serve more sessions, start the runner again each time it exits. See If the runner exits for when that happens and what the runner logs.
3
--- a/self-hosted-environments-reference.md
+++ b/self-hosted-environments-reference.md
@@ -1,6 +1,6 @@
Self-hosted environments are in public beta on Team and Enterprise plans; an [Owner](</docs/en/cloud-environments#organization-shared-environments>) enables them by turning on **Allow self-hosted environments** on the [**Cloud environments** admin page](<https://claude.ai/admin-settings/cloud-environments>). This page is the flag and metric reference; see the [quickstart](</docs/en/self-hosted-environments-quickstart>) for setup and [Deploy to production](</docs/en/self-hosted-environments-deploy>) for the fleet recipes.
-This page is the reference for the two processes you run in a [self-hosted environment](</docs/en/self-hosted-environments>): the runner, which executes Claude Code [cloud sessions](</docs/en/claude-code-on-the-web>) on your hosts, and the optional autoscaling orchestrator, which starts runners as sessions queue. Each has its own flag table. Both run on Linux or macOS hosts, which the defaults such as `/workspace` and `~/.claude` assume. Run `claude self-hosted-runner --help` for the authoritative list on your installed version. Metric series and a few API fields still use `pool` for what these pages call an environment; both terms name the same thing. The environment ID is the `pool_id` field, with the form `ccpool_...`: wherever these pages show a `pool` identifier, it names the environment. CLI flags and environment variables spell it `environment`, such as `--environment-secret-file`; the deprecated `pool` spellings still work, as the `--environment-secret-file` row describes.
+This page is the reference for the two processes you run in a [self-hosted environment](</docs/en/self-hosted-environments>): the runner, which executes Claude Code [cloud sessions](</docs/en/claude-code-on-the-web>) on your hosts, and the optional autoscaling orchestrator, which starts runners as sessions queue. Each has its own flag table. Both run on Linux or macOS hosts, which the defaults such as `/workspace` and `~/.claude` assume. Run `claude self-hosted-runner --help` for the authoritative list on your installed version. Metric series and a few API fields still use `pool` for what these pages call an environment. The environment ID is the `pool_id` field, with the form `ccpool_...`: wherever these pages show a `pool` identifier, it names the environment. CLI flags and environment variables spell it `environment`, such as `--environment-secret-file`; the deprecated `pool` spellings still work, as the `--environment-secret-file` row describes.
## Runner CLI flags
--- a/settings.md
+++ b/settings.md
@@ -111,9 +111,9 @@
### Change a setting for one session
-To try a value without saving it, set it when you start Claude Code. The value applies to that session and your settings files stay as they were. You have three ways to do it:
-
- * **`--settings`** : pass a key as JSON, inline or as a path to a file. Claude Code applies it above your user, project, and local files and below managed settings. It can set any key your user settings file can set; it can’t set `Managed` or `Global config` keys.
+To try a value without saving it, set it when you start Claude Code. You have three ways to do it:
+
+ * **`--settings`** : pass a key as JSON, inline or as a path to a file. Claude Code applies it above your user, project, and local files and below managed settings. With `--settings`, you can’t set [`Managed` or `Global config`](</docs/en/settings-reference#scopes>) keys or some user settings keys, such as [`prependPlugins`](</docs/en/settings-reference#prependplugins>).
* **A flag for that key** : some keys have their own flag, such as `--model` for `model` and `--effort` for `effortLevel` and `modelSettings`.
* **An environment variable** : export the key’s paired variable before you run `claude`, such as `ANTHROPIC_MODEL` for `model`.
@@ -247,7 +247,7 @@
* **Cloud threads in a project** : in a cloud thread in a [project](</docs/en/claude-projects#what-threads-pick-up-from-your-repositories>), none of a repository’s `.claude/settings.json` permission rules, hooks, or `env` apply, however many repositories the project has. [What threads pick up from your repositories](</docs/en/claude-projects#what-threads-pick-up-from-your-repositories>) lists what to use instead.
* **Shared project settings** (`.claude/settings.json`): read in a session with one repository outside a project’s threads, because the file is part of the clone and the session starts inside it. Commit a setting there to apply it in those sessions.
- * **Shared project settings with several repositories** : in an Anthropic-hosted environment, a session with several repositories starts above the clones and reads only the `enabledPlugins` and `extraKnownMarketplaces` keys from each repository’s `.claude/settings.json`, not permission rules, hooks, `env`, or other keys. The marketplaces and plugins those two keys declare still [don’t load in a cloud session](</docs/en/cloud-environments#what-carries-over-from-your-setup>). For a self-hosted environment, see [which repository’s settings apply](</docs/en/self-hosted-environments-configuration#repository-settings-in-sessions-with-several-repositories>).
+ * **Shared project settings with several repositories** : in an Anthropic-hosted environment, a session with several repositories starts above the clones and reads only the `enabledPlugins` and `extraKnownMarketplaces` keys from each repository’s `.claude/settings.json`, not permission rules, hooks, `env`, or other keys. The marketplaces a repository declares still [aren’t added in a cloud session](</docs/en/cloud-environments#what-carries-over-from-your-setup>). For a self-hosted environment, see [which repository’s settings apply](</docs/en/self-hosted-environments-configuration#repository-settings-in-sessions-with-several-repositories>).
* **User and project local settings** (`~/.claude/settings.json` and `.claude/settings.local.json`): not read. Both stay on your machine, and the local file isn’t in the clone.
* **Managed settings** : a `managed-settings.json` file or MDM profile on your device doesn’t reach a cloud session. Your organization’s [server-managed settings](</docs/en/server-managed-settings>) do; [surface coverage](</docs/en/model-config#surface-coverage>) lists which cloud sessions receive them. A [self-hosted environment](</docs/en/self-hosted-environments>) also reads the managed settings file in its runner image. [How Claude Code combines managed sources](</docs/en/managed-settings#how-claude-code-combines-managed-sources>) says when that file applies.
* **`/config`** : in your browser at claude.ai/code, opens your claude.ai **Code** or **Claude Code** settings page instead of changing a value. To change a setting for a cloud session, set an [environment variable](</docs/en/cloud-environments#set-environment-variables>) on the environment. In a session with one repository outside a project’s threads, you can instead commit the key to that repository’s `.claude/settings.json`.
--- a/settings-reference.md
+++ b/settings-reference.md
@@ -2753,7 +2753,7 @@
Label| Defaults to the matched text and is truncated to 28 display columns
Badge count| At most 5 badges render. The oldest is displaced by newer matches and `/clear` removes them
-When a turn completes, Claude Code matches each entry’s `pattern` regex against the turn output on the main thread, so a slow regex blocks the UI until it finishes. Nested quantifiers such as `(a+)+$` can take exponentially long against certain inputs and freeze the session, so keep each `pattern` linear and avoid nesting `+` or `*`. Footer badges render alongside a [custom status line](</docs/en/statusline>) when one is configured; neither replaces the other. Use a status line for a script-driven row that computes its own content from session data, and footer badges to turn IDs from the conversation into links without a script.
+When a turn completes, Claude Code matches each entry’s `pattern` regex against the turn output on the main thread, so a slow regex blocks the UI until it finishes. Nested quantifiers such as `(a+)+$` can take exponentially long against certain inputs and freeze the session, so keep each `pattern` linear and avoid nesting `+` or `*`. Footer badges render alongside a [custom status line](</docs/en/statusline>) when one is configured. Use a status line for a script-driven row that computes its own content from session data, and footer badges to turn IDs from the conversation into links without a script.
### `keybindingFlavor`
@@ -4251,7 +4251,7 @@
### `allowedMcpServers`
-Allowlist the MCP servers people can add. Claude Code blocks any server that doesn’t match an entry wherever it’s defined, including plugin servers, servers a user passes with `--mcp-config`, and servers from claude.ai. Built-in servers such as Claude in Chrome, the `ide` server Claude Code connects to in a running [VS Code](</docs/en/vs-code#the-built-in-ide-mcp-server>) or [JetBrains](</docs/en/jetbrains#the-built-in-ide-mcp-server>) IDE, and servers the CLI itself configures are exempt from the allowlist, and the denylist still applies to them. On Claude Code v2.1.268 or later, a [Claude Tag](</docs/en/claude-tag>) session’s Slack tools are also exempt from the allowlist, and the denylist still applies to them. In-process `type: "sdk"` servers are exempt from both lists; the [app that started the session](</docs/en/mcp#how-connectors-reach-claude-code>) registers them. Servers your organization delivers are also exempt from the allowlist, and the denylist still applies to them. The exemption covers every `managedMcpServers` entry, and any [`managed-mcp.json`](</docs/en/managed-mcp#exclusive-control-with-managed-mcp-json>) entry whose values use [no `${VAR}` expansion outside `env`](</docs/en/managed-mcp#how-allowlists-and-denylists-apply-to-the-managed-set>). See [How a server is evaluated](</docs/en/managed-mcp#how-a-server-is-evaluated>) for the full check order. Before v2.1.259, servers from `managed-mcp.json` had to match too.
+Allowlist the MCP servers people can add. Claude Code blocks any server that doesn’t match an entry wherever it’s defined, including plugin servers, servers a user passes with `--mcp-config`, and servers from claude.ai. [Some servers skip the allowlist](</docs/en/managed-mcp#servers-that-skip-the-allowlist-check>), such as `managedMcpServers` entries. A [Claude Tag](</docs/en/claude-tag>) session’s Slack tools skip it on v2.1.268 or later. Denylist entries in managed or user settings still apply to these servers. In-process `type: "sdk"` servers are exempt from both lists.
* **Scope** : `Any file`. For servers users add, entries from every file merge into one allowlist unless `allowManagedMcpServersOnly` is set. To keep users from adding entries, deploy both keys in managed settings.
* **Type** : array of objects, each with exactly one key. Use `serverName`, a string limited to letters, numbers, hyphens, and underscores; `serverCommand`, an array of the command and its arguments matched exactly; or `serverUrl`, a URL pattern with `*` wildcards
--- a/setup.md
+++ b/setup.md
@@ -121,9 +121,28 @@
### Auto-updates
-Claude Code checks for updates on startup and periodically while running. Updates download and install in the background, then take effect the next time you start Claude Code. Run `claude doctor` in your shell to see the result of the last update attempt Claude Code recorded. On a native installation, if it reports a failed attempt, see [`Auto-update failed` in the session footer](</docs/en/troubleshoot-install#auto-update-failed>) for what to do next. On macOS and Linux, the native installer manages the launcher at `~/.local/bin/claude` as a symlink into `~/.local/share/claude/versions/`. If you replace that launcher with your own script or symlink, auto-update and `claude update` leave it in place: new versions still install under the `versions/` directory, and your launcher decides which version runs. With a custom launcher, Claude Code also keeps every installed version on disk because it can’t tell which version the launcher needs. `claude doctor` reports a launcher that the native installer didn’t create. To let Claude Code manage the launcher again, remove `~/.local/bin/claude` and run `claude update`. If an npm global install can’t auto-update because the npm global directory isn’t writable, Claude Code shows a one-time notice at startup, and `claude doctor` lists the available fixes. See [permission errors during installation](</docs/en/troubleshoot-install#permission-errors-during-installation>) for details.
+Claude Code checks for updates on startup and periodically while running. Updates download and install in the background, then take effect the next time you start Claude Code. Run `claude doctor` in your shell to see the result of the last update attempt Claude Code recorded. On a native installation, if it reports a failed attempt, see [`Auto-update failed` in the session footer](</docs/en/troubleshoot-install#auto-update-failed>) for what to do next. If an npm global install can’t auto-update because the npm global directory isn’t writable, Claude Code shows a one-time notice at startup, and `claude doctor` lists the available fixes. See [permission errors during installation](</docs/en/troubleshoot-install#permission-errors-during-installation>) for details.
Homebrew, WinGet, apt, dnf, and apk installations do not auto-update by default; see below to opt in for Homebrew and WinGet. To upgrade Homebrew manually, run `brew upgrade claude-code` or `brew upgrade claude-code@latest`, depending on which cask you installed. For WinGet, run `winget upgrade Anthropic.ClaudeCode`. For Linux package managers, see the upgrade commands in Install with Linux package managers.To have Claude Code run the upgrade command for you on Homebrew or WinGet, set [`CLAUDE_CODE_PACKAGE_MANAGER_AUTO_UPDATE`](</docs/en/env-vars>) to `1`. Claude Code then runs the upgrade in the background when a new version is available and shows a restart prompt on success. The upgrade targets only the Claude Code package and does not affect other software you have installed.On WinGet the upgrade may fail while Claude Code is running because Windows locks the executable. In that case Claude Code shows the manual command instead. apt, dnf, and apk continue to require a manual upgrade because those commands need elevated privileges.**Known issue:** Claude Code may notify you of updates before the new version is available in these package managers. If an upgrade fails, wait and try again later.Homebrew keeps old versions on disk after upgrades. Run `brew cleanup` periodically to reclaim disk space.
+
+#### Custom launchers
+
+On macOS and Linux, the native installer manages the launcher at `~/.local/bin/claude` as a symlink into `~/.local/share/claude/versions/`. If you replace it with your own script, your script stays in place through auto-update and `claude update`. New versions still install under `versions/`, but you keep running whichever version your launcher starts. With a custom launcher, Claude Code also keeps every installed version on disk because it can’t tell which version the launcher needs. `claude doctor` reports that the launcher `was not created by the native installer`.
+
+#### Restore the managed launcher
+
+To let Claude Code manage `~/.local/bin/claude` again, replace your custom launcher with a symlink to an installed version:
+
+ 1. If you want to keep your launcher, copy `~/.local/bin/claude` to another folder. Step 3 overwrites it.
+ 2. In your shell, list the installed versions:
+
+ ls ~/.local/share/claude/versions/
+
+ 3. Create the symlink. For `VERSION`, use a version number from the list.
+
+ ln -sfn ~/.local/share/claude/versions/VERSION ~/.local/bin/claude
+
+ 4. Run `claude doctor` and check that the launcher warning is gone.
### Configure release channel
--- a/share-sessions.md
+++ b/share-sessions.md
@@ -0,0 +1,97 @@
+You can share a [cloud session](</docs/en/claude-code-on-the-web>) or a [Remote Control](</docs/en/remote-control>) session with a link so that other people can read the conversation.
+
+To share a claude.ai chat, see [Share and unshare chats](<https://support.claude.com/en/articles/10593882-share-and-unshare-chats>).
+
+## What recipients see
+
+When you share a cloud or Remote Control session, recipients see the conversation so far, with Claude’s tool calls and their results, including content such as:
+
+ * **Messages** : your prompts, images you added, the names of files you attached, and Claude’s replies and thinking
+ * **Code and commands** : file contents that Claude read, wrote, or edited, and commands that you or Claude ran, with their output
+ * **Credentials** : keys or tokens that appear in a message, a file, or command output
+ * **Other repositories** : results of Claude’s GitHub searches, which can include private repositories that recipients can’t open
+ * **Connector results** : what a [connector](</docs/en/mcp#use-mcp-servers-from-claude-ai>) returned, such as emails, documents, and Slack messages
+ * **Web content** : pages that Claude read and screenshots it took
+ * **Your setup** : names of connectors Claude used, and names and descriptions of any connectors, [skills](</docs/en/skills>), and [plugins](</docs/en/plugins/overview>) it looked up
+
+Your display name appears on the shared session. On a Max, Ultra, or Pro plan, you can hide it. A recipient’s view doesn’t update in real time. When they reload the page or open the link again, they see messages added to the session after you shared, until you stop sharing.
+
+### What recipients see in a Remote Control session
+
+When you share a Remote Control session, recipients can also see:
+
+ * The contents of files Claude read on your computer during the session, including files outside the folder you started the session in
+ * Text and screenshots of pages Claude opened during the session through the [Claude in Chrome extension](</docs/en/chrome>), including sites where you’re signed in
+
+## Share a session
+
+Check the session first. Then select **Share** at the top of the session, choose **Team** or **Public** , whichever your plan offers, select **Copy link** , and send the link.
+
+### Check a session before you share
+
+Read the conversation, expand the tool calls, and look for the content listed in What recipients see. If the conversation holds something recipients shouldn’t see, keep the session **Private**. The server blocks sharing in some cases, but a session it lets you share can hold sensitive content.
+
+### Share from an Enterprise or Team account
+
+On Enterprise and Team plans, other members of your claude.ai organization may be able to open a session you share:
+
+ * **Visibility options** : **Private** and **Team**
+ * **Repository access** : to open a cloud session you shared, recipients need access to each of its private repositories through their [connected GitHub account](</docs/en/web-quickstart#connect-github>). Members without repository access may be able to open a Remote Control session’s link.
+
+### Share from a Max, Ultra, or Pro account
+
+On Max, Ultra, and Pro plans, anyone who has the link and is signed in to claude.ai may be able to open a session you share:
+
+ * **Visibility options** : **Private** and **Public**
+ * **Repository access** : **Require repository access** is off by default. Turn it on to limit the cloud sessions you share to recipients with access to each session’s private repositories. People without repository access may be able to open a Remote Control session’s link.
+
+To turn on **Require repository access** or turn off **Show your name** , open Settings on claude.ai, then:
+
+ * **If the Settings menu shows Code instead of Claude Code** : go to [**Privacy**](<https://claude.ai/settings/data-privacy-controls>)
+ * **Otherwise** : go to [**Claude Code > Sharing settings**](<https://claude.ai/settings/claude-code>)
+
+## Stop sharing a session
+
+To stop sharing a session you shared, set its visibility back to **Private**. Do this before you move on from a session or an organization, because the link keeps working after you:
+
+ * Archive the session
+ * Turn off Remote Control or close your terminal
+ * Leave or are removed from the organization, for a link you shared as **Team**
+
+For what ends a link without you setting it to **Private** , see Links that stop opening.
+
+## Troubleshoot sharing
+
+You can’t share a session when your organization has turned sharing off or the server refuses that session. A link can also stop opening after you share it.
+
+### Sharing is turned off for your organization
+
+If **Share** is dimmed with “Sharing is disabled by your organization.”, ask an [Owner](</docs/en/server-managed-settings#access-control>) to turn on **Share cloud sessions** in [**Organization settings > Data and privacy**](<https://claude.ai/admin-settings/data-privacy-controls>). You need this setting on to share Remote Control sessions too. Under some compliance configurations, you can’t share sessions even with the setting on.
+
+### Sessions you can’t share
+
+You can’t share some sessions because they may hold content that recipients shouldn’t see. If sharing fails with a message such as “This session can’t be shared.”, trying again doesn’t help. For example, on Enterprise and Team plans, you can’t share a cloud session that uses [uploaded code](</docs/en/claude-code-on-the-web#send-local-repositories-without-github>), because there’s no way to check who’s allowed to see that code. To share work on that code, start a new session whose repository is on github.com and wasn’t uploaded.
+
+### Links that stop opening
+
+If recipients can’t open a link, check for these causes:
+
+ * **Visibility** : the session is **Private** , or the recipient isn’t signed in to claude.ai or is outside your organization on a **Team** link. Check who can open the link.
+ * **Free plan** : the recipient is signed in on a Free account and lands on the upgrade page. Ask them to sign in with an account that has [cloud sessions](</docs/en/claude-code-on-the-web>).
+ * **Repository access** : the link requires repository access, and the recipient’s GitHub account can’t read the repository. Ask them to [connect an account](</docs/en/web-quickstart#connect-github>) that can.
+ * **Uploaded or non-GitHub code** : the link requires repository access, and the code was [uploaded](</docs/en/claude-code-on-the-web#send-local-repositories-without-github>) or is on a Git host such as GitLab or Bitbucket. Share from a session whose repository is on github.com and wasn’t uploaded.
+ * **Invalid link** : the share link may not match the address in your browser, and a **Public** link changes when you stop sharing and share again. Copy the current link from **Share** and send it.
+ * **Organization setting** : **Share cloud sessions** is off for the organization. Ask an Owner to turn it back on.
+ * **Upgraded plan** : you shared a **Public** link, then upgraded your plan to Team or Enterprise. The link follows the rules for Enterprise and Team accounts.
+
+You can’t restore the link in these cases:
+
+ * The session was deleted
+ * The session became one you can’t share
+ * You shared a **Public** link, then [moved your personal account](<https://support.claude.com/en/articles/9267400-move-your-personal-claude-account-to-a-team-or-enterprise-organization>) into an existing organization
+ * Anthropic turned off the link, for example after an abuse or copyright review. The session shows as **Private** , and sharing it again fails with “Couldn’t share this session. Try again.”
+
+## Related resources
+
+ * [Use Claude Code in the cloud](</docs/en/claude-code-on-the-web>): archive, delete, and move cloud sessions
+ * [Remote Control](</docs/en/remote-control>): continue a local session from another device
Show diff (222 lines)
--- a/ship-command.md
+++ b/ship-command.md
@@ -0,0 +1,219 @@
+`/ship` is a Claude Code command that opens a GitHub pull request for your change if your branch doesn’t have one. Claude reviews your change and works on feedback and failing checks to help get it ready to merge. If your pull request is already open and you don’t want a review, type `/steward`. It skips the review, and Claude does the same work on feedback and failing checks.
+
+Run either command from the Claude Code CLI in a terminal, in your local clone of the repository. Cloud sessions don’t have them.
+
+After you type `/ship`, your change goes through these steps:
+
+ 1. **Pull request** : `/ship` can commit your work, push your branch, and open the pull request as you
+ 2. **Review** : Claude reviews your change with [`/code-review`](</docs/en/code-review-local>)
+ 3. **Watch** : Claude keeps checking the pull request from your Claude Code session. It works on failing checks, merge conflicts, reviewers’ comments, and the findings from its review, and pushes fixes. This ongoing work is called a watch
+ 4. **Merge** : once the pull request is ready, merge it yourself
+
+`/steward` skips steps 1 and 2 and starts the watch.
+
+## When to use /ship and /steward
+
+With either command, Claude works on your pull request’s feedback and failing checks. Choose between `/ship` and `/steward` by where your change is:
+
+ * **`/ship`** : your change is finished, and you want Claude to review it and then work on the feedback and failing checks that follow
+ * **`/steward`** : your pull request is already open and you don’t want a review first, or a watch ended and you want to start it again
+
+Both commands run in your session, so their work counts against your usage. If you want something else, such as a review alone or fixes from a cloud session, use one of these:
+
+You want| Use
+---|---
+A review alone| [`/code-review`](</docs/en/code-review-local>)
+Fixes as feedback arrives, from a cloud session| [Auto-fix](</docs/en/claude-code-on-the-web#auto-fix-pull-requests>) or `/autofix-pr`
+Agents for whole repositories, billed to an organization| [Claude Ship](</docs/en/claude-ship>)
+
+## Prerequisites for /ship and /steward
+
+Install or update these tools:
+
+ * Claude Code v2.1.330 or later. If `/ship` is missing, see [/ship isn’t available in your session](</docs/en/ship-command-troubleshooting#%2Fship-isn%E2%80%99t-available-in-your-session>)
+ * The [GitHub CLI](<https://cli.github.com>) 2.63 or later, signed in with `gh auth login`. With an older version, Claude can’t push fixes
+ * git 2.38 or later, to merge new commits into your branch. With an older git, Claude leaves those merges to you
+
+Then get your change and your session ready:
+
+ * **A finished change, for`/ship`**: have it in your local clone of a repository on GitHub. It can be uncommitted, committed on a branch other than the default branch, or already in an open pull request of yours. If the repository is hosted somewhere other than GitHub, `/ship` opens no pull request, and Claude reviews your change
+ * **Only the files that you want in the pull request, for`/ship`**: `/ship` can commit all your uncommitted changes, new files included. In your shell, run `git status`. Delete each new file that you don’t want in the pull request, or stash the file with `git stash push -u -- <file>`
+ * **No secrets in those files, for`/ship`**: `/ship` looks for secrets by file name, such as `.env`, so look inside your files yourself. A deny rule such as `Read(./notes.txt)` doesn’t keep a file out of the commit
+ * **An open pull request on GitHub, for`/steward`**: it has to be your own, with its branch checked out in your local clone
+ * **Permission mode** : choose [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) if you want Claude to work on the pull request unattended. In most other permission modes, Claude waits at each prompt. In `bypassPermissions` mode, no watch starts
+
+On native Windows, [no watch starts](</docs/en/ship-command-troubleshooting#cases-where-no-watch-can-start>).
+
+Run a watch only where you trust everyone who can merge to the base branch or push to your branch. Any of them can run programs on your computer with your credentials.
+
+## Run /ship or /steward
+
+In a terminal, open Claude Code in your clone, then type `/ship` or `/steward` at the prompt. Both take arguments, such as a pull request’s number.
+
+### Run /ship on a finished change
+
+If you made the change with Claude, use that same session, because Claude writes the commit message from the session’s conversation. Anyone who can see the pull request can read that message.
+
+`/ship` proceeds with no confirmation prompt. After you press Enter, it can commit your work, push your branch, and open the pull request as you. Before the commit, and again before the push, a line that ends `Esc to cancel` says what’s about to happen. If you do nothing, `/ship` continues after a few seconds.
+
+If you cancel before the push, a commit that `/ship` made stays. To undo it and keep your files, run `git reset HEAD~1` in your shell.
+
+### What /ship commits and pushes
+
+In a repository on github.com that isn’t a fork, `/ship` can commit your uncommitted changes, push the branch, and open the pull request before the review. On the default branch, it commits on a new branch and switches your checkout to that branch. If your work is already committed on another branch, `/ship` pushes that branch and opens the pull request. `/ship` doesn’t commit your uncommitted changes in these cases. Take the first one that fits:
+
+ * **A pull request is already open for the branch** : commit and push anything that you want in the pull request
+ * **The repository is public** : if you’re on a branch other than the default branch and it has commits of its own, `/ship` pushes those and opens a pull request without your uncommitted changes. Otherwise, commit your work on a branch other than the default branch, then run `/ship` again
+ * **An uncommitted file’s name suggests a secret, such as`.env`**: in a repository that isn’t public, `/ship` doesn’t commit or push anything. See [/ship committed or pushed nothing](</docs/en/ship-command-troubleshooting#%2Fship-committed-or-pushed-nothing>)
+
+Open the pull request yourself, then run `/ship`, if you want any of these:
+
+ * A draft pull request
+ * Another base branch
+ * Your repository’s pull request template
+ * A pull request on [GitHub Enterprise or from a fork](</docs/en/ship-command-troubleshooting#github-enterprise-and-forks>)
+
+If `/ship` commits or pushes nothing and these cases don’t say why, see [/ship committed or pushed nothing](</docs/en/ship-command-troubleshooting#%2Fship-committed-or-pushed-nothing>).
+
+### Start a watch with /steward
+
+To start a watch with no review first, type `/steward` at the Claude Code prompt. Use it on your own open pull request, or to start again after a watch ends. Before you leave a watch alone, see Code that a watch runs on your computer. `/steward` is separate from [PR Steward](</docs/en/pr-steward>), the agent that an organization sets up. Where PR Steward is already working on your pull request, no watch starts.
+
+## What Claude does during a watch
+
+A watch is Claude’s ongoing work on your pull request, which starts after `/ship`’s review or when you type `/steward`. Claude uses your `gh` and `git` sign-ins, so its work on GitHub appears under your name. In auto mode, Claude takes these actions without asking:
+
+ * Works on the review findings that it judges to be problems
+ * Can post one comment that sums up its review
+ * Pushes commits to your branch
+ * Merges the base branch into yours, to resolve conflicts or bring your branch up to date
+ * Works on failing checks, and re-runs failed ones
+ * Answers review comments, resolves threads, and re-requests reviews
+
+Claude reads comments from you and from people with write access. On github.com, it also reads comments from Claude’s bot. To have Claude read another bot’s comments, type `/steward +` and the bot’s name, as in `/steward +my-lint-bot`. When checks pass and comments are answered, Claude says so in the session. Merge the pull request yourself. What can merge depends on your permissions and your repository’s branch rules. See When a watch can lead to a merge.
+
+### Keep working while a watch runs
+
+While a watch runs, keep the session open and [in the foreground](</docs/en/agent-view#send-the-session-to-the-background>), the computer awake, and your pull request’s branch checked out. Claude edits files in the same checkout as you.
+
+ * **To start your next change** : work in another folder, such as a second clone of the repository, and open another Claude Code session there
+ * **To push your own commits** : name the remote and branch, as in `git push origin <branch>`. If you change git’s settings, for example with `git push -u` or `git branch -u`, the watch ends
+ * **Commits that you haven’t pushed** : they can go up with Claude’s next push
+ * **Your uncommitted work** : Claude can edit a file that you’re working on, and can commit it. When Claude acts without a message from you, Claude Code refuses these commands from Claude: `git stash`, `git reset`, `git checkout`, `git add -A`, and `git commit -a`
+
+### Ask Claude to check with you first
+
+To see `/ship`’s review findings or a reviewer’s comment before Claude acts on them, say so in a message at the Claude Code prompt. To see the findings before Claude fixes anything, send the message while the review is running. This example asks Claude to show you its findings, and to ask before it pushes or replies:
+
+ From now on, don't push code changes or reply to reviewers without asking me first. Show me the review findings and wait.
+
+That message is a request to Claude, and Claude Code doesn’t enforce it.
+
+### Save instructions for watches in a repository
+
+To tell Claude how to look after pull requests in a repository, save a file at `.claude/skills/steward/SKILL.md` in the repository’s top folder. [PR Steward reads the same file](</docs/en/pr-steward-pull-requests#save-pr-steward-instructions-for-everyone-in-a-repository>), so one file can serve both, and that section has an example. During a watch, Claude reads the copy in your checkout and follows it as instructions, for example on which checks matter and how to run the tests, within these limits:
+
+ * **Installs and downloads** : Claude can skip a line that installs or downloads something, such as the `npm install` line in that example
+ * **Blocked commands** : the file doesn’t change what Claude Code blocks during a watch
+ * **Changes to the file** : if you add or edit it yourself while a watch runs, the watch ends. For whose other changes can reach it, see Code that a watch runs on your computer
+
+## Check, stop, or restart a watch
+
+A watch is Claude’s ongoing work on your pull request, which starts after `/ship`’s review or when you type `/steward`. It runs in your session, so you check it and stop it at the Claude Code prompt.
+
+### Check whether a watch is running
+
+Type `/tasks` at the Claude Code prompt. Once the review is done and while Claude isn’t working, a running watch appears in the list as a scheduled task whose name starts with `/steward --tend`.
+
+### What ends a watch
+
+After a watch ends, look for a line that starts `Stopped watching pull request`. [A watch stopped](</docs/en/ship-command-troubleshooting#a-watch-stopped>) lists reasons that it gives. The watch ends in cases such as these:
+
+Where| What ends the watch
+---|---
+On the pull request| It’s merged or closed, [PR Steward](</docs/en/pr-steward>) labels it, or seven days pass
+At the keyboard| You press `Esc` or `Ctrl+C` at the prompt or while Claude is working. One press can end the watch, with no confirmation
+In your checkout| You check out another branch, or change git’s settings
+In the session| The session ends, you send it to the background, you start another watch or a `/loop` with a task, or you run `/clear`, `/resume`, or `/branch`
+After a failure| An error, a declined prompt, or a usage limit can end it early
+
+### Stop or restart a watch
+
+To end a watch, type `/ship stop` at the Claude Code prompt in the session that runs it. If Claude is working when you type it, the watch ends when the current turn does, so what Claude pushes or posts in that turn still reaches the pull request. To stop the turn as well, press `Esc`. To start a watch again, type `/steward`.
+
+## Decide where to run a watch
+
+A watch is Claude’s ongoing work on your pull request, which starts after `/ship`’s review or when you type `/steward`. Claude works with your `gh` and `git` sign-ins. Before you leave a watch alone, check what Claude Code blocks, which code can run on your computer, and what can still lead to a merge.
+
+### What Claude Code blocks during a watch
+
+When Claude acts without a message from you, Claude Code blocks `gh` and `git` commands that merge the pull request, approve it, turn on auto-merge, or force-push. At those times, Claude Code also limits Claude’s `gh` and `git` commands to a short list, and refuses tools that the watch doesn’t need, such as connectors, `WebFetch`, and `WebSearch`. To see these limits in Claude Code, type `/ship terms` at the prompt.
+
+The limits on a watch don’t cover everything. The watch uses your `gh` and `git` sign-ins, so it could merge a pull request that your repository’s branch rules let you merge without another person’s approval. See When a watch can lead to a merge. A setting in your session, such as a permission rule or a hook, can [let commands past the limits](</docs/en/ship-command-troubleshooting#messages-during-a-watch>).
+
+### Code that a watch runs on your computer
+
+Code from each of these sources can run on your computer during a watch, with your credentials:
+
+Source| What happens
+---|---
+The base branch| To resolve conflicts or bring your branch up to date, Claude merges the base branch into yours, including scripts that run by themselves
+Other people’s pushes to your branch| Claude is instructed to merge them in
+Programs from your branch, such as your tests| Claude runs them. They can merge or force-push with your credentials. Claude Code checks only the command that starts them, under the session’s permission mode
+Your Claude Code hooks| They run without asking, and may run a file that Claude has edited
+[`.claude/skills/steward/SKILL.md`](</docs/en/pr-steward-pull-requests#save-pr-steward-instructions-for-everyone-in-a-repository>)| Claude follows it if your checkout has one. Anyone who can merge to the repository can write that file
+
+If Claude Code sees that a merge of the base branch or of other people’s pushes would change its settings, `.mcp.json`, or git’s config files, Claude leaves that merge to you.
+
+### When a watch can lead to a merge
+
+Cases such as these can lead to a merge:
+
+Case| What happens
+---|---
+Auto-merge is on for the pull request| GitHub merges once the checks and reviews allow. What Claude does during the watch, such as pushing a fix, can bring that about. To turn it off, run `gh pr merge --disable-auto <number>` in your shell
+In a terminal session, you type a message while Claude is idle| Claude Code’s limits are off while Claude answers your message. They’re also off while Claude handles a background task’s result that arrives during that time. In auto mode, Claude may then be allowed to merge
+You send a session that you started in your terminal to the background during the review or the watch, for example by pressing `←`| The watch ends. Work under way can go on there without these limits. To end that work, [stop that session](</docs/en/agent-view#manage-sessions-from-the-shell>)
+
+### Permission rules and hooks that apply to /ship and /steward
+
+Claude Code runs `/ship`’s own commit, push, and pull request commands itself, [outside the sandbox](</docs/en/sandboxing#what-runs-outside-the-sandbox>). During a watch, when Claude acts without a message from you, it writes its git fetches, merges, commits, and pushes in the form `git -c core.hooksPath=/dev/null push`. Rules and hooks apply this way, whether they’re in your own settings or in managed settings:
+
+Setting| For `/ship`’s own commit and push| During a watch
+---|---|---
+A [deny rule](</docs/en/permissions#manage-permissions>) such as `Bash(git push *)`| `/ship` leaves those steps to you| No watch starts
+A rule that asks on `Bash(git push *)`| Claude Code doesn’t consult it| It [doesn’t match](</docs/en/permissions#bash-rule-limits>) that form, so it adds no prompt
+A rule that asks on `Bash(git *)`| Claude Code doesn’t consult it| It matches, and the watch waits at each prompt, including in auto mode
+Auto mode’s check, and tool hooks such as `PreToolUse`| They don’t run| They don’t apply to the `gh` and `git` commands that Claude Code runs itself, outside the sandbox, for example to read the pull request
+Git hooks in the repository’s hooks folder| They run| They don’t run for Claude’s fetches, merges, commits, and pushes on those turns
+
+## Turn off /ship and /steward for your organization
+
+To turn off both commands, set these keys under [`skillOverrides`](</docs/en/skills#override-skill-visibility-from-settings>) in [managed settings](</docs/en/managed-settings>). `ship-local` is the skill behind `/ship`. This example turns off both:
+
+ {
+ "skillOverrides": {
+ "ship-local": "off",
+ "steward": "off"
+ }
+ }
+
+To stop `/ship`’s own pushes, put a [deny rule](</docs/en/permissions#manage-permissions>) such as `Bash(git push *)` in managed settings. With that rule, no watch starts.
+
+## Arguments for /ship and /steward
+
+Type an argument after `/ship` or `/steward` at the Claude Code prompt. To combine arguments, put the effort level first, as in `/ship low 41 +my-lint-bot`.
+
+You type| Commands| What it does
+---|---|---
+`low`, `medium`, `high`, `xhigh`, or `max`| `/ship`| Asks for a review at that effort level. The default is `high`
+`41`, or a pull request’s URL| `/ship`, `/steward`| Works on that pull request. For a watch, it has to be your own, with its branch checked out
+`+botname`| `/ship`, `/steward`| Also reads that bot’s comments. Repeat it when you start a watch again
+`stop`| `/ship`, `/steward`| Ends the watch
+`terms`| `/ship`, `/steward`| Shows what Claude may do during a watch and what limits it
+
+## Related resources
+
+ * [Troubleshoot `/ship` and `/steward`](</docs/en/ship-command-troubleshooting>): messages that the commands print, and what to do
+ * [Review code locally](</docs/en/code-review-local>): the review that `/ship` runs
+ * [Permission modes](</docs/en/permission-modes>): auto mode and the other permission modes
Show diff (191 lines)
--- a/ship-command-troubleshooting.md
+++ b/ship-command-troubleshooting.md
@@ -0,0 +1,188 @@
+[`/ship`](</docs/en/ship-command>) is a Claude Code command that opens a GitHub pull request for your change and has Claude review it. Claude then keeps working on the pull request from your session. This ongoing work is called a watch. `/steward` starts a watch on a pull request that’s already open. Find what happened in the first column, or search for words from the message that Claude Code printed:
+
+What happened| Go to
+---|---
+`/ship` isn’t in the `/` menu, or Claude Code doesn’t recognize it| /ship isn’t available in your session
+You typed the command and it printed a message without starting| /ship or /steward printed a message and didn’t start
+It ran, and nothing was committed or pushed| /ship committed or pushed nothing
+The pull request is open, and Claude isn’t following up on it| No watch started
+Claude was following up, and stopped| A watch stopped
+A message appeared while Claude was following up| Messages during a watch
+The pull request isn’t what you expected| Pull request results that you didn’t expect
+A custom `/ship` or `/steward` command stopped working| A custom /ship or /steward command stopped loading
+
+## /ship or /steward is missing or doesn’t start
+
+Start here when the command isn’t offered, or when it prints a message.
+
+### /ship isn’t available in your session
+
+`/ship` is missing from the `/` menu, typing it starts `/code-review`, or you see `Unknown command: /ship`. Cloud sessions don’t have `/ship`. On your own machine, take these steps:
+
+ 1. Run `claude update` in your shell, then quit and start `claude` again.
+ 2. If `/ship` is still missing, quit and start `claude` once more, because a new feature [can take a second start](</docs/en/env-vars#first-session-after-an-install-or-upgrade>) to show.
+ 3. Run `/status` at the Claude Code prompt. Its `Setting sources` line lists the settings that loaded. In each one that’s your own [settings file](</docs/en/settings#find-or-create-your-settings-files>), remove [`disableBundledSkills`](</docs/en/settings-reference#disablebundledskills>) and any `ship-local` entry under [`skillOverrides`](</docs/en/skills#override-skill-visibility-from-settings>). To change managed settings, ask your administrator.
+ 4. Check whether your session [skips feature-flag fetching](</docs/en/env-vars#features-that-need-feature-flag-fetching>), for example because `DISABLE_TELEMETRY` is set or you use a third-party provider. `/ship` isn’t available in those sessions.
+
+### A skillOverrides entry turns off /ship or /steward
+
+`Skill "ship-local" is disabled via skillOverrides`, or the same message for `steward`, means that a [`skillOverrides`](</docs/en/skills#override-skill-visibility-from-settings>) entry in your settings turns off the command. Remove the entry. To change an entry in managed settings, ask your administrator.
+
+### /ship or /steward printed a message and didn’t start
+
+Find the opening words of the message:
+
+Message| What to do
+---|---
+`This session was started by another session`| Run it in a session that you started yourself
+`Usage: /ship` or `Usage: /steward`| Check what you typed against [the arguments](</docs/en/ship-command#arguments-for-%2Fship-and-%2Fsteward>)
+`Nothing started. /ship starts only from a line that you type`, or the same for `/steward`| Type the command yourself at the Claude Code prompt. It doesn’t start from `claude -p` or from a program
+`/ship didn't start:` or `/steward didn't start:`| The rest of the message says what to check
+`/ship is turned off right now`, or the same for `/steward`| Run `/login` at the Claude Code prompt, as the message says, then run the command again
+`/ship can't start from a queued message` or `/steward can't start from a queued message`| Wait until Claude has finished, then run it again
+
+### The GitHub CLI isn’t ready
+
+`/ship` and `/steward` reach GitHub through the GitHub CLI, `gh`:
+
+Message| What to do
+---|---
+`GitHub CLI (gh) isn't installed` or `GitHub CLI (gh) isn't signed in`| Install it, run `gh auth login` in your shell, then run the command again
+`gh couldn't tell me about a pull request here`| The words in parentheses say what failed. To see `gh`’s own error, run `gh pr view` in your shell. One cause is that none of your checkout’s remotes is on a GitHub host that `gh` is signed in to. For GitHub Enterprise, run `gh auth login --hostname HOST` in your shell
+
+## /ship committed or pushed nothing
+
+In some cases, `/ship` leaves the commit or the push to you and says why. Its message can start with `Nothing committed or pushed`, `Nothing pushed`, `I didn't push anything`, `There is no pull request to watch`, or `This branch has no open pull request`. Find your case, take the step in its row, then run `/ship` again. In these cases, if nothing is pushed and the branch has no pull request, Claude reviews your change and no watch starts.
+
+### Public repositories and files that /ship doesn’t commit
+
+`/ship` looks at the repository and at each changed file’s name before it commits:
+
+Case| What to do
+---|---
+`For a public repository /ship doesn't commit anything for you`| Commit your work yourself, on a branch other than the default branch
+`By its name, this file may hold secrets` or `By their names, these files may hold secrets`, for a changed file such as `.env` or `password.txt`| If it holds no secret, commit your work yourself, on a branch other than the default branch. Otherwise, set it aside, for example with `git stash push -u -- <file>` in your shell
+The message names empty files that you didn’t create, such as `.bashrc` or `.gitconfig`| On Linux and WSL2, the [sandbox](</docs/en/sandboxing>) keeps empty files in your checkout while a sandboxed command runs. The sandbox needs them until the command ends, so don’t stash, commit, or delete them before then. Stop the command, for example from [`/tasks`](</docs/en/commands#all-commands>), or wait for it to end, and the sandbox removes them. If they stay with no sandboxed command running, [remove the leftover files](</docs/en/errors#stale-sandbox-mask-files-left-by-a-killed-session>)
+You changed a file that configures git, CI, or a coding agent, such as `.gitignore`, `CLAUDE.md`, or anything under `.github/`| Commit your work yourself, on a branch other than the default branch
+
+### Branches that /ship can’t commit to or push
+
+`/ship` needs a branch that it can commit to and push:
+
+Case| What to do
+---|---
+`there is nothing here to open one for`: you have no uncommitted changes, and every commit on the branch is already on the default branch| Make a change, or check out the branch that holds your work
+The default branch holds your commits, and nothing is uncommitted| Move the commits to a new branch, for example with `git switch -c <branch>` in your shell
+You’re in detached HEAD state, or in the middle of a rebase| Check out a branch, or finish the rebase
+
+### Deny rules that forbid a commit or push
+
+A [deny rule](</docs/en/permissions#manage-permissions>), such as `Bash(git push *)`, can forbid the commit, the push, or opening the pull request. If whoever set the rule agrees, take those steps yourself. A watch needs `git commit` and `git push` as well. If the rule forbids one of them, have it removed before you run `/ship` again.
+
+### GitHub Enterprise and forks
+
+`/ship` doesn’t open a pull request on GitHub Enterprise or from a fork. Push the branch and open the pull request yourself, then run `/ship`. From a fork, the checkout also needs a remote for the repository that the pull request goes to, or no watch starts.
+
+## No watch started
+
+A watch is Claude’s ongoing work on your pull request, which starts after `/ship`’s review or when you type `/steward`. In some cases, no watch starts and Claude says why. Its message can contain `/steward didn't start.`, `I can't watch`, or `is running on pull request`. Fix the cause, then type `/steward` to start the watch with no second review, or `/ship` if the branch still has no pull request.
+
+### Your pull request or branch isn’t ready for a watch
+
+Check the pull request and your checkout first:
+
+Cause| What to do
+---|---
+The branch has no pull request, and `/steward` doesn’t open one| See /ship committed or pushed nothing
+The pull request’s branch isn’t checked out in this session| Check it out
+The pull request carries one of [PR Steward](</docs/en/pr-steward>)’s labels, such as `claude-pr-steward-watching`| To take over, remove the label and pull the branch, as Claude’s message says
+
+### A session setting blocks a watch
+
+Some settings of the session keep a watch from starting:
+
+Cause| What to do
+---|---
+The session is in `bypassPermissions` mode| Press `Shift+Tab` to switch to a permission mode other than plan mode
+[Remote Control](</docs/en/remote-control>) is on| Run `/rc`, then select **Disconnect this session**
+`your PATH has a relative or empty entry`| `/ship` with no pull request number reviews your change, and doesn’t commit, push, or look for a pull request. Take the empty or relative entry out of `PATH`, such as a trailing `:`, or `;` on Windows. Start `claude` again, then run `/ship`
+Your `PATH` holds a folder inside the checkout. This happens, for example, when you activate a Python virtual environment that’s in the checkout, or start `claude` through `npx` or a package script| To start a session without that folder, run `deactivate` in your shell if you use a virtual environment, then start `claude` directly
+
+### A tool, rule, or hook blocks a watch
+
+A watch needs `gh`, `git commit`, and `git push`, and it doesn’t start where a project’s hook could approve commands:
+
+Cause| What to do
+---|---
+`gh` isn’t installed or signed in| See The GitHub CLI isn’t ready
+A deny rule forbids a command that the watch needs, such as `git push`| Claude’s message names the command and the settings that hold the rule. If whoever set it agrees, remove it there. To change a rule in managed settings, ask your administrator
+The project sets a hook that could approve commands, for example a `PreToolUse` or `PermissionRequest` [hook](</docs/en/hooks>) on shell commands in the checkout’s `.claude/settings.json`| The message names the file and says what to change
+
+### Cases where no watch can start
+
+In these cases, `/ship` can still review your change:
+
+ * You’re on native Windows
+ * Someone else opened the pull request
+ * You can’t push to the repository that the pull request goes to, and another person has commented or reviewed. If this happens while a watch is running, the watch ends
+
+## A watch stopped
+
+A watch is Claude’s ongoing work on your pull request, which starts after `/ship`’s review or when you type `/steward`. After one ends, look for a line that starts `Stopped watching pull request`, which gives the reason. To start the watch again, type the command that the line gives, if it gives one. To check whether a watch is still running, type [`/tasks`](</docs/en/ship-command#check-whether-a-watch-is-running>) at the Claude Code prompt while Claude is idle. Find the words that follow “because” in that line:
+
+Reason| What happened
+---|---
+`its check-in was cancelled`| You pressed `Esc` or `Ctrl+C` at the prompt or while Claude was working, or stopped the task in `/tasks`. Claude’s messages call its work on the pull request a check-in. An `Esc` that closes the `/tasks` list leaves a watch running
+`the watch couldn't go on`| Claude’s reply may give the cause. One cause is that the pull request’s branch is no longer checked out. Check it out in the folder where you started, then type `/steward`
+`a watch doesn't carry over when a session is resumed`| The process that ran the watch has ended, for example because you closed the terminal. Running `claude --continue` in your shell brings back the conversation without the watch
+`you moved to another session`| `/clear`, `/resume`, or `/branch` can do that
+`its check-ins were replaced`| You started a `/loop`
+`your new command took over this session`| You ran `/ship` or `/steward` again
+`a deny rule now forbids a command that the watch runs`| Type `/permissions` at the Claude Code prompt to see the rule. See A tool, rule, or hook blocks a watch
+`the watch reached its time limit`| About seven days passed
+`no next check-in was set`| A declined permission prompt, an error, or a usage limit can do that
+`a file that gh, git, or /steward relies on changed`| See A file that the watch relies on changed
+
+`No pull request is being watched in this session` means that you typed `/ship stop` or `/steward stop` and no watch was running. Scroll up for a `Stopped watching pull request` line.
+
+### A file that the watch relies on changed
+
+A watch ends when something changes a file that `gh`, `git`, or `/steward` relies on. Files such as these count:
+
+ * **Git’s settings** : `git push -u`, `git branch -u`, and `git remote add` change them. An editor such as VS Code can also add a setting to `.git/config` when it opens the repository or you switch back to it
+ * **`.claude/settings.local.json`** : Claude Code writes it when you answer a permission prompt with “Yes, and don’t ask again”
+
+Review the change, then type `/steward` to start the watch again. If you changed none, one cause on Linux and WSL2 is a [sandboxed](</docs/en/sandboxing>) command that starts or ends during the watch. Stop the command or wait for it to end.
+
+## Messages during a watch
+
+These messages appear in your session during a watch:
+
+Message, or what you see| What to do
+---|---
+`Claude Code did not run this`, or `Not run · permission denied`| Claude tried a step, and a [limit on the watch](</docs/en/ship-command#what-claude-code-blocks-during-a-watch>) or one of your rules or hooks refused it. The message also appears when the watch had already ended. Claude’s messages call those limits “the fence”
+`In this session there's a way around my limits`| A setting in your session, such as a rule, a hook, a plugin, or the sandbox, lets some commands past the [limits on the watch](</docs/en/ship-command#what-claude-code-blocks-during-a-watch>). The text after the message names it. To see your rules, type `/permissions` at the Claude Code prompt. To end the watch while you decide, type `/steward stop`
+A line such as `1 comment not read (no write access, or a bot that you haven't named)`| Claude [skipped a comment](</docs/en/ship-command#what-claude-does-during-a-watch>). Open the link in the message to read it. For a bot that you want Claude to read, type `/steward +botname`. For a person’s comment that you agree with, tell Claude what to change
+`gh couldn't say where the pull request's head and base stand`| One cause is a GitHub CLI older than 2.63. Run `gh --version` in your shell to check. Update it, then type `/steward` to start the watch again
+`Claude resuming /loop wakeup` or `/steward --tend` in the session| Claude Code enters them when Claude checks the pull request during a watch. You can keep working as you are
+
+## Pull request results that you didn’t expect
+
+Start here when `/ship` ran, and something on GitHub or in your repository surprised you:
+
+What you see| Why, and what to do
+---|---
+The pull request’s title is a line such as `Update greet.py and 1 more`| `/ship` falls back to that title when Claude can’t write one from the session’s conversation, for example in a session where you didn’t discuss the change. Edit the title and description on GitHub. Next time, run `/ship` in the session where you made the change, or commit your work yourself first, on a branch other than the default branch
+Claude pushed commits or answered a reviewer before you saw them| In auto mode, or where your rules or the sandbox allow a command, a watch works that way. See [Ask Claude to check with you first](</docs/en/ship-command#ask-claude-to-check-with-you-first>)
+New uncommitted changes didn’t reach the open pull request| Once a pull request is open, `/ship` doesn’t commit your work. Commit it, then push it, as in `git push origin <branch>` in your shell
+`git pull` or `git push` asks for an upstream branch| `/ship` sets no upstream. Name the remote and branch, as in `git push origin <branch>`. Setting an upstream changes git’s settings, which [ends a running watch](</docs/en/ship-command#keep-working-while-a-watch-runs>)
+
+## A custom /ship or /steward command stopped loading
+
+A `Not loaded: a custom /ship` or `Not loaded: custom /ship, /steward` notice is about a custom skill or command. Its name is one that the built-in commands reserve, such as `ship`, `ship-local`, or `steward`. Rename it, then restart Claude Code. Leave a repository’s `.claude/skills/steward/SKILL.md` as it is, because PR Steward and the watch read it as instructions. The notice doesn’t count that file, so a notice that names `/steward` is about another skill or command.
+
+## Related resources
+
+ * [`/ship` and `/steward`](</docs/en/ship-command>): what the commands do, how to run them, and what limits Claude during a watch
+ * [Permission modes](</docs/en/permission-modes>): auto mode and the other permission modes
+ * [Hooks](</docs/en/hooks>): the `PreToolUse` and `PermissionRequest` hooks
--- a/statusline.md
+++ b/statusline.md
@@ -129,7 +129,11 @@
### Size output to the terminal
-Claude Code captures your script’s output instead of connecting it directly to the terminal, so `tput cols` and language-level width detection cannot read the terminal size from inside the script. Read the `COLUMNS` and `LINES` environment variables instead. Claude Code sets these to the current terminal dimensions before running your script.
+To fit your status line to the terminal, read the size that Claude Code passes to your script. Claude Code puts the width in the `COLUMNS` environment variable and the height in `LINES`, and updates both each time it runs your script. Calls that ask the terminal directly, such as `stty size`, can fail because your script isn’t connected to the terminal. To keep a line from being cut off with `…`, make it at least four columns narrower than the terminal. Those four columns leave room for the spacing Claude Code adds on each side. This Bash example calculates the widest your output can be:
+
+ max_width=$((COLUMNS - 4))
+
+In an 80-column terminal, `max_width` is 76. If you set `padding`, also subtract twice its value from `max_width`. When you measure a line, count an emoji such as 📁 as two columns.
## Available data
@@ -171,7 +175,7 @@
`agent.name`| Agent name when running with the `--agent` flag or agent settings configured
`pr.number`, `pr.url`| Open pull request for the current branch. Mirrors the PR badge in the footer. In a repository with a GitLab remote, Claude Code fills these fields from the branch’s open [merge request](</docs/en/interactive-mode#gitlab-merge-requests>) instead, so `pr.number` is the merge request number. Merge request data requires Claude Code v2.1.234 or later. Absent when not in a git repository, until a pull request or merge request is found, or once it merges or closes
`pr.review_state`| Review status of the open PR: `approved`, `pending`, `changes_requested`, or `draft`. May be independently absent even when `pr` is present
-`pr.kind`| `mr` when `pr` describes a [GitLab merge request](</docs/en/interactive-mode#gitlab-merge-requests>). Absent for GitHub pull requests, so scripts written before this field keep working. For a merge request, Claude Code sets `review_state` to `approved` when GitLab reports it mergeable, `pending` for any other open state, and `draft` for a draft. Requires Claude Code v2.1.234 or later
+`pr.kind`| `mr` when `pr` describes a [GitLab merge request](</docs/en/interactive-mode#gitlab-merge-requests>). Absent for GitHub pull requests. For a merge request, Claude Code sets `review_state` to `approved` when GitLab reports it mergeable, `pending` for any other open state, and `draft` for a draft. Requires Claude Code v2.1.234 or later
`worktree.name`| Name of the active worktree. Present only while the session is in a [worktree session](</docs/en/worktrees>)
`worktree.path`| Absolute path to the worktree directory
`worktree.branch`| Git branch name for the worktree (for example, `"worktree-my-feature"`). Absent for hook-based worktrees
@@ -320,7 +324,7 @@
The `context_window` object describes the live context window from the most recent API response.
* **Combined totals** (`total_input_tokens`, `total_output_tokens`): tokens currently in the context window. `total_input_tokens` is the sum of `input_tokens`, `cache_creation_input_tokens`, and `cache_read_input_tokens`; `total_output_tokens` is the output tokens from the most recent response. Both are `0` before the first API response.
- * **Per-component usage** (`current_usage`): the same token counts broken out by category. Use this when you need cache hits separate from fresh input. The object is `null` before the first API call in a session, and `null` or all zeros after `/compact` until the next API call. Treat both as empty.
+ * **Per-component usage** (`current_usage`): the same token counts broken out by category. Use this when you need cache hits separate from fresh input. `current_usage` is `null` until the conversation has an API response, and `null` or all zeros after `/compact` until the next API call. Treat both as empty.
The `current_usage` object contains:
@@ -329,7 +333,7 @@
* `cache_creation_input_tokens`: tokens written to cache
* `cache_read_input_tokens`: tokens read from cache
-For what the cache fields mean and how they’re billed, see [check cache performance](</docs/en/prompt-caching#check-cache-performance>). The `used_percentage` field is calculated from input tokens only: `input_tokens + cache_creation_input_tokens + cache_read_input_tokens`. It does not include `output_tokens`. If you calculate context percentage manually from `current_usage`, use the same input-only formula to match `used_percentage`.
+For what the cache fields mean and how they’re billed, see [check cache performance](</docs/en/prompt-caching#check-cache-performance>). The `used_percentage` field is calculated from input tokens only: `input_tokens + cache_creation_input_tokens + cache_read_input_tokens`. If you calculate context percentage manually from `current_usage`, use the same input-only formula to match `used_percentage`.
### Spend limit fields
@@ -1088,4 +1092,4 @@
* System notifications like MCP server errors and auto-updates display on the right side of the row. Transient notifications such as the context-low warning also cycle through this area.
* Enabling verbose mode adds a token counter to this area, showing the size of your context as the last API response reported it, not the [per-turn count beside the spinner](</docs/en/costs#read-the-token-count-beside-the-spinner>)
- * On narrow terminals, these notifications may truncate your status line output
+ * When a notification doesn’t fit beside your status line, the notification moves to a row below
--- a/sub-agents.md
+++ b/sub-agents.md
@@ -888,7 +888,7 @@
#### Resume subagents
-Each subagent invocation creates a new instance rather than continuing an earlier one. To continue an existing subagent’s work instead of starting over, ask Claude to resume it. Resumed subagents retain their full conversation history, including all previous tool calls, results, and reasoning. If the subagent spawned background subagents of its own, that history includes the results they delivered while it ran. Before v2.1.304, a subagent that Claude messaged or resumed right after it finished could forget its most recent work.
+Each subagent invocation creates a new instance rather than continuing an earlier one. To continue an existing subagent’s work, ask Claude to resume it. Resumed subagents retain their full conversation history, including all previous tool calls, results, and reasoning. If the subagent spawned background subagents of its own, that history includes the results they delivered while it ran. Before v2.1.304, a subagent that Claude messaged or resumed right after it finished could forget its most recent work.
* When a subagent completes, Claude receives its agent ID.
* For work you’ll continue later, use `general-purpose` or a custom subagent. The built-in Explore and Plan agents can finish without giving Claude an ID to resume them with.
--- a/terminal-config.md
+++ b/terminal-config.md
@@ -1,4 +1,4 @@
-Claude Code works in any terminal without configuration. This page is for when something specific is not behaving the way you expect. Find your symptom below. If everything already feels right, you do not need this page.
+Claude Code works in any terminal without configuration. This page is for when something specific isn’t behaving the way you expect. Find your symptom below.
* Shift+Enter submits instead of inserting a newline
* Option-key shortcuts do nothing on macOS
@@ -27,7 +27,7 @@
* If Claude Code can’t read or parse the keymap, can’t back it up, or can’t verify the merged result, it [leaves the file unchanged and prints the keybinding block to add yourself](</docs/en/errors#terminal-setup-left-your-zed-keymap-unchanged>)
* If the keymap is a symlink, [add the keybinding yourself](</docs/en/errors#terminal-setup-left-your-zed-keymap-unchanged>)
-If you are running inside tmux, Shift+Enter also requires the tmux configuration below even when the outer terminal supports it. To bind newline to a different key, or to swap behavior so Enter inserts a newline and Shift+Enter submits, map the `chat:newline` and `chat:submit` actions in your [keybindings file](</docs/en/keybindings>).
+If you are running inside tmux, Shift+Enter also requires the tmux configuration below. To bind newline to a different key, or to swap behavior so Enter inserts a newline and Shift+Enter submits, map the `chat:newline` and `chat:submit` actions in your [keybindings file](</docs/en/keybindings>).
## Enable Option key shortcuts on macOS
@@ -137,7 +137,7 @@
`base`| string| Built-in preset the theme starts from: `dark`, `light`, `dark-daltonized`, `light-daltonized`, `dark-ansi`, or `light-ansi`. Defaults to `dark`
`overrides`| object| Map of color token names to color values. Tokens not listed here fall through to the base preset
-Color values accept `#rrggbb`, `#rgb`, `rgb(r,g,b)`, `ansi256(n)`, or `ansi:<name>` where `<name>` is one of the 16 standard ANSI color names such as `red` or `cyanBright`. Unknown tokens and invalid color values are ignored, so a typo cannot break rendering. The following example defines a theme that keeps the dark preset but recolors the prompt accent, error text, and success text:
+Color values accept `#rrggbb`, `#rgb`, `rgb(r,g,b)`, `ansi256(n)`, or `ansi:<name>` where `<name>` is one of the 16 standard ANSI color names such as `red` or `cyanBright`. Unknown tokens and invalid color values are ignored. The following example defines a theme that keeps the dark preset but recolors the prompt accent, error text, and success text:
~/.claude/themes/dracula.json
@@ -151,7 +151,7 @@
}
}
-Claude Code watches `~/.claude/themes/` and reloads when a file is added or changed, so edits made in your editor apply to a running session without a restart. If the `~/.claude/themes/` folder itself didn’t exist when Claude Code started, restart once after creating your first theme file. After that, changes apply without a restart. The reference below covers the tokens you can set in `overrides`. The interactive editor in `/theme` shows the same tokens with a live preview, plus a few single-purpose accents such as onboarding screen colors that are omitted here.
+Claude Code watches `~/.claude/themes/` and reloads when a file is added or changed, so edits made in your editor apply to a running session without a restart. If the `~/.claude/themes/` folder itself didn’t exist when Claude Code started, restart once after creating your first theme file. The reference below covers the tokens you can set in `overrides`. The interactive editor in `/theme` shows the same tokens with a live preview, plus a few single-purpose accents such as onboarding screen colors that are omitted here.
Color token reference
@@ -291,7 +291,7 @@
### How Claude treats pasted text
-When you submit, Claude sees the content behind each `[Pasted text #N]` placeholder marked as text you pasted from somewhere else rather than typed. Claude is told that a paste can contain instructions you didn’t write, and to follow instructions inside it only where the message you typed asks it to. Pastes can reach Claude unmarked, such as in your [first session after an install](</docs/en/env-vars#first-session-after-an-install-or-upgrade>).
+When you submit, Claude sees the content behind each `[Pasted text #N]` placeholder marked as text you pasted from somewhere else rather than typed. Pastes can reach Claude unmarked, such as in your [first session after an install](</docs/en/env-vars#first-session-after-an-install-or-upgrade>).
### Delete and restore a collapsed paste
--- a/third-party-integrations.md
+++ b/third-party-integrations.md
@@ -28,7 +28,7 @@
## Configure proxies and gateways
-Most organizations can use a cloud provider directly without additional configuration. However, you may need to configure a corporate proxy or LLM gateway if your organization has specific network or management requirements. These are different configurations that can be used together:
+You may need to configure a corporate proxy or LLM gateway if your organization has specific network or management requirements. These are different configurations that can be used together:
* **Corporate proxy** : Routes traffic through an HTTP/HTTPS proxy. Use this if your organization requires all outbound traffic to pass through a proxy server for security monitoring, compliance, or network policy enforcement. Configure with the `HTTPS_PROXY` or `HTTP_PROXY` environment variables. Learn more in [Enterprise network configuration](</docs/en/network-config>).
* **LLM Gateway** : A service that sits between Claude Code and the cloud provider to handle authentication and routing. Use this if you need centralized usage tracking across teams, custom rate limiting or budgets, or centralized authentication management. Configure with the `ANTHROPIC_BASE_URL`, `ANTHROPIC_BEDROCK_BASE_URL`, `ANTHROPIC_AWS_BASE_URL`, `ANTHROPIC_VERTEX_BASE_URL`, or `ANTHROPIC_FOUNDRY_BASE_URL` environment variables. Learn more in [LLM gateways](</docs/en/llm-gateway>).
--- a/tools-reference.md
+++ b/tools-reference.md
@@ -16,7 +16,7 @@
`EnterPlanMode`| Switches to plan mode to design an approach before coding| No
`EnterWorktree`| Creates an isolated [git worktree](</docs/en/worktrees>) and switches into it, or switches into an existing worktree. See EnterWorktree tool behavior| Some worktrees
`ExitPlanMode`| Presents a plan for approval and exits plan mode| Yes
-`ExitWorktree`| Exits a worktree session and returns to the original directory. Not available to subagents that already run in their own working directory, such as with [`isolation: worktree`](</docs/en/sub-agents#supported-frontmatter-fields>). Removed or refused once [`permissions.blockWritesOutsideWorkingDirectories`](</docs/en/settings-reference#permissions-blockwritesoutsideworkingdirectories>) is on| No
+`ExitWorktree`| Exits a worktree session and returns to the original directory. Not available to subagents that already run in their own working directory, such as with [`isolation: worktree`](</docs/en/sub-agents#supported-frontmatter-fields>). Removed or refused once [`permissions.blockWritesOutsideWorkingDirectories`](</docs/en/settings-reference#permissions-blockwritesoutsideworkingdirectories>) is on| Yes on v2.1.327 or later, to remove a worktree when Claude Code can’t check it or finds work at risk, such as unpushed commits or files that `git status` lists
`Glob`| Finds files based on pattern matching. Absent by default on macOS, Linux, and WSL. See Glob tool behavior| No
`Grep`| Searches for patterns in file contents. Absent by default on macOS, Linux, and WSL. See Grep tool behavior| No
`ListAgents`| Lists the agents Claude can message with `SendMessage`: subagents in the session, [agent team](</docs/en/agent-teams>) teammates, your other local Claude Code sessions, and, while this session is connected to [Remote Control](</docs/en/remote-control>), your [cloud sessions](</docs/en/claude-code-on-the-web>) and your Remote Control sessions on other machines. Backs the `/list-agents` command. See [cross-session messaging](</docs/en/cross-session-messaging>). Requires Claude Code v2.1.224 or later, and appears only in sessions where [cross-session messaging is enabled](</docs/en/cross-session-messaging#availability>). Teammate rows and the first line showing this session’s own name require v2.1.239 or later| No
--- a/troubleshoot-install.md
+++ b/troubleshoot-install.md
@@ -208,7 +208,7 @@
ls -la ~/.local/bin/claude
-A native install shows a symlink into `~/.local/share/claude/versions/`. A script or a symlink you created yourself at this path is a custom launcher, which [auto-update leaves in place](</docs/en/setup#auto-updates>).If either `ls` command prints `No such file or directory`, that’s not an error. It means nothing is installed at that location, so move on to the next check.
+A native install shows a symlink into `~/.local/share/claude/versions/`. If you put your own launcher at this path, see [Custom launchers](</docs/en/setup#custom-launchers>).If either `ls` command prints `No such file or directory`, that’s not an error. It means nothing is installed at that location, so move on to the next check.
ls -la ~/.claude/local/
--- a/troubleshooting.md
+++ b/troubleshooting.md
@@ -13,6 +13,7 @@
`CLINotFoundError`, `CLIConnectionError`, `ProcessError`, `Claude Code process exited with code N`, `Claude Code returned an error result`, `CLIJSONDecodeError`, `structured_output` is `None`| CLI startup, CLI process exit, Large tool calls and results, and Structured outputs on this page
`Operation aborted`, `Claude Code process aborted by user`, `Prompt stream failed; closing stdin`, or a Python `query()` loop that stops, with no exception, before all your messages are answered| Streaming input on this page
`Image could not be processed`| Image could not be processed on this page
+`option can't be sent to Claude Code` in TypeScript| [`Options`](</docs/en/agent-sdk/typescript#options>): fix the option the message names
## CLI startup
--- a/typescript.md
+++ b/typescript.md
@@ -116,8 +116,6 @@
---|---|---
`options`| `Options`| Optional configuration object, the same type that `startup()` takes
`initializeTimeoutMs`| `number`| Maximum time in milliseconds to wait for the spare’s initialization. Defaults to `60000`. If initialization doesn’t complete in time, the promise rejects with a timeout error
-
-`prewarm()` counts time spent in [Setup](</docs/en/hooks#setup>) hooks toward `initializeTimeoutMs`, even when you leave it unset. To give slow Setup hooks more time, set a longer value.
#### Returns
@@ -1119,7 +1117,7 @@
`disallowedTools`| No| Array of tool names to explicitly disallow for this agent. MCP server-level patterns are also accepted: `mcp__server` or `mcp__server__*` removes every tool from that server, and `mcp__*` removes every MCP tool from any server
`prompt`| Yes| The agent’s system prompt
`model`| No| Model override for this agent. Accepts an alias such as `'fable'`, `'opus'`, `'sonnet'`, `'haiku'`, `'inherit'`, or a full model ID. `'inherit'` uses the model of the agent that spawned this one. When you omit `model`, Claude Code picks the model in the [subagent model order](</docs/en/sub-agents#choose-a-model>)
-`mcpServers`| No| MCP server specifications for this agent
+`mcpServers`| No| MCP server specifications for this agent. Put a `createSdkMcpServer()` server in the `mcpServers` field of `Options`. If you pass the server object in this field instead, TypeScript Agent SDK v0.3.327 or later ignores it and emits a `CLAUDE_SDK_AGENT_IN_PROCESS_SERVER` warning
`skills`| No| Array of skill names to preload into the agent context
`initialPrompt`| No| Auto-submitted as the first user turn when this agent runs as the main thread agent
`maxTurns`| No| Maximum number of agentic turns (API round-trips) before stopping
@@ -3727,6 +3725,7 @@
taskId: string;
timeoutMs: number;
persistent?: boolean;
+ keptInSandboxByCheck?: boolean;
};
Returns the background task ID for the running monitor. Use this ID with `TaskStop` to cancel the watch early.
--- a/user-input.md
+++ b/user-input.md
@@ -224,7 +224,7 @@
return { behavior: "deny", message: "User declined" };
};
-The user approves but wants to modify the request first. You can change the input before the tool executes. Claude sees the result but isn’t told you changed anything. Useful for sanitizing parameters, adding constraints, or scoping access.
+The user approves but wants to modify the request first. You can change the input before the tool executes. Useful for sanitizing parameters, adding constraints, or scoping access.
Python
--- a/vs-code.md
+++ b/vs-code.md
@@ -679,7 +679,7 @@
* **Tool steps** : “Claude” plus the tool name, such as “Claude, Bash”
* **Thinking blocks** : “Claude, thinking”
-Because the extension exposes the transcript as a labeled region, you can also move focus to the transcript itself with `Tab` and read it at your own pace. To move focus to the newest message or a waiting permission prompt instead, run **Claude Code: Focus last message** from the Command Palette. When a permission prompt option saves a permission rule or directory access, its label ends by naming where the approval is saved, such as “all projects” or “this session”. To change the destination:
+Because the extension exposes the transcript as a labeled region, you can also move focus to the transcript itself with `Tab` and read it at your own pace. To move focus to the newest message or a waiting permission prompt instead, run **Claude Code: Focus last message** from the Command Palette. When a permission prompt option saves a permission rule or directory access, its label names where the approval is saved, such as “all projects” or “this session”. To change the destination:
* With that option focused, press the `Left` or `Right` arrow key. The extension announces each destination as you move to it. The arrow keys require Claude Code v2.1.268 or later.
* Click the destination in the label.
--- a/workflows.md
+++ b/workflows.md
@@ -100,7 +100,14 @@
#### Dismiss or turn off the keyword
-If you didn’t mean to start a workflow, press `Option+W` on macOS or `Alt+W` on Windows and Linux to dismiss the highlight for this prompt, or press backspace while the cursor is right after the highlighted keyword. To stop the keyword from triggering at all, turn off Ultracode keyword trigger in `/config`.
+To use the word `ultracode` without asking for a workflow, skip the keyword for one prompt or turn the keyword off for every prompt:
+
+ * **One prompt, as you type** : put the word in backticks. For example, this prompt is a regular request to search your files:
+
+ find every file that mentions `ultracode`
+
+ * **One prompt, already highlighted in your terminal** : press Backspace right after the word, or press `Alt+W`. On macOS, that key is `Option+W` with [Option as Meta](</docs/en/terminal-config#enable-option-key-shortcuts-on-macos>).
+ * **Every prompt** : turn off [**Ultracode keyword trigger**](</docs/en/settings-reference#workflowkeywordtriggerenabled>) in `/config`.
#### Where the keyword works
@@ -177,7 +184,7 @@
Run /triage-issues on issues 1024, 1025, and 1030
-Claude passes the list as structured data, so the script can call array and object methods on `args` directly without parsing it first. If `args` is omitted, the global is `undefined` inside the script.
+Claude passes the list as structured data, so the script can call array and object methods on `args` directly. If `args` is omitted, the global is `undefined` inside the script.
## Example workflow prompts
@@ -221,7 +228,7 @@
### What the saved script looks like
-When you save a workflow, the file in `.claude/workflows/` holds a `meta` block followed by a script body that orchestrates subagents. You usually don’t need to edit it, but here is the shape of a small one so you can recognize what Claude generated:
+When you save a workflow, the file in `.claude/workflows/` holds a `meta` block followed by a script body that orchestrates subagents. Here is the shape of a small one so you can recognize what Claude generated:
export const meta = {
name: 'audit-routes',
--- a/worktrees.md
+++ b/worktrees.md
@@ -95,7 +95,7 @@
### Clean up subagent and background-session worktrees
-Claude Code runs a periodic sweep that removes worktrees that Claude created for subagents and [background sessions](</docs/en/agent-view#how-file-edits-are-isolated>) once they are older than your [`cleanupPeriodDays`](</docs/en/settings-reference#cleanupperioddays>) setting, following the [retention sweep rules](</docs/en/claude-directory#cleaned-up-automatically>). When you [background](</docs/en/agent-view#send-the-session-to-the-background>) a `--worktree` session, its worktree becomes a background-session worktree that the sweep can remove. The sweep leaves a worktree in place in these cases:
+Claude Code runs a periodic sweep that removes worktrees that Claude created for subagents and [background sessions](</docs/en/agent-view#how-file-edits-are-isolated>) once they are older than your [`cleanupPeriodDays`](</docs/en/settings-reference#cleanupperioddays>) setting, following the [retention sweep rules](</docs/en/claude-directory#cleaned-up-automatically>). When you [background](</docs/en/agent-view#send-the-session-to-the-background>) a `--worktree` session, its worktree becomes a background-session worktree that the sweep can remove. The sweep leaves a worktree in place in cases such as these:
* The worktree still holds work: changed or untracked files, or unpushed commits.
* A checked-out submodule in the worktree holds changed or untracked files, or Claude Code can’t inspect the worktree’s submodules. This check requires Claude Code v2.1.274 or later.
@@ -187,7 +187,7 @@
A worktree gets its own files and branch, but it shares the following with the main checkout:
* **The repository’s`.git` directory**: git commands in a worktree write to the main repository’s shared `.git` directory. With the [sandbox](</docs/en/sandboxing#filesystem-isolation>) enabled, commands such as `git commit` work in a session at the worktree’s root, which is where `--worktree` starts one. By default, they [fail with an `index.lock` error if you run `claude` in a subdirectory of the worktree](</docs/en/sandboxing#git-index-lock>).
- * **Plugins** : plugins installed at [project scope](</docs/en/plugins/loading#find-where-a-plugin-is-enabled>) from the main checkout also load in worktrees of the same repository, so you don’t need to reinstall them per worktree.
+ * **Plugins** : plugins installed at [project scope](</docs/en/plugins/loading#find-where-a-plugin-is-enabled>) from the main checkout also load in worktrees of the same repository.
* **Permission approvals** : choosing “Yes, and don’t ask again” for a Bash command in a worktree session saves the rule to the main checkout’s `.claude/settings.local.json`. The rule applies in the main checkout and in every other worktree of the repository, and it survives the worktree’s removal. On Windows and in the other cases where Claude Code [doesn’t use the repository root](</docs/en/settings#where-claude-code-looks-for-each-file>), the rule stays with that worktree. See [where approvals are saved](</docs/en/permissions#permission-system>).
* **Untracked skills, agents, and commands** : when the worktree checkout has no `.claude/skills` directory at its root, for example because your `.claude/skills` is gitignored, Claude Code loads the main checkout’s [project skills](</docs/en/skills#where-skills-live>) in the worktree session. In a worktree with its own `.claude/skills` directory, only that copy loads. The same read-through covers `.claude/agents` and `.claude/commands`. For skills, the read-through requires Claude Code v2.1.277 or later.