One read of Claude Code CLIclaude-code-20261202T230702Z
68 pages moved out of 220 read.
Pages moved
68
significant first
Pages read
220
in this capture
Captured
23:07 UTC
Corpus hash
98745c4a90d1
corpus-hash
What this read moved
1-25 of 68, page 1 of 3This capture is too large to show at once. Changes 1-25 of 68 are below, significant first; the rest are on the following screens.
agent-sdk/troubleshooting Changed · +6 / -2 lines
from line 4
44
55This page covers Agent SDK errors in CLI startup, CLI process exit, large tool calls and results, streaming input, and structured outputs. Entries on this page are keyed to the error you see. Each entry names the cause and what to do.
66
7Symptoms tied to a feature, such as a hook not firing or a skill not being used, have a troubleshooting section on that feature's page. Look up your symptom in this table to find the section or page that covers it:
7Symptoms tied to a feature, such as a hook not firing or a skill not being used, have a troubleshooting section on that feature's page.
88
9The following table lists symptoms and the section or page that covers each:
10
911| Symptom | Go to |
1012| :- | :- |
1113| Skills not found, a skill not being used, `Invalid skill name` error | [Skills troubleshooting](https://code.claude.com/docs/en/agent-sdk/skills.md#troubleshooting) |
from line 71
6971
7072### CLIConnectionError: Failed to start Claude Code
7173
72The SDK found a file at the resolved path but couldn't launch it. Python raises these failures as a `CLIConnectionError`. TypeScript rejects the message iteration with an error carrying no SDK class. The table below maps each message to what it tells you. Match the message you see:
74The SDK found a file at the resolved path but couldn't launch it. Python raises these failures as a `CLIConnectionError`. TypeScript rejects the message iteration with an error carrying no SDK class.
75
76This table shows what each message means:
7377
7478| Message | SDK | What it tells you |
7579| - | - | - |
agent-sdk/user-input Changed · +1 / -4 lines
from line 614
614614
615615#### Support free-text input
616616
617Claude's predefined options won't always cover what users want. To let users type their own answer:
618
619* Display an additional "Other" choice after Claude's options that accepts text input
620* Use the user's custom text as the answer value (not the word "Other")
617Claude's predefined options won't always cover what users want. To let users type their own answer, display an additional "Other" choice after Claude's options that accepts text input. Use the user's custom text as the answer value (not the word "Other").
621618
622619See the [complete example](#complete-example) below for a full implementation.
623620
approvals Changed · +8 / -8 lines
from line 12
1212
1313
1414
15Use 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](https://code.claude.com/docs/en/code-review.md) passes.
15Use Approvals to set how many people have to approve a change, with more on risky changes and fewer on routine ones. For example, you can require two people for billing code, and one person for test fixtures once [Code Review](https://code.claude.com/docs/en/code-review.md) passes.
1616
1717> [!NOTE]
1818>
from line 79
7979
8080### Merges without human review
8181
82A 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:
82A pull request can merge without human review when your policy or your GitHub rules allow it, for example:
8383
84* **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
85* **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
86* **GitHub counts Claude's approval**: where a GitHub branch rule requires one approval, Claude's approving review can be that approval
87* **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](https://code.claude.com/docs/en/approvals-setup.md#let-claude-approve-when-code-review-passes)
84* **You leave the check optional**: for the **Claude Approvals** check to block a merge, make it a required check in GitHub and enforce the policy
85* **You set the [`seats`](https://code.claude.com/docs/en/approvals-policy#verdict) field to `1` or `0`**: with `seats: 1`, the author can meet it alone. With `seats: 0`, a pull request can merge without any human review, whether a person or a bot wrote it. To require approval from a person other than the authors, [add a policy rule that excludes authors](https://code.claude.com/docs/en/approvals-github-rules.md#ask-for-a-person-who-isn’t-an-author)
86* **GitHub counts Claude's approval**: if you require one approval in a GitHub branch rule, Claude's approving review can be that approval. To prevent that, add an unconditional `claude: comments` rule to an enforced root policy file. Write it for every path and set `nested: inherit` on it, as in [the rule that excludes authors](https://code.claude.com/docs/en/approvals-github-rules.md#ask-for-a-person-who-isn’t-an-author)
87* **You set `claude: approves` on a rule**: Claude can approve an unreviewed change. To get a review first, [let Claude approve only when Code Review passes](https://code.claude.com/docs/en/approvals-setup.md#let-claude-approve-when-code-review-passes)
8888
89For the other cases, and a rule that asks for a person who isn't an author, see [Merges without human review](https://code.claude.com/docs/en/approvals-github-rules.md#merges-without-human-review).
89For the other cases, see [Merges without human review](https://code.claude.com/docs/en/approvals-github-rules.md#merges-without-human-review).
9090
9191### Keep automatic Code Reviews
9292
93[Code Review](https://code.claude.com/docs/en/code-review.md), 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](#set-up-claude-approvals) and when the policy is enforced.
93[Code Review](https://code.claude.com/docs/en/code-review.md), another Claude Ship agent, can review each pull request automatically. Automatic reviews normally stop on a pull request whose changed files are each under a directory with a policy file, unless a rule for those files names the `claude/code_review` classifier. This applies to enforced policies and in [observe mode](#set-up-claude-approvals).
9494
9595To keep automatic reviews, [list `claude/code_review` in a rule](https://code.claude.com/docs/en/approvals-policy#advisory), as the [example policy](#example-policy) does under `advisory`.
9696
approvals-classifiers Changed · +7 / -7 lines
from line 2
22
33> Let a Claude Approvals rule depend on Code Review's answer or on a question you define. Add a classifier, read its answer, and limit what a run costs.
44
5In [Claude Approvals](https://code.claude.com/docs/en/approvals.md), the rules in your [policy file](https://code.claude.com/docs/en/approvals-policy.md) 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.
5In [Claude Approvals](https://code.claude.com/docs/en/approvals.md), you decide who has to approve a pull request by writing rules in your [policy file](https://code.claude.com/docs/en/approvals-policy.md). A classifier answers a question about the change, such as whether Code Review passed or how risky the change is, and you can make a rule depend on its answer. For example, you can require two people, or only one when a classifier rates the change as low risk.
66
77A rule can decide from paths, facts, and classifiers:
88
from line 58
5858
5959A 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.
6060
61To 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](#read-a-classifier’s-answer-from-a-rule).
61To 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`. To require fewer people under that condition, see [Read a classifier's answer from a rule](#read-a-classifier’s-answer-from-a-rule).
6262
6363## Classifiers Anthropic provides
6464
from line 98
9898
9999### When a classifier's answer appears
100100
101After 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:
101After you merge a classifier's definition and the rule that names it, wait five minutes. Then open a non-draft pull request that changes a file matching the rule's `paths` patterns. Look for the classifier's line in one of these places:
102102
103103* **Claude's comment**: under **Classifier results**
104104* **The Claude Approvals check's summary**: under **Advisory classifiers (not counted toward this verdict)**
from line 116
116116
117117Keep the strict verdict on the rule itself, because the rule's verdict applies [when a run gives no answer](#what-a-rule-sees-when-a-classifier-run-gives-no-answer).
118118
119This rule asks for two people, and for one while `repo/change_risk` answers `low`:
119To require two people, or one when the `repo/change_risk` classifier answers `low`, write a rule like this one:
120120
121121```yaml theme={null}
122122# .claude/approvals.yml
from line 223
223223
224224## How a classifier run behaves
225225
226A rule's result can turn on when its classifier runs, what the run can read, and what happens when it gives no answer.
226Your rule's result can depend on when its classifier runs, what the run can read, and whether it answers.
227227
228228### When a classifier runs
229229
from line 253
253253
254254| A condition reads | When |
255255| :- | :- |
256| `incomplete` | The run began and ended with no answer |
257| `error` | The run couldn't start, was broken off, or outlasted the check's wait |
256| `incomplete` | The run ended by itself without a usable answer, such as at its [time or cost limit](#budget) |
257| `error` | The run failed to start, was broken off, or ran longer than the check waits |
258258
259259In 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**.
260260
approvals-github-rules Changed · +5 / -5 lines
from line 1
11# Claude Approvals and your GitHub rules
22
3> See how the Claude Approvals check works with required reviews, CODEOWNERS, and merge queues, what can merge with no person, and who can change a policy
3> See how the Claude Approvals check works with required reviews, CODEOWNERS, and merge queues, what can merge without human review, and who can change a policy
44
55[Claude Approvals](https://code.claude.com/docs/en/approvals.md) adds a check to the GitHub pull requests that it evaluates. The check reports who has to approve a pull request, following a [policy](https://code.claude.com/docs/en/approvals-policy.md), 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.
66
77If you administer a repository or review its security, check how your policy and your GitHub settings work together before you [enforce the policy](https://code.claude.com/docs/en/approvals-setup.md#enforce-your-policy-and-require-claude-approvals):
88
9* **[Merges without human review](#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
9* **[Merges without human review](#merges-without-human-review)**: the settings that allow them, and how to require approval from a person other than the authors
1010* **[Required reviews and CODEOWNERS](#required-reviews-and-codeowners)**: how GitHub's own review rules count Claude's approving review, and what to set
1111* **[Auto-merge and merge queues](#auto-merge-and-merge-queues)**: what can merge without anyone acting
1212* **[Who can change or loosen a policy](#who-can-change-or-loosen-a-policy)**: who can edit the policy file, stop requiring the check, or steer a classifier's answer
from line 13
1313
1414## Merges without human review
1515
16With 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:
16A pull request can merge without human review if the **Claude Approvals** check is optional in GitHub or the policy is in [observe mode](https://code.claude.com/docs/en/approvals-pull-requests.md#approvals-in-observe-mode). After you require the check and enforce the policy, a pull request can still merge without human review. Causes include the following:
1717
1818* `seats: 0`
1919* `seats: 1`, which the author can fill
from line 21
2121* A machine user, a user account that a script or an agent drives, which [can count as a person](https://code.claude.com/docs/en/approvals-policy.md#whether-a-pull-request’s-author-counts)
2222* A [`reuse`](https://code.claude.com/docs/en/approvals-policy#reuse) that keeps seats after a push
2323* Files that no rule covers, where GitHub counts the neutral result as passing
24* A condition that reads a [classifier's](https://code.claude.com/docs/en/approvals-classifiers.md) 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](#classifier-answers-that-a-pull-request-can-steer)
24* A [classifier's](https://code.claude.com/docs/en/approvals-classifiers.md) answer that you use in the `if` condition of a rule or an override, or in a `reuse` condition, because [a pull request's text can steer](#classifier-answers-that-a-pull-request-can-steer) it. To limit what a steered answer can change, [add a rule that excludes authors](#ask-for-a-person-who-isn’t-an-author)
2525
2626A push directly to the default branch gets no check. Require pull requests there in GitHub.
2727
from line 29
2929
3030### Ask for a person who isn't an author
3131
32To 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](https://code.claude.com/docs/en/approvals-policy.md) that you [enforce](https://code.claude.com/docs/en/approvals-setup.md#enforce-your-policy-and-require-claude-approvals):
32To make the **Claude Approvals** check require approval on every path from one person other than the authors, add this file's rule to a root [policy file](https://code.claude.com/docs/en/approvals-policy.md) that you [enforce](https://code.claude.com/docs/en/approvals-setup.md#enforce-your-policy-and-require-claude-approvals):
3333
3434```yaml theme={null}
3535# .claude/approvals.yml
approvals-policy Changed · +15 / -15 lines
from line 64
6464
6565To 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`.
6666
67For 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](#how-rules-combine-into-one-verdict), decides for it. A `nested: inherit` rule in a policy file higher up counts as one of the deciding policy file's rules.
67For each changed file, Approvals walks up from that file's directory. The deciding policy file is the first enforcing one that covers the changed file and in which a rule with a `verdict` key [applies](#how-rules-combine-into-one-verdict) to that file. A `nested: inherit` rule in a policy file higher up counts as one of the deciding policy file's rules.
6868
6969* **The nearest policy file decides**: it can ask for less than the root policy file. Above it, only rules marked `nested: inherit` still count.
7070* **`paths` start at the directory**: in `services/billing/.claude/approvals.yml`, write `api/**` to match the files under `services/billing/api/`
from line 96
9696
9797## Rule keys
9898
99Give 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](#how-rules-combine-into-one-verdict) no file.
99To add a rule to your policy file, give the rule the `purpose` and `paths` keys, and at least one of the `verdict`, `advisory`, and `findings` keys.
100100
101101You can write these keys on a rule:
102102
from line 111
111111| [`reuse`](#reuse) | Condition or map | Keep nothing | What still counts after a push that changes the diff |
112112| [`findings`](#findings) | Map | No list | Who may close a classifier's finding |
113113| [`use`](#locals-and-use) | List of `"@name"` | | Locals whose keys are copied into the rule |
114| `mode` | `enforce`, `observe` | The file's | A rule that observes neither [applies nor covers](#how-rules-combine-into-one-verdict) a file |
114| `mode` | `enforce`, `observe` | The file's | Only an enforced rule [applies to or covers](#how-rules-combine-into-one-verdict) a file |
115115| `nested` | `overwrite`, `inherit` | The file's | `inherit` keeps the rule in force under the policy files below |
116116| `run` | `sequential`, `parallel` | The file's | Whether the rule's own classifiers start in turn or together |
117117
from line 156
156156
157157| Field | Values | Description |
158158| :- | :- | :- |
159| `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](#how-rules-combine-into-one-verdict). 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 |
160| `seats` | `0` to `16`, or a list of up to eight sets | How many [people](#how-people’s-approvals-are-counted) have to approve. A number `N` is short for `[{ count: N, from: humans }]`. Refused beside `blocks` |
159| `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](#how-rules-combine-into-one-verdict). `comments`: Claude withholds its approval. `blocks`: the check fails |
160| `seats` | `0` to `16`, or a list of up to eight sets | How many [accounts](#how-people’s-approvals-are-counted) the rule requires. The author [can be one of them](#whether-a-pull-request’s-author-counts). A number `N` is short for `[{ count: N, from: humans }]`. Refused with `claude: blocks` |
161161| `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** |
162162
163163Give each set in `seats` a `count`, from `1` to `16`, and a `from`, which is a [people list](#people-lists). Every set has to be filled, and one person can fill a seat in several sets.
from line 178
178178| `pr/authors`, `pr/opened_by` | The accounts that the fact holds |
179179| `"!pr/authors"` | Takes accounts away. Quote it, with single quotes in a condition, and put it beside an item with no `!` |
180180
181If 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.
181If a set's `from` list includes Claude, for example through `bots`, `everyone`, or `bot:claude`, and every applicable verdict says `approves`, Approvals can count Claude toward that set. The **Claude Approvals** check can then pass without human review.
182182
183183### `override`
184184
from line 230
230230
231231* **Every rule that matches the files**: write `reuse` on each of them
232232* **When `claude/diff` gives no answer**: a condition that reads it keeps nothing
233* **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"`.
234* **Earlier authors count too**: where `reuse` keeps `seats`, people who held the [author's seat](#whether-a-pull-request’s-author-counts) 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"`.
235* **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
233* **After a dismissal or a force-push**: if the rules on the changed files use the example, an approval stops counting when GitHub dismisses it at a push. It also stops counting after a force-push that changes the diff and replaces the approved commit, as a rebase, amend, or squash does. You can keep those approvals with a `seats` condition whose only classifier is `claude/diff`, such as `"claude/diff <= same_intent"`.
234* **Earlier authors count too**: if your `reuse` key keeps approvals, people who [counted without approving](#whether-a-pull-request’s-author-counts) at an earlier commit can continue to count. Two such authors can meet `seats: 2` without anyone approving. To prevent that, exclude authors in the rule's verdict and overrides, as in `seats: [{ count: 2, from: [humans, "!pr/authors"] }]`.
235* **Pushes to other files**: once a policy file has a `reuse` key, a person's approval can still count after a push that changes only files where it couldn't count. Files that no rule covers are one example.
236236
237237### `findings`
238238
from line 240
240240
241241Until 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.
242242
243This example lets the `acme/leads` team, less the pull request's authors, close Code Review's findings:
243This example lets the `acme/leads` team close Code Review's findings, excluding the pull request's authors:
244244
245245```yaml theme={null}
246246# in .claude/approvals.yml, on a rule with no if, beside verdict
from line 255
255255| :- | :- |
256256| A [people list](#people-lists) | One list for every classifier's findings. `resolution: humans` lets people with write access close them, the author included |
257257| A map of classifier names to lists | A list for each classifier |
258| 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` |
259| `nobody` | No person's resolve alone closes a finding. A classifier can close its own findings |
258| A list of sets, each `{ if, from }` | Each set's `if` condition can read `finding/severity`, as in `{ if: "finding/severity >= high", from: acme/leads }`. When your conditions read only `finding/severity`, the first set whose condition is true decides. End with a set that omits the `if` key |
259| `nobody` | A person's resolve alone leaves the finding open. A classifier can close its own findings |
260260
261261To 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](#policy-files-in-subdirectories) for the file. For a resolve alone to count, every list that applies to that file has to admit the person who resolves.
262262
from line 292
292292Check what a local can hold and where you can use it:
293293
294294* **What a local holds**: text, a number, `true` or `false`, a list, or one map
295* **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"`.
296* **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.
295* **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, write it unquoted, as in `"pr/files_changed > @many"`.
296* **What the `use` key copies**: the `verdict`, `override`, `if`, `paths`, `reuse`, `advisory`, and `findings` keys. Values you set on the rule replace the copied ones: key by key inside `verdict`, `findings`, and a `reuse` map, and as a whole for any other key.
297297
298298## How rules combine into one verdict
299299
from line 314
314314
315315| Case | What happens |
316316| :- | :- |
317| No rule covers a changed file | Nobody is asked to review that file. A [protected file](#protected-files) can still need a person. Claude doesn't approve the pull request |
317| No rule covers a changed file | Approvals sets requirements for the covered files only, but can still require one person for a [protected file](#protected-files) |
318318| No rule covers any changed file | Normally no check appears. If 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 |
319319| Rules cover a changed file, and none applies | The check fails, with a title that starts **No rule applies to** |
320320| A file moves between a path that rules cover and one that they don't | Claude comments that Approvals did not run. If GitHub requires the check, you need permission to bypass that requirement to merge |
claude-ship Changed · +3 / -3 lines
from line 28
2828
2929### Code Review finds problems
3030
31[Code Review](https://code.claude.com/docs/en/code-review.md) reads a change alongside the surrounding code. Findings arrive as inline comments on the lines concerned, ranked by severity.
31[Code Review](https://code.claude.com/docs/en/code-review.md) reads a change alongside the surrounding code. It posts findings as inline comments on the affected lines, ranked by severity.
3232
3333### PR Steward pushes fixes
3434
from line 51
5151Turn on one agent at a time in one repository, in this order:
5252
53531. [Set up Code Review](https://code.claude.com/docs/en/code-review-setup.md)
542. [Set up PR Steward](https://code.claude.com/docs/en/pr-steward-setup.md). For the setting that chooses when PR Steward starts, begin with [**Manual (@claude steward)**](https://code.claude.com/docs/en/pr-steward-setup.md#choose-when-pr-steward-starts-in-each-repository). PR Steward has no spend limit of its own until you set one.
542. [Set up PR Steward](https://code.claude.com/docs/en/pr-steward-setup.md). At first, set the repository to [**Manual (@claude steward)**](https://code.claude.com/docs/en/pr-steward-setup.md#choose-when-pr-steward-starts-in-each-repository). PR Steward has no spend limit of its own until you set one.
55553. [Set up Claude Approvals](https://code.claude.com/docs/en/approvals-setup.md). A policy file in the repository starts it, so see [who can turn it on](https://code.claude.com/docs/en/approvals.md#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](https://code.claude.com/docs/en/approvals-setup.md#what-approvals-costs).
5656
5757### If you already use Code Review
from line 58
5858
5959Code Review's settings moved to [**Organization settings > Claude Ship**](https://claude.ai/admin-settings/claude-ship).
6060
61A 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](https://code.claude.com/docs/en/approvals-policy#advisory).
61Once `.claude/approvals.yml`, a Claude Approvals policy file, is on the default branch, automatic reviews normally stop on a pull request unless a matching rule names the `claude/code_review` [classifier](https://code.claude.com/docs/en/approvals-classifiers.md). That applies to enforced policies and in observe mode. To keep automatic reviews, [add the classifier to a rule](https://code.claude.com/docs/en/approvals-policy.md#advisory).
6262
6363## Plans and billing
6464
desktop Changed · +6 / -4 lines
This page is larger than the 256 KiB this site keeps, so one side of the diff below stops where the stored text does.
from line 366
366366
367367### Check usage
368368
369To see how full this session's context window is, find your Code tab layout:
369You can see how full this session's context window is in either Code tab layout:
370370
371371* **Current layout**: the header of the **Context** card in the [session details panel](#see-session-details) shows it as a percentage. Open the card to see what is using the window by category.
372372* **[Earlier layout](#check-which-layout-you-have)**: click the usage ring next to the model picker. Its popover shows your context window usage.
from line 497
497497* **As the default for a [saved local or SSH environment](#create-a-saved-environment)**: set **Worktree** when you create or edit the environment
498498* **[Earlier layout](#check-which-layout-you-have)**: select the **worktree** checkbox beside the branch name, above the prompt box
499499
500Worktrees are stored in `<project-root>/.claude/worktrees/` by default. To store them in a custom directory instead:
500Worktrees are stored in `<project-root>/.claude/worktrees/` by default. To store them in a custom directory instead, change the setting for your session type:
501501
502502* **Local sessions**: set **Worktree location** in **Settings > Code** or **Settings > Claude Code**
503503* **SSH sessions**: set **Worktree folder** on the [SSH connection](#choose-where-ssh-session-worktrees-go)
from line 2303
23032303| `permissions.disableBypassPermissionsMode` | set to `"disable"` to prevent users from enabling Bypass permissions mode. |
23042304| `disableAutoMode` | set to `"disable"` to remove [Auto](https://code.claude.com/docs/en/permission-modes.md#eliminate-prompts-with-auto-mode) mode from the mode selector. Also accepted under `permissions`. |
23052305| `autoMode` | customize what the auto mode classifier trusts and blocks across your organization. See [Configure auto mode](https://code.claude.com/docs/en/auto-mode-config.md). |
2306| `model` | set the model ID that [new local sessions start on](#set-the-model-that-new-sessions-start-on) |
2306| `model` | set a [starting model ID for new local sessions](#set-the-model-that-new-sessions-start-on) |
23072307| `browserExternalPageTools` | set to `"disabled"` to prevent Claude from using tools to read or act on external pages in the [Browser pane](#browse-external-sites). Users can still navigate to external sites themselves, and local dev server previews are unaffected. |
23082308| `disableMobileSimulatorTools` | set to `true` to block Claude's tools for controlling and capturing devices in the [iOS Simulator pane](https://code.claude.com/docs/en/desktop-ios-simulator.md#turn-off-simulator-access). The pane stays usable for the user's own taps; only Claude's access is removed. The value must be the JSON boolean `true`; the string `"true"` is ignored. |
23092309| `disableBrowserExternalNavigation` | set to `true` to turn off external browsing in the [Browser pane](#browse-external-sites) entirely. Users and Claude can't go to external sites, and localhost dev server previews are unaffected. HTML files that users open in Desktop's SSH and WSL sessions [don't run scripts](#turn-off-scripts-in-ssh-and-wsl-previews-for-your-organization). For the file pane, that requires Claude Desktop v7.37095.0 or later. The value must be the JSON boolean `true`; the string `"true"` is ignored. |
from line 2373
23732373
23742374If your [organization default model](https://code.claude.com/docs/en/model-config.md#organization-default-model) overrides user selection, these sessions start on that default when the user can select it, even though your `model` takes precedence in the terminal. To let users choose, also turn off **Always start with the default model and effort level** in [**Organization settings > Models**](https://claude.ai/admin-settings/models) and in each custom role with its own default.
23752375
2376With the override on, a local [scheduled task](https://code.claude.com/docs/en/desktop-scheduled-tasks.md) whose model is left on **Default** starts on your `model` value when it runs on schedule or from **Run now**. If your model isn't available to the user, or before Claude Desktop v5.9827.0, the task starts on the organization default, if they can select that. For a run that starts as the app opens, see [Create a scheduled task](https://code.claude.com/docs/en/desktop-scheduled-tasks.md#create-a-scheduled-task).
2377
23762378#### Deploy skills for all users
23772379
23782380To give every user the same skills in local and SSH sessions, deploy them as [enterprise skills](https://code.claude.com/docs/en/skills.md#where-skills-live), which you install once on a machine for all of its users. Install them on the machine where the session runs:
from line 2657
26552657
26562658### Check your version
26572659
2658To see which version of the desktop app you're running:
2660To see which version of the desktop app you're running, do the following:
26592661
26602662* **macOS**: click **Claude** in the menu bar, then **About Claude**
26612663* **Windows**: click **Help**, then **About Claude**
from line 2799
27972799
27982800* **`ssh` asks whether to continue connecting**: [compare](#check-a-remote-machines-host-key) the fingerprint that it shows with that machine's own. Answer `yes` only if they match.
27992801* **`ssh` warns that the host key has changed**: [compare](#check-a-remote-machines-host-key) the warning's fingerprint with that machine's own. Only if they match, delete the line that `Offending <type> key in <file>:<line>` names and rerun `ssh`. If `ssh` warns again about another line, compare, delete and rerun as before.
2800* **`ssh` refuses a key that it doesn't know, without asking**: get that machine's `known_hosts` line from whoever manages it, not over the connection that you're checking. Add the line to your `known_hosts` file, with the name from `ssh`'s message as its host name, and rerun `ssh`.
2801* **`ssh` goes on to sign in without asking you about the host key**: don't type a password yet. [Check the keys that `ssh` already trusts](#check-the-keys-that-ssh-already-trusts).
2802
2803Once `ssh` accepts a key that you checked or added, retry in Desktop. If Desktop refuses the key again, see [Get Desktop's logs for an SSH problem](#get-desktops-logs-for-an-ssh-problem).
2804
2805##### Check the keys that `ssh` already trusts
2806
2807Rerun the same `ssh` command with `-v -S none` added. In its output, a `Server host key:` line shows a fingerprint, a
2802* **`ssh` refuses a key that it doesn't know, without asking**: get that machine's `known_hosts` line from whoever manages it, not over the connection that you're checking. Add the line to your `known_hosts` file, with the name from `ssh`
errors Changed · +3 / -2 lines
This page is larger than the 256 KiB this site keeps, so one side of the diff below stops where the stored text does.
from line 587
587587| `Denying Bash also turns off the PowerShell tool, so Claude has neither` | [Configuration warnings](#denying-bash-also-turns-off-the-powershell-tool) |
588588| `CLAUDE_CODE_DISABLE_1M_CONTEXT is set, but the 200K limit isn't enforced` | [Configuration warnings](#the-200k-limit-isnt-enforced) |
589589| `CLAUDE_CODE_AUTO_COMPACT_WINDOW="<value>" reads as <N> tokens, so Claude Code treats it as the 100k minimum` | [Values and warnings for `CLAUDE_CODE_AUTO_COMPACT_WINDOW`](https://code.claude.com/docs/en/model-config#claude_code_auto_compact_window-values) |
590| `CLAUDE_CODE_AUTO_COMPACT_WINDOW="<value>" is too large, so Claude Code treats it as the 1M maximum` | [Values and warnings for `CLAUDE_CODE_AUTO_COMPACT_WINDOW`](https://code.claude.com/docs/en/model-config#claude_code_auto_compact_window-values) |
591590| `CLAUDE_CODE_AUTO_COMPACT_WINDOW="<value>" isn't a usable size, so Claude Code ignores it` | [Values and warnings for `CLAUDE_CODE_AUTO_COMPACT_WINDOW`](https://code.claude.com/docs/en/model-config#claude_code_auto_compact_window-values) |
592591| `Model "<model>" isn't recognized · context assumed to be <N> tokens` / `Claude Code doesn't recognize the model "<model>", so it assumes a context window of <N> tokens` | [Correct the window for a gateway or custom model ID](https://code.claude.com/docs/en/model-config.md#correct-the-window-for-a-gateway-or-custom-model-id) |
593592| `Model "<model>" isn't recognized · did you mean "<suggestion>"?` / `Claude Code doesn't recognize the model "<model>". Did you mean "<suggestion>"?` | [Fix a mistyped model name](https://code.claude.com/docs/en/model-config.md#fix-a-mistyped-model-name) |
from line 2366
23672366
23682367### The proxy refused the connection
23692368
2370You see this message when Claude reads an [artifact](https://code.claude.com/docs/en/
2369You see this message when Claude reads an [artifact](https://code.claude.com/docs/en/artifacts.md) through the proxy you set in `HTTPS_PROXY` or a related [proxy variable](https://code.claude.com/docs/en/network-config.md#environment-variables). Artifact content comes from `*.frame.claudeusercontent.com`, so Claude Code first sends the
managed-mcp Changed · +7 / -5 lines
from line 40
4040
4141## Exclusive control with managed-mcp.json
4242
43When you deploy a `managed-mcp.json` file, Claude Code loads only these MCP servers:
43When you deploy a `managed-mcp.json` file, the MCP servers that can still load include:
4444
4545* The servers the file defines
4646* Servers you [provide through `managedMcpServers`](#provide-servers-through-managed-settings)
from line 47
4747* In-process servers that the app that started the session registers, such as the VS Code extension's own server or the [connectors the desktop app delivers](https://code.claude.com/docs/en/mcp.md#how-connectors-reach-claude-code)
4848* The server that Claude Code creates when a [mod](https://code.claude.com/docs/en/plugins/mods/overview.md) [adds tools](https://code.claude.com/docs/en/plugins/mods/api.md#add-a-tool). To block the tools that your users' mods add, [stop user-installed mods from loading](https://code.claude.com/docs/en/plugins/mods/admin.md#stop-user-installed-mods-from-loading).
4949* The built-in [Claude in Chrome](https://code.claude.com/docs/en/chrome.md) server, if you [allow it alongside the managed set](#allow-claude-in-chrome-alongside-the-managed-set)
50* On a self-hosted runner with Claude Code v2.1.301 or later, the `claude-code-remote` server, with [only its repository tools](https://code.claude.com/docs/en/self-hosted-environments-configuration.md#turn-off-built-in-session-tools)
5051
51Users can't add, modify, or use any other MCP servers, including plugin-provided servers and servers passed with the [`--mcp-config` CLI flag](https://code.claude.com/docs/en/cli-reference#cli-flags). The file also suppresses the claude.ai connectors Claude Code fetches itself unless you [allow them alongside the managed set](#allow-claude-ai-connectors-alongside-the-managed-set).
52From their next launch, users can't use the servers in `.mcp.json` and `~/.claude.json` files or in [plugins](https://code.claude.com/docs/en/mcp.md#plugin-provided-mcp-servers). They also can't add servers with the [`--mcp-config` CLI flag](https://code.claude.com/docs/en/cli-reference#cli-flags). The file also suppresses the claude.ai connectors Claude Code fetches itself unless you [allow them alongside the managed set](#allow-claude-ai-connectors-alongside-the-managed-set).
5253
5354### Deploy managed-mcp.json
5455
from line 101
100101When a session receives servers through `--mcp-config` while a `managed-mcp.json` that Claude Code can read and parse is deployed, what the user sees differs between a workstation and a cloud session:
101102
102103* On a workstation, Claude Code exits at startup with `You cannot dynamically configure MCP servers when an enterprise MCP config is present`.
103* In [cloud sessions](https://code.claude.com/docs/en/claude-code-on-the-web.md) on a host where the file is deployed, such as a [self-hosted runner](https://code.claude.com/docs/en/self-hosted-environments-configuration.md#mcp-servers), Claude Code starts with the managed servers only and skips the claude.ai connectors and other servers the cloud host delivers through `--mcp-config`. Nothing in the session tells the user which servers were left out. Claude Code names them in a warning on its stderr, which a self-hosted runner records at the `debug` log level.
104* In [cloud sessions](https://code.claude.com/docs/en/claude-code-on-the-web.md) on a host with the file deployed, Claude Code skips the claude.ai connectors and other servers the cloud host delivers through `--mcp-config`, apart from [a few exceptions](#exclusive-control-with-managed-mcp-json). A [self-hosted runner](https://code.claude.com/docs/en/self-hosted-environments-configuration.md#mcp-servers) is one such host. Nothing in the session tells the user which servers Claude Code skipped. Claude Code names them in a warning on its stderr, which a self-hosted runner records at the `debug` log level.
104105
105106The `--strict-mcp-config` flag asks to replace the managed set. If a user passes it while such a file is deployed, Claude Code exits at startup on a workstation and in a cloud session alike.
106107
from line 365
364365
365366#### Servers that skip the allowlist check
366367
367Three groups of servers skip the allowlist check, in addition to the in-process `type: "sdk"` servers that skip [all three checks](#how-a-server-is-evaluated):
368Servers that skip the allowlist check include these groups, in addition to the in-process `type: "sdk"` servers that skip [all three checks](#how-a-server-is-evaluated):
368369
369370* The organization's own servers: every `managedMcpServers` entry, and any `managed-mcp.json` entry whose values use no `${VAR}` expansion outside `env`.
370371* 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.
371372* A [Claude Tag](https://code.claude.com/docs/en/claude-tag.md) session's Slack tools: the servers it uses to read the thread and post its replies load without an allowlist entry.
373* On a self-hosted runner, the `claude-code-remote` server, which loads with [only its repository tools](https://code.claude.com/docs/en/self-hosted-environments-configuration.md#turn-off-built-in-session-tools) when no entry matches it.
372374
373375A `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](#how-allowlists-and-denylists-apply-to-the-managed-set).
374376
managed-settings Changed · +5 / -3 lines
from line 83
8383 * **In a full VM sandbox**: when your Claude Desktop managed configuration sets [`requireCoworkFullVmSandbox`](https://claude.com/docs/third-party/claude-desktop/configuration#requirecoworkfullvmsandbox), Claude Code runs inside a virtual machine where the device's MDM policy and managed settings file aren't present.
8484 * **Remote Cowork sessions**: these run on Anthropic-managed VMs, where Claude Code has no device policy to read.
8585
86 Wherever the session runs, claude.ai applies the admin console's [`strictKnownMarketplaces`](https://code.claude.com/docs/en/settings-reference#strictknownmarketplaces) and [`blockedMarketplaces`](https://code.claude.com/docs/en/settings-reference#blockedmarketplaces) lists itself when anyone adds a marketplace from a git repository on claude.ai or from **Customize** in Cowork. [How restrictions work](https://code.claude.com/docs/en/plugins/org.md#restrict-what-users-can-install) describes that check. The [surface coverage](https://code.claude.com/docs/en/model-config.md#surface-coverage) table compares Cowork with the other surfaces.
86 In each case, claude.ai applies the admin console's [`strictKnownMarketplaces`](https://code.claude.com/docs/en/settings-reference#strictknownmarketplaces) and [`blockedMarketplaces`](https://code.claude.com/docs/en/settings-reference#blockedmarketplaces) lists when anyone adds a marketplace from a git repository on claude.ai or from Cowork's **Customize** or **Plugins** page. [How restrictions work](https://code.claude.com/docs/en/plugins/org.md#restrict-what-users-can-install) describes that check. The [surface coverage](https://code.claude.com/docs/en/model-config.md#surface-coverage) table compares Cowork with the other surfaces.
8787* **Running sessions**: most changes reach a running session on the schedule in the [delivery mechanism table](#choose-a-delivery-mechanism), without a restart.
8888 * Changes to [`forceRemoteSettingsRefresh`](https://code.claude.com/docs/en/settings-reference#forceremotesettingsrefresh), [`requiredMinimumVersion`](https://code.claude.com/docs/en/settings-reference#requiredminimumversion), and [some user-editable keys](https://code.claude.com/docs/en/settings.md#when-edits-take-effect) take effect at the next session start.
8989 * A new or changed [`policyHelper`](https://code.claude.com/docs/en/settings-reference#policyhelper) entry takes effect at the next launch. If server-managed settings shadow the helper at that launch, the helper runs as soon as a fetch reports those settings removed.
from line 207
207207
208208Under `"merge"`, Claude Code adds a lower source's list entries, such as `permissions.allow` rules and hooks, to the policy, so turn it on only when every source ranked below your highest one is under an administrator's control.
209209
210This table shows how Claude Code combines each kind of key under `"merge"`. The [`managedSourcesBehavior` entry](https://code.claude.com/docs/en/settings-reference#managedsourcesbehavior) names every key in three of the rows: restriction allowlists, values taken whole, and keys read from the highest-ranked source only.
210This table shows how Claude Code combines keys under `"merge"`:
211211
212212| Kind of key | How Claude Code combines it | Examples |
213213| :- | :- | :- |
from line 219
219219| Keys read from the highest-ranked source only | Ignores the key in every lower source, even when the highest-ranked source leaves it unset | `modelPicker`, `permissions.defaultMode`, and credential helpers such as `apiKeyHelper` |
220220| `env` | Merges per variable across admin sources under either setting, as [Keys read from every admin source](#keys-read-from-every-admin-source) describes | |
221221| Login keys | Under either setting, takes them from the MDM policy or managed settings file, whichever is the higher-ranked one carrying a [policy key](#how-claude-code-combines-managed-sources), [ahead of remote settings](#which-managed-source-supplies-login-keys) | `forceLoginOrgUUID`, `forceLoginMethod`, and the [gateway login keys](#choose-a-delivery-mechanism) |
222| Every other key | Takes the value from the highest-ranked source that sets it | `model`, `cleanupPeriodDays` |
222| Other strings, numbers, and Booleans | Takes the value from the highest-ranked source that sets it | `model`, `cleanupPeriodDays` |
223
224The [`managedSourcesBehavior` entry](https://code.claude.com/docs/en/settings-reference#managedsourcesbehavior) names every restriction allowlist key.
223225
224226To confirm which sources combined on a machine, [read the `Setting sources` line in `/status`](#read-the-source-in-/status); that section says what each label means.
225227
mcp Changed · +5 / -5 lines
from line 477
477477
478478The per-call limits still apply while the call runs in the background: the wall-clock limit set by the per-server `timeout` or [`MCP_TOOL_TIMEOUT`](https://code.claude.com/docs/en/env-vars), and the idle timeout set by [`CLAUDE_CODE_MCP_TOOL_IDLE_TIMEOUT`](https://code.claude.com/docs/en/env-vars).
479479
480To change or turn off automatic backgrounding:
480You can change or turn off automatic backgrounding with these environment variables:
481481
482482* Set the [`CLAUDE_CODE_MCP_AUTO_BACKGROUND_MS`](https://code.claude.com/docs/en/env-vars) environment variable in milliseconds to change the threshold, or set it to `0` to turn automatic backgrounding off. With `0`, Claude also [waits for MCP tasks](#make-claude-wait-for-the-result-of-an-mcp-task) in an interactive terminal session
483483* Set [`CLAUDE_CODE_DISABLE_BACKGROUND_TASKS`](https://code.claude.com/docs/en/env-vars) to `1` to turn off automatic backgrounding and [background commands](https://code.claude.com/docs/en/tools-reference.md#background-commands)
from line 621
621621
622622If a task's result hasn't arrived in a cloud session or chat, send a message so Claude Code checks the task again. You can leave while a task runs. When it completes or fails, Claude usually picks up the result unprompted, even in a session that stopped for inactivity.
623623
624If Claude reports one of these problems with the task, take the step that matches its report:
624These are the next steps when Claude reports a problem with the task:
625625
626626* **The task was cancelled because it asked you a question**: you [can't answer](#mcp-task-questions-in-the-cloud) in that session or chat, so start the task again from an interactive terminal session
627627* **Tracking stopped after failed status checks**: the job can still be running, so ask Claude to check it again. If no result follows, ask Claude to find the outcome with the server's other tools
from line 1611
16111611}
16121612```
16131613
1614This setting uses any-source-true semantics: `true` in any settings source takes precedence. A checked-in project `.claude/settings.json` can opt a repository out of the connectors Claude Code fetches itself, but a project-level `false` can't re-enable connectors that a user- or policy-level `true` has disabled. Servers passed explicitly via `--mcp-config` are unaffected.
1614This setting uses any-source-true semantics: `true` in any settings source takes precedence, so a project-level `false` can't re-enable connectors that a user- or policy-level `true` has disabled. Servers passed explicitly via `--mcp-config` are unaffected.
16151615
16161616You can also set the `ENABLE_CLAUDEAI_MCP_SERVERS` environment variable to `false`, which has the same effect for the current shell session:
16171617
from line 1968
19681968Anthropic scans skills from some connectors, with [exceptions and limitations](#limitations-of-mcp-skills). For these connectors, a version loads only after it passes the scan:
19691969
19701970* Third-party [Directory](https://claude.ai/directory) connectors you add on claude.ai
1971* Custom connectors, while your Enterprise organization keeps **Skill and plugin security scanning** on in [**Organization settings > Plugins & skills > Policy**](https://claude.ai/admin-settings/skills?tab=policy)
1971* Custom connectors, while your Enterprise organization keeps the **Skill and plugin security scanning** setting on in [**Organization settings > Plugins & skills > Policy**](https://claude.ai/admin-settings/skills?tab=policy). In the newer layout, the setting is **Plugin security scanning** in **Organization settings > Policy**
19721972
19731973Anthropic doesn't scan skills from other connectors or servers, including Directory servers added with `claude mcp add`.
19741974
from line 2005
20052005
20062006To turn on MCP skills for Team or Enterprise members who sign in with `/login`:
20072007
2008* **Connectors**: an [Owner](https://code.claude.com/docs/en/server-managed-settings.md#access-control) turns on **Skills over MCP** in [**Organization settings > Connectors**](https://claude.ai/admin-settings/connectors). Your organization's [**Skills** setting](https://claude.ai/admin-settings/skills?tab=policy) must also be on.
2008* **Connectors**: an [Owner](https://code.claude.com/docs/en/server-managed-settings.md#access-control) turns on the **Skills over MCP** setting in [**Organization settings > Connectors**](https://claude.ai/admin-settings/connectors). Your organization's [**Skills** setting](https://claude.ai/admin-settings/skills?tab=policy) must also be on. In the newer layout, the **Skills** setting is the **Plugins** setting in **Organization settings > Policy**.
20092009* **Other servers**: set [`disableDirectMcpSkills`](https://code.claude.com/docs/en/settings-reference#disabledirectmcpskills) to `false` in [managed settings](https://code.claude.com/docs/en/managed-settings.md), in the highest-ranked [admin source](https://code.claude.com/docs/en/managed-settings.md#how-claude-code-combines-managed-sources) you use
20102010
20112011> [!WARNING]
plugins/mods/troubleshoot Changed · +3 / -3 lines
from line 39
3939
4040Nothing the mod adds appears, and the [`mods active` line](https://code.claude.com/docs/en/plugins/mods/overview#see-which-mods-a-session-loaded) in `/plugin` doesn't name it. The hooks module didn't load. When Claude Code refused it, the debug log has a line that starts with `hooks module`, the mod's name, and `not loaded:`, as in `hooks module first-mod@inline not loaded: disableAllHooks in managed settings` for a mod loaded with `--plugin-dir`.
4141
42Read the reason after the colon. The [refusal messages](#refusal-messages) section lists each one. If the log has no such line, work through the other entries in this group.
42In the debug log, find the text that follows `not loaded:` and look it up in [Refusal messages](#refusal-messages). If the debug log has no `not loaded:` line for your mod, work through the other entries under [The mod doesn't load](#the-mod-doesn’t-load).
4343
4444Some settings stop a mod and leave the rest of its plugin working. [Turn mods on or off](https://code.claude.com/docs/en/plugins/mods/overview.md#turn-mods-on-or-off) names them.
4545
from line 47
4747
4848The line starts with the mod's name and goes to stderr. The hooks module was refused. A non-interactive run has no transcript, so the message goes to stderr.
4949
50Read the reason after the colon. The [refusal messages](#refusal-messages) section lists each one.
50Find the text that follows `not loaded:` in the message and look it up in [Refusal messages](#refusal-messages).
5151
5252### Refusal messages
5353
from line 273
273273
274274### `needs a key`, `is drawn twice`, or `key each once`
275275
276An element in the tree your `ui.render` hook returns has no valid [`key`](https://code.claude.com/docs/en/plugins/mods/interface#which-controls-need-a-key), or two elements share one. Find the message you got:
276An element in the tree your `ui.render` hook returns has no valid [`key`](https://code.claude.com/docs/en/plugins/mods/interface#which-controls-need-a-key), or two elements share one. The following messages each have a fix:
277277
278278* **`<Input> needs a key` or `<Select> needs a key`**: the element has no `key` prop, or its `key` is empty or isn't a string, as in `key: 3`. Give it a non-empty string as its `key`.
279279* **`<Button> needs a key`**: give the button a non-empty string as its `key`
plugins/org Changed · +3 / -3 lines
from line 13
1313> * **Installing plugins for yourself**: start at [Install plugins](https://code.claude.com/docs/en/plugins/install.md)
1414> * **Controlling which plugins members can use in claude.ai and Cowork**: see [Manage plugins for your organization](https://claude.com/docs/plugins/admin) on claude.com
1515> * **Rolling one plugin out to claude.ai, Cowork, and Claude Code together**: see [Choose a rollout route](https://claude.com/docs/plugins/org-rollout#choose-a-rollout-route) on claude.com
16> * **The plugins page in claude.ai's admin settings**: [**Organization settings > Plugins & skills**](https://claude.ai/admin-settings/skills?tab=inventory) turns plugins on for members' claude.ai accounts, and those reach Claude Code as [synced plugins](https://code.claude.com/docs/en/plugins/loading.md#synced-plugins). It doesn't set any of the keys on this page
16> * **The plugins page in claude.ai's admin settings**: you turn plugins on for members' claude.ai accounts at [**Organization settings > Plugins & skills**](https://claude.ai/admin-settings/skills?tab=inventory), or the **Plugins** page in the newer layout. Those plugins reach Claude Code as [synced plugins](https://code.claude.com/docs/en/plugins/loading.md#synced-plugins)
1717
1818The sections follow the order most rollouts take: [require plugins](#pre-install-and-require-plugins) for everyone or per repository, [seed containers and CI](#seed-containers-and-ci), [restrict](#restrict-what-users-can-install) what users can add on their own, [set update policy](#set-update-policy), then [audit](#audit-and-review) what's installed. To review every policy key in one place, see the [control matrix](#control-matrix).
1919
from line 164
164164
165165Where the two lists are enforced depends on where you set them:
166166
167* **The claude.ai admin console**: Claude Code enforces both lists in the sessions that [read server-managed settings](https://code.claude.com/docs/en/managed-settings.md#where-and-when-a-policy-applies). claude.ai also checks them when anyone in your organization adds a marketplace from a git repository on claude.ai, or from **Customize** in the Desktop app outside its Code tab.
167* **The claude.ai admin console**: Claude Code enforces both lists in the sessions that [read server-managed settings](https://code.claude.com/docs/en/managed-settings.md#where-and-when-a-policy-applies). claude.ai checks them when anyone in your organization adds a marketplace from a git repository on claude.ai, or from the Desktop app's **Customize** or **Plugins** page outside the Code tab.
168168
169169 That covers a marketplace a member adds for their own account and one added for the whole organization under [**Organization settings > Plugins & skills**](https://claude.ai/admin-settings/skills?tab=marketplaces). claude.ai refuses a repository that the allowlist doesn't admit or that the blocklist names. It doesn't re-check a marketplace that was added in either place before you set the lists, and it doesn't check uploaded plugins.
170170* **A managed settings file, OS-level policy, or other managed source**: Claude Code enforces both lists where it reads that source. claude.ai doesn't read it.
from line 389
389389* **Restricting entries inside an allowed marketplace**: the allowlist matches marketplace sources. To block one plugin from an allowed marketplace, set it to `false` in managed `enabledPlugins`.
390390* **Hiding `/plugin`**: no key disables the command. The nearest equivalent combines an allowlist naming only your marketplace, managed `enabledPlugins` entries for the plugins you supply, and `disableSideloadFlags`.
391391* **Gating `--plugin-dir` through the allowlist**: the allowlist doesn't cover `--plugin-dir`. `disableSideloadFlags` does.
392* **Enforcing the claude.ai plugin toggles through these keys**: [**Organization settings > Plugins & skills**](https://claude.ai/admin-settings/skills?tab=inventory) doesn't set the keys on this page. What members and your organization turn on there reaches the CLI as [synced plugins](https://code.claude.com/docs/en/plugins/loading.md#synced-plugins), which have their own controls.
392* **Enforcing the claude.ai plugin toggles through these keys**: you can't set the keys on this page from [**Organization settings > Plugins & skills**](https://claude.ai/admin-settings/skills?tab=inventory), or the **Plugins** page in the newer layout. What members and your organization turn on in claude.ai reaches the CLI as [synced plugins](https://code.claude.com/docs/en/plugins/loading.md#synced-plugins), which have their own controls.
393393
394394## Troubleshoot policy
395395
pr-steward Changed · +3 / -3 lines
from line 6
66
77> [!TIP]
88>
9> To turn on PR Steward, follow [Set up PR Steward](https://code.claude.com/docs/en/pr-steward-setup.md), which takes an Owner role in your Claude organization.
9> To turn on PR Steward, follow [Set up PR Steward](https://code.claude.com/docs/en/pr-steward-setup.md), which requires an Owner role in your Claude organization.
1010
1111PR Steward picks up a problem on GitHub, works on it in a cloud session, and reports back on the pull request:
1212
from line 24
2424
2525In 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.
2626
27PR 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](https://code.claude.com/docs/en/pr-steward-setup.md#choose-when-pr-steward-starts-in-each-repository) so that PR Steward includes drafts, or normally starts only when someone asks it to.
27PR Steward skips drafts, pull requests from forks, and pull requests opened by a bot or by someone without write access to the repository. An Owner can [change the repository's setting](https://code.claude.com/docs/en/pr-steward-setup.md#choose-when-pr-steward-starts-in-each-repository) so that PR Steward includes drafts, or normally starts only when someone asks it to.
2828
2929### What PR Steward fixes
3030
from line 62
6262
6363## Next steps
6464
65* [Set up PR Steward](https://code.claude.com/docs/en/pr-steward-setup.md), which takes an Owner
65* [Set up PR Steward](https://code.claude.com/docs/en/pr-steward-setup.md), which requires an Owner role
6666* [Work with PR Steward](https://code.claude.com/docs/en/pr-steward-pull-requests.md) on your pull requests
6767* [What PR Steward can access](https://code.claude.com/docs/en/pr-steward-security.md)
6868* [Troubleshoot PR Steward](https://code.claude.com/docs/en/pr-steward-troubleshooting.md)
self-hosted-environments-configuration Changed · +12 / -2 lines
from line 195
195195
196196Typical uses are pushing a snapshot branch of uncommitted changes, archiving logs, or emitting a session-ended event to your own systems.
197197
198The hook fires on every session end where a child process was spawned, whatever the cause; the `CLAUDE_RUNNER_EXIT_REASON` values below enumerate the cases. It can't fire when the runner terminates abruptly, such as a VM preemption or a power loss; if you need guarantees against abrupt termination, snapshot periodically from inside the session with a Claude Code `PostToolUse` hook instead. The runner sets:
198The hook fires when a session that spawned a child process ends; the `CLAUDE_RUNNER_EXIT_REASON` values below enumerate the cases. It can't fire when the runner terminates abruptly, such as a VM preemption or a power loss. If you need guarantees against abrupt termination, snapshot periodically from inside the session with a Claude Code `PostToolUse` hook instead.
199199
200Your hook can read these variables, which the runner sets:
201
200202| Variable | Description |
201203| :- | :- |
202204| `CLAUDE_RUNNER_SESSION_ID` | Session ID in the tagged `session_...` form |
from line 637
635637
636638Claude Code also loads MCP servers from other sources:
637639
638* The enterprise-scope [managed MCP file](https://code.claude.com/docs/en/managed-mcp.md) at its standard system path: `/etc/claude-code/managed-mcp.json` on Linux runner hosts, `/Library/Application Support/ClaudeCode/managed-mcp.json` on macOS hosts. Use it for locked-down fleets where only administrator-listed servers may load. See [exclusive control with managed-mcp.json](https://code.claude.com/docs/en/managed-mcp.md#exclusive-control-with-managed-mcp-json) for the precedence rules. When this file is on the runner host, Claude Code skips the MCP servers Anthropic's control plane delivers to a session, including claude.ai connectors, and names them in a warning on the session child's stderr, which the runner records at the `debug` log level. Before v2.1.229, those sessions exited at startup with `You cannot dynamically configure MCP servers when an enterprise MCP config is present`.
640* The enterprise-scope [managed MCP file](https://code.claude.com/docs/en/managed-mcp.md) at its standard system path: `/etc/claude-code/managed-mcp.json` on Linux runner hosts, `/Library/Application Support/ClaudeCode/managed-mcp.json` on macOS hosts. See [exclusive control with managed-mcp.json](https://code.claude.com/docs/en/managed-mcp.md#exclusive-control-with-managed-mcp-json) for the precedence rules.
641
642 When this file is on the runner host, Claude Code skips the MCP servers Anthropic's control plane delivers, including claude.ai connectors, apart from [a few exceptions](https://code.claude.com/docs/en/managed-mcp.md#exclusive-control-with-managed-mcp-json). To see which it skipped, look for a warning on the session child's stderr, which the runner records at the `debug` log level.
643
644 Before v2.1.229, those sessions exited at startup with `You cannot dynamically configure MCP servers when an enterprise MCP config is present`.
639645* The [`managedMcpServers`](https://code.claude.com/docs/en/settings-reference#managedmcpservers) key in [managed settings](https://code.claude.com/docs/en/managed-settings.md) on the runner host: provides HTTP and SSE servers without taking exclusive control, so servers from the other sources still load. Requires Claude Code v2.1.259 or later.
640646* `<repo>/.mcp.json`: project scope. Outside a [project](https://code.claude.com/docs/en/claude-projects.md#what-threads-pick-up-from-your-repositories) thread, commit the file to the repository, and its servers are auto-approved in cloud sessions. In a session with several repositories, [at most one repository's file loads](#repository-settings-in-sessions-with-several-repositories). With [`--trust-workspace false`](https://code.claude.com/docs/en/self-hosted-environments-reference#runner-cli-flags), sessions skip the file's servers unless settings the repository doesn't commit approve them, such as [`enabledMcpjsonServers`](https://code.claude.com/docs/en/settings-reference#enabledmcpjsonservers) in the host's `~/.claude/settings.json`. Requires Claude Code v2.1.319 or later.
641647* A [`--mcp-config`](https://code.claude.com/docs/en/cli-reference#cli-flags) file from your wrapper script: append the flag after `"$@"`, as in `exec "$CLAUDE_RUNNER_CLAUDE_BIN" "$@" --mcp-config /etc/claude/mcp.json`. To keep that file's servers running when the session's delivered servers are updated mid-session, have your wrapper pass the [full environment](#wrapper-scripts) to the child, as `exec` does. Before v2.1.299, the stdio, HTTP, and SSE servers in that file shut down at the first such update that didn't name them.
from line 694
688694Put the rules in [server-managed settings](https://code.claude.com/docs/en/server-managed-settings.md) to reach sessions with no change to the runner, or in `~/.claude/settings.json` on the runner. On a runner that [sends model requests to Bedrock or Agent Platform](#send-model-requests-to-bedrock-or-agent-platform), use that file, because server-managed settings don't reach those sessions. [Permissions and tool approval](#permissions-and-tool-approval) explains how settings on the runner reach sessions.
689695
690696To confirm the rules took effect, start a session on the environment and ask Claude to list its MCP tools. Claude Code removes a denied tool from Claude's context, so the denied tools are absent from its answer.
697
698> [!NOTE]
699>
700> If you block the `claude-code-remote` server with a `managed-mcp.json` file, the `disableSideloadFlags` setting, or an `allowedMcpServers` list, new sessions still load its repository tools. These can include `add_repo`, `check_repo_access`, `list_repos`, and `register_repo_root`. To remove them, add the deny rules in this section. Requires Claude Code v2.1.301 or later.
691701
692702## Prompt sessions to push their work
693703
self-hosted-environments-reference Changed · +2 / -4 lines
from line 434
434434
435435Before v2.1.260, the runner terminated every session that reached its `--kill-session-after-min` limit and counted it in `sessions_interrupted_total`.
436436
437The [`post-session` hook](https://code.claude.com/docs/en/self-hosted-environments-configuration#post-session)'s `CLAUDE_RUNNER_EXIT_REASON` classifies clean handoffs differently. The hook reports these as `interrupted`, because the runner stopped the child: a release, a startup timeout, a server deassign, and an archive or delete that the poll noticed first. These counters record the same events as `completed`, because the slot was handed back cleanly.
437The [`post-session` hook](https://code.claude.com/docs/en/self-hosted-environments-configuration#post-session)'s `CLAUDE_RUNNER_EXIT_REASON` variable classifies clean handoffs differently from these counters. The hook reports these as `interrupted`, because the runner stopped the child: a release, a startup timeout, a server deassign, and an archive or delete that the poll noticed first. These counters record the same events as `completed`, because the slot was handed back cleanly. If you reconcile hook receipts against `sessions_completed_total` directly, you undercount completions.
438438
439If you reconcile hook receipts against `sessions_completed_total` directly, you undercount completions. Use the hook for per-session guarantees and the counters for aggregate rates.
440
441439On a one-shot environment, `--capacity 1` with the default `--drain-grace-sec 0`, each runner process exits moments after its one session ends. `sessions_completed_total`, `sessions_failed_total`, and `sessions_interrupted_total` increment only at session end, right before that exit, so a Prometheus scrape every 15 to 60 seconds rarely catches the increment before the runner's series disappears; these three end-of-session counters are the terminal counters the rest of this section refers to. `sessions_started_total` increments at spawn and stays visible for the life of the session, so it reliably shows up, but on a one-shot environment it reads closer to "sessions currently running" than a cumulative count.
442440
443441Use the series in this table for the corresponding goal instead of the terminal counters:
from line 449
451449
452450The `orchestrator_*` rows exist only on environments running the [on-demand orchestrator](https://code.claude.com/docs/en/self-hosted-environments-configuration.md#on-demand-runners). On a fixed fleet whose runners outlive their sessions, with `--drain-grace-sec` above `0`, use `sum(rate(claude_code_self_hosted_runner_sessions_started_total[5m]))` for throughput; on a one-shot fleet that series has the same scrape-window problem as the terminal counters, so rely on the queued-sessions count instead. Check backlog on the environment's **Activity** tab, on the [**Cloud environments** admin page](https://claude.ai/admin-settings/cloud-environments): the runners don't export a queue-depth series.
453451
454For per-session outcome reporting, use the [`post-session` hook](https://code.claude.com/docs/en/self-hosted-environments-configuration#post-session) instead: it fires at every session end where a child process was spawned, apart from abrupt runner termination such as a VM preemption, per the [hook's own contract](https://code.claude.com/docs/en/self-hosted-environments-configuration.md#post-session).
452To report a session's outcome, use the [`post-session` hook](https://code.claude.com/docs/en/self-hosted-environments-configuration#post-session) instead of the session lifecycle counters.
455453
456454## What's next
457455
settings-reference Changed · +33 / -12 lines
### `disableWindowsBashCommandSplit`
This page is larger than the 256 KiB this site keeps, so one side of the diff below stops where the stored text does.
from line 88
8888| [`disableRemotePreviewScripts`](#disableremotepreviewscripts) | Turn off scripts in HTML files that people open in the [desktop](https://code.claude.com/docs/en/desktop.md#preview-html-files-in-ssh-and-wsl-sessions) app's SSH and WSL sessions | Remote, desktop, and notifications | Managed |
8989| [`disableSideloadFlags`](#disablesideloadflags) | Reject the CLI flags that sideload [plugins](https://code.claude.com/docs/en/plugins/overview.md), [subagents](https://code.claude.com/docs/en/sub-agents.md), and [MCP servers](https://code.claude.com/docs/en/mcp.md) | Enterprise and managed settings | Managed |
9090| [`disableSkillShellExecution`](#disableskillshellexecution) | Stop [skills](https://code.claude.com/docs/en/skills.md) and custom commands from running inline shell | Plugins and skills | Any file |
91| [`disableWindowsBashCommandSplit`](#disablewindowsbashcommandsplit) | On Windows, stop Claude Code from splitting a long [Bash command](https://code.claude.com/docs/en/tools-reference.md#bash-tool-behavior) into multiple arguments | Enterprise and managed settings | Managed |
9192| [`disableWorkflows`](#disableworkflows) | Turn [dynamic workflows](https://code.claude.com/docs/en/workflows.md) off for everyone; use `enableWorkflows` for yourself | Hooks and automation | Any file |
9293| [`editorMode`](#editormode) | Use [vim key bindings](https://code.claude.com/docs/en/interactive-mode.md#vim-editor-mode) in the input prompt | Interface and terminal | Any file |
9394| [`effortLevel`](#effortlevel) | Set a default [effort level](https://code.claude.com/docs/en/model-config.md#adjust-effort-level) for models without a saved level of their own | Model and responses | Any file |
from line 3302
33013302Show the times in the interface in a time zone other than your system's. Set it to an [IANA time zone name](https://www.iana.org/time-zones), such as `"UTC"` or `"Europe/Dublin"`. The times that [`timeFormat`](#timeformat) controls then show in this zone. If `timeFormat` is `"24-hour-utc"`, times stay in UTC and Claude Code ignores this key. `/config` has no row for this key, so set it in a settings file. Requires Claude Code v2.1.257 or later.
33023303
33033304* **Scope**: [`Any file`](#scopes)
3304* **Type**: string, an IANA time zone name. When Claude Code doesn't recognize the name, it uses your system time zone
3305* **Default**: unset, so times show in your system time zone
3306
3307```json settings.json theme={null}
3308{
3309 "timeZone": "Europe/Dublin"
3310}
3311```
3312
3313### `tui`
3314
3315Choose the terminal UI renderer. Use `"fullscreen"` for the flicker-free [alt-screen renderer](https://code.claude.com/docs/en/ful
3305* **Type**: string, an IANA time zone name. When Claude Code doesn't recognize the name, it uses your system time zon
skills Changed · +6 / -2 lines
from line 180
180180
181181Skills in a `.claude/skills/` directory below where you started don't load at startup. They load the first time Claude reads or edits a file in that subdirectory and stay available for the rest of the session. Until then they don't appear in the `/` menu and you can't invoke them by name. To load them sooner, run `/add-dir` with the subdirectory's path, which requires Claude Code v2.1.257 or later. For a worktree session that you start from the desktop app, see [What worktrees share with the main checkout](https://code.claude.com/docs/en/worktrees.md#what-worktrees-share-with-the-main-checkout).
182182
183> [!NOTE]
184>
185> While the [sandbox](https://code.claude.com/docs/en/sandboxing.md) is on, and until you restart after turning it off, nested skills don't load when Claude works on files in their subdirectory. To use them, start Claude Code in the subdirectory or run `/cd` with its path.
186
183187When a nested skill's directory name matches another skill's name, both stay available. With a `deploy` skill at the repository root and another in `apps/web/.claude/skills/`:
184188
185189* `/deploy` runs the root skill. Claude Code also lists the directory-qualified variants for Claude, with an instruction to invoke the one whose directory holds the files it's working on, so the nested skill still applies to work in `apps/web/`.
from line 227
223227
224228[Cowork](https://claude.com/product/cowork) sessions and [cloud sessions](https://code.claude.com/docs/en/cloud-environments.md#what-carries-over-from-your-setup), including [cloud scheduled tasks](https://code.claude.com/docs/en/routines.md), don't read `~/.claude/skills/` on your machine. Both interactive and scheduled Cowork sessions load the skills enabled for your claude.ai account, synced at session start. Manage those skills at [claude.ai/customize/skills/yours](https://claude.ai/customize/skills/yours).
225229
226If a skill exists only in `~/.claude/skills/` on your machine, Claude Code reports that the skill was not found when a [cloud scheduled task](https://code.claude.com/docs/en/routines.md) invokes it. This happens because each run starts as a fresh cloud session. To make a personal skill available in these sessions:
230If a skill exists only in `~/.claude/skills/` on your machine, Claude Code reports that the skill was not found when a [cloud scheduled task](https://code.claude.com/docs/en/routines.md) invokes it. This happens because each run starts as a fresh cloud session. You can make a personal skill available in these sessions through your claude.ai account or the repository:
227231
228232* For Cowork sessions, cloud sessions, and cloud threads in a [project](https://code.claude.com/docs/en/claude-projects.md#what-threads-pick-up-from-your-repositories), enable the skill for your claude.ai account. [Some sessions in a self-hosted environment](https://code.claude.com/docs/en/self-hosted-environments-configuration.md#how-each-session’s-config-is-assembled) don't load your account's skills.
229233* For cloud sessions, you can instead commit the skill to the repository's `.claude/skills/`. For a project, check [which threads load it](https://code.claude.com/docs/en/claude-projects.md#what-threads-pick-up-from-your-repositories). Plugins enabled only in your user settings [don't load in cloud sessions](https://code.claude.com/docs/en/cloud-environments.md#what-carries-over-from-your-setup).
from line 1069
10651069
10661070### Claude stops following a skill
10671071
1068If Claude follows a skill in its first response and stops following it later, start with whichever of these cases matches:
1072When Claude follows a skill in its first response and stops following it later, the fix depends on what it skipped or whether the conversation was compacted:
10691073
10701074* **Claude skipped a rule that must hold every time**: move the rule into a [hook](https://code.claude.com/docs/en/hooks-guide.md) in a [settings file](https://code.claude.com/docs/en/hooks.md#hook-locations) or a plugin's `hooks/hooks.json`. Claude Code runs that hook when its event occurs, such as before a file edit, whether or not Claude is following the skill.
10711075* **Claude skipped guidance it should apply with judgment**: word the guidance so it applies to the whole task, for example "Run the tests after every edit" rather than "Run the tests". Claude Code adds the skill's content to the conversation when the skill is invoked and [doesn't re-read the file](#skill-content-lifecycle) on later turns.
vs-code Changed · +6 / -6 lines
from line 72
7272
7373**2. Sign in**
7474
75The first time you open the panel, a sign-in screen appears. Click **Sign in** and complete authorization in your browser.
75The first time you open the panel, a sign-in screen appears. Choose a sign-in method and complete authorization in your browser.
7676
77To use your Console account [without creating an API key](https://code.claude.com/docs/en/authentication.md#sign-in-without-an-api-key), select the **Anthropic Console (no API key)** button if the sign-in screen offers it. Requires Claude Code v2.1.324 or later.
78
7779If you see **Not logged in · Please run /login** later, the extension reopens the sign-in screen automatically. If it doesn't appear, reload the window from the Command Palette with **Developer: Reload Window**.
7880
7981If you have `ANTHROPIC_API_KEY` set in your shell but still see the sign-in prompt, VS Code may not have inherited your shell environment. Launch VS Code from a terminal with `code .` so it inherits your environment variables, or sign in with your Claude account instead.
from line 292
290292
291293By default, a session with no activity for 14 days moves to **Archived sessions** automatically, unless it is open, unread, or in a [group](#organize-sessions-into-groups). Automatic archiving requires Claude Code v2.1.265 or later. To change the period or turn it off, open the [Archive Inactive Sessions setting](vscode://settings/claudeCode.archiveInactiveSessions) and select a number of days or **Never**.
292294
293To restore archived sessions:
295You can restore one archived session or all of them at once:
294296
295297* **One session**: expand **Archived sessions** and click **Unarchive session**.
296298* **Every archived session at once**: hover over the **Archived sessions** header in the sessions list in the Activity Bar and click its unarchive icon. Requires Claude Code v2.1.277 or later.
from line 841
839841
840842While Claude works, your screen reader reads a text label in place of the progress spinner's animation.
841843
842When you reopen a session or switch to another one, the extension announces nothing: restored history, pending permission prompts, and in-progress status stay silent until something new happens.
843
844844### Use the chat panel from the keyboard
845845
846846Each turn in the transcript starts with a visually hidden heading labeled with the prompt that started the turn. Use your screen reader's heading navigation to jump between turns.
from line 854
854854
855855Because 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](#vs-code-commands-and-shortcuts).
856856
857When 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:
857When 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". You can change the destination with the keyboard or a click:
858858
859859* 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.
860860* Click the destination in the label.
from line 1040
10401040}
10411041```
10421042
1043The file goes in your Claude Code configuration directory, which is `~/.claude` unless you moved it with `CLAUDE_CONFIG_DIR`. Look in that directory and take the step that matches what you find:
1043The file goes in your Claude Code configuration directory, which is `~/.claude` unless you moved it with `CLAUDE_CONFIG_DIR`. Create the file there, or update the file you already have:
10441044
10451045* **No `keybindings.json` yet**: create it with exactly the content of the example
10461046* **A `keybindings.json` with no `Chat` block**: add the example's `Chat` block to the top-level `bindings` array, at any position
workflows Changed · +3 / -3 lines
from line 430
430430* `agent lost its reply on all 6 attempts`: every attempt's response stream went silent and Claude Code gave up waiting on it. Lengthening the stall window doesn't help, since a [streaming idle watchdog](https://code.claude.com/docs/en/network-config.md#streaming-idle-watchdogs) ended the response first and `CLAUDE_STREAM_IDLE_TIMEOUT_MS` sets that watchdog's timeout
431431* `agent abandoned after 6 attempts`: the attempts ended in different ways, which the error lists in order
432432
433To give an agent more time to produce output before the window ends:
433You can give one agent or every agent more time to produce output before the window ends:
434434
435435* **One agent**: pass `stallMs` in milliseconds on its `agent()` call, such as `agent(prompt, { stallMs: 1800000 })` for 30 minutes
436436* **Every agent**: set [`CLAUDE_ASYNC_AGENT_STALL_TIMEOUT_MS`](https://code.claude.com/docs/en/env-vars#variables), which also applies to subagents outside workflows
from line 457
457457
458458Claude Code picks each workflow agent's model in the same [order it uses for subagents](https://code.claude.com/docs/en/sub-agents.md#choose-a-model). A model the script names for a stage counts as the per-invocation model in that order. When nothing else assigns one, the agent runs on your session's model.
459459
460To control the model cost:
460You can control the model cost in the following ways:
461461
462462* Check `/model` before a large run if you usually switch to a smaller model for routine work
463463* Ask Claude to use a smaller model for stages that don't need the strongest one when you describe the task
from line 487
487487
488488Workflows are available in the CLI, the Desktop app, the IDE extensions, [non-interactive mode](https://code.claude.com/docs/en/headless.md) with `claude -p`, and the [Agent SDK](https://code.claude.com/docs/en/agent-sdk/overview.md). The same disable settings apply on every surface.
489489
490To turn workflows off for yourself:
490You can turn workflows off for yourself in `/config`, in your settings, or with an environment variable:
491491
492492* Toggle Dynamic workflows off in `/config`. Persists across sessions.
493493* Set `"disableWorkflows": true` in `~/.claude/settings.json`. Persists across sessions.
agent-sdk/hooks Changed · +1 / -1 lines
from line 883
883883
884884### Recursive hook loops with subagents
885885
886A `UserPromptSubmit` hook that spawns subagents can create infinite loops if those subagents trigger the same hook. To prevent this:
886A `UserPromptSubmit` hook that spawns subagents can create infinite loops if those subagents trigger the same hook. You can prevent the loop in the following ways:
887887
888888* Use a shared variable or session state to track whether you're already inside a subagent
889889* Scope hooks to only run for the top-level agent session
agent-sdk/hosting Changed · +1 / -1 lines
from line 265
265265
266266Default SDK behavior reads settings and `CLAUDE.md` memory files from the filesystem. In a shared container that serves multiple tenants, those files can leak one tenant's context into another tenant's session.
267267
268To isolate tenants inside a shared container:
268To isolate tenants inside a shared container, do the following:
269269
270270* Pass `settingSources: []` in TypeScript or `setting_sources=[]` in Python to skip user, project, and local settings.
271271* Set `CLAUDE_CODE_DISABLE_AUTO_MEMORY=1` in `env`. [Auto memory](https://code.claude.com/docs/en/memory.md#auto-memory) at `~/.claude/projects/<project>/memory/` loads into the system prompt regardless of `settingSources`. See [What settingSources does not control](https://code.claude.com/docs/en/agent-sdk/claude-code-features.md#what-settingsources-does-not-control) for the other inputs that load unconditionally.
agent-sdk/overview Changed · +1 / -1 lines
from line 6
66
77## Compare the Agent SDK to other Claude tools
88
9The Agent SDK, the CLI, the Client SDK, and Managed Agents differ in who runs the agent, what comes built in, and how you reach it. Find the row that matches how you want to build and run yours.
9The Agent SDK, the CLI, the Client SDK, and Managed Agents differ in who runs the agent, what comes built in, and how you reach it.
1010
1111| You want to | Use | What you get |
1212| - | - | - |
agent-sdk/sessions Changed · +1 / -1 lines
from line 387
387387
388388## Resume across hosts
389389
390Session files are local to the machine that created them. To resume a session on a different host (CI workers, ephemeral containers, serverless), pick the approach that fits:
390Session files are local to the machine that created them. To resume a session on a different host (CI workers, ephemeral containers, serverless), pass a session store or move the session file. You can also pass results into a fresh session:
391391
392392* **Pass a session store.** Attach a [`sessionStore` / `session_store` adapter](https://code.claude.com/docs/en/agent-sdk/session-storage) so the SDK mirrors transcripts to your own backend and another host can resume them. The store lookup key derives from the working directory, so resume from a `cwd` matching the original run's.
393393