cal.pub0.org/lib/validations/attendee.ts

14 lines
375 B
TypeScript

import { withValidation } from "next-validations";
import { _AttendeeModel as Attendee } from "@calcom/prisma/zod";
export const schemaAttendeeBodyParams = Attendee.omit({ id: true }).partial();
export const schemaAttendeePublic = Attendee.omit({});
export const withValidAttendee = withValidation({
schema: schemaAttendeeBodyParams,
type: "Zod",
mode: "body",
});