diff --git a/packages/features/CalendarEventBuilder.ts b/packages/features/CalendarEventBuilder.ts index 10ae0d6832d19b..1efd779085ea0f 100644 --- a/packages/features/CalendarEventBuilder.ts +++ b/packages/features/CalendarEventBuilder.ts @@ -479,6 +479,14 @@ export class CalendarEventBuilder { return this; } + withHashedLink(hashedLink?: string | null) { + this.event = { + ...this.event, + hashedLink, + }; + return this; + } + build(): CalendarEvent | null { // Validate required fields if ( diff --git a/packages/features/bookings/lib/service/RegularBookingService.ts b/packages/features/bookings/lib/service/RegularBookingService.ts index 95cf13acdfc7d2..f7a8c2b86d8bd3 100644 --- a/packages/features/bookings/lib/service/RegularBookingService.ts +++ b/packages/features/bookings/lib/service/RegularBookingService.ts @@ -1387,6 +1387,7 @@ async function handler( platformCancelUrl, platformBookingUrl, }) + .withHashedLink(hasHashedBookingLink ? reqBody.hashedLink ?? null : null) .build(); if (!builtEvt) { diff --git a/packages/types/Calendar.d.ts b/packages/types/Calendar.d.ts index 22e67ce5463998..009ad2fe062d0c 100644 --- a/packages/types/Calendar.d.ts +++ b/packages/types/Calendar.d.ts @@ -163,6 +163,7 @@ export interface CalendarEvent { // Instead of sending this per event. // TODO: Links sent in email should be validated and automatically redirected to org domain or regular app. It would be a much cleaner way. Maybe use existing /api/link endpoint bookerUrl?: string; + hashedLink?: string | null; type: string; title: string; startTime: string;