/** * Elicitation Content Validation Helper * * Validates elicitation result content against the stored JSON Schema. * Uses Zod 4's native `z.fromJSONSchema` for JSON Schema → Zod conversion. * * @module elicitation/helpers/validate-elicitation-content */ /** * Validation result interface. */ export interface ElicitationValidationResult { /** Whether validation succeeded */ success: boolean; /** Validation errors (if any) */ errors?: Array<{ path: string[]; message: string; }>; } /** * Validate elicitation content against a JSON Schema. * * This function converts the JSON Schema to a Zod schema and validates * the content against it. * * @param content - The content to validate * @param jsonSchema - The JSON Schema to validate against * @returns Validation result with success flag and optional errors * * @example * ```typescript * const result = validateElicitationContent( * { name: 'John', age: '30' }, // age should be number * { * type: 'object', * properties: { * name: { type: 'string' }, * age: { type: 'number' } * }, * required: ['name', 'age'] * } * ); * * if (!result.success) { * console.log(result.errors); * // [{ path: ['age'], message: 'Expected number, received string' }] * } * ``` */ export declare function validateElicitationContent(content: unknown, jsonSchema: Record): ElicitationValidationResult; //# sourceMappingURL=validate-elicitation-content.d.ts.map