@effect/ai-anthropic 4.0.0-beta.70 → 4.0.0-beta.72

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.
@@ -1,28 +1,96 @@
1
1
  /**
2
- * Anthropic provider-defined tools for use with the LanguageModel.
2
+ * The `AnthropicTool` module defines Anthropic provider tools that can be
3
+ * attached to Anthropic-backed Effect AI language model requests. These are
4
+ * provider-defined tools: Anthropic owns the tool names, argument formats,
5
+ * beta headers, and in some cases the execution environment.
6
+ *
7
+ * **Mental model**
8
+ *
9
+ * - Exports such as {@link Bash_20250124}, {@link CodeExecution_20250825},
10
+ * {@link ComputerUse_20250124}, and {@link WebSearch_20250305} create
11
+ * versioned provider-defined tool values understood by the Anthropic
12
+ * language model integration
13
+ * - Tool-specific `Schema` exports describe the arguments Claude may provide
14
+ * when invoking that provider tool
15
+ * - Some tools run on Anthropic infrastructure, such as
16
+ * {@link WebSearch_20250305}, {@link WebFetch_20250910}, and
17
+ * {@link CodeExecution_20250825}; handler-backed tools such as Bash,
18
+ * Computer Use, and Text Editor variants require application-side execution
19
+ * - Selecting a versioned tool lets the Anthropic model layer add the beta
20
+ * header required by that exact Anthropic API version
21
+ *
22
+ * **Common tasks**
23
+ *
24
+ * - Enable terminal-style actions with {@link Bash_20250124}
25
+ * - Enable sandboxed code execution with {@link CodeExecution_20250825}
26
+ * - Enable desktop automation payloads with {@link ComputerUse_20250124}
27
+ * - Enable persistent memory file operations with {@link Memory_20250818}
28
+ * - Enable text-editor commands with {@link TextEditor_20250728}
29
+ * - Enable hosted web capabilities with {@link WebSearch_20250305} or
30
+ * {@link WebFetch_20250910}
31
+ * - Restrict tool discovery with {@link ToolSearchRegex_20251119} or
32
+ * {@link ToolSearchBM25_20251119}
33
+ *
34
+ * **Quickstart**
35
+ *
36
+ * **Example** (Creating hosted Anthropic tools)
37
+ *
38
+ * ```ts
39
+ * import { AnthropicTool } from "@effect/ai-anthropic"
40
+ *
41
+ * const tools = [
42
+ * AnthropicTool.WebSearch_20250305({ maxUses: 3 }),
43
+ * AnthropicTool.WebFetch_20250910({
44
+ * citations: { enabled: true }
45
+ * })
46
+ * ]
47
+ * ```
3
48
  *
4
- * Provides tools that are natively supported by Anthropic's API, including
5
- * Bash, Code Execution, Computer Use, Memory, and Text Editor functionality.
49
+ * **Gotchas**
50
+ *
51
+ * - The suffix date is part of the Anthropic tool contract; choose the version
52
+ * that matches the model and beta behavior you intend to use
53
+ * - Handler-backed tools expose schemas for Claude's requested actions, but
54
+ * your runtime is responsible for performing those actions and returning
55
+ * results
6
56
  *
7
57
  * @since 4.0.0
8
58
  */
9
59
  import * as Schema from "effect/Schema";
10
60
  import * as Tool from "effect/unstable/ai/Tool";
11
61
  /**
12
- * Union of all Anthropic provider-defined tools.
62
+ * Union of all Anthropic provider-defined tool definitions exported by this module.
63
+ *
64
+ * **When to use**
65
+ *
66
+ * Use when a helper, collection, or option accepts any Anthropic
67
+ * provider-defined tool value created by this module.
68
+ *
69
+ * **Details**
70
+ *
71
+ * The union is built from the return types of the exported constructors,
72
+ * including Bash, Code Execution, Computer Use, Memory, Text Editor, Tool
73
+ * Search, Web Fetch, and Web Search tool versions.
13
74
  *
14
75
  * @category models
15
76
  * @since 4.0.0
16
77
  */
17
78
  export type AnthropicTool = ReturnType<typeof Bash_20241022> | ReturnType<typeof Bash_20250124> | ReturnType<typeof CodeExecution_20250522> | ReturnType<typeof CodeExecution_20250825> | ReturnType<typeof ComputerUse_20241022> | ReturnType<typeof ComputerUse_20250124> | ReturnType<typeof ComputerUse_20251124> | ReturnType<typeof Memory_20250818> | ReturnType<typeof TextEditor_20241022> | ReturnType<typeof TextEditor_20250124> | ReturnType<typeof TextEditor_20250429> | ReturnType<typeof TextEditor_20250728> | ReturnType<typeof ToolSearchRegex_20251119> | ReturnType<typeof ToolSearchBM25_20251119> | ReturnType<typeof WebFetch_20250910> | ReturnType<typeof WebSearch_20250305>;
18
79
  /**
19
- * Anthropic Bash tool (2024-10-22 version).
80
+ * Defines the Anthropic Bash tool (2024-10-22 version).
81
+ *
82
+ * **When to use**
83
+ *
84
+ * Use when you need the model to execute bash commands and require the 2024-10-22
85
+ * version of the Anthropic computer-use beta.
20
86
  *
21
87
  * **Details**
22
88
  *
23
89
  * Allows the model to execute bash commands in a sandboxed environment.
24
90
  * Requires the "computer-use-2024-10-22" beta header.
25
91
  *
92
+ * @see {@link Bash_20250124} for the newer 2025-01-24 version of the bash tool
93
+ *
26
94
  * @category Bash
27
95
  * @since 4.0.0
28
96
  */
@@ -39,13 +107,20 @@ export declare const Bash_20241022: <Mode extends Tool.FailureMode | undefined =
39
107
  readonly failureMode: Mode extends undefined ? "error" : Mode;
40
108
  }, true>;
41
109
  /**
42
- * Anthropic Bash tool (2025-01-24 version).
110
+ * Defines the Anthropic Bash tool (2025-01-24 version).
111
+ *
112
+ * **When to use**
113
+ *
114
+ * Use when you need the model to execute bash commands and require the 2025-01-24
115
+ * version of the Anthropic computer-use beta.
43
116
  *
44
117
  * **Details**
45
118
  *
46
119
  * Allows the model to execute bash commands in a sandboxed environment.
47
120
  * Requires the "computer-use-2025-01-24" beta header.
48
121
  *
122
+ * @see {@link Bash_20241022} for the older 2024-10-22 version of the bash tool
123
+ *
49
124
  * @category Bash
50
125
  * @since 4.0.0
51
126
  */
@@ -64,6 +139,13 @@ export declare const Bash_20250124: <Mode extends Tool.FailureMode | undefined =
64
139
  /**
65
140
  * Schema for a code execution request that asks Anthropic to run source code as a programmatic tool call.
66
141
  *
142
+ * **When to use**
143
+ *
144
+ * Use when constructing or validating a programmatic tool call for the Anthropic
145
+ * Code Execution tool.
146
+ *
147
+ * @see {@link CodeExecution_20250522} for the parent tool definition
148
+ *
67
149
  * @category Code Execution
68
150
  * @since 4.0.0
69
151
  */
@@ -82,7 +164,19 @@ export declare const CodeExecutionProgrammaticToolCall: Schema.Struct<{
82
164
  */
83
165
  export type CodeExecutionProgrammaticToolCall = typeof CodeExecutionProgrammaticToolCall.Type;
84
166
  /**
85
- * Schema for a code execution request that runs a bash command.
167
+ * Schema for the `bash_code_execution` input variant of Anthropic Code Execution.
168
+ *
169
+ * **When to use**
170
+ *
171
+ * Use when validating or constructing a bash command request for
172
+ * `CodeExecution_20250522`.
173
+ *
174
+ * **Details**
175
+ *
176
+ * The schema requires `type` to be `"bash_code_execution"` and `command` to
177
+ * contain the bash command sent to Anthropic.
178
+ *
179
+ * @see {@link CodeExecution_20250522} for the provider-defined tool that consumes this input variant
86
180
  *
87
181
  * @category Code Execution
88
182
  * @since 4.0.0
@@ -95,14 +189,44 @@ export declare const CodeExecutionBashCommand: Schema.Struct<{
95
189
  readonly command: Schema.String;
96
190
  }>;
97
191
  /**
98
- * Input payload for a bash command executed through Anthropic code execution.
192
+ * Input payload for a bash command routed through the Anthropic code execution tool.
193
+ *
194
+ * **When to use**
195
+ *
196
+ * Use when representing a provider-executed bash command request for the
197
+ * 2025-05-22 code execution tool.
198
+ *
199
+ * **Details**
200
+ *
201
+ * The payload uses `type: "bash_code_execution"` to distinguish bash execution
202
+ * from programmatic code and text editor operations, and `command` contains the
203
+ * bash command to run.
204
+ *
205
+ * @see {@link CodeExecutionProgrammaticToolCall} for programmatic code execution input
206
+ * @see {@link CodeExecutionTextEditorView} for viewing files through text editor code execution
207
+ * @see {@link CodeExecutionTextEditorCreate} for creating files through text editor code execution
208
+ * @see {@link CodeExecutionTextEditorStrReplace} for replacing text through text editor code execution
209
+ * @see {@link CodeExecution_20250522} for the provider-defined tool that consumes this payload
99
210
  *
100
211
  * @category Code Execution
101
212
  * @since 4.0.0
102
213
  */
103
214
  export type CodeExecutionBashCommand = typeof CodeExecutionBashCommand.Type;
104
215
  /**
105
- * Text editor view command for code execution.
216
+ * Schema for a code execution text editor request that views a file by path.
217
+ *
218
+ * **When to use**
219
+ *
220
+ * Use to validate or construct the `view` command for Anthropic code execution
221
+ * text editor tool calls.
222
+ *
223
+ * **Details**
224
+ *
225
+ * The encoded payload uses `type: "text_editor_code_execution"`,
226
+ * `command: "view"`, and a `path` string.
227
+ *
228
+ * @see {@link CodeExecutionTextEditorCreate} for the command that creates a file
229
+ * @see {@link CodeExecutionTextEditorStrReplace} for the command that replaces text in a file
106
230
  *
107
231
  * @category Code Execution
108
232
  * @since 4.0.0
@@ -116,14 +240,48 @@ export declare const CodeExecutionTextEditorView: Schema.Struct<{
116
240
  readonly path: Schema.String;
117
241
  }>;
118
242
  /**
119
- * Input payload for viewing a file through the text editor code execution tool.
243
+ * Input payload for the `view` command of Anthropic's text editor code execution tool.
244
+ *
245
+ * **When to use**
246
+ *
247
+ * Use when handling or validating the `view` command for Anthropic's text
248
+ * editor code execution tool.
249
+ *
250
+ * **Details**
251
+ *
252
+ * The payload is discriminated by `type: "text_editor_code_execution"` and
253
+ * `command: "view"`. The `path` field identifies the file to view.
254
+ *
255
+ * **Gotchas**
256
+ *
257
+ * This code execution view payload does not include `view_range`; line ranges
258
+ * are part of the standalone text editor view payload, not this code execution
259
+ * payload.
260
+ *
261
+ * @see {@link CodeExecution_20250522} for the provider-defined code execution tool that includes this payload
262
+ * @see {@link TextEditorViewCommand} for the standalone text editor view payload
120
263
  *
121
264
  * @category Code Execution
122
265
  * @since 4.0.0
123
266
  */
124
267
  export type CodeExecutionTextEditorView = typeof CodeExecutionTextEditorView.Type;
125
268
  /**
126
- * Text editor create command for code execution.
269
+ * Schema for a text editor code execution request that creates a file at a path.
270
+ *
271
+ * **When to use**
272
+ *
273
+ * Use when validating or constructing an Anthropic `text_editor_code_execution`
274
+ * tool call that should create a file.
275
+ *
276
+ * **Details**
277
+ *
278
+ * The request is discriminated by `type: "text_editor_code_execution"` and
279
+ * `command: "create"`. It requires `path` and accepts optional `file_text`; the
280
+ * schema allows `file_text` to be omitted, `null`, or a string.
281
+ *
282
+ * @see {@link CodeExecution_20250522} for the provider-defined tool that consumes this request
283
+ * @see {@link CodeExecutionTextEditorView} for the matching view request
284
+ * @see {@link CodeExecutionTextEditorStrReplace} for the matching replace request
127
285
  *
128
286
  * @category Code Execution
129
287
  * @since 4.0.0
@@ -148,7 +306,20 @@ export declare const CodeExecutionTextEditorCreate: Schema.Struct<{
148
306
  */
149
307
  export type CodeExecutionTextEditorCreate = typeof CodeExecutionTextEditorCreate.Type;
150
308
  /**
151
- * Text editor str_replace command for code execution.
309
+ * Schema for a code execution text editor request that replaces one exact string in a file.
310
+ *
311
+ * **When to use**
312
+ *
313
+ * Use when validating or constructing the `str_replace` text editor operation
314
+ * for the 2025-05-22 Anthropic code execution tool.
315
+ *
316
+ * **Gotchas**
317
+ *
318
+ * The `old_str` must match the file contents exactly, including whitespace and
319
+ * indentation, and must identify a single occurrence.
320
+ *
321
+ * @see {@link CodeExecutionTextEditorView} for reading file contents before choosing the replacement text
322
+ * @see {@link CodeExecution_20250522} for the provider-defined tool that consumes this payload
152
323
  *
153
324
  * @category Code Execution
154
325
  * @since 4.0.0
@@ -179,6 +350,13 @@ export type CodeExecutionTextEditorStrReplace = typeof CodeExecutionTextEditorSt
179
350
  /**
180
351
  * Schema for the 2025-08-25 code execution tool input, containing the code to execute.
181
352
  *
353
+ * **When to use**
354
+ *
355
+ * Use when validating or constructing the input payload for the 2025-08-25
356
+ * Anthropic code execution tool.
357
+ *
358
+ * @see {@link CodeExecution_20250825} for the provider-defined tool that consumes this schema
359
+ *
182
360
  * @category Code Execution
183
361
  * @since 4.0.0
184
362
  */
@@ -191,12 +369,28 @@ export declare const CodeExecution_20250825_Parameters: Schema.Struct<{
191
369
  /**
192
370
  * Input payload for the 2025-08-25 Anthropic code execution tool.
193
371
  *
372
+ * **When to use**
373
+ *
374
+ * Use when typing input passed to the 2025-08-25 Anthropic code execution tool.
375
+ *
376
+ * **Details**
377
+ *
378
+ * The payload has a single `code` field containing the source code string to
379
+ * execute.
380
+ *
381
+ * @see {@link CodeExecution_20250825} for the provider-defined tool that consumes this payload
382
+ *
194
383
  * @category Code Execution
195
384
  * @since 4.0.0
196
385
  */
197
386
  export type CodeExecution_20250825_Parameters = typeof CodeExecution_20250825_Parameters.Type;
198
387
  /**
199
- * Anthropic Code Execution tool (2025-05-22 version).
388
+ * Defines the Anthropic Code Execution tool (2025-05-22 version).
389
+ *
390
+ * **When to use**
391
+ *
392
+ * Use when you need the model to execute code in a sandboxed environment and
393
+ * require the 2025-05-22 version of the Anthropic code-execution beta.
200
394
  *
201
395
  * **Details**
202
396
  *
@@ -204,6 +398,8 @@ export type CodeExecution_20250825_Parameters = typeof CodeExecution_20250825_Pa
204
398
  * for multiple execution types including programmatic tool calls, bash
205
399
  * execution, and text editor operations.
206
400
  *
401
+ * @see {@link CodeExecutionProgrammaticToolCall} for the programmatic tool call schema
402
+ *
207
403
  * @category Code Execution
208
404
  * @since 4.0.0
209
405
  */
@@ -272,11 +468,20 @@ export declare const CodeExecution_20250522: <Mode extends Tool.FailureMode | un
272
468
  readonly failureMode: Mode extends undefined ? "error" : Mode;
273
469
  }, false>;
274
470
  /**
275
- * Anthropic Code Execution tool (2025-08-25 version).
471
+ * Defines the Anthropic Code Execution tool (2025-08-25 version).
472
+ *
473
+ * **When to use**
474
+ *
475
+ * Use when you need the model to execute code in a sandboxed environment and
476
+ * require the 2025-08-25 version of the Anthropic code-execution beta.
276
477
  *
277
478
  * **Details**
278
479
  *
279
- * Allows the model to execute code in a sandboxed environment.
480
+ * Requires the `code-execution-2025-08-25` beta header and uses
481
+ * `CodeExecution_20250825_Parameters` as its input schema.
482
+ *
483
+ * @see {@link CodeExecution_20250522} for the older 2025-05-22 code execution tool
484
+ * @see {@link CodeExecution_20250825_Parameters} for the input schema consumed by this tool
280
485
  *
281
486
  * @category Code Execution
282
487
  * @since 4.0.0
@@ -339,65 +544,102 @@ export declare const CodeExecution_20250825: <Mode extends Tool.FailureMode | un
339
544
  readonly failureMode: Mode extends undefined ? "error" : Mode;
340
545
  }, false>;
341
546
  /**
342
- * An `[x, y]` pixel position.
547
+ * Schema for an `[x, y]` screen coordinate in pixels.
548
+ *
549
+ * **Details**
550
+ *
551
+ * This is a two-number tuple used by computer-use actions that accept screen
552
+ * positions.
553
+ *
554
+ * **Gotchas**
555
+ *
556
+ * This schema validates tuple shape only and does not check display bounds.
343
557
  *
344
- * @category Computer Use
558
+ * @category computer use
345
559
  * @since 4.0.0
346
560
  */
347
561
  export declare const Coordinate: Schema.Tuple<readonly [Schema.Number, Schema.Number]>;
348
562
  /**
349
563
  * An `[x, y]` screen coordinate in pixels.
350
564
  *
351
- * @category Computer Use
565
+ * @category computer use
352
566
  * @since 4.0.0
353
567
  */
354
568
  export type Coordinate = typeof Coordinate.Type;
355
569
  /**
356
- * A `[x1, y1, x2, y2]` position defining top-left and bottom-right corners.
570
+ * Schema for an `[x1, y1, x2, y2]` screen region in pixels.
357
571
  *
358
- * @category Computer Use
572
+ * **Details**
573
+ *
574
+ * The tuple represents top-left and bottom-right corners.
575
+ *
576
+ * **Gotchas**
577
+ *
578
+ * This schema validates four numbers only and does not check coordinate ordering
579
+ * or display bounds.
580
+ *
581
+ * @category computer use
359
582
  * @since 4.0.0
360
583
  */
361
584
  export declare const Region: Schema.Tuple<readonly [Schema.Number, Schema.Number, Schema.Number, Schema.Number]>;
362
585
  /**
363
586
  * An `[x1, y1, x2, y2]` screen region in pixels, from top-left to bottom-right.
364
587
  *
365
- * @category Computer Use
588
+ * @category computer use
366
589
  * @since 4.0.0
367
590
  */
368
591
  export type Region = typeof Region.Type;
369
592
  /**
370
- * The direction of the scroll for scroll actions.
593
+ * Schema for scroll direction literals: `"up"`, `"down"`, `"left"`, or `"right"`.
371
594
  *
372
- * @category Computer Use
595
+ * @see {@link ComputerUseScrollAction} for the action payload that consumes this schema
596
+ *
597
+ * @category computer use
373
598
  * @since 4.0.0
374
599
  */
375
600
  export declare const ScrollDirection: Schema.Literals<readonly ["up", "down", "left", "right"]>;
376
601
  /**
377
602
  * Direction used by computer-use scroll actions: `"up"`, `"down"`, `"left"`, or `"right"`.
378
603
  *
379
- * @category Computer Use
604
+ * @category computer use
380
605
  * @since 4.0.0
381
606
  */
382
607
  export type ScrollDirection = typeof ScrollDirection.Type;
383
608
  /**
384
- * Modifier keys that can be held during click/scroll actions.
609
+ * Schema for modifier key literals.
610
+ *
611
+ * **Details**
385
612
  *
386
- * @category Computer Use
613
+ * Allowed values are `"alt"`, `"ctrl"`, `"meta"`, and `"shift"`.
614
+ *
615
+ * @category computer use
387
616
  * @since 4.0.0
388
617
  */
389
618
  export declare const ModifierKey: Schema.Literals<readonly ["alt", "ctrl", "meta", "shift"]>;
390
619
  /**
391
- * Modifier key that can be held during computer-use click or scroll actions.
620
+ * Modifier key literals.
621
+ *
622
+ * **Details**
392
623
  *
393
- * @category Computer Use
624
+ * Allowed values are `"alt"`, `"ctrl"`, `"meta"`, and `"shift"`.
625
+ *
626
+ * @category computer use
394
627
  * @since 4.0.0
395
628
  */
396
629
  export type ModifierKey = typeof ModifierKey.Type;
397
630
  /**
398
- * Press a key or key combination (e.g. `"Return"`, `"ctrl+c"`, `"ctrl+s"`).
631
+ * Schema for a computer-use action that presses a key or key combination, such
632
+ * as `"Return"`, `"ctrl+c"`, or `"ctrl+s"`.
633
+ *
634
+ * **When to use**
635
+ *
636
+ * Use when validating or constructing a computer-use action for keyboard
637
+ * shortcuts or non-text key presses.
399
638
  *
400
- * @category Computer Use
639
+ * @see {@link TypeAction} for entering ordinary text strings
640
+ * @see {@link ComputerUseHoldKeyAction} for holding a key for a duration
641
+ *
642
+ * @category computer use
401
643
  * @since 4.0.0
402
644
  */
403
645
  export declare const ComputerUseKeyAction: Schema.Struct<{
@@ -410,14 +652,44 @@ export declare const ComputerUseKeyAction: Schema.Struct<{
410
652
  /**
411
653
  * Computer-use action payload for pressing a key or key combination.
412
654
  *
413
- * @category Computer Use
655
+ * **Details**
656
+ *
657
+ * The payload uses `action: "key"` and stores the key or key combination to
658
+ * press in `text`, such as `"Return"`, `"ctrl+c"`, or `"ctrl+s"`.
659
+ *
660
+ * **Gotchas**
661
+ *
662
+ * `text` is typed as `string`; the paired schema does not validate
663
+ * provider-specific key names or key combinations.
664
+ *
665
+ * @category computer use
414
666
  * @since 4.0.0
415
667
  */
416
668
  export type ComputerUseKeyAction = typeof ComputerUseKeyAction.Type;
417
669
  /**
418
- * Perform a left click at the current mouse position or the specified coordinates.
670
+ * Schema for a computer-use action that performs a left click.
671
+ *
672
+ * **When to use**
419
673
  *
420
- * @category Computer Use
674
+ * Use to validate or construct an Anthropic computer-use payload for clicking
675
+ * once at the current mouse position or at a specific screen coordinate.
676
+ *
677
+ * **Details**
678
+ *
679
+ * The encoded payload uses `action: "left_click"`. The optional `coordinate`
680
+ * field supplies the `[x, y]` pixel position; when omitted, the action uses the
681
+ * current mouse position.
682
+ *
683
+ * **Gotchas**
684
+ *
685
+ * The coordinate schema only checks that the value is a two-number tuple. It
686
+ * does not validate that the point falls within the configured display
687
+ * dimensions.
688
+ *
689
+ * @see {@link ComputerUseDoubleClickAction} for performing a double click
690
+ * @see {@link ComputerUseMouseMoveAction} for moving the mouse without clicking
691
+ *
692
+ * @category computer use
421
693
  * @since 4.0.0
422
694
  */
423
695
  export declare const ComputerUseLeftClickAction: Schema.Struct<{
@@ -431,14 +703,31 @@ export declare const ComputerUseLeftClickAction: Schema.Struct<{
431
703
  /**
432
704
  * Computer-use action payload for performing a left click, optionally at a specific coordinate.
433
705
  *
434
- * @category Computer Use
706
+ * @category computer use
435
707
  * @since 4.0.0
436
708
  */
437
709
  export type ComputerUseLeftClickAction = typeof ComputerUseLeftClickAction.Type;
438
710
  /**
439
- * Move the mouse cursor to the specified coordinates.
711
+ * Schema for a computer-use action that moves the mouse cursor to a required
712
+ * `[x, y]` screen coordinate.
713
+ *
714
+ * **When to use**
715
+ *
716
+ * Use to validate or construct a mouse movement action for an Anthropic
717
+ * computer-use tool call.
718
+ *
719
+ * **Details**
440
720
  *
441
- * @category Computer Use
721
+ * The encoded payload has action `"mouse_move"` and a required `coordinate`
722
+ * field containing the target `[x, y]` pixel position.
723
+ *
724
+ * **Gotchas**
725
+ *
726
+ * The coordinate schema only checks that the value is a two-number tuple. It
727
+ * does not validate that the point falls within the configured display
728
+ * dimensions.
729
+ *
730
+ * @category computer use
442
731
  * @since 4.0.0
443
732
  */
444
733
  export declare const ComputerUseMouseMoveAction: Schema.Struct<{
@@ -451,14 +740,26 @@ export declare const ComputerUseMouseMoveAction: Schema.Struct<{
451
740
  /**
452
741
  * Computer-use action payload for moving the mouse cursor to a specific coordinate.
453
742
  *
454
- * @category Computer Use
743
+ * @category computer use
455
744
  * @since 4.0.0
456
745
  */
457
746
  export type ComputerUseMouseMoveAction = typeof ComputerUseMouseMoveAction.Type;
458
747
  /**
459
- * Capture the current display.
748
+ * Schema for a computer-use action that requests a screenshot of the current display.
749
+ *
750
+ * **When to use**
751
+ *
752
+ * Use to validate or construct a computer-use tool action that asks the handler
753
+ * to capture the full current display.
460
754
  *
461
- * @category Computer Use
755
+ * **Details**
756
+ *
757
+ * The payload contains only `action: "screenshot"` and does not include
758
+ * coordinates or other options.
759
+ *
760
+ * @see {@link ComputerUseZoomAction} for requesting a zoomed-in screenshot of a specific screen region with the 2025-11-24 computer-use tool
761
+ *
762
+ * @category computer use
462
763
  * @since 4.0.0
463
764
  */
464
765
  export declare const ComputerUseScreenshotAction: Schema.Struct<{
@@ -467,14 +768,26 @@ export declare const ComputerUseScreenshotAction: Schema.Struct<{
467
768
  /**
468
769
  * Computer-use action payload for capturing the current display.
469
770
  *
470
- * @category Computer Use
771
+ * @category computer use
471
772
  * @since 4.0.0
472
773
  */
473
774
  export type ComputerUseScreenshotAction = typeof ComputerUseScreenshotAction.Type;
474
775
  /**
475
- * Type a text string.
776
+ * Schema for a computer-use action that enters text.
777
+ *
778
+ * **When to use**
476
779
  *
477
- * @category Computer Use
780
+ * Use to validate or construct a computer-use action for entering ordinary text
781
+ * strings.
782
+ *
783
+ * **Details**
784
+ *
785
+ * The payload uses `action: "type"` and a `text` string containing the text to
786
+ * enter.
787
+ *
788
+ * @see {@link ComputerUseKeyAction} for key presses and keyboard shortcuts
789
+ *
790
+ * @category computer use
478
791
  * @since 4.0.0
479
792
  */
480
793
  export declare const TypeAction: Schema.Struct<{
@@ -487,14 +800,38 @@ export declare const TypeAction: Schema.Struct<{
487
800
  /**
488
801
  * Computer-use action payload for typing a text string.
489
802
  *
490
- * @category Computer Use
803
+ * **Details**
804
+ *
805
+ * The payload uses `action: "type"` and a `text` string containing the text to
806
+ * enter.
807
+ *
808
+ * @category computer use
491
809
  * @since 4.0.0
492
810
  */
493
811
  export type TypeAction = typeof TypeAction.Type;
494
812
  /**
495
- * Perform a double click.
813
+ * Schema for a computer-use action that performs a double click.
814
+ *
815
+ * **When to use**
816
+ *
817
+ * Use to validate or construct an Anthropic computer-use payload for double
818
+ * clicking at the current mouse position or at a specific screen coordinate.
819
+ *
820
+ * **Details**
821
+ *
822
+ * The encoded payload uses `action: "double_click"`. The optional
823
+ * `coordinate` field supplies the `[x, y]` pixel position; when omitted, the
824
+ * action uses the current mouse position.
825
+ *
826
+ * **Gotchas**
496
827
  *
497
- * @category Computer Use
828
+ * The coordinate schema only checks that the value is a two-number tuple. It
829
+ * does not validate that the point falls within the configured display
830
+ * dimensions.
831
+ *
832
+ * @see {@link ComputerUseLeftClickAction} for performing a single left click
833
+ *
834
+ * @category computer use
498
835
  * @since 4.0.0
499
836
  */
500
837
  export declare const ComputerUseDoubleClickAction: Schema.Struct<{
@@ -508,14 +845,33 @@ export declare const ComputerUseDoubleClickAction: Schema.Struct<{
508
845
  /**
509
846
  * Computer-use action payload for performing a double click, optionally at a specific coordinate.
510
847
  *
511
- * @category Computer Use
848
+ * @category computer use
512
849
  * @since 4.0.0
513
850
  */
514
851
  export type ComputerUseDoubleClickAction = typeof ComputerUseDoubleClickAction.Type;
515
852
  /**
516
- * Hold a key for a specified duration during computer-use execution.
853
+ * Keeps a key pressed for a specified duration during computer-use execution.
854
+ *
855
+ * **When to use**
856
+ *
857
+ * Use to keep a keyboard key depressed for a fixed number of seconds in a
858
+ * computer-use action sequence.
859
+ *
860
+ * **Details**
861
+ *
862
+ * The schema describes objects with `action: "hold_key"`, a `text` field
863
+ * containing the key to hold, and a `duration` field containing the number of
864
+ * seconds to hold it.
865
+ *
866
+ * **Gotchas**
867
+ *
868
+ * The schema only checks that `duration` is a number; it does not require a
869
+ * positive value.
517
870
  *
518
- * @category Computer Use
871
+ * @see {@link ComputerUseKeyAction} for pressing a key or key combination without holding it
872
+ * @see {@link ComputerUseWaitAction} for pausing between actions without holding a key
873
+ *
874
+ * @category computer use
519
875
  * @since 4.0.0
520
876
  */
521
877
  export declare const ComputerUseHoldKeyAction: Schema.Struct<{
@@ -532,14 +888,44 @@ export declare const ComputerUseHoldKeyAction: Schema.Struct<{
532
888
  /**
533
889
  * Computer-use action payload for holding a key for a specified duration.
534
890
  *
535
- * @category Computer Use
891
+ * **When to use**
892
+ *
893
+ * Use to represent a key that should remain pressed for a measured interval.
894
+ *
895
+ * **Details**
896
+ *
897
+ * Set `action` to `"hold_key"`, `text` to the key to hold, and `duration` to
898
+ * the number of seconds to hold it.
899
+ *
900
+ * @see {@link ComputerUseKeyAction} for a single key press or key combination without a hold duration
901
+ *
902
+ * @category computer use
536
903
  * @since 4.0.0
537
904
  */
538
905
  export type ComputerUseHoldKeyAction = typeof ComputerUseHoldKeyAction.Type;
539
906
  /**
540
- * Click and drag from start coordinate to end coordinate.
907
+ * Schema for a computer-use action that drags with the left mouse button.
908
+ *
909
+ * **When to use**
910
+ *
911
+ * Use to validate or construct an Anthropic computer-use payload for dragging
912
+ * from one screen coordinate to another in a single action.
541
913
  *
542
- * @category Computer Use
914
+ * **Details**
915
+ *
916
+ * The encoded payload uses `action: "left_click_drag"` and requires both
917
+ * `start_coordinate` and `coordinate` as `[x, y]` pixel positions.
918
+ *
919
+ * **Gotchas**
920
+ *
921
+ * The coordinate schema only checks that each value is a two-number tuple. It
922
+ * does not validate that either point falls within the configured display
923
+ * dimensions.
924
+ *
925
+ * @see {@link ComputerUseLeftMouseDownAction} for starting a manual drag sequence
926
+ * @see {@link ComputerUseLeftMouseUpAction} for ending a manual drag sequence
927
+ *
928
+ * @category computer use
543
929
  * @since 4.0.0
544
930
  */
545
931
  export declare const ComputerUseLeftClickDragAction: Schema.Struct<{
@@ -556,18 +942,19 @@ export declare const ComputerUseLeftClickDragAction: Schema.Struct<{
556
942
  /**
557
943
  * Computer-use action payload for dragging from a start coordinate to an end coordinate.
558
944
  *
559
- * @category Computer Use
945
+ * @category computer use
560
946
  * @since 4.0.0
561
947
  */
562
948
  export type ComputerUseLeftClickDragAction = typeof ComputerUseLeftClickDragAction.Type;
563
949
  /**
564
- * Press the left mouse button down (without releasing).
950
+ * Starts a left mouse button press without releasing it.
565
951
  *
566
952
  * **When to use**
567
953
  *
568
- * Use this for fine-grained click control.
954
+ * Use when constructing a manual click or drag sequence that should press and
955
+ * hold the left mouse button before a later release.
569
956
  *
570
- * @category Computer Use
957
+ * @category computer use
571
958
  * @since 4.0.0
572
959
  */
573
960
  export declare const ComputerUseLeftMouseDownAction: Schema.Struct<{
@@ -581,18 +968,19 @@ export declare const ComputerUseLeftMouseDownAction: Schema.Struct<{
581
968
  /**
582
969
  * Computer-use action payload for pressing and holding the left mouse button, optionally at a specific coordinate.
583
970
  *
584
- * @category Computer Use
971
+ * @category computer use
585
972
  * @since 4.0.0
586
973
  */
587
974
  export type ComputerUseLeftMouseDownAction = typeof ComputerUseLeftMouseDownAction.Type;
588
975
  /**
589
- * Release the left mouse button.
976
+ * Releases the left mouse button.
590
977
  *
591
978
  * **When to use**
592
979
  *
593
- * Use this for fine-grained click control.
980
+ * Use when constructing a manual click or drag sequence that should release the
981
+ * left mouse button after it was previously held down.
594
982
  *
595
- * @category Computer Use
983
+ * @category computer use
596
984
  * @since 4.0.0
597
985
  */
598
986
  export declare const ComputerUseLeftMouseUpAction: Schema.Struct<{
@@ -606,14 +994,33 @@ export declare const ComputerUseLeftMouseUpAction: Schema.Struct<{
606
994
  /**
607
995
  * Computer-use action payload for releasing the left mouse button, optionally at a specific coordinate.
608
996
  *
609
- * @category Computer Use
997
+ * @category computer use
610
998
  * @since 4.0.0
611
999
  */
612
1000
  export type ComputerUseLeftMouseUpAction = typeof ComputerUseLeftMouseUpAction.Type;
613
1001
  /**
614
- * Perform a middle click.
1002
+ * Schema for a computer-use action that performs a middle click.
1003
+ *
1004
+ * **When to use**
1005
+ *
1006
+ * Use to validate or construct a middle-button click action for Anthropic
1007
+ * computer use, optionally targeting a specific screen coordinate.
1008
+ *
1009
+ * **Details**
1010
+ *
1011
+ * The payload must use `action: "middle_click"`. When `coordinate` is omitted,
1012
+ * the click occurs at the current mouse position.
615
1013
  *
616
- * @category Computer Use
1014
+ * **Gotchas**
1015
+ *
1016
+ * This action is available in the 2025-01-24 computer-use action set and later;
1017
+ * it is not part of `ComputerUse_20241022`.
1018
+ *
1019
+ * @see {@link ComputerUse_20250124} for the provider-defined tool version that first accepts this action
1020
+ * @see {@link ComputerUseLeftClickAction} for primary-button clicks
1021
+ * @see {@link ComputerUseRightClickAction} for secondary-button clicks
1022
+ *
1023
+ * @category computer use
617
1024
  * @since 4.0.0
618
1025
  */
619
1026
  export declare const ComputerUseMiddleClickAction: Schema.Struct<{
@@ -627,14 +1034,29 @@ export declare const ComputerUseMiddleClickAction: Schema.Struct<{
627
1034
  /**
628
1035
  * Computer-use action payload for performing a middle click, optionally at a specific coordinate.
629
1036
  *
630
- * @category Computer Use
1037
+ * @category computer use
631
1038
  * @since 4.0.0
632
1039
  */
633
1040
  export type ComputerUseMiddleClickAction = typeof ComputerUseMiddleClickAction.Type;
634
1041
  /**
635
- * Perform a right click.
1042
+ * Schema for a computer-use action that performs a right click, optionally at a
1043
+ * specific screen coordinate.
1044
+ *
1045
+ * **When to use**
636
1046
  *
637
- * @category Computer Use
1047
+ * Use to validate or construct the `right_click` action for an Anthropic
1048
+ * computer-use tool call.
1049
+ *
1050
+ * **Details**
1051
+ *
1052
+ * The optional `coordinate` field is an `[x, y]` screen coordinate in pixels.
1053
+ * When omitted, the right click is performed at the current mouse position.
1054
+ *
1055
+ * @see {@link ComputerUse_20250124} for the provider-defined computer-use tool version that introduced this action
1056
+ * @see {@link ComputerUseLeftClickAction} for the corresponding left-click action
1057
+ * @see {@link ComputerUseMiddleClickAction} for the corresponding middle-click action
1058
+ *
1059
+ * @category computer use
638
1060
  * @since 4.0.0
639
1061
  */
640
1062
  export declare const ComputerUseRightClickAction: Schema.Struct<{
@@ -648,14 +1070,31 @@ export declare const ComputerUseRightClickAction: Schema.Struct<{
648
1070
  /**
649
1071
  * Computer-use action payload for performing a right click, optionally at a specific coordinate.
650
1072
  *
651
- * @category Computer Use
1073
+ * @category computer use
652
1074
  * @since 4.0.0
653
1075
  */
654
1076
  export type ComputerUseRightClickAction = typeof ComputerUseRightClickAction.Type;
655
1077
  /**
656
- * Scroll a given amount in a specified direction.
1078
+ * Schema for a computer-use scroll action.
1079
+ *
1080
+ * **When to use**
1081
+ *
1082
+ * Use when validating or constructing Anthropic computer-use scroll payloads.
1083
+ *
1084
+ * **Details**
1085
+ *
1086
+ * The encoded payload uses `action: "scroll"`, an optional `coordinate`,
1087
+ * `scroll_direction`, and `scroll_amount`.
1088
+ *
1089
+ * **Gotchas**
657
1090
  *
658
- * @category Computer Use
1091
+ * `coordinate` only checks a two-number tuple, and `scroll_amount` is only
1092
+ * `Schema.Number`.
1093
+ *
1094
+ * @see {@link ComputerUse_20250124} for the tool version that accepts this action
1095
+ * @see {@link ScrollDirection} for the accepted direction literals
1096
+ *
1097
+ * @category computer use
659
1098
  * @since 4.0.0
660
1099
  */
661
1100
  export declare const ComputerUseScrollAction: Schema.Struct<{
@@ -677,14 +1116,33 @@ export declare const ComputerUseScrollAction: Schema.Struct<{
677
1116
  /**
678
1117
  * Computer-use action payload for scrolling by a specified amount in a specified direction, optionally from a coordinate.
679
1118
  *
680
- * @category Computer Use
1119
+ * @category computer use
681
1120
  * @since 4.0.0
682
1121
  */
683
1122
  export type ComputerUseScrollAction = typeof ComputerUseScrollAction.Type;
684
1123
  /**
685
- * Perform a triple click.
1124
+ * Schema for a computer-use triple-click action.
1125
+ *
1126
+ * **When to use**
1127
+ *
1128
+ * Use when validating or constructing Anthropic computer-use triple-click
1129
+ * payloads at the current pointer position or an optional coordinate.
1130
+ *
1131
+ * **Details**
1132
+ *
1133
+ * The encoded payload uses `action: "triple_click"` and an optional
1134
+ * `coordinate`.
1135
+ *
1136
+ * **Gotchas**
686
1137
  *
687
- * @category Computer Use
1138
+ * `coordinate` only validates as a two-number tuple and does not check display
1139
+ * bounds.
1140
+ *
1141
+ * @see {@link ComputerUse_20250124} for the tool version that accepts this action
1142
+ * @see {@link ComputerUseDoubleClickAction} for the two-click variant
1143
+ * @see {@link ComputerUseLeftClickAction} for a single left click
1144
+ *
1145
+ * @category computer use
688
1146
  * @since 4.0.0
689
1147
  */
690
1148
  export declare const ComputerUseTripleClickAction: Schema.Struct<{
@@ -698,14 +1156,32 @@ export declare const ComputerUseTripleClickAction: Schema.Struct<{
698
1156
  /**
699
1157
  * Computer-use action payload for performing a triple click, optionally at a specific coordinate.
700
1158
  *
701
- * @category Computer Use
1159
+ * @category computer use
702
1160
  * @since 4.0.0
703
1161
  */
704
1162
  export type ComputerUseTripleClickAction = typeof ComputerUseTripleClickAction.Type;
705
1163
  /**
706
- * Pause between performing actions.
1164
+ * Schema for a computer-use wait action.
707
1165
  *
708
- * @category Computer Use
1166
+ * **When to use**
1167
+ *
1168
+ * Use when validating or constructing Anthropic computer-use payloads that pause
1169
+ * between actions.
1170
+ *
1171
+ * **Details**
1172
+ *
1173
+ * The encoded payload uses `action: "wait"` and a required `duration` in
1174
+ * seconds.
1175
+ *
1176
+ * **Gotchas**
1177
+ *
1178
+ * `duration` is only `Schema.Number`; it is not constrained to positive or
1179
+ * finite values.
1180
+ *
1181
+ * @see {@link ComputerUseHoldKeyAction} for another duration-based computer-use action
1182
+ * @see {@link ComputerUse_20250124} for the tool version that accepts this action
1183
+ *
1184
+ * @category computer use
709
1185
  * @since 4.0.0
710
1186
  */
711
1187
  export declare const ComputerUseWaitAction: Schema.Struct<{
@@ -718,18 +1194,26 @@ export declare const ComputerUseWaitAction: Schema.Struct<{
718
1194
  /**
719
1195
  * Computer-use action payload for pausing for a specified duration.
720
1196
  *
721
- * @category Computer Use
1197
+ * @category computer use
722
1198
  * @since 4.0.0
723
1199
  */
724
1200
  export type ComputerUseWaitAction = typeof ComputerUseWaitAction.Type;
725
1201
  /**
726
- * Zoom into a specific region of the screen at full resolution.
1202
+ * Zooms into a specific region of the screen at full resolution.
727
1203
  *
728
1204
  * **Details**
729
1205
  *
730
- * Requires `enableZoom: true` in the tool definition.
1206
+ * The encoded payload uses `action: "zoom"` and a `region` tuple.
1207
+ *
1208
+ * **Gotchas**
1209
+ *
1210
+ * Requires `enableZoom: true` in the tool definition. `region` is only a
1211
+ * four-number tuple and does not validate corner ordering or display bounds.
1212
+ *
1213
+ * @see {@link ComputerUse_20251124} for the tool version that accepts this action
1214
+ * @see {@link ComputerUseScreenshotAction} for capturing the full screen instead
731
1215
  *
732
- * @category Computer Use
1216
+ * @category computer use
733
1217
  * @since 4.0.0
734
1218
  */
735
1219
  export declare const ComputerUseZoomAction: Schema.Struct<{
@@ -743,23 +1227,25 @@ export declare const ComputerUseZoomAction: Schema.Struct<{
743
1227
  /**
744
1228
  * Computer-use action payload for zooming into a specific screen region.
745
1229
  *
746
- * **Details**
1230
+ * **Gotchas**
747
1231
  *
748
1232
  * The enclosing computer-use tool must be configured with `enableZoom: true`.
1233
+ * `region` is only a four-number tuple and does not validate corner ordering or
1234
+ * display bounds.
749
1235
  *
750
- * @category Computer Use
1236
+ * @category computer use
751
1237
  * @since 4.0.0
752
1238
  */
753
1239
  export type ComputerUseZoomAction = typeof ComputerUseZoomAction.Type;
754
1240
  /**
755
- * Computer use tool for Claude 3.5 Sonnet v2 (deprecated).
1241
+ * Defines the deprecated computer-use tool for Claude 3.5 Sonnet v2.
756
1242
  *
757
1243
  * **Details**
758
1244
  *
759
1245
  * Requires the "computer-use-2024-10-22" beta header.
760
1246
  * Basic actions only: screenshot, left_click, type, key, mouse_move.
761
1247
  *
762
- * @category Computer Use
1248
+ * @category computer use
763
1249
  * @since 4.0.0
764
1250
  */
765
1251
  export declare const ComputerUse_20241022: <Mode extends Tool.FailureMode | undefined = undefined>(args: {
@@ -817,7 +1303,12 @@ export declare const ComputerUse_20241022: <Mode extends Tool.FailureMode | unde
817
1303
  readonly failureMode: Mode extends undefined ? "error" : Mode;
818
1304
  }, true>;
819
1305
  /**
820
- * Computer use tool for Claude 4 models and Claude Sonnet 3.7.
1306
+ * Defines the computer-use tool for Claude 4 models and Claude Sonnet 3.7.
1307
+ *
1308
+ * **When to use**
1309
+ *
1310
+ * Use when configuring Anthropic computer use for Claude 4 models or Claude
1311
+ * Sonnet 3.7 with the 2025-01-24 action set.
821
1312
  *
822
1313
  * **Details**
823
1314
  *
@@ -826,7 +1317,10 @@ export declare const ComputerUse_20241022: <Mode extends Tool.FailureMode | unde
826
1317
  * right_click, middle_click, double_click, triple_click, left_mouse_down,
827
1318
  * left_mouse_up, hold_key, wait.
828
1319
  *
829
- * @category Computer Use
1320
+ * @see {@link ComputerUse_20241022} for the older basic action set
1321
+ * @see {@link ComputerUse_20251124} for the newer zoom-capable version
1322
+ *
1323
+ * @category computer use
830
1324
  * @since 4.0.0
831
1325
  */
832
1326
  export declare const ComputerUse_20250124: <Mode extends Tool.FailureMode | undefined = undefined>(args: {
@@ -967,15 +1461,27 @@ export declare const ComputerUse_20250124: <Mode extends Tool.FailureMode | unde
967
1461
  readonly failureMode: Mode extends undefined ? "error" : Mode;
968
1462
  }, true>;
969
1463
  /**
970
- * Computer use tool for Claude Opus 4.5 only.
1464
+ * Defines the computer-use tool for Claude Opus 4.5 only.
1465
+ *
1466
+ * **When to use**
1467
+ *
1468
+ * Use when configuring Anthropic computer use for Claude Opus 4.5 with the
1469
+ * 2025-11-24 action set and zoom-capable screen inspection.
971
1470
  *
972
1471
  * **Details**
973
1472
  *
974
1473
  * Requires the "computer-use-2025-11-24" beta header.
975
1474
  * Includes all actions from computer_20250124 plus the zoom action for
976
- * detailed screen region inspection. Requires `enableZoom: true` in args.
1475
+ * detailed screen region inspection.
1476
+ *
1477
+ * **Gotchas**
1478
+ *
1479
+ * Zoom actions require `enableZoom: true` in args.
977
1480
  *
978
- * @category Computer Use
1481
+ * @see {@link ComputerUse_20250124} for the previous action set without zoom
1482
+ * @see {@link ComputerUseZoomAction} for the zoom action payload
1483
+ *
1484
+ * @category computer use
979
1485
  * @since 4.0.0
980
1486
  */
981
1487
  export declare const ComputerUse_20251124: <Mode extends Tool.FailureMode | undefined = undefined>(args: {
@@ -1125,29 +1631,45 @@ export declare const ComputerUse_20251124: <Mode extends Tool.FailureMode | unde
1125
1631
  readonly failureMode: Mode extends undefined ? "error" : Mode;
1126
1632
  }, true>;
1127
1633
  /**
1128
- * A `[start, end]` line range for viewing file contents.
1634
+ * Defines a `[start, end]` line range for viewing file contents.
1635
+ *
1636
+ * **When to use**
1637
+ *
1638
+ * Use when constructing or validating `view_range` for memory or text editor
1639
+ * view commands.
1129
1640
  *
1130
1641
  * **Details**
1131
1642
  *
1132
- * Lines are 1-indexed. Use -1 for end to read to the end of the file. For
1643
+ * Lines are 1-indexed. Use `-1` for end to read to the end of the file. For
1133
1644
  * example, `[1, 50]` views lines 1-50 and `[100, -1]` views from line 100 to
1134
1645
  * the end of the file.
1135
1646
  *
1136
- * @category Memory
1647
+ * @see {@link MemoryViewCommand} for memory view payloads that use this range
1648
+ * @see {@link TextEditorViewCommand} for text editor view payloads that use this range
1649
+ *
1650
+ * @category memory
1137
1651
  * @since 4.0.0
1138
1652
  */
1139
1653
  export declare const ViewRange: Schema.Tuple<readonly [Schema.Number, Schema.Number]>;
1140
1654
  /**
1141
1655
  * A `[start, end]` 1-indexed line range for viewing file contents, using `-1` as the end value to read through the end of the file.
1142
1656
  *
1143
- * @category Memory
1657
+ * **When to use**
1658
+ *
1659
+ * Use when typing `view_range` for memory or text editor view commands.
1660
+ *
1661
+ * @category memory
1144
1662
  * @since 4.0.0
1145
1663
  */
1146
1664
  export type ViewRange = typeof ViewRange.Type;
1147
1665
  /**
1148
- * Creates a new file.
1666
+ * Schema for the memory tool command that creates a new file at a path.
1667
+ *
1668
+ * **Details**
1149
1669
  *
1150
- * @category Memory
1670
+ * The payload contains `command: "create"` and a `path` string.
1671
+ *
1672
+ * @category memory
1151
1673
  * @since 4.0.0
1152
1674
  */
1153
1675
  export declare const MemoryCreateCommand: Schema.Struct<{
@@ -1160,34 +1682,46 @@ export declare const MemoryCreateCommand: Schema.Struct<{
1160
1682
  /**
1161
1683
  * Memory tool command payload for creating a new file at a path.
1162
1684
  *
1163
- * @category Memory
1685
+ * @category memory
1164
1686
  * @since 4.0.0
1165
1687
  */
1166
1688
  export type MemoryCreateCommand = typeof MemoryCreateCommand.Type;
1167
1689
  /**
1168
- * Delete a file or directory.
1690
+ * Schema for a memory command that deletes a file or directory.
1169
1691
  *
1170
- * @category Memory
1692
+ * @category memory
1171
1693
  * @since 4.0.0
1172
1694
  */
1173
1695
  export declare const MemoryDeleteCommand: Schema.Struct<{
1174
1696
  readonly command: Schema.Literal<"delete">;
1175
1697
  /**
1176
- * The path to the file to delete.
1698
+ * The path to the file or directory to delete.
1177
1699
  */
1178
1700
  readonly path: Schema.String;
1179
1701
  }>;
1180
1702
  /**
1181
1703
  * Memory tool command payload for deleting a file or directory at a path.
1182
1704
  *
1183
- * @category Memory
1705
+ * @category memory
1184
1706
  * @since 4.0.0
1185
1707
  */
1186
1708
  export type MemoryDeleteCommand = typeof MemoryDeleteCommand.Type;
1187
1709
  /**
1188
- * Insert text at a specific line.
1710
+ * Schema for the memory `insert` command.
1711
+ *
1712
+ * **When to use**
1189
1713
  *
1190
- * @category Memory
1714
+ * Use when validating or constructing `insert` payloads for `Memory_20250818`.
1715
+ *
1716
+ * **Details**
1717
+ *
1718
+ * The payload is discriminated by `command: "insert"` and requires `path`,
1719
+ * `insert_line`, and `insert_text`.
1720
+ *
1721
+ * @see {@link Memory_20250818} for the provider-defined tool that consumes this command
1722
+ * @see {@link MemoryStrReplaceCommand} for replacing existing text instead
1723
+ *
1724
+ * @category memory
1191
1725
  * @since 4.0.0
1192
1726
  */
1193
1727
  export declare const MemoryInsertCommand: Schema.Struct<{
@@ -1208,14 +1742,19 @@ export declare const MemoryInsertCommand: Schema.Struct<{
1208
1742
  /**
1209
1743
  * Memory tool command payload for inserting text at a specific line in a file.
1210
1744
  *
1211
- * @category Memory
1745
+ * @category memory
1212
1746
  * @since 4.0.0
1213
1747
  */
1214
1748
  export type MemoryInsertCommand = typeof MemoryInsertCommand.Type;
1215
1749
  /**
1216
- * Rename or move a file or directory.
1750
+ * Schema for the memory command that renames or moves a file or directory.
1751
+ *
1752
+ * **Details**
1753
+ *
1754
+ * The payload uses `command: "rename"` and requires `old_path` as the current
1755
+ * path plus `new_path` as the new destination path.
1217
1756
  *
1218
- * @category Memory
1757
+ * @category memory
1219
1758
  * @since 4.0.0
1220
1759
  */
1221
1760
  export declare const MemoryRenameCommand: Schema.Struct<{
@@ -1232,14 +1771,26 @@ export declare const MemoryRenameCommand: Schema.Struct<{
1232
1771
  /**
1233
1772
  * Memory tool command payload for renaming or moving a file or directory.
1234
1773
  *
1235
- * @category Memory
1774
+ * @category memory
1236
1775
  * @since 4.0.0
1237
1776
  */
1238
1777
  export type MemoryRenameCommand = typeof MemoryRenameCommand.Type;
1239
1778
  /**
1240
- * Replace text in a file.
1779
+ * Schema for the memory `str_replace` command.
1780
+ *
1781
+ * **When to use**
1782
+ *
1783
+ * Use when validating or constructing `str_replace` payloads for
1784
+ * `Memory_20250818`.
1785
+ *
1786
+ * **Details**
1241
1787
  *
1242
- * @category Memory
1788
+ * The payload is discriminated by `command: "str_replace"` and requires `path`,
1789
+ * `old_str`, and `new_str`.
1790
+ *
1791
+ * @see {@link Memory_20250818} for the provider-defined tool that consumes this command
1792
+ *
1793
+ * @category memory
1243
1794
  * @since 4.0.0
1244
1795
  */
1245
1796
  export declare const MemoryStrReplaceCommand: Schema.Struct<{
@@ -1260,20 +1811,25 @@ export declare const MemoryStrReplaceCommand: Schema.Struct<{
1260
1811
  /**
1261
1812
  * Memory tool command payload for replacing text in a file.
1262
1813
  *
1263
- * @category Memory
1814
+ * @category memory
1264
1815
  * @since 4.0.0
1265
1816
  */
1266
1817
  export type MemoryStrReplaceCommand = typeof MemoryStrReplaceCommand.Type;
1267
1818
  /**
1268
1819
  * Shows directory contents or file contents with optional line ranges.
1269
1820
  *
1270
- * @category Memory
1821
+ * **Details**
1822
+ *
1823
+ * When used on a file, returns file contents optionally limited by `view_range`.
1824
+ * When used on a directory, lists contents.
1825
+ *
1826
+ * @category memory
1271
1827
  * @since 4.0.0
1272
1828
  */
1273
1829
  export declare const MemoryViewCommand: Schema.Struct<{
1274
1830
  readonly command: Schema.Literal<"view">;
1275
1831
  /**
1276
- * The path to the file to view.
1832
+ * The path to the file or directory to view.
1277
1833
  */
1278
1834
  readonly path: Schema.String;
1279
1835
  /**
@@ -1284,19 +1840,19 @@ export declare const MemoryViewCommand: Schema.Struct<{
1284
1840
  /**
1285
1841
  * Memory tool command payload for viewing a file or directory, optionally with a file line range.
1286
1842
  *
1287
- * @category Memory
1843
+ * @category memory
1288
1844
  * @since 4.0.0
1289
1845
  */
1290
1846
  export type MemoryViewCommand = typeof MemoryViewCommand.Type;
1291
1847
  /**
1292
- * Memory tool for persistent file operations across conversations.
1848
+ * Defines the memory tool for persistent file operations across conversations.
1293
1849
  *
1294
1850
  * **Details**
1295
1851
  *
1296
1852
  * Provides commands for creating, viewing, editing, renaming, and deleting
1297
1853
  * files within the model's memory space.
1298
1854
  *
1299
- * @category Memory
1855
+ * @category memory
1300
1856
  * @since 4.0.0
1301
1857
  */
1302
1858
  export declare const Memory_20250818: <Mode extends Tool.FailureMode | undefined = undefined>(args: void) => Tool.ProviderDefined<"anthropic.memory_20250818", "AnthropicMemory", {
@@ -1310,7 +1866,7 @@ export declare const Memory_20250818: <Mode extends Tool.FailureMode | undefined
1310
1866
  }>, Schema.Struct<{
1311
1867
  readonly command: Schema.Literal<"delete">;
1312
1868
  /**
1313
- * The path to the file to delete.
1869
+ * The path to the file or directory to delete.
1314
1870
  */
1315
1871
  readonly path: Schema.String;
1316
1872
  }>, Schema.Struct<{
@@ -1354,7 +1910,7 @@ export declare const Memory_20250818: <Mode extends Tool.FailureMode | undefined
1354
1910
  }>, Schema.Struct<{
1355
1911
  readonly command: Schema.Literal<"view">;
1356
1912
  /**
1357
- * The path to the file to view.
1913
+ * The path to the file or directory to view.
1358
1914
  */
1359
1915
  readonly path: Schema.String;
1360
1916
  /**
@@ -1367,14 +1923,23 @@ export declare const Memory_20250818: <Mode extends Tool.FailureMode | undefined
1367
1923
  readonly failureMode: Mode extends undefined ? "error" : Mode;
1368
1924
  }, false>;
1369
1925
  /**
1370
- * View the contents of a file or list directory contents.
1926
+ * Reads the contents of a file or lists directory contents.
1927
+ *
1928
+ * **When to use**
1929
+ *
1930
+ * Use when validating or constructing the standalone Anthropic Text Editor
1931
+ * `view` command.
1371
1932
  *
1372
1933
  * **Details**
1373
1934
  *
1374
1935
  * When used on a file, returns the file contents, optionally limited to a line
1375
1936
  * range. When used on a directory, lists all files and subdirectories.
1937
+ * `view_range` is a 1-indexed `[start, end]` tuple where `-1` means through
1938
+ * the end of the file.
1939
+ *
1940
+ * @see {@link CodeExecutionTextEditorView} for the code-execution variant without `view_range`
1376
1941
  *
1377
- * @category Text Editor
1942
+ * @category text editor
1378
1943
  * @since 4.0.0
1379
1944
  */
1380
1945
  export declare const TextEditorViewCommand: Schema.Struct<{
@@ -1392,18 +1957,33 @@ export declare const TextEditorViewCommand: Schema.Struct<{
1392
1957
  /**
1393
1958
  * Text editor command payload for viewing file contents or listing directory contents.
1394
1959
  *
1395
- * @category Text Editor
1960
+ * **Details**
1961
+ *
1962
+ * `view_range` is a 1-indexed `[start, end]` tuple where `-1` means through
1963
+ * the end of the file.
1964
+ *
1965
+ * @category text editor
1396
1966
  * @since 4.0.0
1397
1967
  */
1398
1968
  export type TextEditorViewCommand = typeof TextEditorViewCommand.Type;
1399
1969
  /**
1400
1970
  * Create a new file with specified content.
1401
1971
  *
1972
+ * **When to use**
1973
+ *
1974
+ * Use when validating or constructing an Anthropic text editor `create`
1975
+ * command.
1976
+ *
1977
+ * **Details**
1978
+ *
1979
+ * The payload is discriminated by `command: "create"` and requires both `path`
1980
+ * and `file_text`.
1981
+ *
1402
1982
  * **Gotchas**
1403
1983
  *
1404
1984
  * Fails if the file already exists. Parent directories must exist.
1405
1985
  *
1406
- * @category Text Editor
1986
+ * @category text editor
1407
1987
  * @since 4.0.0
1408
1988
  */
1409
1989
  export declare const TextEditorCreateCommand: Schema.Struct<{
@@ -1424,19 +2004,32 @@ export declare const TextEditorCreateCommand: Schema.Struct<{
1424
2004
  *
1425
2005
  * The command fails if the file already exists or if parent directories are missing.
1426
2006
  *
1427
- * @category Text Editor
2007
+ * @category text editor
1428
2008
  * @since 4.0.0
1429
2009
  */
1430
2010
  export type TextEditorCreateCommand = typeof TextEditorCreateCommand.Type;
1431
2011
  /**
1432
- * Replace a specific string in a file with a new string.
2012
+ * Replaces a specific string in a file with a new string.
2013
+ *
2014
+ * **When to use**
2015
+ *
2016
+ * Use when validating or constructing standalone Anthropic text editor
2017
+ * `str_replace` commands.
2018
+ *
2019
+ * **Details**
2020
+ *
2021
+ * The payload uses `command: "str_replace"`, `path`, `old_str`, and `new_str`.
2022
+ * `new_str` may be empty to delete text.
1433
2023
  *
1434
2024
  * **Gotchas**
1435
2025
  *
1436
2026
  * The `old_str` must match exactly (including whitespace and indentation)
1437
2027
  * and must be unique in the file.
1438
2028
  *
1439
- * @category Text Editor
2029
+ * @see {@link TextEditorViewCommand} for reading contents before choosing `old_str`
2030
+ * @see {@link CodeExecutionTextEditorStrReplace} for the code-execution variant
2031
+ *
2032
+ * @category text editor
1440
2033
  * @since 4.0.0
1441
2034
  */
1442
2035
  export declare const TextEditorStrReplaceCommand: Schema.Struct<{
@@ -1457,18 +2050,24 @@ export declare const TextEditorStrReplaceCommand: Schema.Struct<{
1457
2050
  /**
1458
2051
  * Text editor command payload for replacing one exact, unique string in a file.
1459
2052
  *
1460
- * @category Text Editor
2053
+ * **Gotchas**
2054
+ *
2055
+ * The `old_str` must match exactly, including whitespace and indentation, and
2056
+ * must be unique in the file.
2057
+ *
2058
+ * @category text editor
1461
2059
  * @since 4.0.0
1462
2060
  */
1463
2061
  export type TextEditorStrReplaceCommand = typeof TextEditorStrReplaceCommand.Type;
1464
2062
  /**
1465
- * Insert text at a specific line number in a file.
2063
+ * Inserts text at a specific line number in a file.
1466
2064
  *
1467
2065
  * **Details**
1468
2066
  *
1469
- * Inserts the new text AFTER the specified line number.
2067
+ * Inserts the new text after the specified line number. Use `0` to insert at
2068
+ * the beginning of the file; other values are 1-indexed.
1470
2069
  *
1471
- * @category Text Editor
2070
+ * @category text editor
1472
2071
  * @since 4.0.0
1473
2072
  */
1474
2073
  export declare const TextEditorInsertCommand: Schema.Struct<{
@@ -1489,23 +2088,25 @@ export declare const TextEditorInsertCommand: Schema.Struct<{
1489
2088
  /**
1490
2089
  * Text editor command payload for inserting text after a specific line number in a file.
1491
2090
  *
1492
- * @category Text Editor
2091
+ * @category text editor
1493
2092
  * @since 4.0.0
1494
2093
  */
1495
2094
  export type TextEditorInsertCommand = typeof TextEditorInsertCommand.Type;
1496
2095
  /**
1497
- * Undo the last edit made to a file.
2096
+ * Undoes the last edit made to a file.
1498
2097
  *
1499
2098
  * **Details**
1500
2099
  *
1501
- * Reverts the most recent str_replace, insert, or create operation on the file.
2100
+ * Reverts the most recent `str_replace`, `insert`, or `create` operation on the
2101
+ * file.
1502
2102
  *
1503
2103
  * **Gotchas**
1504
2104
  *
1505
- * This command is available in text_editor_20241022 and text_editor_20250124,
1506
- * but not in text_editor_20250728 (Claude 4 models).
2105
+ * This command is available in `text_editor_20241022` and
2106
+ * `text_editor_20250124`, but not in `text_editor_20250429` or
2107
+ * `text_editor_20250728`.
1507
2108
  *
1508
- * @category Text Editor
2109
+ * @category text editor
1509
2110
  * @since 4.0.0
1510
2111
  */
1511
2112
  export declare const TextEditorUndoEditCommand: Schema.Struct<{
@@ -1520,20 +2121,30 @@ export declare const TextEditorUndoEditCommand: Schema.Struct<{
1520
2121
  *
1521
2122
  * **Gotchas**
1522
2123
  *
1523
- * Available for `text_editor_20241022` and `text_editor_20250124`, but not for Claude 4 text editor versions.
2124
+ * Available for `text_editor_20241022` and `text_editor_20250124`, but not for
2125
+ * `text_editor_20250429` or `text_editor_20250728`.
1524
2126
  *
1525
- * @category Text Editor
2127
+ * @category text editor
1526
2128
  * @since 4.0.0
1527
2129
  */
1528
2130
  export type TextEditorUndoEditCommand = typeof TextEditorUndoEditCommand.Type;
1529
2131
  /**
1530
- * Text editor tool for Claude 3.5 Sonnet (deprecated).
2132
+ * Defines the deprecated text editor tool for Claude 3.5 Sonnet.
2133
+ *
2134
+ * **When to use**
2135
+ *
2136
+ * Use when configuring the 2024-10-22 `str_replace_editor` compatibility path
2137
+ * for Claude 3.5 Sonnet.
1531
2138
  *
1532
2139
  * **Details**
1533
2140
  *
1534
- * Requires the "computer-use-2024-10-22" beta header.
2141
+ * Requires the "computer-use-2024-10-22" beta header and supports `view`,
2142
+ * `create`, `str_replace`, `insert`, and `undo_edit` commands.
2143
+ *
2144
+ * @see {@link TextEditor_20250124} for the newer `str_replace_editor` version
2145
+ * @see {@link TextEditor_20250728} for the Claude 4 `str_replace_based_edit_tool` line
1535
2146
  *
1536
- * @category Text Editor
2147
+ * @category text editor
1537
2148
  * @since 4.0.0
1538
2149
  */
1539
2150
  export declare const TextEditor_20241022: <Mode extends Tool.FailureMode | undefined = undefined>(args: {
@@ -1601,13 +2212,22 @@ export declare const TextEditor_20241022: <Mode extends Tool.FailureMode | undef
1601
2212
  readonly failureMode: Mode extends undefined ? "error" : Mode;
1602
2213
  }, true>;
1603
2214
  /**
1604
- * Text editor tool for Claude Sonnet 3.7 (deprecated model).
2215
+ * Defines the text editor tool for deprecated Claude Sonnet 3.7.
2216
+ *
2217
+ * **When to use**
2218
+ *
2219
+ * Use when configuring the 2025-01-24 Claude Sonnet 3.7 text editor tool using
2220
+ * `str_replace_editor`.
1605
2221
  *
1606
2222
  * **Details**
1607
2223
  *
1608
- * Requires the "computer-use-2025-01-24" beta header.
2224
+ * Requires the "computer-use-2025-01-24" beta header, requires a handler, and
2225
+ * supports `view`, `create`, `str_replace`, `insert`, and `undo_edit` commands.
2226
+ *
2227
+ * @see {@link TextEditor_20241022} for the older `str_replace_editor` version
2228
+ * @see {@link TextEditor_20250429} for the Claude 4 `str_replace_based_edit_tool` line
1609
2229
  *
1610
- * @category Text Editor
2230
+ * @category text editor
1611
2231
  * @since 4.0.0
1612
2232
  */
1613
2233
  export declare const TextEditor_20250124: <Mode extends Tool.FailureMode | undefined = undefined>(args: {
@@ -1675,7 +2295,12 @@ export declare const TextEditor_20250124: <Mode extends Tool.FailureMode | undef
1675
2295
  readonly failureMode: Mode extends undefined ? "error" : Mode;
1676
2296
  }, true>;
1677
2297
  /**
1678
- * Text editor tool for Claude 4 models using Anthropic's `str_replace_based_edit_tool`.
2298
+ * Defines the text editor tool for Claude 4 models using Anthropic's `str_replace_based_edit_tool`.
2299
+ *
2300
+ * **When to use**
2301
+ *
2302
+ * Use when configuring the 2025-04-29 Claude 4 `str_replace_based_edit_tool`
2303
+ * version.
1679
2304
  *
1680
2305
  * **Details**
1681
2306
  *
@@ -1685,7 +2310,10 @@ export declare const TextEditor_20250124: <Mode extends Tool.FailureMode | undef
1685
2310
  *
1686
2311
  * This version does not support the `undo_edit` command.
1687
2312
  *
1688
- * @category Text Editor
2313
+ * @see {@link TextEditor_20250124} for the previous `str_replace_editor` version
2314
+ * @see {@link TextEditor_20250728} for the later Claude 4 text editor version
2315
+ *
2316
+ * @category text editor
1689
2317
  * @since 4.0.0
1690
2318
  */
1691
2319
  export declare const TextEditor_20250429: <Mode extends Tool.FailureMode | undefined = undefined>(args: {
@@ -1754,13 +2382,18 @@ export declare const TextEditor_20250429: <Mode extends Tool.FailureMode | undef
1754
2382
  readonly failureMode: Mode extends undefined ? "error" : Mode;
1755
2383
  }, true>;
1756
2384
  /**
1757
- * Text editor tool for Claude 4 models.
2385
+ * Defines the text editor tool for Claude 4 models.
2386
+ *
2387
+ * **Details**
2388
+ *
2389
+ * Uses Anthropic's `str_replace_based_edit_tool`. `max_characters` can limit
2390
+ * file-view output for this version.
1758
2391
  *
1759
2392
  * **Gotchas**
1760
2393
  *
1761
2394
  * This version does not support the `undo_edit` command.
1762
2395
  *
1763
- * @category Text Editor
2396
+ * @category text editor
1764
2397
  * @since 4.0.0
1765
2398
  */
1766
2399
  export declare const TextEditor_20250728: <Mode extends Tool.FailureMode | undefined = undefined>(args: {
@@ -1829,12 +2462,20 @@ export declare const TextEditor_20250728: <Mode extends Tool.FailureMode | undef
1829
2462
  readonly failureMode: Mode extends undefined ? "error" : Mode;
1830
2463
  }, true>;
1831
2464
  /**
1832
- * User location for localizing search results.
2465
+ * Describes user location for localizing search results.
1833
2466
  *
1834
2467
  * **When to use**
1835
2468
  *
1836
- * Providing location helps return more relevant results for location-dependent
1837
- * queries like weather, local businesses, events, etc.
2469
+ * Use when providing location helps return more relevant results for
2470
+ * location-dependent queries like weather, local businesses, or events.
2471
+ *
2472
+ * **Details**
2473
+ *
2474
+ * The schema uses `type: "approximate"` plus optional `city`, `region`,
2475
+ * `country`, and `timezone`. `country` is an ISO 3166-1 alpha-2 code, and
2476
+ * `timezone` is an IANA time zone identifier.
2477
+ *
2478
+ * @see {@link WebSearch_20250305_Args} for the argument schema that consumes this location
1838
2479
  *
1839
2480
  * @category Web Search
1840
2481
  * @since 4.0.0
@@ -1862,7 +2503,24 @@ export declare const WebSearchUserLocation: Schema.Struct<{
1862
2503
  readonly timezone: Schema.optional<Schema.String>;
1863
2504
  }>;
1864
2505
  /**
1865
- * Configuration arguments for the web search tool.
2506
+ * Defines configuration arguments for the web search tool.
2507
+ *
2508
+ * **When to use**
2509
+ *
2510
+ * Use when configuring `WebSearch_20250305` with search limits, domain filters,
2511
+ * or user location.
2512
+ *
2513
+ * **Details**
2514
+ *
2515
+ * The payload can set `maxUses`, `allowedDomains`, `blockedDomains`, and
2516
+ * `userLocation`.
2517
+ *
2518
+ * **Gotchas**
2519
+ *
2520
+ * `allowedDomains` and `blockedDomains` are mutually exclusive.
2521
+ *
2522
+ * @see {@link WebSearch_20250305} for the provider-defined tool that consumes these arguments
2523
+ * @see {@link WebSearchUserLocation} for localizing search results
1866
2524
  *
1867
2525
  * @category Web Search
1868
2526
  * @since 4.0.0
@@ -1913,12 +2571,23 @@ export declare const WebSearch_20250305_Args: Schema.Struct<{
1913
2571
  /**
1914
2572
  * Configuration arguments for the Anthropic web search tool, including usage limits, domain filters, and optional user location.
1915
2573
  *
2574
+ * **Gotchas**
2575
+ *
2576
+ * `allowedDomains` and `blockedDomains` are mutually exclusive.
2577
+ *
1916
2578
  * @category Web Search
1917
2579
  * @since 4.0.0
1918
2580
  */
1919
2581
  export type WebSearch_20250305_Args = typeof WebSearch_20250305_Args.Type;
1920
2582
  /**
1921
- * Input parameters for a web search.
2583
+ * Schema for Claude-supplied web search tool parameters.
2584
+ *
2585
+ * **Details**
2586
+ *
2587
+ * The payload contains the generated `query` string and is consumed by
2588
+ * `WebSearch_20250305`.
2589
+ *
2590
+ * @see {@link WebSearch_20250305} for the provider-defined tool that consumes this payload
1922
2591
  *
1923
2592
  * @category Web Search
1924
2593
  * @since 4.0.0
@@ -1936,12 +2605,18 @@ export declare const WebSearchParameters: Schema.Struct<{
1936
2605
  *
1937
2606
  * Contains the generated search query used by `WebSearch_20250305`.
1938
2607
  *
2608
+ * @see {@link WebSearch_20250305} for the provider-defined tool that consumes this payload
2609
+ *
1939
2610
  * @category Web Search
1940
2611
  * @since 4.0.0
1941
2612
  */
1942
2613
  export type WebSearchParameters = typeof WebSearchParameters.Type;
1943
2614
  /**
1944
- * Web search tool for Claude models.
2615
+ * Defines the web search tool for Claude models.
2616
+ *
2617
+ * **When to use**
2618
+ *
2619
+ * Use when Claude should search the web for real-time information.
1945
2620
  *
1946
2621
  * **Details**
1947
2622
  *
@@ -1949,6 +2624,8 @@ export type WebSearchParameters = typeof WebSearchParameters.Type;
1949
2624
  * server-side tool executed by Anthropic's infrastructure.
1950
2625
  * Generally available (no beta header required).
1951
2626
  *
2627
+ * @see {@link WebFetch_20250910} for retrieving known URLs after discovery
2628
+ *
1952
2629
  * @category Web Search
1953
2630
  * @since 4.0.0
1954
2631
  */
@@ -2027,7 +2704,18 @@ export declare const WebSearch_20250305: <Mode extends Tool.FailureMode | undefi
2027
2704
  readonly failureMode: Mode extends undefined ? "error" : Mode;
2028
2705
  }, false>;
2029
2706
  /**
2030
- * Citation configuration for web fetch.
2707
+ * Defines citation configuration for web fetch.
2708
+ *
2709
+ * **When to use**
2710
+ *
2711
+ * Use when configuring whether web fetch results should include citations.
2712
+ *
2713
+ * **Details**
2714
+ *
2715
+ * The payload contains the `enabled` flag. `citations` is optional on
2716
+ * `WebFetch_20250910_Args`, and citations are disabled by default.
2717
+ *
2718
+ * @see {@link WebFetch_20250910_Args} for the argument schema that consumes this configuration
2031
2719
  *
2032
2720
  * @category Web Fetch
2033
2721
  * @since 4.0.0
@@ -2041,12 +2729,38 @@ export declare const WebFetchCitationsConfig: Schema.Struct<{
2041
2729
  /**
2042
2730
  * Configuration payload for enabling or disabling citations on web fetch results.
2043
2731
  *
2732
+ * **Details**
2733
+ *
2734
+ * The payload contains the `enabled` flag. `citations` is optional on
2735
+ * `WebFetch_20250910_Args`, and citations are disabled by default.
2736
+ *
2737
+ * @see {@link WebFetch_20250910_Args} for the argument schema that consumes this configuration
2738
+ *
2044
2739
  * @category Web Fetch
2045
2740
  * @since 4.0.0
2046
2741
  */
2047
2742
  export type WebFetchCitationsConfig = typeof WebFetchCitationsConfig.Type;
2048
2743
  /**
2049
- * Configuration arguments for the web fetch tool.
2744
+ * Defines configuration arguments for the web fetch tool.
2745
+ *
2746
+ * **When to use**
2747
+ *
2748
+ * Use when configuring `WebFetch_20250910` with usage limits, domain filters,
2749
+ * citations, or content token limits.
2750
+ *
2751
+ * **Details**
2752
+ *
2753
+ * The payload can set `maxUses`, domain filters, `citations`, and
2754
+ * `maxContentTokens`, which map to Anthropic web fetch request fields.
2755
+ *
2756
+ * **Gotchas**
2757
+ *
2758
+ * `allowedDomains` and `blockedDomains` are mutually exclusive.
2759
+ * `maxContentTokens` is approximate and does not apply to binary content such
2760
+ * as PDFs.
2761
+ *
2762
+ * @see {@link WebFetch_20250910} for the provider-defined tool that consumes these arguments
2763
+ * @see {@link WebFetchCitationsConfig} for configuring citations
2050
2764
  *
2051
2765
  * @category Web Fetch
2052
2766
  * @since 4.0.0
@@ -2085,12 +2799,34 @@ export declare const WebFetch_20250910_Args: Schema.Struct<{
2085
2799
  /**
2086
2800
  * Configuration arguments for the Anthropic web fetch tool, including usage limits, domain filters, citation settings, and token limits.
2087
2801
  *
2802
+ * **Gotchas**
2803
+ *
2804
+ * `allowedDomains` and `blockedDomains` are mutually exclusive.
2805
+ * `maxContentTokens` is approximate and does not apply to binary content such
2806
+ * as PDFs.
2807
+ *
2088
2808
  * @category Web Fetch
2089
2809
  * @since 4.0.0
2090
2810
  */
2091
2811
  export type WebFetch_20250910_Args = typeof WebFetch_20250910_Args.Type;
2092
2812
  /**
2093
- * Input parameters for a web fetch.
2813
+ * Schema for Claude-supplied web fetch parameters.
2814
+ *
2815
+ * **When to use**
2816
+ *
2817
+ * Use when validating or constructing the `url` payload consumed by
2818
+ * `WebFetch_20250910`.
2819
+ *
2820
+ * **Details**
2821
+ *
2822
+ * The payload contains the single `url` parameter for Anthropic web fetch.
2823
+ *
2824
+ * **Gotchas**
2825
+ *
2826
+ * The URL must be user-provided or from prior search/fetch results. Maximum URL
2827
+ * length is 250 characters.
2828
+ *
2829
+ * @see {@link WebFetch_20250910} for the provider-defined tool that consumes this payload
2094
2830
  *
2095
2831
  * @category Web Fetch
2096
2832
  * @since 4.0.0
@@ -2105,18 +2841,33 @@ export declare const WebFetchParameters: Schema.Struct<{
2105
2841
  /**
2106
2842
  * Type of the parameters Claude supplies when invoking the Anthropic web fetch tool.
2107
2843
  *
2844
+ * **Details**
2845
+ *
2846
+ * The payload contains the single `url` parameter for Anthropic web fetch.
2847
+ *
2848
+ * **Gotchas**
2849
+ *
2850
+ * The URL must be user-provided or from prior search/fetch results. Maximum URL
2851
+ * length is 250 characters.
2852
+ *
2108
2853
  * @category Web Fetch
2109
2854
  * @since 4.0.0
2110
2855
  */
2111
2856
  export type WebFetchParameters = typeof WebFetchParameters.Type;
2112
2857
  /**
2113
- * Web fetch tool for Claude models.
2858
+ * Defines the web fetch tool for Claude models.
2859
+ *
2860
+ * **When to use**
2861
+ *
2862
+ * Use when Claude should retrieve the content of a specific web page or PDF.
2114
2863
  *
2115
2864
  * **Details**
2116
2865
  *
2117
2866
  * Allows Claude to retrieve full content from web pages and PDF documents.
2118
- * This is a server-side tool executed by Anthropic's infrastructure.
2119
- * Requires the "web-fetch-2025-09-10" beta header.
2867
+ * This is a server-side tool executed by Anthropic's infrastructure. Selecting
2868
+ * this tool adds the "web-fetch-2025-09-10" beta header.
2869
+ *
2870
+ * @see {@link WebSearch_20250305} for discovering URLs before fetching specific content
2120
2871
  *
2121
2872
  * @category Web Fetch
2122
2873
  * @since 4.0.0
@@ -2196,14 +2947,14 @@ export declare const WebFetch_20250910: <Mode extends Tool.FailureMode | undefin
2196
2947
  readonly failureMode: Mode extends undefined ? "error" : Mode;
2197
2948
  }, false>;
2198
2949
  /**
2199
- * Input parameters for regex-based tool search.
2950
+ * Schema for regex-based tool search input parameters.
2200
2951
  *
2201
2952
  * **Details**
2202
2953
  *
2203
2954
  * Claude constructs regex patterns using Python's `re.search()` syntax.
2204
2955
  * Maximum query length: 200 characters.
2205
2956
  *
2206
- * @category Tool Search
2957
+ * @category tool search
2207
2958
  * @since 4.0.0
2208
2959
  */
2209
2960
  export declare const ToolSearchRegexParameters: Schema.Struct<{
@@ -2215,14 +2966,31 @@ export declare const ToolSearchRegexParameters: Schema.Struct<{
2215
2966
  /**
2216
2967
  * Type of the parameters Claude supplies when invoking regex-based Anthropic tool search.
2217
2968
  *
2218
- * @category Tool Search
2969
+ * **Details**
2970
+ *
2971
+ * Claude constructs regex patterns using Python's `re.search()` syntax.
2972
+ * Maximum query length: 200 characters.
2973
+ *
2974
+ * @category tool search
2219
2975
  * @since 4.0.0
2220
2976
  */
2221
2977
  export type ToolSearchRegexParameters = typeof ToolSearchRegexParameters.Type;
2222
2978
  /**
2223
- * Input parameters for BM25/natural language tool search.
2979
+ * Defines input parameters for BM25/natural language tool search.
2980
+ *
2981
+ * **When to use**
2982
+ *
2983
+ * Use when validating or constructing the natural-language query payload for
2984
+ * `ToolSearchBM25_20251119`.
2985
+ *
2986
+ * **Details**
2224
2987
  *
2225
- * @category Tool Search
2988
+ * The payload contains Claude's natural-language `query`. BM25 searches tool
2989
+ * names, descriptions, argument names, and argument descriptions.
2990
+ *
2991
+ * @see {@link ToolSearchBM25_20251119} for the provider-defined tool that consumes these parameters
2992
+ *
2993
+ * @category tool search
2226
2994
  * @since 4.0.0
2227
2995
  */
2228
2996
  export declare const ToolSearchBM25Parameters: Schema.Struct<{
@@ -2234,12 +3002,12 @@ export declare const ToolSearchBM25Parameters: Schema.Struct<{
2234
3002
  /**
2235
3003
  * Type of the parameters Claude supplies when invoking BM25 natural-language Anthropic tool search.
2236
3004
  *
2237
- * @category Tool Search
3005
+ * @category tool search
2238
3006
  * @since 4.0.0
2239
3007
  */
2240
3008
  export type ToolSearchBM25Parameters = typeof ToolSearchBM25Parameters.Type;
2241
3009
  /**
2242
- * Regex-based tool search for Claude models.
3010
+ * Defines regex-based tool search for Claude models.
2243
3011
  *
2244
3012
  * **Details**
2245
3013
  *
@@ -2248,7 +3016,7 @@ export type ToolSearchBM25Parameters = typeof ToolSearchBM25Parameters.Type;
2248
3016
  * argument names, and argument descriptions.
2249
3017
  * Requires the "advanced-tool-use-2025-11-20" beta header.
2250
3018
  *
2251
- * @category Tool Search
3019
+ * @category tool search
2252
3020
  * @since 4.0.0
2253
3021
  */
2254
3022
  export declare const ToolSearchRegex_20251119: <Mode extends Tool.FailureMode | undefined = undefined>(args: void) => Tool.ProviderDefined<"anthropic.tool_search_tool_regex_20251119", "AnthropicToolSearchRegex", {
@@ -2275,7 +3043,12 @@ export declare const ToolSearchRegex_20251119: <Mode extends Tool.FailureMode |
2275
3043
  readonly failureMode: Mode extends undefined ? "error" : Mode;
2276
3044
  }, false>;
2277
3045
  /**
2278
- * BM25/natural language tool search for Claude models.
3046
+ * Defines BM25/natural language tool search for Claude models.
3047
+ *
3048
+ * **When to use**
3049
+ *
3050
+ * Use when you want Claude to find relevant tools from a natural-language query
3051
+ * instead of a regex pattern.
2279
3052
  *
2280
3053
  * **Details**
2281
3054
  *
@@ -2284,7 +3057,9 @@ export declare const ToolSearchRegex_20251119: <Mode extends Tool.FailureMode |
2284
3057
  * argument names, and argument descriptions.
2285
3058
  * Requires the "advanced-tool-use-2025-11-20" beta header.
2286
3059
  *
2287
- * @category Tool Search
3060
+ * @see {@link ToolSearchRegex_20251119} for the regex-pattern alternative
3061
+ *
3062
+ * @category tool search
2288
3063
  * @since 4.0.0
2289
3064
  */
2290
3065
  export declare const ToolSearchBM25_20251119: <Mode extends Tool.FailureMode | undefined = undefined>(args: void) => Tool.ProviderDefined<"anthropic.tool_search_tool_bm25_20251119", "AnthropicToolSearchBM25", {