From 8df3a368dd719beea9d7288d9eb11c383630024e Mon Sep 17 00:00:00 2001 From: Pavel Jbanov Date: Wed, 3 Dec 2025 10:59:01 -0500 Subject: [PATCH] fix(genkit-tool/common): fixed ToolResponse interface naming typo --- genkit-tools/common/src/types/parts.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/genkit-tools/common/src/types/parts.ts b/genkit-tools/common/src/types/parts.ts index b2acf20f02..eef420cc7b 100644 --- a/genkit-tools/common/src/types/parts.ts +++ b/genkit-tools/common/src/types/parts.ts @@ -115,11 +115,11 @@ const ToolResponseSchemaBase = z.object({ /** * Tool response part. */ -export type ToolResponsePart = z.infer & { +export type ToolResponse = z.infer & { content?: Part[]; }; -export const ToolResponseSchema: z.ZodType = +export const ToolResponseSchema: z.ZodType = ToolResponseSchemaBase.extend({ content: z.array(z.any()).optional(), // TODO: switch to this once we have effective recursive schema support across the board. @@ -134,6 +134,8 @@ export const ToolResponsePartSchema = EmptyPartSchema.extend({ toolResponse: ToolResponseSchema, }); +export type ToolResponsePart = z.infer; + /** * Zod schema of a data part. */