* experiment: cold start perf * fix: update failing test * chore: add database indexes * chore: use json protocol and add query batching back * Update [status].tsx * Update [trpc].ts * Delete getSlimSession.ts * Update createContext.ts * remove trpc caller * correctly import Prisma * lazy ethRouter * replace crypto with md5 * import fixes * public event endpoint refactor * Update yarn.lock * Update yarn.lock * Using yarn.lock from main --------- Co-authored-by: Omar López <zomars@me.com> Co-authored-by: Peer Richelsen <peeroke@gmail.com> Co-authored-by: Efraín Rochín <roae.85@gmail.com> Co-authored-by: Keith Williams <keithwillcode@gmail.com>
35 lines
992 B
TypeScript
35 lines
992 B
TypeScript
import { z } from "zod";
|
|
|
|
import {
|
|
TIME_UNIT,
|
|
WORKFLOW_ACTIONS,
|
|
WORKFLOW_TEMPLATES,
|
|
WORKFLOW_TRIGGER_EVENTS,
|
|
} from "@calcom/features/ee/workflows/lib/constants";
|
|
|
|
export const ZUpdateInputSchema = z.object({
|
|
id: z.number(),
|
|
name: z.string(),
|
|
activeOn: z.number().array(),
|
|
steps: z
|
|
.object({
|
|
id: z.number(),
|
|
stepNumber: z.number(),
|
|
action: z.enum(WORKFLOW_ACTIONS),
|
|
workflowId: z.number(),
|
|
sendTo: z.string().optional().nullable(),
|
|
reminderBody: z.string().optional().nullable(),
|
|
emailSubject: z.string().optional().nullable(),
|
|
template: z.enum(WORKFLOW_TEMPLATES),
|
|
numberRequired: z.boolean().nullable(),
|
|
sender: z.string().optional().nullable(),
|
|
senderName: z.string().optional().nullable(),
|
|
})
|
|
.array(),
|
|
trigger: z.enum(WORKFLOW_TRIGGER_EVENTS),
|
|
time: z.number().nullable(),
|
|
timeUnit: z.enum(TIME_UNIT).nullable(),
|
|
});
|
|
|
|
export type TUpdateInputSchema = z.infer<typeof ZUpdateInputSchema>;
|