From 6847f5de95fa2af5714f27d25cf90ea024ce7e5a Mon Sep 17 00:00:00 2001 From: saridsa2 Date: Mon, 20 Apr 2026 15:44:56 +0530 Subject: [PATCH] fix(messaging): appointment field is 'status' not 'appointmentStatus' MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Matched the working agent tool mutation — platform expects 'status' for AppointmentCreateInput, not 'appointmentStatus'. Co-Authored-By: Claude Opus 4.6 (1M context) --- src/messaging/messaging.service.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/messaging/messaging.service.ts b/src/messaging/messaging.service.ts index 8101e82..9a92a67 100644 --- a/src/messaging/messaging.service.ts +++ b/src/messaging/messaging.service.ts @@ -364,7 +364,7 @@ ${callerContext ? `\n${callerContext}` : ''}`; const result = await platform.query( `mutation($data: AppointmentCreateInput!) { createAppointment(data: $data) { id } }`, - { data: { name: `WhatsApp Booking — ${patientName} (${department})`, scheduledAt, appointmentStatus: 'SCHEDULED', doctorName, department, reasonForVisit: reason } }, + { data: { name: `WhatsApp Booking — ${patientName} (${department})`, scheduledAt, status: 'SCHEDULED', doctorName, department, reasonForVisit: reason } }, ); const id = result?.createAppointment?.id; if (id) {