@anthropic-ai/claude-agent-sdk 0.3.286 → 0.3.288

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/manifest.json CHANGED
@@ -1,55 +1,53 @@
1
1
  {
2
- "version": "2.1.286",
2
+ "version": "2.1.288",
3
3
  "manifestSignatureEnforcement": "flag",
4
- "commit": "f344a08993bbba4fc1ea9b295245324610f02c58",
5
- "modsCommit": "732e167ee9d71296b4b63d6f529ac1334513826a",
6
- "buildDate": "2026-09-30T15:55:40Z",
4
+ "commit": "17fe1eb736e5b1433d6ca86a1db334cec8520450",
5
+ "modsCommit": "52c76441cae91f6891e4712306bffb057ff6fec5",
6
+ "buildDate": "2026-10-02T17:00:28Z",
7
7
  "platforms": {
8
8
  "darwin-arm64": {
9
9
  "binary": "claude",
10
- "checksum": "75e3016e9d2570767b08e43a7467d4817a4f149232c169ca295f2c95fef21433",
11
- "size": 225167728
10
+ "checksum": "bbe93063f7a0879a1021b2891e5c9354e5b3b98433e32efe6750f7710afed750",
11
+ "size": 229255312
12
12
  },
13
13
  "darwin-x64": {
14
14
  "binary": "claude",
15
- "checksum": "53e6a936e89519d695230f9cc97943991286b72766674fba11bee845f0a7c047",
16
- "size": 233607424
15
+ "checksum": "946acab03a55b60e2016e30964c48b96ef6673cb5da684383f4835da410eede0",
16
+ "size": 237702400
17
17
  },
18
18
  "linux-arm64": {
19
19
  "binary": "claude",
20
- "checksum": "0292fa22ac2fd43e16be9d0e511ddd8347280d6e0ebaca744ef5b27e05d8d0f8",
21
- "size": 241033208
20
+ "checksum": "359ab6a058fcde9741dff54979a212fd134cdf8e8cfc2f8de02bc350b9e2b9d5",
21
+ "size": 245096440
22
22
  },
23
23
  "linux-x64": {
24
24
  "binary": "claude",
25
- "checksum": "fe503f65c6289d59c23e5b21ae44f03583f997dd33a2cbfc75ab4f96fb8fc73f",
26
- "size": 241667256
25
+ "checksum": "0298068b686e7fdbaf9402a7a587bb7f49c0b0e084de09f69145a0719207640c",
26
+ "size": 245734584
27
27
  },
28
28
  "linux-arm64-musl": {
29
29
  "binary": "claude",
30
- "checksum": "5b9b9e41b8b347ba573924342b29b1133d88a7bec51362d5a90a9f22cd6f76cf",
31
- "size": 233387840
30
+ "checksum": "6b9816b225b303dacc17acc9d83016055274498effdbce6227e62d5dbaa762b9",
31
+ "size": 237451072
32
32
  },
33
33
  "linux-x64-musl": {
34
34
  "binary": "claude",
35
- "checksum": "410780234cc3e54afe41a958ef26a4b4f1d253849b769c760f6bcf0bb525fb09",
36
- "size": 235417688
35
+ "checksum": "b4334268a2ce06bf984dab2d6925cc5afe9d2344fa427fc362e266da0d57a894",
36
+ "size": 239480920
37
37
  },
38
38
  "win32-x64": {
39
39
  "binary": "claude.exe",
40
- "checksum": "0b6ecec8edef1ce3069682f696c894d1553239faa6b84e56e167a3ced88fa333",
41
- "size": 245092000
40
+ "checksum": "84304f7d4b0cd0ebcbe8318695a260151b48991a6659c3366fdd5da290c0ab91",
41
+ "size": 249149600
42
42
  },
43
43
  "win32-arm64": {
44
44
  "binary": "claude.exe",
45
- "checksum": "9109c7b0a0de5b40fd013b9009411e517199c8275d2363b824e851cc1133d3c3",
46
- "size": 232616096
45
+ "checksum": "5015d2b92866232b85384ac6e5eef4ff155418a92123503e52714c29186af8c6",
46
+ "size": 236673184
47
47
  }
48
48
  },
49
49
  "sdkCompat": {
50
50
  "testedWrapperVersions": [
51
- "0.3.246",
52
- "0.3.247",
53
51
  "0.3.248",
54
52
  "0.3.250",
55
53
  "0.3.251",
package/manifest.zst.json CHANGED
@@ -1,63 +1,61 @@
1
1
  {
2
- "version": "2.1.286",
2
+ "version": "2.1.288",
3
3
  "manifestSignatureEnforcement": "flag",
4
- "commit": "f344a08993bbba4fc1ea9b295245324610f02c58",
5
- "modsCommit": "732e167ee9d71296b4b63d6f529ac1334513826a",
6
- "buildDate": "2026-09-30T15:57:03Z",
4
+ "commit": "17fe1eb736e5b1433d6ca86a1db334cec8520450",
5
+ "modsCommit": "52c76441cae91f6891e4712306bffb057ff6fec5",
6
+ "buildDate": "2026-10-02T17:01:52Z",
7
7
  "platforms": {
8
8
  "darwin-arm64": {
9
9
  "binary": "claude.zst",
10
- "checksum": "b1be27fbd8fe95bef2418c09f60a307f91c8631dc444fe9a828a7ed2520e45b5",
11
- "size": 75060478,
10
+ "checksum": "ba88682b23623966b04ec3639b537ef643c1d0686cc76286cc689602be8c1200",
11
+ "size": 76486664,
12
12
  "bundle": {
13
- "checksum": "f2326db618029608409be774a5f4d5fde8a032d319d6aa58c3043afda393dd96",
14
- "size": 75074255
13
+ "checksum": "48d54124d3c346c2b8f18b02bbe2f5d7c0184b826d66ee55a5428b26c6cbdfa4",
14
+ "size": 76499869
15
15
  }
16
16
  },
17
17
  "darwin-x64": {
18
18
  "binary": "claude.zst",
19
- "checksum": "e2bbc2a329924533319d0eb4f5a33e2488ce921f60329ab333bca10b0e4c02f2",
20
- "size": 79220957,
19
+ "checksum": "c470eaaccffe95fb288e933cf153c8907f8a2ad0d774d7544f13bbda6864676a",
20
+ "size": 80669475,
21
21
  "bundle": {
22
- "checksum": "fda00b160da41c43716c36fbd4f21729108f898911eea5ede701b10305bca5eb",
23
- "size": 79224277
22
+ "checksum": "7bebb03604b8ace9c91d03beeff4783170bd42fb49774aef622ec86fee2f9014",
23
+ "size": 80664734
24
24
  }
25
25
  },
26
26
  "linux-arm64": {
27
27
  "binary": "claude.zst",
28
- "checksum": "fb24324439bcca9575083f06af6a351a7f9f25066fcf370372b5e829287ef1ee",
29
- "size": 84176167
28
+ "checksum": "65cc3a14ea007b1f949cfc09cee9c523cd61617eeb6c78b6386520c0c4b7b47b",
29
+ "size": 85569159
30
30
  },
31
31
  "linux-x64": {
32
32
  "binary": "claude.zst",
33
- "checksum": "a14d80443473126e40cbc50eb78899f43e8f4d4336095863f8089a6b9ca02a97",
34
- "size": 84909116
33
+ "checksum": "dc67a1d84fec13386cfc50f231211427fee5bd7b7b7f4b5a55af1a6af6f2f326",
34
+ "size": 86304607
35
35
  },
36
36
  "linux-arm64-musl": {
37
37
  "binary": "claude.zst",
38
- "checksum": "e86dc4ad41e7e0af1b2cdadcd9b850acb4aed8f141bddce754f29091e59cf250",
39
- "size": 82570865
38
+ "checksum": "6bd0ec7c4568b53837ea94cf34f9c0e4fed911644ac9b59579aa6e2fb7e3fbcd",
39
+ "size": 83980534
40
40
  },
41
41
  "linux-x64-musl": {
42
42
  "binary": "claude.zst",
43
- "checksum": "b79ed7738c8eb72812d89d2d4032fe4196cf19dac067ee8e724d4f892350c710",
44
- "size": 83360753
43
+ "checksum": "6dc8667b6aa3c6199b0a0920149971a806d532e6e302fa281127449795b1572f",
44
+ "size": 84763155
45
45
  },
46
46
  "win32-x64": {
47
47
  "binary": "claude.exe.zst",
48
- "checksum": "635c1867224abd72c010948307b6dd871c64837dada77e67d98ed850408198bf",
49
- "size": 87205724
48
+ "checksum": "36aa8c97bf8665d371c5b5be82f2f1252fcc623dd323a6c7ac1fba0b09b8a35c",
49
+ "size": 88605512
50
50
  },
51
51
  "win32-arm64": {
52
52
  "binary": "claude.exe.zst",
53
- "checksum": "f485b6b45317d01eb9c6cb3f62c66520aaa87f3e0f7c729ece129b832c211cbc",
54
- "size": 83529567
53
+ "checksum": "35ac5392396c85b0729146af1f1be7f3b4203c3e9dcfccba119ca209f143d1c6",
54
+ "size": 84944844
55
55
  }
56
56
  },
57
57
  "sdkCompat": {
58
58
  "testedWrapperVersions": [
59
- "0.3.246",
60
- "0.3.247",
61
59
  "0.3.248",
62
60
  "0.3.250",
63
61
  "0.3.251",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@anthropic-ai/claude-agent-sdk",
3
- "version": "0.3.286",
3
+ "version": "0.3.288",
4
4
  "main": "sdk.mjs",
5
5
  "types": "sdk.d.ts",
6
6
  "exports": {
@@ -61,14 +61,14 @@
61
61
  "zod": "^4.0.0"
62
62
  },
63
63
  "optionalDependencies": {
64
- "@anthropic-ai/claude-agent-sdk-linux-x64": "0.3.286",
65
- "@anthropic-ai/claude-agent-sdk-linux-arm64": "0.3.286",
66
- "@anthropic-ai/claude-agent-sdk-linux-x64-musl": "0.3.286",
67
- "@anthropic-ai/claude-agent-sdk-linux-arm64-musl": "0.3.286",
68
- "@anthropic-ai/claude-agent-sdk-darwin-x64": "0.3.286",
69
- "@anthropic-ai/claude-agent-sdk-darwin-arm64": "0.3.286",
70
- "@anthropic-ai/claude-agent-sdk-win32-x64": "0.3.286",
71
- "@anthropic-ai/claude-agent-sdk-win32-arm64": "0.3.286"
64
+ "@anthropic-ai/claude-agent-sdk-linux-x64": "0.3.288",
65
+ "@anthropic-ai/claude-agent-sdk-linux-arm64": "0.3.288",
66
+ "@anthropic-ai/claude-agent-sdk-linux-x64-musl": "0.3.288",
67
+ "@anthropic-ai/claude-agent-sdk-linux-arm64-musl": "0.3.288",
68
+ "@anthropic-ai/claude-agent-sdk-darwin-x64": "0.3.288",
69
+ "@anthropic-ai/claude-agent-sdk-darwin-arm64": "0.3.288",
70
+ "@anthropic-ai/claude-agent-sdk-win32-x64": "0.3.288",
71
+ "@anthropic-ai/claude-agent-sdk-win32-arm64": "0.3.288"
72
72
  },
73
73
  "files": [
74
74
  "sdk.mjs",
@@ -85,8 +85,8 @@
85
85
  "extractFromBunfs.d.ts",
86
86
  "manifest.json",
87
87
  "manifest.zst.json",
88
- "core-5c9xf7pv.mjs",
89
- "core-y9rc2t7d.mjs"
88
+ "core-ejtftkpy.mjs",
89
+ "core-wn2j871p.mjs"
90
90
  ],
91
- "claudeCodeVersion": "2.1.286"
91
+ "claudeCodeVersion": "2.1.288"
92
92
  }
package/sdk.d.ts CHANGED
@@ -244,6 +244,8 @@ export declare type CanUseTool = (toolName: string, input: Record<string, unknow
244
244
  };
245
245
  /** Explains why this permission request was triggered. */
246
246
  decisionReason?: string;
247
+
248
+
247
249
  /**
248
250
  * Full permission prompt sentence rendered by the bridge (e.g.
249
251
  * "Claude wants to read foo.txt"). Use this as the primary prompt
@@ -1184,7 +1186,7 @@ export declare type McpHttpServerConfig = {
1184
1186
  timeout?: number;
1185
1187
 
1186
1188
  /**
1187
- * When true, all tools from this server are always included in the prompt and never deferred behind tool search, except a tool the server itself lists with _meta anthropic/alwaysLoad set to false. Equivalent to setting defer_loading: false on the API. Default: tools are deferred when tool search is enabled. As a side effect this also blocks startup until the server is connected (capped at the standard 5s connect timeout) even though MCP startup is otherwise non-blocking by default, since the tools must be present when the turn-1 prompt is built.
1189
+ * When true, all tools from this server are always included in the prompt and never deferred behind tool search, except a tool the server itself lists with _meta anthropic/alwaysLoad set to false. Equivalent to setting defer_loading: false on the API. When false, all tools from this server are deferred behind tool search. Default: tools are deferred when tool search is enabled. As a side effect, true also blocks startup until the server is connected (capped at the standard 5s connect timeout) even though MCP startup is otherwise non-blocking by default, since the tools must be present when the turn-1 prompt is built.
1188
1190
  */
1189
1191
  alwaysLoad?: boolean;
1190
1192
 
@@ -1323,7 +1325,7 @@ export declare type McpSSEServerConfig = {
1323
1325
  timeout?: number;
1324
1326
 
1325
1327
  /**
1326
- * When true, all tools from this server are always included in the prompt and never deferred behind tool search, except a tool the server itself lists with _meta anthropic/alwaysLoad set to false. Equivalent to setting defer_loading: false on the API. Default: tools are deferred when tool search is enabled. As a side effect this also blocks startup until the server is connected (capped at the standard 5s connect timeout) even though MCP startup is otherwise non-blocking by default, since the tools must be present when the turn-1 prompt is built.
1328
+ * When true, all tools from this server are always included in the prompt and never deferred behind tool search, except a tool the server itself lists with _meta anthropic/alwaysLoad set to false. Equivalent to setting defer_loading: false on the API. When false, all tools from this server are deferred behind tool search. Default: tools are deferred when tool search is enabled. As a side effect, true also blocks startup until the server is connected (capped at the standard 5s connect timeout) even though MCP startup is otherwise non-blocking by default, since the tools must be present when the turn-1 prompt is built.
1327
1329
  */
1328
1330
  alwaysLoad?: boolean;
1329
1331
 
@@ -1339,7 +1341,7 @@ export declare type McpStdioServerConfig = {
1339
1341
  */
1340
1342
  timeout?: number;
1341
1343
  /**
1342
- * When true, all tools from this server are always included in the prompt and never deferred behind tool search, except a tool the server itself lists with _meta anthropic/alwaysLoad set to false. Equivalent to setting defer_loading: false on the API. Default: tools are deferred when tool search is enabled. As a side effect this also blocks startup until the server is connected (capped at the standard 5s connect timeout) even though MCP startup is otherwise non-blocking by default, since the tools must be present when the turn-1 prompt is built.
1344
+ * When true, all tools from this server are always included in the prompt and never deferred behind tool search, except a tool the server itself lists with _meta anthropic/alwaysLoad set to false. Equivalent to setting defer_loading: false on the API. When false, all tools from this server are deferred behind tool search. Default: tools are deferred when tool search is enabled. As a side effect, true also blocks startup until the server is connected (capped at the standard 5s connect timeout) even though MCP startup is otherwise non-blocking by default, since the tools must be present when the turn-1 prompt is built.
1343
1345
  */
1344
1346
  alwaysLoad?: boolean;
1345
1347
 
@@ -2669,7 +2671,7 @@ export declare type PostToolUseHookSpecificOutput = {
2669
2671
  hookEventName: 'PostToolUse';
2670
2672
  additionalContext?: string;
2671
2673
  /**
2672
- * Host-asserted context shown to the auto-mode permission classifier alongside this tool call's result. In the live session the classifier may weigh a user statement relayed here as user intent (it can satisfy a consent bar a user turn would satisfy, never a hard boundary); values restored from saved session state are treated as unverified context only. Relay discipline is the host's obligation: put ONLY genuine user statements in intent-bearing positions — never tool output or model text dressed as one. Capped at 2000 UTF-16 code units, a budget shared across all hooks that contribute to one call (surrogate-pair-safe; emoji and other astral characters count as two). Honored on synchronous hook responses only: an async hook's late response arrives after the result message is frozen and this field in it is silently ignored. Security note: do not copy untrusted tool output or third-party text into it blindly — content placed here reaches the permission classifier with host-application framing. Applies only to calls the classifier transcript shows: read-only lookups the transcript omits (file reads, searches), inner REPL calls, and remote-engine shells produce no per-result line, and context attached to them is silently unused. Not a delivery channel: it is bound to a single call id and sized for a short assertion, not for relaying messages or events. Rewrite integrity: if this assertion describes output you are rewriting, return it in the SAME hook result as the rewrite — it is then dropped automatically if your rewrite is rejected or superseded by a later hook's rewrite; assertions returned without a rewrite are never invalidated by other hooks' rewrites, so a non-rewriting hook should assert only what holds regardless of other hooks' rewrites — hosts that need an assertion bound to exact output bytes should make it in the hook that produces those bytes. (Do NOT return an identity rewrite just to pair an assertion: hooks run in parallel on the ORIGINAL output, so an identity rewrite competes last-write-wins with sibling rewrites and can clobber a real redaction.)
2674
+ * Host-asserted context shown to the auto-mode permission classifier alongside this tool call's result. In the live session the classifier may weigh a user statement relayed here as user intent (it can satisfy a consent bar a user turn would satisfy, never a hard boundary); values restored from saved session state are treated as unverified context only. Relay discipline is the host's obligation: put ONLY genuine user statements in intent-bearing positions — never tool output or model text dressed as one. Capped at 2000 UTF-16 code units, a budget shared across all hooks that contribute to one call (surrogate-pair-safe; emoji and other astral characters count as two). Honored on synchronous hook responses only: an async hook's late response arrives after the result message is frozen and this field in it is silently ignored. Security note: do not copy untrusted tool output or third-party text into it blindly — content placed here reaches the permission classifier with host-application framing. Applies only to calls the classifier transcript shows: read-only lookups the transcript omits (file reads, searches) and remote-engine shells produce no per-result line, and context attached to them is silently unused. Not a delivery channel: it is bound to a single call id and sized for a short assertion, not for relaying messages or events. Rewrite integrity: if this assertion describes output you are rewriting, return it in the SAME hook result as the rewrite — it is then dropped automatically if your rewrite is rejected or superseded by a later hook's rewrite; assertions returned without a rewrite are never invalidated by other hooks' rewrites, so a non-rewriting hook should assert only what holds regardless of other hooks' rewrites — hosts that need an assertion bound to exact output bytes should make it in the hook that produces those bytes. (Do NOT return an identity rewrite just to pair an assertion: hooks run in parallel on the ORIGINAL output, so an identity rewrite competes last-write-wins with sibling rewrites and can clobber a real redaction.)
2673
2675
  */
2674
2676
  classifierContext?: string;
2675
2677
  /**
@@ -3653,6 +3655,7 @@ export declare type SDKAssistantMessage = {
3653
3655
 
3654
3656
 
3655
3657
 
3658
+
3656
3659
  /**
3657
3660
  * ISO timestamp of when this content block finished on the originating process. One API assistant turn may produce several assistant messages sharing a message.id, each with its own timestamp. Uses the originating host's clock, so it's for display only; do not order messages by this field. Older emitters omit it; consumers should fall back to receive time.
3658
3661
  */
@@ -4202,6 +4205,35 @@ declare type SDKControlGetSettingsRequest = {
4202
4205
  subtype: 'get_settings';
4203
4206
  };
4204
4207
 
4208
+ /**
4209
+ * Reads the end of one background shell or Monitor task's output: at most the last 8 KiB the command wrote, the same tail the terminal's /tasks detail view reads. Read-only and no model turn; a host polls it while the task runs, and can read it once more after the task ends. The output is whatever the command printed, escape sequences included: render it as plain text. Refused for a task_id that is neither a shell or Monitor task of this session nor shaped like one (an ended task's id whose file is gone reads as empty), and on a lane that redacts what it persists (a Remote Control bridge worker, a tenant worker).
4210
+ */
4211
+ declare type SDKControlGetTaskOutputRequest = {
4212
+ subtype: 'get_task_output';
4213
+ /**
4214
+ * A shell or Monitor task of this session, running or ended: the task_id from task_started or background_tasks_changed.
4215
+ */
4216
+ task_id: string;
4217
+ };
4218
+
4219
+ /**
4220
+ * Success payload answering get_task_output.
4221
+ */
4222
+ declare type SDKControlGetTaskOutputResponse = {
4223
+ /**
4224
+ * The end of the output, decoded as UTF-8; empty when the command has written nothing yet.
4225
+ */
4226
+ output: string;
4227
+ /**
4228
+ * The size of the whole output in bytes.
4229
+ */
4230
+ total_bytes: number;
4231
+ /**
4232
+ * Whether output holds only the end of a longer output (the last 8 KiB).
4233
+ */
4234
+ truncated: boolean;
4235
+ };
4236
+
4205
4237
  /**
4206
4238
  * Requests the structured /usage data: session cost/usage totals plus claude.ai plan rate-limit utilization when available. Experimental — the response shape may change.
4207
4239
  */
@@ -4539,7 +4571,7 @@ export declare type SDKControlInitializeResponse = {
4539
4571
  plugins_applied?: boolean;
4540
4572
 
4541
4573
  /**
4542
- * What became of each entry of this initialize's sdkMcpServerManifests, keyed by sdk server name, for the entries whose name is in sdkMcpServers. 'parked': kept for the connect that follows this reply, which answers the server's MCP initialize and first tools/list from it (a later failure to replay shows up as live mcp_message frames, as when no entry was sent). 'already_connected': this CLI already had a live client for the server. 'protocol_version_mismatch': initializeResult.protocolVersion is not the version this CLI's client requests. 'malformed': the entry is not of the documented shape, reported whether or not manifests were honoured (every name in sdkMcpServers gets this when the field itself is not an object). 'not_honoured': the CLI did not use the entry: manifests or remote manifests are switched off in this CLI, the session service has not told this remote-session worker in the last five minutes that only the account owning the session can send events to it, or the request reached such a worker other than over its session stream (nothing for the host to change in any of these cases); or it came over the session stream without sdkMcpServerManifestsOrigin or on a frame too old to trust (the host's to fix). Absent when the request carried no sdkMcpServerManifests or named no sdkMcpServers, and on CLIs that predate the field.
4574
+ * What became of each entry of this initialize's sdkMcpServerManifests, keyed by sdk server name, for the entries whose name is in sdkMcpServers. 'parked': kept for the connect that follows this reply, which answers the server's MCP initialize and first tools/list from it (a later failure to replay shows up as live mcp_message frames, as when no entry was sent). 'already_connected': this CLI already had a live client for the server. 'protocol_version_mismatch': initializeResult.protocolVersion is not the version this CLI's client requests. 'malformed': the entry is not of the documented shape, reported whether or not manifests were honoured (every name in sdkMcpServers gets this when the field itself is not an object); or an honoured entry is past the limits this CLI sets on a live answer. 'not_honoured': the CLI did not use the entry: manifests or remote manifests are switched off in this CLI, the session service has not told this remote-session worker in the last five minutes that only the account owning the session can send events to it, or the request reached such a worker other than over its session stream (nothing for the host to change in any of these cases); or this CLI had read as many tool lists as it allows in a minute (send it again later); or it came over the session stream without sdkMcpServerManifestsOrigin or on a frame too old to trust (the host's to fix). Absent when the request carried no sdkMcpServerManifests or named no sdkMcpServers, and on CLIs that predate the field.
4543
4575
  */
4544
4576
  sdk_mcp_manifests_parked?: Record<string, 'parked' | 'already_connected' | 'protocol_version_mismatch' | 'malformed' | 'not_honoured'>;
4545
4577
 
@@ -4558,6 +4590,7 @@ export declare type SDKControlInitializeResponse = {
4558
4590
 
4559
4591
 
4560
4592
 
4593
+
4561
4594
  };
4562
4595
 
4563
4596
  /**
@@ -4570,6 +4603,8 @@ declare type SDKControlInterruptRequest = {
4570
4603
  * When true, the interrupt also cancels every uuid-stamped main-thread command still in the queue or already dequeued for the imminent turn but not yet reachable by the abort (the first-command prewait window) — the same set the response would otherwise list under `still_queued`. Each is closed with a terminal 'cancelled' lifecycle and listed on the response's `cancelled` field. `still_queued` is then empty, except that a client driving a hosted session lists there what it can no longer recall (a send already in flight to that session, or the first prompt the session was created with) and, when the session's own sweep then cancels one of those or a send it had already delivered, follows up with a command_lifecycle 'cancelled' frame for it. (The isFoldInFlight guard cancel_async_message uses does not apply here: this request also aborts the running turn, so a fold-in-flight uuid is never delivered and is swept with the rest. A fold-in-flight uuid's queued_command attachment may already appear in the aborted turn's transcript if the abort landed after the fold's attachment yield — pre-existing leave-queued semantics; it never runs as its own turn.) Uuid-less commands (task notifications) still in the queue are also dequeued but cannot be listed; a uuid-less command already in the prewait window is unreachable by either cancel leg — the first-command prewait latch covers it (this request latches exactly like a plain interrupt; see still_queued): its turn starts aborted. When false or absent, queued commands survive the interrupt and are listed under `still_queued` — the interrupt_receipt_v1 contract is unchanged. A Stop-means-stop-everything client (a remote UI's Stop button) sets this true so one round-trip halts the session; a wrapper that wants per-uuid control leaves it false and follows up with cancel_async_message. Advertised by the `interrupt_cancel_queued_v1` capability on system/init; older CLIs ignore the field and behave as if false.
4571
4604
  */
4572
4605
  cancel_queued?: boolean;
4606
+
4607
+
4573
4608
  };
4574
4609
 
4575
4610
  /**
@@ -4580,6 +4615,7 @@ export declare type SDKControlInterruptResponse = {
4580
4615
  * Uuids of async user messages that survive this interrupt: commands still in the queue, plus any batch already dequeued for the imminent turn but not yet reachable by the abort. An interrupt — plain or cancel_queued:true — that lands during the FIRST-command prewait window (before the first turn of the session has armed a controller) is additionally LATCHED, scoped to the user-intent work pending at that instant — the batch already dequeued and parked for the imminent turn, plus the user-intent main-thread commands then in the queue (the work this list enumerates): the first turn to arm that carries any of that doomed work starts already aborted, exactly once, so the listed prewait batch is delivered into an immediately-aborted turn, its frames and result flowing through the normal abort path, instead of running to completion. A turn carrying none of it arms live and leaves the latch waiting: a system delivery turn (for example a replayed host event), or a prompt enqueued after the interrupt — post-interrupt work is never coalesced with the doomed work and never dies to the latch, so the Stop kills exactly what this receipt listed. The latch is released when the doomed work is retired without arming: if a parked prewait batch is entirely cancelled, the latch is released even when other queued commands remain (those arm and run normally); with nothing parked, it is released once none of the doomed commands remains queued — work enqueued after the interrupt neither holds it up nor is aborted by it. Survivors that ride any later turn run normally. These WILL run (subject to that latch) unless cancelled first (or unless the request set cancel_queued:true, in which case every uuid-stamped survivor this process holds is removed, emitted a terminal `cancelled` synchronously, and listed under `cancelled` instead — leaving here only what a client driving a hosted session can no longer recall: a send already in flight to that session, or the first prompt the session was created with; a send that client still holds on its own machine behind a send gate (it waits there until that session is ready to take it) has not gone out, so it is withdrawn and listed under `cancelled` like a queued one, and cancel_async_message can withdraw it too, while a plain interrupt leaves it held and lists it here). Cancellation granularity: uuids still in the queue are individually cancellable via cancel_async_message; once a batch is dequeued and coalesced into one turn, cancelling a NON-representative member uuid is a no-op (its content still runs), while cancelling the batch-representative uuid drops the WHOLE coalesced batch — in both cases the cancel response reports cancelled:false because the message was no longer in the queue. Coverage caveats: only uuid-STAMPED messages appear (a message enqueued without a uuid still runs but is never listed, so [] does not mean "nothing will run"); only main-thread messages are listed (subagent-addressed messages are out of scope); and the list may include internally-enqueued uuids the client never sent (cron triggers, auto-resume continuations) — ignore unknown uuids rather than treating them as an error. Ordering: on a clean interrupt this receipt is written before the interrupted turn result; a turn that crashes during interrupt handling emits its error result on a direct-write path that may precede the receipt. Snapshot is taken synchronously with abort processing — probing the queue after the interrupted result instead always loses the race against the drain loop, which starts the next queued turn immediately.
4581
4616
  */
4582
4617
  still_queued: string[];
4618
+
4583
4619
  /**
4584
4620
  * Present only when the request set cancel_queued:true — uuids of main-thread commands cancelled by this interrupt: every survivor that would otherwise have appeared under `still_queued`, including any uuid that was mid-fold at the interrupt instant (this request also aborts, so the fold never delivers it). Each listed uuid has been removed (queue-resident) or marked cancel-pending (the first-command prewait window, closed by the drain loop's backstop) and emits a terminal 'cancelled' lifecycle synchronously at the first such interrupt (a repeat interrupt over the same parked batch re-lists the uuid idempotently without re-emitting); none will run. Same coverage caveats as `still_queued` (uuid-stamped main-thread only; internally-enqueued uuids may appear). Advertised by the `interrupt_cancel_queued_v1` capability.
4585
4621
  */
@@ -4951,7 +4987,7 @@ export declare type SDKControlRequest = {
4951
4987
 
4952
4988
  };
4953
4989
 
4954
- declare type SDKControlRequestInner = SDKControlInterruptRequest | SDKControlPermissionRequest | SDKControlInitializeRequest | SDKControlSetPermissionModeRequest | SDKControlSetModelRequest | SDKControlSetMaxThinkingTokensRequest | SDKControlRenameSessionRequest | SDKControlSetColorRequest | SDKControlMcpStatusRequest | SDKControlGetContextUsageRequest | SDKControlGetSessionCostRequest | SDKControlListModelsRequest | SDKControlGetUsageRequest | SDKControlGetBinaryVersionRequest | SDKControlMcpCallRequest | SDKControlFileSuggestionsRequest | SDKHookCallbackRequest | SDKControlMcpMessageRequest | SDKControlRewindFilesRequest | SDKControlCancelAsyncMessageRequest | SDKControlReadFileRequest | SDKControlSeedReadStateRequest | SDKControlMcpSetServersRequest | SDKControlRegisterRepoRootRequest | SDKControlReloadPluginsRequest | SDKControlReloadSkillsRequest | SDKControlReloadOutputStylesRequest | SDKControlMcpReconnectRequest | SDKControlMcpToggleRequest | SDKControlStopTaskRequest | SDKControlBackgroundTasksRequest | SDKControlApplyFlagSettingsRequest | SDKControlGetSettingsRequest | SDKControlGetHooksListingRequest | SDKControlUpdateSettingsRequest | SDKControlElicitationRequest | SDKControlRequestUserDialogRequest | SDKControlListPermissionRulesRequest | SDKControlMcpReadResourceRequest;
4990
+ declare type SDKControlRequestInner = SDKControlInterruptRequest | SDKControlPermissionRequest | SDKControlInitializeRequest | SDKControlSetPermissionModeRequest | SDKControlSetModelRequest | SDKControlSetMaxThinkingTokensRequest | SDKControlRenameSessionRequest | SDKControlSetColorRequest | SDKControlMcpStatusRequest | SDKControlGetContextUsageRequest | SDKControlGetSessionCostRequest | SDKControlListModelsRequest | SDKControlGetUsageRequest | SDKControlGetBinaryVersionRequest | SDKControlMcpCallRequest | SDKControlFileSuggestionsRequest | SDKHookCallbackRequest | SDKControlMcpMessageRequest | SDKControlRewindFilesRequest | SDKControlCancelAsyncMessageRequest | SDKControlReadFileRequest | SDKControlSeedReadStateRequest | SDKControlMcpSetServersRequest | SDKControlRegisterRepoRootRequest | SDKControlReloadPluginsRequest | SDKControlReloadSkillsRequest | SDKControlReloadOutputStylesRequest | SDKControlMcpReconnectRequest | SDKControlMcpToggleRequest | SDKControlStopTaskRequest | SDKControlBackgroundTasksRequest | SDKControlGetTaskOutputRequest | SDKControlApplyFlagSettingsRequest | SDKControlGetSettingsRequest | SDKControlGetHooksListingRequest | SDKControlUpdateSettingsRequest | SDKControlElicitationRequest | SDKControlRequestUserDialogRequest | SDKControlListPermissionRulesRequest | SDKControlMcpReadResourceRequest;
4955
4991
 
4956
4992
  /**
4957
4993
  * Progress for a long-running client-originated control_request (currently only side_question), correlated by request_id. status 'started' means the worker accepted the request and launched the work; 'api_retry' carries the same retry counters as SDKAPIRetryMessage and is present only for that status.
@@ -5215,6 +5251,10 @@ export declare type SDKInformationalMessage = {
5215
5251
  * When true, execution stops after this message (e.g. a Stop hook denied continuation).
5216
5252
  */
5217
5253
  prevent_continuation?: boolean;
5254
+ /**
5255
+ * Opaque feature tag on a line a host may treat specially; absent on ordinary lines. Hosts ignore values they do not know.
5256
+ */
5257
+ tag?: string;
5218
5258
  uuid: UUID;
5219
5259
  session_id: string;
5220
5260
  };
@@ -5701,6 +5741,8 @@ export declare type SDKResultSuccess = {
5701
5741
 
5702
5742
 
5703
5743
 
5744
+
5745
+
5704
5746
  user_message_uuid?: string;
5705
5747
  user_message_uuids?: string[];
5706
5748
  resume_reason?: string;
@@ -5721,9 +5763,12 @@ export declare type SDKResultSuccess = {
5721
5763
 
5722
5764
 
5723
5765
  first_text_post_ms?: number;
5766
+ first_text_post_queue_wait_ms?: number;
5767
+ first_text_post_queued_behind?: 'durable_post' | 'ephemeral_post' | 'retry_backoff' | 'hold' | 'none';
5724
5768
  first_text_post_wall_ms?: number;
5725
5769
  time_to_request_from_spawn_ms?: number;
5726
5770
  warm_spare_claimed?: boolean;
5771
+
5727
5772
  time_origin_ms?: number;
5728
5773
  is_error: boolean;
5729
5774
  api_error_status?: number | null;
@@ -6185,7 +6230,7 @@ export declare type SDKUserMessage = {
6185
6230
  parent_tool_use_id: string | null;
6186
6231
  isSynthetic?: boolean;
6187
6232
  /**
6188
- * Structured tool output — the tool's full Output object, not the string content sent to the model. The shape is per-tool, keyed by the matching tool_use block's name (see the *Output types in toolTypes); MCP and dynamic tools carry their own shapes, so the field stays unknown-typed. For the Agent/Task tool the completed shape is the subagent's final report without the model-directed agentId/usage trailer, plus run totals — render from it instead of parsing the tool_result text.
6233
+ * Structured tool output — the tool's full Output object, not the string content sent to the model. The shape is per-tool, keyed by the matching tool_use block's name (see the *Output types in toolTypes); MCP and dynamic tools carry their own shapes, so the field stays unknown-typed. For the Agent/Task tool the completed shape is the subagent's final report without the model-directed agentId/usage trailer, plus run totals — render from it instead of parsing the tool_result text. A call that stepped aside for a message the user sent (today a WebFetch or WebSearch call) carries `{ detachedToolCall: true }` in place of its Output: the call is still running, and its result reaches the model in a later turn.
6189
6234
  */
6190
6235
  tool_use_result?: unknown;
6191
6236
  priority?: 'now' | 'next' | 'later';
@@ -6274,7 +6319,7 @@ export declare type SDKUserMessageReplay = {
6274
6319
  parent_tool_use_id: string | null;
6275
6320
  isSynthetic?: boolean;
6276
6321
  /**
6277
- * Structured tool output — the tool's full Output object, not the string content sent to the model. The shape is per-tool, keyed by the matching tool_use block's name (see the *Output types in toolTypes); MCP and dynamic tools carry their own shapes, so the field stays unknown-typed. For the Agent/Task tool the completed shape is the subagent's final report without the model-directed agentId/usage trailer, plus run totals — render from it instead of parsing the tool_result text.
6322
+ * Structured tool output — the tool's full Output object, not the string content sent to the model. The shape is per-tool, keyed by the matching tool_use block's name (see the *Output types in toolTypes); MCP and dynamic tools carry their own shapes, so the field stays unknown-typed. For the Agent/Task tool the completed shape is the subagent's final report without the model-directed agentId/usage trailer, plus run totals — render from it instead of parsing the tool_result text. A call that stepped aside for a message the user sent (today a WebFetch or WebSearch call) carries `{ detachedToolCall: true }` in place of its Output: the call is still running, and its result reaches the model in a later turn.
6278
6323
  */
6279
6324
  tool_use_result?: unknown;
6280
6325
  priority?: 'now' | 'next' | 'later';
@@ -7474,7 +7519,7 @@ export declare interface Settings {
7474
7519
  */
7475
7520
  url: string;
7476
7521
  /**
7477
- * Subdirectory within the repo containing the plugin (e.g., "tools/claude-plugin"). Cloned sparsely using partial clone (--filter=tree:0) to minimize bandwidth for monorepos.
7522
+ * Subdirectory within the repo containing the plugin (e.g., "tools/claude-plugin"). Checked out sparsely — over https or ssh as a partial clone (--filter=tree:0) — to minimize bandwidth for monorepos.
7478
7523
  */
7479
7524
  path: string;
7480
7525
  /**
@@ -7726,7 +7771,7 @@ export declare interface Settings {
7726
7771
  */
7727
7772
  url: string;
7728
7773
  /**
7729
- * Subdirectory within the repo containing the plugin (e.g., "tools/claude-plugin"). Cloned sparsely using partial clone (--filter=tree:0) to minimize bandwidth for monorepos.
7774
+ * Subdirectory within the repo containing the plugin (e.g., "tools/claude-plugin"). Checked out sparsely — over https or ssh as a partial clone (--filter=tree:0) — to minimize bandwidth for monorepos.
7730
7775
  */
7731
7776
  path: string;
7732
7777
  /**
@@ -7973,7 +8018,7 @@ export declare interface Settings {
7973
8018
  */
7974
8019
  url: string;
7975
8020
  /**
7976
- * Subdirectory within the repo containing the plugin (e.g., "tools/claude-plugin"). Cloned sparsely using partial clone (--filter=tree:0) to minimize bandwidth for monorepos.
8021
+ * Subdirectory within the repo containing the plugin (e.g., "tools/claude-plugin"). Checked out sparsely — over https or ssh as a partial clone (--filter=tree:0) — to minimize bandwidth for monorepos.
7977
8022
  */
7978
8023
  path: string;
7979
8024
  /**
@@ -8210,7 +8255,7 @@ export declare interface Settings {
8210
8255
  */
8211
8256
  url: string;
8212
8257
  /**
8213
- * Subdirectory within the repo containing the plugin (e.g., "tools/claude-plugin"). Cloned sparsely using partial clone (--filter=tree:0) to minimize bandwidth for monorepos.
8258
+ * Subdirectory within the repo containing the plugin (e.g., "tools/claude-plugin"). Checked out sparsely — over https or ssh as a partial clone (--filter=tree:0) — to minimize bandwidth for monorepos.
8214
8259
  */
8215
8260
  path: string;
8216
8261
  /**
@@ -8447,7 +8492,7 @@ export declare interface Settings {
8447
8492
  */
8448
8493
  url: string;
8449
8494
  /**
8450
- * Subdirectory within the repo containing the plugin (e.g., "tools/claude-plugin"). Cloned sparsely using partial clone (--filter=tree:0) to minimize bandwidth for monorepos.
8495
+ * Subdirectory within the repo containing the plugin (e.g., "tools/claude-plugin"). Checked out sparsely — over https or ssh as a partial clone (--filter=tree:0) — to minimize bandwidth for monorepos.
8451
8496
  */
8452
8497
  path: string;
8453
8498
  /**
@@ -8921,6 +8966,10 @@ export declare interface Settings {
8921
8966
  * Maximum effort level for this model. Within one settings file it replaces the top-level maxEffortLevel for the model ("max" exempts it); across settings files the lowest applicable value wins. Keyed like effortLevel: the canonical model name also matches its dated, [1m], Bedrock and Vertex spellings.
8922
8967
  */
8923
8968
  maxEffortLevel?: 'low' | 'medium' | 'high' | 'xhigh' | 'max';
8969
+ /**
8970
+ * Auto-compact window for this model, in tokens (100000 to 1000000), or "auto" for the window tuned for the model. Within one settings file it replaces the top-level autoCompactWindow for the model. /autocompact saves here. The canonical model name as key also matches its dated, [1m], Bedrock and Vertex spellings.
8971
+ */
8972
+ autoCompactWindow?: 'auto' | number;
8924
8973
  [k: string]: unknown;
8925
8974
  };
8926
8975
  };