* feat: lang support * fix: type errors * feat: select voice agent * refactor: address feedback * refactor: address feedback * refactor: missing import * fix: types * feat: add inbound calls * chore: formatting * chore * feat: finish inbound call * chore: formatting * fix: update bug * fix: types * refactor: Agent Configuration Sheet (#23930) * refactor: agent configuration sheet * chore: use default phone numbre * refactor: improvements * refactor: improvements * fix: types * fix: feedback * chore: * fix: feedback * fix: prompt * fix: review * fix: review * refactor: class * refactor: class * refactor: rename * Update apps/web/public/static/locales/en/common.json * Update apps/web/public/static/locales/en/common.json * chore: update set value * fix: remove index * fix: type error * fix: update tetss * fix: use logger * refactor: don't use static * fix: type * fix: schema * refactor: --------- Co-authored-by: Carina Wollendorfer <[email protected]>
39 lines
1.1 KiB
TypeScript
39 lines
1.1 KiB
TypeScript
import { z } from "zod";
|
|
|
|
import {
|
|
WORKFLOW_TEMPLATES,
|
|
TIME_UNIT,
|
|
WORKFLOW_ACTIONS,
|
|
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().nullable(),
|
|
reminderBody: z.string().nullable(),
|
|
emailSubject: z.string().nullable(),
|
|
template: z.enum(WORKFLOW_TEMPLATES),
|
|
numberRequired: z.boolean().nullable(),
|
|
sender: z.string().nullable(),
|
|
senderName: z.string().nullable(),
|
|
includeCalendarEvent: z.boolean(),
|
|
agentId: z.string().nullish(),
|
|
inboundAgentId: z.string().nullish(),
|
|
})
|
|
.array(),
|
|
trigger: z.enum(WORKFLOW_TRIGGER_EVENTS),
|
|
time: z.number().nullable(),
|
|
timeUnit: z.enum(TIME_UNIT).nullable(),
|
|
isActiveOnAll: z.boolean().optional(),
|
|
});
|
|
|
|
export type TUpdateInputSchema = z.infer<typeof ZUpdateInputSchema>;
|