Configuration for creating a tool without schema (no parameters)

interface CreateToolConfigWithoutSchema {
    name: string;
    description: string;
    fn: ((args: Record<string, never>, context: ToolContext) => any);
    isLongRunning?: boolean;
    shouldRetryOnFailure?: boolean;
    maxRetryAttempts?: number;
}

Properties

name: string

The name of the tool

description: string

A description of what the tool does

fn: ((args: Record<string, never>, context: ToolContext) => any)

The function to execute (can be sync or async)

isLongRunning?: boolean

Whether the tool is a long running operation

shouldRetryOnFailure?: boolean

Whether the tool execution should be retried on failure

maxRetryAttempts?: number

Maximum retry attempts