From 39db61cc767dde0d0fe0a232d00b3f3aae7ad603 Mon Sep 17 00:00:00 2001 From: unknown Date: Mon, 6 Apr 2026 15:05:43 +0200 Subject: [PATCH] fix(mcp): add describe() to remaining z.enum fields for better tool descriptions --- server/src/mcp/tools.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/server/src/mcp/tools.ts b/server/src/mcp/tools.ts index a42df8c8..66be7489 100644 --- a/server/src/mcp/tools.ts +++ b/server/src/mcp/tools.ts @@ -465,7 +465,7 @@ export function registerTools(server: McpServer, userId: number): void { inputSchema: { tripId: z.number().int().positive(), title: z.string().min(1).max(200), - type: z.enum(['flight', 'hotel', 'restaurant', 'train', 'car', 'cruise', 'event', 'tour', 'activity', 'other']), + type: z.enum(['flight', 'hotel', 'restaurant', 'train', 'car', 'cruise', 'event', 'tour', 'activity', 'other']).describe('Reservation type: "flight", "hotel", "restaurant", "train", "car", "cruise", "event", "tour", "activity", or "other"'), reservation_time: z.string().optional().describe('ISO 8601 datetime or time string'), location: z.string().max(500).optional(), confirmation_number: z.string().max(100).optional(), @@ -641,12 +641,12 @@ export function registerTools(server: McpServer, userId: number): void { tripId: z.number().int().positive(), reservationId: z.number().int().positive(), title: z.string().min(1).max(200).optional(), - type: z.enum(['flight', 'hotel', 'restaurant', 'train', 'car', 'cruise', 'event', 'tour', 'activity', 'other']).optional(), + type: z.enum(['flight', 'hotel', 'restaurant', 'train', 'car', 'cruise', 'event', 'tour', 'activity', 'other']).optional().describe('Reservation type: "flight", "hotel", "restaurant", "train", "car", "cruise", "event", "tour", "activity", or "other"'), reservation_time: z.string().optional().describe('ISO 8601 datetime or time string'), location: z.string().max(500).optional(), confirmation_number: z.string().max(100).optional(), notes: z.string().max(1000).optional(), - status: z.enum(['pending', 'confirmed', 'cancelled']).optional(), + status: z.enum(['pending', 'confirmed', 'cancelled']).optional().describe('Reservation status: "pending", "confirmed", or "cancelled"'), place_id: z.number().int().positive().nullable().optional().describe('Link to a place (use for hotel type), or null to unlink'), assignment_id: z.number().int().positive().nullable().optional().describe('Link to a day assignment (use for restaurant, train, car, cruise, event, tour, activity, other), or null to unlink'), },