export interface ToolSchema { type?: string; properties?: Record; required?: string[]; items?: ToolSchema; } export declare class ToolArgumentError extends Error { constructor(message: string); } /** * Closest name by edit distance alone. * * suggestParameter is the wrong ranking for a value drawn from a fixed list. * It puts shared whole words first, which is right for parameter names — `date` * really does mean `txn_date` — but wrong for an enum whose members are * variations on one phrase: against `aged_payable` it prefers * `aged_payable_detail`, which shares two words, over `aged_payables`, which is * a single character away and obviously what was meant. */ export declare function suggestClosest(unknown: string, valid: string[]): string | undefined; /** * Best valid name for a misspelling, or undefined when nothing is close. * * Edit distance alone is not enough for the misspellings that actually happen * here, because the real names are compounds: `date` → `txn_date` is four edits * apart but shares the whole word. Shared underscore-separated tokens rank * first, edit distance breaks the tie. */ export declare function suggestParameter(unknown: string, valid: string[]): string | undefined; /** * Throw unless `args` matches the tool's declared input schema. * * Checks unknown keys and required keys, at every nesting level. Types and * enums are deliberately left to the handlers and to QuickBooks, so that a * value the handler already normalizes is not rejected here. */ export declare function validateToolArguments(toolName: string, schema: ToolSchema | undefined, args: Record | undefined): void; //# sourceMappingURL=validate.d.ts.map