@anthropic-ai/claude-agent-sdk 0.3.290 → 0.3.292

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,49 +1,49 @@
1
1
  {
2
- "version": "2.1.290",
2
+ "version": "2.1.292",
3
3
  "manifestSignatureEnforcement": "flag",
4
- "commit": "3897a65075994f4efddcf34b4a32ea7c7c5ebc13",
5
- "modsCommit": "2bfb629dfaff0c8318047a4beb93cf1dc5b58b18",
6
- "buildDate": "2026-10-05T16:35:05Z",
4
+ "commit": "37832d0b7cad7b40bac7c82dff58629313913edf",
5
+ "modsCommit": "8e60c4cac989c0e0cc6d2c49407a5c67f5a4a8e6",
6
+ "buildDate": "2026-10-06T05:43:35Z",
7
7
  "platforms": {
8
8
  "darwin-arm64": {
9
9
  "binary": "claude",
10
- "checksum": "b8412a3826b2dc8ecb1c0605970c28dea28355de5faa740407dd881acdd40237",
11
- "size": 233260816
10
+ "checksum": "97a01e5bc74a199e67189435d0331ea3a24eac2e07db4b76d9148c5b0386138f",
11
+ "size": 235017328
12
12
  },
13
13
  "darwin-x64": {
14
14
  "binary": "claude",
15
- "checksum": "c3b1cb200701ce02fd5000cad06cdfab9858773a03ffc9c6483a2f35eae0c358",
16
- "size": 241731328
15
+ "checksum": "a9739a215728ce72435885fedb19d1317ee1ccec61e246fbfb3acaf01689c473",
16
+ "size": 243514624
17
17
  },
18
18
  "linux-arm64": {
19
19
  "binary": "claude",
20
- "checksum": "24c31a685e363190c165353f10b4e8434fd22647c1dd76eb6d2a05634eb60b95",
21
- "size": 249094136
20
+ "checksum": "24caa9e6ff13bf227049a2626f1c816fc895023050f0ec3b12dbf14d897367e0",
21
+ "size": 250798072
22
22
  },
23
23
  "linux-x64": {
24
24
  "binary": "claude",
25
- "checksum": "ea38ee1a1f946eea9bc6e97fb912dbe71fc379b25cc605d91b308afa1ca08be7",
26
- "size": 249687224
25
+ "checksum": "a967e7b1d8b4e47ee421d5433027880347952b0c0857abf880e2c942a4ec93b3",
26
+ "size": 251456696
27
27
  },
28
28
  "linux-arm64-musl": {
29
29
  "binary": "claude",
30
- "checksum": "38493501b8d1d8d75a921734487c192557bc189f12becc31133c56f7f48f908b",
31
- "size": 241383232
30
+ "checksum": "a17c919b13df206371a55de716ab81e3dcd7c039f66b79003ed87b7665fdc15f",
31
+ "size": 243152704
32
32
  },
33
33
  "linux-x64-musl": {
34
34
  "binary": "claude",
35
- "checksum": "b969a855d7da25b483c0962eac5c758b0044a153045ab834dda79ba2f040f397",
36
- "size": 243437656
35
+ "checksum": "d23f28ef84f5459a25d2d4cf999a7debd41df83507160446983d4ca65554e50f",
36
+ "size": 245203032
37
37
  },
38
38
  "win32-x64": {
39
39
  "binary": "claude.exe",
40
- "checksum": "467d3dff9d6bbb26ab765284490a200dd713ee5778c55662007240e7e86386b2",
41
- "size": 253090464
40
+ "checksum": "eb95bb65955f8b1702e800815f9a2c0388a5de0f196c354c7ee1dd5cb9a2ba23",
41
+ "size": 254858400
42
42
  },
43
43
  "win32-arm64": {
44
44
  "binary": "claude.exe",
45
- "checksum": "96d0243e096a910f4d30cfca26cd9599ce7c301b097a818e93a869d07288d599",
46
- "size": 240615072
45
+ "checksum": "0bfe32208d4f34d9bc01454ac8aa226f71bbf24617d913e78db5792ad937b784",
46
+ "size": 242380960
47
47
  }
48
48
  },
49
49
  "sdkCompat": {
package/manifest.zst.json CHANGED
@@ -1,57 +1,57 @@
1
1
  {
2
- "version": "2.1.290",
2
+ "version": "2.1.292",
3
3
  "manifestSignatureEnforcement": "flag",
4
- "commit": "3897a65075994f4efddcf34b4a32ea7c7c5ebc13",
5
- "modsCommit": "2bfb629dfaff0c8318047a4beb93cf1dc5b58b18",
6
- "buildDate": "2026-10-05T16:36:16Z",
4
+ "commit": "37832d0b7cad7b40bac7c82dff58629313913edf",
5
+ "modsCommit": "8e60c4cac989c0e0cc6d2c49407a5c67f5a4a8e6",
6
+ "buildDate": "2026-10-06T05:44:47Z",
7
7
  "platforms": {
8
8
  "darwin-arm64": {
9
9
  "binary": "claude.zst",
10
- "checksum": "45d9bf95d7acfd50c2baceca874110da4b5031a6483248daa95769d98a4b90e4",
11
- "size": 77725283,
10
+ "checksum": "dfabaa49a309abe3229719ecfaf41d557c831168b2b642cf2c24e7ab0fc40291",
11
+ "size": 78320219,
12
12
  "bundle": {
13
- "checksum": "5601f512d99646f5f494f7ba61140646b6ac378db5394f6d2faf233f7c1afcc3",
14
- "size": 77737596
13
+ "checksum": "29f45ff68babc471f404a9dbcd4ac9e380d8cdc0f0abdb4372227f0c7ee969b1",
14
+ "size": 78334565
15
15
  }
16
16
  },
17
17
  "darwin-x64": {
18
18
  "binary": "claude.zst",
19
- "checksum": "3285554867ceaffbb56e5b2b8e8935a7e38e2a6c72af83ec3b27a22481cb069d",
20
- "size": 81940184,
19
+ "checksum": "e05d438fc6fd2b2a955f4aa5520dae8dda26b148fa56fd12b3ce8d0cadf1a4ce",
20
+ "size": 82549522,
21
21
  "bundle": {
22
- "checksum": "a8c014583bac41261d5da40c162b4209529a5df4f8c58683c4cb4506c46e8369",
23
- "size": 81942828
22
+ "checksum": "ded81c8b0a9cd7278993a4c8549798017bd1ccdf33e4f9e87ecd1eb4eda4e966",
23
+ "size": 82552065
24
24
  }
25
25
  },
26
26
  "linux-arm64": {
27
27
  "binary": "claude.zst",
28
- "checksum": "a380389213f15f62e57f5e216b1c63cc10f6f039d75cc60d1952d1595dc5a968",
29
- "size": 86820953
28
+ "checksum": "e5e4c92326001ce91eeed9cdf165faec2932459d6863a9e087e2649536a9220b",
29
+ "size": 87405964
30
30
  },
31
31
  "linux-x64": {
32
32
  "binary": "claude.zst",
33
- "checksum": "a88616f640519c16f523cf1e9083a9ddf3b59da44edf8217e784426accf6e0e1",
34
- "size": 87545356
33
+ "checksum": "28509427a53a5c15bd94d022d39013cc4b867a8e6305497f48162dcf91576326",
34
+ "size": 88133859
35
35
  },
36
36
  "linux-arm64-musl": {
37
37
  "binary": "claude.zst",
38
- "checksum": "b765c7ec97c52ed875c6b30696833134d38681f56241173435c8322ca48d5e15",
39
- "size": 85216928
38
+ "checksum": "d23939bd282dc1179756023edac02080b91e36c28d7ebd9b4ed360e8bd97fd12",
39
+ "size": 85801900
40
40
  },
41
41
  "linux-x64-musl": {
42
42
  "binary": "claude.zst",
43
- "checksum": "5d77e2ad5af983e292bb51b8feb4b06c72677517c3c7b44aebe7a9ec8935df4b",
44
- "size": 85978900
43
+ "checksum": "3d5c168338a902acb2fd717fe1a15af658df0da389e1e1aa0273358702fd6ce4",
44
+ "size": 86587113
45
45
  },
46
46
  "win32-x64": {
47
47
  "binary": "claude.exe.zst",
48
- "checksum": "97bbb88194cd5efb63b1628619027ea9a7ecdf44c9112a2bb8f8ee924789741b",
49
- "size": 89837495
48
+ "checksum": "79f8686565d0b5abf02e19f0ae07d7de2a5ba2ed6837bc0711a7938dab8565b9",
49
+ "size": 90444996
50
50
  },
51
51
  "win32-arm64": {
52
52
  "binary": "claude.exe.zst",
53
- "checksum": "b11834fd3b719e1a57fceea602fb6f70ad18d5fbb92c62f5c278918b0ccdb557",
54
- "size": 86199542
53
+ "checksum": "e2bfc2a02b4ddac855fe62598be44d50384d71cecbea53f71df62fabccc1b14a",
54
+ "size": 86774574
55
55
  }
56
56
  },
57
57
  "sdkCompat": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@anthropic-ai/claude-agent-sdk",
3
- "version": "0.3.290",
3
+ "version": "0.3.292",
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.290",
65
- "@anthropic-ai/claude-agent-sdk-linux-arm64": "0.3.290",
66
- "@anthropic-ai/claude-agent-sdk-linux-x64-musl": "0.3.290",
67
- "@anthropic-ai/claude-agent-sdk-linux-arm64-musl": "0.3.290",
68
- "@anthropic-ai/claude-agent-sdk-darwin-x64": "0.3.290",
69
- "@anthropic-ai/claude-agent-sdk-darwin-arm64": "0.3.290",
70
- "@anthropic-ai/claude-agent-sdk-win32-x64": "0.3.290",
71
- "@anthropic-ai/claude-agent-sdk-win32-arm64": "0.3.290"
64
+ "@anthropic-ai/claude-agent-sdk-linux-x64": "0.3.292",
65
+ "@anthropic-ai/claude-agent-sdk-linux-arm64": "0.3.292",
66
+ "@anthropic-ai/claude-agent-sdk-linux-x64-musl": "0.3.292",
67
+ "@anthropic-ai/claude-agent-sdk-linux-arm64-musl": "0.3.292",
68
+ "@anthropic-ai/claude-agent-sdk-darwin-x64": "0.3.292",
69
+ "@anthropic-ai/claude-agent-sdk-darwin-arm64": "0.3.292",
70
+ "@anthropic-ai/claude-agent-sdk-win32-x64": "0.3.292",
71
+ "@anthropic-ai/claude-agent-sdk-win32-arm64": "0.3.292"
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-29pt3grd.mjs",
89
- "core-ygywjedj.mjs"
88
+ "core-95ey60bt.mjs",
89
+ "core-czfq02x9.mjs"
90
90
  ],
91
- "claudeCodeVersion": "2.1.290"
91
+ "claudeCodeVersion": "2.1.292"
92
92
  }
package/sdk-tools.d.ts CHANGED
@@ -468,6 +468,8 @@ export type ArtifactOutput =
468
468
  pinned?: boolean;
469
469
  }[];
470
470
  truncated?: boolean;
471
+ total?: number;
472
+ total_at_least?: true;
471
473
  pins_enabled?: boolean;
472
474
  scope?: "shared" | "all";
473
475
  external_listed?: true;
@@ -779,6 +781,10 @@ export interface AgentInput {
779
781
  * Optional model override for this agent. Takes precedence over the agent definition's model frontmatter and the configured default subagent model. If omitted, uses the agent definition's model, else the default (inherits from the parent unless a default subagent model is configured). Ignored for subagent_type: "fork" — forks always inherit the parent model.
780
782
  */
781
783
  model?: "sonnet" | "opus" | "haiku" | "fable";
784
+ /**
785
+ * Reasoning effort for this agent. Set this ONLY when the user, or instructions such as CLAUDE.md or a skill, explicitly ask that this agent or delegated work run at a specific effort level, never on your own judgment; otherwise omit it and the agent runs at its usual effort.
786
+ */
787
+ effort?: "low" | "medium" | "high" | "xhigh" | "max";
782
788
  /**
783
789
  * Agents run in the background by default; you will be notified when one completes. Set to false only when your very next action depends on this agent's result and nothing else could usefully happen while it runs — otherwise leave it in the background so the user can hand you other work.
784
790
  */
@@ -3302,7 +3308,7 @@ export interface BashOutput {
3302
3308
  */
3303
3309
  backgroundCwdHint?: string;
3304
3310
  /**
3305
- * True when this backgrounded command is owned by a synchronous subagent and is therefore terminated when that agent gives its final response; absent when the command survives (main loop, async subagents)
3311
+ * True when this backgrounded command is terminated at its caller's final response, so no completion notification can follow (a synchronous subagent's command, or a headless session that takes no further input and is not waiting for background commands); absent when the command survives
3306
3312
  */
3307
3313
  backgroundEndsWithFinalResponse?: true;
3308
3314
  /**
@@ -4048,11 +4054,19 @@ export interface ReadNotificationsOutput {
4048
4054
  * Verbatim notification body.
4049
4055
  */
4050
4056
  content: string;
4057
+ /**
4058
+ * RFC3339 timestamp, by this machine's clock, of when the notification reached this session's queue. Missing from results saved before this field existed.
4059
+ */
4060
+ arrived_at?: string;
4051
4061
  }[];
4052
4062
  /**
4053
4063
  * Notifications still queued after this drain (drains are size-budgeted); call the tool again to read them.
4054
4064
  */
4055
4065
  remaining: number;
4066
+ /**
4067
+ * RFC3339 timestamp, by this machine's clock, of when this call read the queue. Missing from results saved before this field existed.
4068
+ */
4069
+ read_at?: string;
4056
4070
  }
4057
4071
  export interface ScheduleWakeupOutput {
4058
4072
  /**
package/sdk.d.ts CHANGED
@@ -1199,6 +1199,7 @@ export declare type McpSdkServerConfig = {
1199
1199
  * Per-server tool-call timeout in milliseconds. Overrides the MCP_TOOL_TIMEOUT environment variable for this server. Hard wall-clock limit per call; progress notifications do not extend it. Values below 1000ms are ignored (falls through to MCP_TOOL_TIMEOUT or the default). Applies when the server is first registered; changing it for an already-registered server has no effect until it is removed and re-added.
1200
1200
  */
1201
1201
  timeout?: number;
1202
+
1202
1203
  };
1203
1204
 
1204
1205
  /**
@@ -3644,6 +3645,10 @@ export declare type SDKAssistantMessage = {
3644
3645
  * True when this assistant message was truncated by an interrupt/abort before the stream completed: stop_reason was never received and the content may end mid-word. Absent on normally completed messages.
3645
3646
  */
3646
3647
  aborted?: true;
3648
+ /**
3649
+ * ID of the subagent that produced this message: the `task_id` of its task events, unchanged when the subagent is resumed. Absent on main-thread messages.
3650
+ */
3651
+ agent_id?: string;
3647
3652
  /**
3648
3653
  * Subagent type that produced this message.
3649
3654
  */
@@ -3702,7 +3707,7 @@ export declare type SDKAuthStatusMessage = {
3702
3707
  };
3703
3708
 
3704
3709
  /**
3705
- * The full set of live background tasks, emitted whenever membership changes (start, completion, kill, a foreground agent being backgrounded) or an entry's `ambient` flag flips. A level signal, unlike the task_started/task_notification edge bookends: consumers that only need 'is background work running' should replace their set with each payload rather than pairing edges, so a missed bookend cannot wedge a stale running indicator. Ordering relative to the bookends for the same transition is unspecified (in practice the level precedes them) and the payload carries ids only, so do not correlate it with the edge stream. The level is per-process: nothing is emitted at startup, so consumers must reset to the empty set whenever the session's CLI process (re)starts and let the next membership change repopulate it. A host that re-initializes an already-running process (a repeated `initialize` control request, e.g. after reconnecting) is sent a snapshot of the current set right behind the success response to that request, even when it is empty, so it need not wait for a change; CLIs that predate this send nothing there.
3710
+ * The full set of live background tasks, emitted whenever membership changes (start, completion, kill, a foreground agent being backgrounded) or an entry's `ambient` flag or `parent_task_id` changes. A level signal, unlike the task_started/task_notification edge bookends: consumers that only need 'is background work running' should replace their set with each payload rather than pairing edges, so a missed bookend cannot wedge a stale running indicator. Ordering relative to the bookends for the same transition is unspecified (in practice a task that starts in the background joins the level before its task_started, and a finishing task leaves it after its task_updated and task_notification) and the payload carries ids only, so do not correlate it with the edge stream. The level is per-process: nothing is emitted at startup, so consumers must reset to the empty set whenever the session's CLI process (re)starts and let the next membership change repopulate it. A host that re-initializes an already-running process (a repeated `initialize` control request, e.g. after reconnecting) is sent a snapshot of the current set right behind the success response to that request, even when it is empty, so it need not wait for a change; CLIs that predate this send nothing there.
3706
3711
  */
3707
3712
  export declare type SDKBackgroundTasksChangedMessage = {
3708
3713
  type: 'system';
@@ -3712,8 +3717,16 @@ export declare type SDKBackgroundTasksChangedMessage = {
3712
3717
  */
3713
3718
  tasks: {
3714
3719
  task_id: string;
3720
+ /**
3721
+ * Id of one run of the task: equal on every task_* event, background_tasks_changed entry and saved notification (its origin.runId) of that run. A resumed task keeps its task_id and gets a new one. The run ids of one task sort, by plain string comparison, in the order the runs opened; a frame that names a run sorting before the one a reader shows is late. Nothing else about the format is promised. Absent for a task this process did not register, and from CLIs that predate it.
3722
+ */
3723
+ run_id?: string;
3715
3724
  task_type: string;
3716
3725
  description: string;
3726
+ /**
3727
+ * task_id of the subagent (local_agent) task whose agent launched this subagent, shell, monitor or workflow task. Absent when the launcher is the main thread, has no task_id of its own (a teammate, an agent inside a workflow), or is no longer tracked. A resumed subagent keeps its original parent. The parent may be a foreground or already-ended task, so treat an unknown id as no parent.
3728
+ */
3729
+ parent_task_id?: string;
3717
3730
  /**
3718
3731
  * True for tasks that are not activity (every skip_transcript task, plus every live-update watcher, requested or auto-started); hosts should exclude them from activity indicators.
3719
3732
  */
@@ -4473,6 +4486,7 @@ declare type SDKControlInitializeRequest = {
4473
4486
  * Per-server tool-call timeout in milliseconds. Overrides the MCP_TOOL_TIMEOUT environment variable for this server. Hard wall-clock limit per call; progress notifications do not extend it. Values below 1000ms are ignored (falls through to MCP_TOOL_TIMEOUT or the default). Applies when the server is first registered; changing it for an already-registered server has no effect until it is removed and re-added.
4474
4487
  */
4475
4488
  timeout?: number;
4489
+
4476
4490
  }>;
4477
4491
  /**
4478
4492
  * Optional, keyed by sdk server name (each key should also appear in sdkMcpServers; other keys are ignored). Unlike sdkMcpServerConfigs — host-declared settings the CLI keeps for the server's lifetime, same shape inline on mcp_set_servers — this is a one-shot cache of the servers' own handshake output: sent on initialize only, consumed by the connect that follows it, never retained. MCP handshake results the host already obtained from its in-process servers by delivering initialize + notifications/initialized (+ tools/list) to them itself before writing this request. For each such server the CLI answers its own MCP client's initialize and first tools/list from these results and skips the notifications/initialized round trip, so registering N in-process servers costs no mcp_message control round trips before the first turn; tools/call and everything after the handshake still flow as mcp_message exactly as before. The host MUST keep answering mcp_message for every server as if this field were absent: a CLI that predates the field ignores it and performs the full per-server handshake over the control channel, and a newer CLI does the same for any server whose entry is missing or malformed, whose initializeResult.protocolVersion differs from the MCP protocol version the CLI's client requests, or that the CLI had already connected. Entries apply only to the connect that follows this initialize; they are never retained for later reconnects. Over a remote session transport the CLI uses the field only when sdkMcpServerManifestsOrigin is set (see that field); a host on the CLI's own stream-json stdio transport needs no marker. sdk_mcp_manifests_parked in the response reports what became of each entry. Absent (older hosts, the Python SDK, browser clients): unchanged behaviour.
@@ -4608,6 +4622,7 @@ declare type SDKControlInterruptRequest = {
4608
4622
 
4609
4623
 
4610
4624
 
4625
+
4611
4626
  };
4612
4627
 
4613
4628
  /**
@@ -4855,7 +4870,7 @@ export declare type SDKControlPermissionRulesState = {
4855
4870
  };
4856
4871
 
4857
4872
  /**
4858
- * Read a file from the session filesystem for the remote sidebar viewer. Path is resolved against cwd and gated by the same read-permission rules as the Read tool.
4873
+ * Read a file from the session filesystem for the remote sidebar viewer. Path is resolved against cwd by default and gated by the same read-permission rules as the Read tool.
4859
4874
  */
4860
4875
  declare type SDKControlReadFileRequest = {
4861
4876
  subtype: 'read_file';
@@ -4865,6 +4880,7 @@ declare type SDKControlReadFileRequest = {
4865
4880
  * How to encode the bytes in `contents`. Defaults to utf-8 (lossy for binary); pass 'base64' to read images.
4866
4881
  */
4867
4882
  encoding?: 'utf-8' | 'base64';
4883
+
4868
4884
  };
4869
4885
 
4870
4886
  /**
@@ -4878,6 +4894,7 @@ export declare type SDKControlReadFileResponse = {
4878
4894
  * Set when the request asked for base64. Absent means utf-8 — including when an older CLI ignored the request's encoding field.
4879
4895
  */
4880
4896
  encoding?: 'base64';
4897
+
4881
4898
  };
4882
4899
 
4883
4900
  /**
@@ -5382,6 +5399,10 @@ export declare type SDKMessageOrigin = {
5382
5399
  */
5383
5400
  fireReason?: string;
5384
5401
 
5402
+ /**
5403
+ * On a background task's own notification: the run_id its task_* events carried, as of when the notification was queued. Not part of the text the model reads.
5404
+ */
5405
+ runId?: string;
5385
5406
  } | {
5386
5407
  kind: 'coordinator';
5387
5408
  } | {
@@ -5494,6 +5515,7 @@ export declare type SDKPartialAssistantMessage = {
5494
5515
  session_id: string;
5495
5516
  ttft_ms?: number;
5496
5517
 
5518
+
5497
5519
  /**
5498
5520
  * Client uuid of the user message this turn is answering (submitMessage options.uuid), stamped on a non-ping stream event each time that send changes: the turn's FIRST non-ping stream event (normally the frame that triggers the turn's initial ack), and, for a turn started by a synthetic (meta) prompt, the first non-ping stream event after each queued user message folded in mid-turn takes the echo over (see SDKAssistantMessage.user_message_uuid for the rule) — so a consumer can bind the reply stream to the send it answers without waiting for the result. A turn started by a typed prompt stamps only its first non-ping stream event; independently, its first complete assistant message is stamped as well (see SDKAssistantMessage.user_message_uuid), so the same uuid may appear on both. Absent on every other stream event of the turn, on turns that neither had a client uuid nor folded a user message in, and from older producers.
5499
5521
  */
@@ -5692,6 +5714,7 @@ export declare type SDKResultError = {
5692
5714
  */
5693
5715
  modelUsage: Record<string, ModelUsage>;
5694
5716
 
5717
+
5695
5718
  permission_denials: SDKPermissionDenial[];
5696
5719
  /**
5697
5720
  * User-initiated sends still waiting in the command queue when this result was produced. Greater than 0 means at least one more user turn (and result) follows without further input, barring cancellation; 0 means none is pending, or the session is ending (end_session or a shutdown latched mid-turn discards the backlog). Queued sends may coalesce into fewer turns, so this counts pending sends, not remaining results. System-generated queue entries are not counted. Absent on fatal startup results and on surfaces without a command queue.
@@ -5796,6 +5819,7 @@ export declare type SDKResultSuccess = {
5796
5819
  */
5797
5820
  modelUsage: Record<string, ModelUsage>;
5798
5821
 
5822
+
5799
5823
  permission_denials: SDKPermissionDenial[];
5800
5824
  /**
5801
5825
  * User-initiated sends still waiting in the command queue when this result was produced. Greater than 0 means at least one more user turn (and result) follows without further input, barring cancellation; 0 means none is pending, or the session is ending (end_session or a shutdown latched mid-turn discards the backlog). Queued sends may coalesce into fewer turns, so this counts pending sends, not remaining results. System-generated queue entries are not counted. Absent on fatal startup results and on surfaces without a command queue.
@@ -5905,6 +5929,7 @@ export declare type SDKStatusMessage = {
5905
5929
  compact_result?: 'success' | 'failed';
5906
5930
  compact_error?: string;
5907
5931
 
5932
+
5908
5933
  uuid: UUID;
5909
5934
  session_id: string;
5910
5935
  };
@@ -6000,6 +6025,10 @@ export declare type SDKTaskNotificationMessage = {
6000
6025
  type: 'system';
6001
6026
  subtype: 'task_notification';
6002
6027
  task_id: string;
6028
+ /**
6029
+ * Id of one run of the task: equal on every task_* event, background_tasks_changed entry and saved notification (its origin.runId) of that run. A resumed task keeps its task_id and gets a new one. The run ids of one task sort, by plain string comparison, in the order the runs opened; a frame that names a run sorting before the one a reader shows is late. Nothing else about the format is promised. Absent for a task this process did not register, and from CLIs that predate it.
6030
+ */
6031
+ run_id?: string;
6003
6032
  tool_use_id?: string;
6004
6033
  status: 'completed' | 'failed' | 'stopped';
6005
6034
  /**
@@ -6017,6 +6046,8 @@ export declare type SDKTaskNotificationMessage = {
6017
6046
  * CLI-owned: for a backgrounded MCP task (task_type mcp_task) that completed, the `resource_link` content blocks of its final result — the files it returned by reference — collected from the raw result before the CLI renders it as the text the model reads. A backgrounded task's tool_result is the placeholder text and its real result arrives as this notification, so this is where a host learns which files that tool call produced; join to the originating call via tool_use_id. Same fields and caps as tool_use_result.resourceLinks (at most 50 links, 64 KiB serialized), absent when the result had none or the task is any other type. Never populated from the server's _meta.
6018
6047
  */
6019
6048
  resource_links?: SDKMcpResourceLink[];
6049
+
6050
+
6020
6051
  skip_transcript?: boolean;
6021
6052
  /**
6022
6053
  * True for tasks that are not activity (every skip_transcript task, plus every live-update watcher, requested or auto-started); hosts should exclude them from activity indicators.
@@ -6030,6 +6061,10 @@ export declare type SDKTaskProgressMessage = {
6030
6061
  type: 'system';
6031
6062
  subtype: 'task_progress';
6032
6063
  task_id: string;
6064
+ /**
6065
+ * Id of one run of the task: equal on every task_* event, background_tasks_changed entry and saved notification (its origin.runId) of that run. A resumed task keeps its task_id and gets a new one. The run ids of one task sort, by plain string comparison, in the order the runs opened; a frame that names a run sorting before the one a reader shows is late. Nothing else about the format is promised. Absent for a task this process did not register, and from CLIs that predate it.
6066
+ */
6067
+ run_id?: string;
6033
6068
  tool_use_id?: string;
6034
6069
  description: string;
6035
6070
  /**
@@ -6055,6 +6090,10 @@ export declare type SDKTaskStartedMessage = {
6055
6090
  type: 'system';
6056
6091
  subtype: 'task_started';
6057
6092
  task_id: string;
6093
+ /**
6094
+ * Id of one run of the task: equal on every task_* event, background_tasks_changed entry and saved notification (its origin.runId) of that run. A resumed task keeps its task_id and gets a new one. The run ids of one task sort, by plain string comparison, in the order the runs opened; a frame that names a run sorting before the one a reader shows is late. Nothing else about the format is promised. Absent for a task this process did not register, and from CLIs that predate it.
6095
+ */
6096
+ run_id?: string;
6058
6097
  tool_use_id?: string;
6059
6098
  description: string;
6060
6099
  /**
@@ -6069,6 +6108,10 @@ export declare type SDKTaskStartedMessage = {
6069
6108
  * Nesting depth of a spawned subagent (local_agent) task: 1 for a top-level spawn, N+1 when spawned from inside a depth-N agent. Not set on other tasks.
6070
6109
  */
6071
6110
  spawn_depth?: number;
6111
+ /**
6112
+ * task_id of the subagent (local_agent) task whose agent launched this subagent, shell, monitor or workflow task. Absent when the launcher is the main thread, has no task_id of its own (a teammate, an agent inside a workflow), or is no longer tracked. A resumed subagent keeps its original parent. The parent may be a foreground or already-ended task, so treat an unknown id as no parent.
6113
+ */
6114
+ parent_task_id?: string;
6072
6115
  task_type?: string;
6073
6116
  /**
6074
6117
  * meta.name from the workflow script (e.g. 'spec'). Only set when task_type is 'local_workflow'.
@@ -6091,6 +6134,10 @@ export declare type SDKTaskUpdatedMessage = {
6091
6134
  type: 'system';
6092
6135
  subtype: 'task_updated';
6093
6136
  task_id: string;
6137
+ /**
6138
+ * Id of one run of the task: equal on every task_* event, background_tasks_changed entry and saved notification (its origin.runId) of that run. A resumed task keeps its task_id and gets a new one. The run ids of one task sort, by plain string comparison, in the order the runs opened; a frame that names a run sorting before the one a reader shows is late. Nothing else about the format is promised. Absent for a task this process did not register, and from CLIs that predate it.
6139
+ */
6140
+ run_id?: string;
6094
6141
  /**
6095
6142
  * Wire-safe subset of TaskState fields that changed. Excludes abortController, messages, result. Clients merge into their local task map.
6096
6143
  */
@@ -6306,6 +6353,10 @@ export declare type SDKUserMessage = {
6306
6353
  */
6307
6354
  inline_pastes?: string[];
6308
6355
  session_id?: string;
6356
+ /**
6357
+ * ID of the subagent that produced this message: the `task_id` of its task events, unchanged when the subagent is resumed. Absent on main-thread messages.
6358
+ */
6359
+ agent_id?: string;
6309
6360
  /**
6310
6361
  * Subagent type that produced this message.
6311
6362
  */
@@ -9816,7 +9867,7 @@ export declare interface Transport {
9816
9867
  /**
9817
9868
  * Messages meaning "a usage limit was genuinely reached" — the error-path
9818
9869
  * outputs of getLimitReachedText (rateLimitMessages.ts) and
9819
- * getFableCreditsRequiredContent (api/errors.ts).
9870
+ * getUsageCreditsOnlyModelRejectionContent (api/errors.ts).
9820
9871
  *
9821
9872
  * @alpha
9822
9873
  */