CodeTool
Defined in: agents/src/code.ts:70
Properties
Section titled “Properties”isReadOnly
Section titled “isReadOnly”readonly isReadOnly: boolean;Defined in: agents/src/code.ts:75
readonly kind: "code";Defined in: agents/src/code.ts:71
limits
Section titled “limits”readonly limits: Readonly<CodeLimits>;Defined in: agents/src/code.ts:74
readonly name: string;Defined in: agents/src/code.ts:72
needsApproval
Section titled “needsApproval”readonly needsApproval: boolean;Defined in: agents/src/code.ts:76
readonly tools: readonly Tool<unknown, unknown>[];Defined in: agents/src/code.ts:73
Methods
Section titled “Methods”definition()
Section titled “definition()”definition(enabled?): ToolDefinition;Defined in: agents/src/code.ts:78
The loop supplies only the enabled subset; callers cannot add bindings.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
enabled? |
readonly string[] |
Returns
Section titled “Returns”ToolDefinition
withTools()
Section titled “withTools()”withTools(tools): CodeTool;Defined in: agents/src/code.ts:80
Return a new descriptor with the same binding names, driver and limits. No object is mutated.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
tools |
readonly Tool<unknown, unknown>[] |
Returns
Section titled “Returns”CodeTool