@anthropic-ai/claude-agent-sdk 0.3.198 → 0.3.199

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,47 +1,47 @@
1
1
  {
2
- "version": "2.1.198",
3
- "commit": "b80c496480ebf28e6dfe755cf0b8e3dd1d7cba1f",
4
- "buildDate": "2026-07-01T06:17:25Z",
2
+ "version": "2.1.199",
3
+ "commit": "968b0c4118bde7c998acd97511e68daecacd8507",
4
+ "buildDate": "2026-07-02T01:58:04Z",
5
5
  "platforms": {
6
6
  "darwin-arm64": {
7
7
  "binary": "claude",
8
- "checksum": "ab6f7ee109816ede414f7c285446633f805b623aa609f425609a64266451d61e",
9
- "size": 229328464
8
+ "checksum": "e3cb61abc8a2ec7b98976cee1ffdde5a3fa755c9990bc8d688cd89290e0dcec0",
9
+ "size": 232155536
10
10
  },
11
11
  "darwin-x64": {
12
12
  "binary": "claude",
13
- "checksum": "280b6cfc60dacc4caed31af1249e53c259c01759556e60633944c02405c82dd0",
14
- "size": 238706000
13
+ "checksum": "e64853ff3bc2ae6ed8115581c851e1176762d445d0b8b9e0dd37d0d560224a88",
14
+ "size": 240192080
15
15
  },
16
16
  "linux-arm64": {
17
17
  "binary": "claude",
18
- "checksum": "99b50a6f2b1f3ef07bcaf1e58a2f9883c470c84e428afa321972b1aa20372e9a",
19
- "size": 245742320
18
+ "checksum": "14851b5170b154b01baca09bba970172e70cdd768b5a012bf347ba0f594b4ad3",
19
+ "size": 247184112
20
20
  },
21
21
  "linux-x64": {
22
22
  "binary": "claude",
23
- "checksum": "7066af42a5fe93038c13af5072d4c034dc3928092cb121fdd892c76b94b6b84d",
24
- "size": 248900408
23
+ "checksum": "b31dfd5e3dee23b51c42e0d8ddb405148978237d3aabc8cbbf77c5cf83367e27",
24
+ "size": 250383160
25
25
  },
26
26
  "linux-arm64-musl": {
27
27
  "binary": "claude",
28
- "checksum": "88cb391085e419457569bcc57a672f734f30b424e17df7323f3bbb421238e801",
29
- "size": 238990520
28
+ "checksum": "4115c07bc6dfa71affff595400599032b70b4ab25b7a2dae982341ef4da47b38",
29
+ "size": 240432312
30
30
  },
31
31
  "linux-x64-musl": {
32
32
  "binary": "claude",
33
- "checksum": "42892159a03bee492926b616b1270313544f7a52b68d32cb680e91984a4c6659",
34
- "size": 243589504
33
+ "checksum": "22c8b0861078cef1b572023e7eda4ce0dda7e12cc2e3060858eaa3de010bee21",
34
+ "size": 245068160
35
35
  },
36
36
  "win32-x64": {
37
37
  "binary": "claude.exe",
38
- "checksum": "6afd07cb03aa981c5e918808f53a1e2b729015b695122a944f6e41aaf5393933",
39
- "size": 239292064
38
+ "checksum": "63de670613bb74594564a2125cb54e0e2e78192c5696e396adfae093b9132eec",
39
+ "size": 240716448
40
40
  },
41
41
  "win32-arm64": {
42
42
  "binary": "claude.exe",
43
- "checksum": "10a6d21332f674c87f52b1dc09926945d0169f1bb82aced84ada100639ab70bc",
44
- "size": 233758880
43
+ "checksum": "7e4900b1ce5588003e0ade6caa0aaef1e2b8efd903c5a86c671d0de258b7a4d4",
44
+ "size": 235182752
45
45
  }
46
46
  }
47
47
  }
package/manifest.zst.json CHANGED
@@ -1,55 +1,55 @@
1
1
  {
2
- "version": "2.1.198",
3
- "commit": "b80c496480ebf28e6dfe755cf0b8e3dd1d7cba1f",
4
- "buildDate": "2026-07-01T06:19:10Z",
2
+ "version": "2.1.199",
3
+ "commit": "968b0c4118bde7c998acd97511e68daecacd8507",
4
+ "buildDate": "2026-07-02T01:59:55Z",
5
5
  "platforms": {
6
6
  "darwin-arm64": {
7
7
  "binary": "claude.zst",
8
- "checksum": "7bc5ee873344f53ca0ea0d7ae48c77c3787aa8f437d5aeb33a6a6d83ab8d813f",
9
- "size": 47036104,
8
+ "checksum": "6ee8d7ed4bfd7e0dd2d4f20d694cdade31df5b32cd9c667c8c1ed807832ebb00",
9
+ "size": 48610501,
10
10
  "bundle": {
11
- "checksum": "e84cec46ebd581937b5128e7be4f3e8788b13947bf4040a699d3404478f4bc57",
12
- "size": 47034441
11
+ "checksum": "bffd78fbb26dcc00be341109772da068ada6ad38ef0826531c6595d295b5f5a2",
12
+ "size": 48620700
13
13
  }
14
14
  },
15
15
  "darwin-x64": {
16
16
  "binary": "claude.zst",
17
- "checksum": "b70b7a3d9f3fdb675e119bca0c1632d810aacdefadee1da5e82ebb77cbabd124",
18
- "size": 51377668,
17
+ "checksum": "c41a93c21b86a6e6ec5bf385732aa0594d522e3edcd82264a2b6d36185945237",
18
+ "size": 51631685,
19
19
  "bundle": {
20
- "checksum": "c8eb65cce724f80d4467c9850e0643cbab91e1d66fa88b21ea17f398c7835d50",
21
- "size": 51390885
20
+ "checksum": "cebf0ccc7298485d13d635decbbc43bff1e513a34fbef666dc539542e70486eb",
21
+ "size": 51645139
22
22
  }
23
23
  },
24
24
  "linux-arm64": {
25
25
  "binary": "claude.zst",
26
- "checksum": "4d9f42ab338ead6a6e9b9738a6d1ec7ba9a0737acbc8cf7f09099172b6ff16d7",
27
- "size": 56120743
26
+ "checksum": "c615bb15e71949249c3c2ee85d66a62a118c071be691a9f534e6f232a3b1151b",
27
+ "size": 56363665
28
28
  },
29
29
  "linux-x64": {
30
30
  "binary": "claude.zst",
31
- "checksum": "dc7986a7fad5958bfe4bf9eaf14936da2bafb283de7b80ca3e2e1878620873fe",
32
- "size": 57376892
31
+ "checksum": "0c3f4f2a2f9dc653da2e6acc1a45967d504e8577a64b675ba8e9fcb2dcb0d24c",
32
+ "size": 57645371
33
33
  },
34
34
  "linux-arm64-musl": {
35
35
  "binary": "claude.zst",
36
- "checksum": "55c5691e89c947a04777a7e2711c7bfe1589cf1783ff47ae25ad277bef9f4aeb",
37
- "size": 54805858
36
+ "checksum": "85c2e1a6877beaa247a85555e0b815165d5060d8365893103aefb1dd5e9fd717",
37
+ "size": 55048686
38
38
  },
39
39
  "linux-x64-musl": {
40
40
  "binary": "claude.zst",
41
- "checksum": "d0eecbaa59489d9282fbfccabf010feadb3c212e6a40b7e3e112d1c07c6cf300",
42
- "size": 56180603
41
+ "checksum": "b264b1b400162a528623cb93b5275d0cdcea5a7da7af09a33c9a4b101917a0c0",
42
+ "size": 56449012
43
43
  },
44
44
  "win32-x64": {
45
45
  "binary": "claude.exe.zst",
46
- "checksum": "f9ce31065214cba9a1838b4eafd00f004002389a1ee87c45ca00d901fbc03129",
47
- "size": 57521925
46
+ "checksum": "d14fc2cd93ec55e9b2d97b391be53497ce3398ed816c129a60fd617d01ab58db",
47
+ "size": 57765508
48
48
  },
49
49
  "win32-arm64": {
50
50
  "binary": "claude.exe.zst",
51
- "checksum": "f4c7b7c80da3f07dea7d13530eeea321db4380a9da4bc1a1010c13e7e8ea6736",
52
- "size": 55546586
51
+ "checksum": "d3557e13095e4b0cb61486a861023d1235cb1f1d81c422cc69fc545d5403304e",
52
+ "size": 55778042
53
53
  }
54
54
  }
55
55
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@anthropic-ai/claude-agent-sdk",
3
- "version": "0.3.198",
3
+ "version": "0.3.199",
4
4
  "main": "sdk.mjs",
5
5
  "types": "sdk.d.ts",
6
6
  "exports": {
@@ -57,14 +57,14 @@
57
57
  "zod": "^4.0.0"
58
58
  },
59
59
  "optionalDependencies": {
60
- "@anthropic-ai/claude-agent-sdk-linux-x64": "0.3.198",
61
- "@anthropic-ai/claude-agent-sdk-linux-arm64": "0.3.198",
62
- "@anthropic-ai/claude-agent-sdk-linux-x64-musl": "0.3.198",
63
- "@anthropic-ai/claude-agent-sdk-linux-arm64-musl": "0.3.198",
64
- "@anthropic-ai/claude-agent-sdk-darwin-x64": "0.3.198",
65
- "@anthropic-ai/claude-agent-sdk-darwin-arm64": "0.3.198",
66
- "@anthropic-ai/claude-agent-sdk-win32-x64": "0.3.198",
67
- "@anthropic-ai/claude-agent-sdk-win32-arm64": "0.3.198"
60
+ "@anthropic-ai/claude-agent-sdk-linux-x64": "0.3.199",
61
+ "@anthropic-ai/claude-agent-sdk-linux-arm64": "0.3.199",
62
+ "@anthropic-ai/claude-agent-sdk-linux-x64-musl": "0.3.199",
63
+ "@anthropic-ai/claude-agent-sdk-linux-arm64-musl": "0.3.199",
64
+ "@anthropic-ai/claude-agent-sdk-darwin-x64": "0.3.199",
65
+ "@anthropic-ai/claude-agent-sdk-darwin-arm64": "0.3.199",
66
+ "@anthropic-ai/claude-agent-sdk-win32-x64": "0.3.199",
67
+ "@anthropic-ai/claude-agent-sdk-win32-arm64": "0.3.199"
68
68
  },
69
69
  "files": [
70
70
  "sdk.mjs",
@@ -80,5 +80,5 @@
80
80
  "manifest.json",
81
81
  "manifest.zst.json"
82
82
  ],
83
- "claudeCodeVersion": "2.1.198"
83
+ "claudeCodeVersion": "2.1.199"
84
84
  }
package/sdk-tools.d.ts CHANGED
@@ -29,6 +29,7 @@ export type ToolInputSchemas =
29
29
  | WebFetchInput
30
30
  | WebSearchInput
31
31
  | AskUserQuestionInput
32
+ | ClaudeDesignInput
32
33
  | ProjectsInput
33
34
  | EnterPlanModeInput
34
35
  | TaskCreateInput
@@ -87,6 +88,7 @@ export type ToolOutputSchemas =
87
88
  | CronDeleteOutput
88
89
  | CronListOutput
89
90
  | PushNotificationOutput
91
+ | ClaudeDesignOutput
90
92
  | ProjectsOutput;
91
93
  export type AgentOutput =
92
94
  | {
@@ -304,6 +306,10 @@ export type FileReadOutput =
304
306
  */
305
307
  filePath: string;
306
308
  };
309
+ /**
310
+ * Set when the dedup matched a startup-seeded entry (CLAUDE.md / nested memory) rather than a prior Read tool_result
311
+ */
312
+ source?: "seeded";
307
313
  };
308
314
  export type ListMcpResourcesOutput = {
309
315
  /**
@@ -364,9 +370,6 @@ export type ProjectsOutput =
364
370
  knowledge: {
365
371
  knowledge_size: number;
366
372
  max_knowledge_size: number;
367
- search_threshold: number | null;
368
- rag_active: boolean;
369
- remaining_budget: number | null;
370
373
  };
371
374
  }
372
375
  | {
@@ -395,13 +398,6 @@ export type ProjectsOutput =
395
398
  path: string;
396
399
  doc_uuid: string;
397
400
  replaced: boolean;
398
- knowledge: {
399
- knowledge_size: number;
400
- max_knowledge_size: number;
401
- search_threshold: number | null;
402
- rag_active: boolean;
403
- remaining_budget: number | null;
404
- };
405
401
  }
406
402
  | {
407
403
  method: "project_delete";
@@ -716,6 +712,10 @@ export interface ReportFindingsInput {
716
712
  * Concrete inputs/state → wrong output/crash
717
713
  */
718
714
  failure_scenario: string;
715
+ /**
716
+ * Short kebab-case slug of the finding type, e.g. "correctness", "simplification", "efficiency", "test-coverage"
717
+ */
718
+ category?: string;
719
719
  /**
720
720
  * Set when a verify pass ran; absent on inline-only reviews
721
721
  */
@@ -2337,6 +2337,18 @@ export interface AskUserQuestionInput {
2337
2337
  source?: string;
2338
2338
  };
2339
2339
  }
2340
+ export interface ClaudeDesignInput {
2341
+ /**
2342
+ * Claude Design action to perform. Call with "list" first to discover the available operations and their argument schemas.
2343
+ */
2344
+ operation: string;
2345
+ /**
2346
+ * Action input object (server-validated). Pass {} for operations that take no input.
2347
+ */
2348
+ arguments: {
2349
+ [k: string]: unknown;
2350
+ };
2351
+ }
2340
2352
  export interface ProjectsInput {
2341
2353
  method: "project_info" | "project_read" | "project_search" | "project_write" | "project_delete";
2342
2354
  /**
@@ -2351,10 +2363,6 @@ export interface ProjectsInput {
2351
2363
  * project_write: a file inside the working directory to upload. The tool reads, encodes, and uploads directly — contents never enter your context. Mutually exclusive with content.
2352
2364
  */
2353
2365
  local_path?: string;
2354
- /**
2355
- * project_write: bypass the chat-injection budget guard. Set only when the write is genuinely worth degrading chat to retrieval mode for everyone in the project.
2356
- */
2357
- force?: boolean;
2358
2366
  /**
2359
2367
  * project_search: knowledge-base query
2360
2368
  */
@@ -2992,6 +3000,10 @@ export interface ReportFindingsOutput {
2992
3000
  * Concrete inputs/state → wrong output/crash
2993
3001
  */
2994
3002
  failure_scenario: string;
3003
+ /**
3004
+ * Short kebab-case slug of the finding type, e.g. "correctness", "simplification", "efficiency", "test-coverage"
3005
+ */
3006
+ category?: string;
2995
3007
  /**
2996
3008
  * Set when a verify pass ran; absent on inline-only reviews
2997
3009
  */
@@ -3484,10 +3496,15 @@ export interface PushNotificationOutput {
3484
3496
  pushSent?: boolean;
3485
3497
  localSent?: boolean;
3486
3498
  disabledReason?: "config_off" | "user_present" | "no_transport";
3487
- idleSec?: number;
3488
- hasFocus?: boolean;
3489
3499
  /**
3490
3500
  * ISO timestamp captured at tool execution on the emitting process. Optional — resumed sessions replay pre-sentAt outputs verbatim.
3491
3501
  */
3492
3502
  sentAt?: string;
3493
3503
  }
3504
+ export interface ClaudeDesignOutput {
3505
+ operation: string;
3506
+ content: {
3507
+ [k: string]: unknown;
3508
+ }[];
3509
+ isError?: boolean;
3510
+ }
package/sdk.d.ts CHANGED
@@ -188,6 +188,12 @@ export declare type BaseOutputFormat = {
188
188
  /**
189
189
  * Permission callback function for controlling tool usage.
190
190
  * Called before each tool execution to determine if it should be allowed.
191
+ *
192
+ * Return `null` ONLY after the consumer has already sent the
193
+ * control_response out-of-band (e.g. a signed HTTP POST echoing
194
+ * `requestId`); the SDK will skip its own transport write. Fail-closed: an
195
+ * accidental null means no control_response is sent and the tool stays
196
+ * blocked indefinitely — permission prompts have no park deadline.
191
197
  */
192
198
  export declare type CanUseTool = (toolName: string, input: Record<string, unknown>, options: {
193
199
  /** Signaled if the operation should be aborted. */
@@ -231,7 +237,13 @@ export declare type CanUseTool = (toolName: string, input: Record<string, unknow
231
237
  toolUseID: string;
232
238
  /** If running within the context of a sub-agent, the sub-agent's ID. */
233
239
  agentID?: string;
234
- }) => Promise<PermissionResult>;
240
+ /**
241
+ * The control_request envelope's `request_id`. A control_response sent
242
+ * out-of-band (e.g. a signed HTTP POST instead of the SDK's WS write)
243
+ * must echo this value for the worker to match it.
244
+ */
245
+ requestId: string;
246
+ }) => Promise<PermissionResult | null>;
235
247
 
236
248
  export declare type ConfigChangeHookInput = BaseHookInput & {
237
249
  hook_event_name: 'ConfigChange';
@@ -2617,8 +2629,13 @@ declare const SandboxCredentialsConfigSchema: () => z.ZodOptional<z.ZodObject<{
2617
2629
  }, z.core.$strip>>>;
2618
2630
  envVars: z.ZodOptional<z.ZodArray<z.ZodObject<{
2619
2631
  name: z.ZodString;
2620
- mode: z.ZodLiteral<"deny">;
2632
+ mode: z.ZodEnum<{
2633
+ deny: "deny";
2634
+ mask: "mask";
2635
+ }>;
2636
+ injectHosts: z.ZodOptional<z.ZodArray<z.ZodString>>;
2621
2637
  }, z.core.$strip>>>;
2638
+ allowPlaintextInject: z.ZodOptional<z.ZodBoolean>;
2622
2639
  }, z.core.$strip>>;
2623
2640
 
2624
2641
  export declare type SandboxFilesystemConfig = NonNullable<z.infer<ReturnType<typeof SandboxFilesystemConfigSchema>>>;
@@ -2696,8 +2713,13 @@ declare const SandboxSettingsSchema: () => z.ZodObject<{
2696
2713
  }, z.core.$strip>>>;
2697
2714
  envVars: z.ZodOptional<z.ZodArray<z.ZodObject<{
2698
2715
  name: z.ZodString;
2699
- mode: z.ZodLiteral<"deny">;
2716
+ mode: z.ZodEnum<{
2717
+ deny: "deny";
2718
+ mask: "mask";
2719
+ }>;
2720
+ injectHosts: z.ZodOptional<z.ZodArray<z.ZodString>>;
2700
2721
  }, z.core.$strip>>>;
2722
+ allowPlaintextInject: z.ZodOptional<z.ZodBoolean>;
2701
2723
  }, z.core.$strip>>;
2702
2724
  ignoreViolations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>>;
2703
2725
  enableWeakerNestedSandbox: z.ZodOptional<z.ZodBoolean>;
@@ -3387,6 +3409,10 @@ declare type SDKControlPermissionRequest = {
3387
3409
  tool_use_id: string;
3388
3410
  agent_id?: string;
3389
3411
  description?: string;
3412
+ /**
3413
+ * True when the tool's approval card IS the user-interaction surface (Tool.requiresUserInteraction()). SDK hosts must not offer one-tap Approve/Deny for these — the user has to open the session and respond on the card itself.
3414
+ */
3415
+ requires_user_interaction?: boolean;
3390
3416
  };
3391
3417
 
3392
3418
  /**
@@ -5813,7 +5839,7 @@ export declare interface Settings {
5813
5839
  httpProxyPort?: number;
5814
5840
  socksProxyPort?: number;
5815
5841
  /**
5816
- * [EXPERIMENTAL] Enable in-process TLS termination so the per-request filter can see HTTPS request bodies. Provide a CA cert+key, or omit both to have sandbox-runtime generate an ephemeral one for the session.
5842
+ * [EXPERIMENTAL] Enable in-process TLS termination so the per-request filter can see HTTPS request bodies. Provide a CA cert+key, or omit both to have sandbox-runtime generate an ephemeral one for the session. Only honored from user, managed/policy, or CLI (`--settings`) settings — project settings (.claude/settings.json and .claude/settings.local.json) are ignored.
5817
5843
  */
5818
5844
  tlsTerminate?: {
5819
5845
  caCertPath?: string;
@@ -5857,7 +5883,7 @@ export declare interface Settings {
5857
5883
  mode: 'deny';
5858
5884
  }[];
5859
5885
  /**
5860
- * Environment variables to protect. `deny` unsets the variable for sandboxed commands.
5886
+ * Environment variables to protect. `deny` unsets the variable for sandboxed commands; `mask` substitutes a sentinel inside the sandbox and injects the real value at the proxy.
5861
5887
  */
5862
5888
  envVars?: {
5863
5889
  /**
@@ -5865,10 +5891,18 @@ export declare interface Settings {
5865
5891
  */
5866
5892
  name: string;
5867
5893
  /**
5868
- * Access mode for this environment variable. Only `deny` is supported.
5894
+ * Access mode for this environment variable. `deny` unsets the variable for sandboxed commands; `mask` shows sandboxed commands a sentinel value and the host proxy swaps sentinel→real on egress to `injectHosts`.
5869
5895
  */
5870
- mode: 'deny';
5896
+ mode: 'deny' | 'mask';
5897
+ /**
5898
+ * Optional narrowing of where the proxy substitutes this credential. Only meaningful when mode is `mask`; accepted but ignored for `deny`. If unset, defaults to `network.allowedDomains` — the credential is injected at every reachable host. Each entry must be reachable via `network.allowedDomains` (sandbox-runtime validates this).
5899
+ */
5900
+ injectHosts?: string[];
5871
5901
  }[];
5902
+ /**
5903
+ * Allow sentinel→real substitution on the plain-HTTP proxy path. Defaults to false: without TLS termination the upstream identity is unverified and the credential travels in cleartext. Set only for trusted-network test fixtures. Only honored from user, managed/policy, or CLI (`--settings`) settings — project settings (.claude/settings.json and .claude/settings.local.json) are ignored.
5904
+ */
5905
+ allowPlaintextInject?: boolean;
5872
5906
  };
5873
5907
  ignoreViolations?: {
5874
5908
  [k: string]: string[];