/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod"; import { remap as remap$ } from "../../lib/primitives.js"; import { ConditionV2, ConditionV2$inboundSchema, ConditionV2$Outbound, ConditionV2$outboundSchema, } from "./conditionv2.js"; import { EscalationPathNodeV2, EscalationPathNodeV2$inboundSchema, EscalationPathNodeV2$Outbound, EscalationPathNodeV2$outboundSchema, } from "./escalationpathnodev2.js"; export type EscalationPathNodeIfElseV2 = { /** * The condition that defines which branch to take */ conditions: Array; /** * The nodes that form the levels if our condition is not met */ elsePath: Array; /** * The nodes that form the levels if our condition is met */ thenPath: Array; }; /** @internal */ export const EscalationPathNodeIfElseV2$inboundSchema: z.ZodType< EscalationPathNodeIfElseV2, z.ZodTypeDef, unknown > = z.object({ conditions: z.array(ConditionV2$inboundSchema), else_path: z.array(EscalationPathNodeV2$inboundSchema), then_path: z.array(EscalationPathNodeV2$inboundSchema), }).transform((v) => { return remap$(v, { "else_path": "elsePath", "then_path": "thenPath", }); }); /** @internal */ export type EscalationPathNodeIfElseV2$Outbound = { conditions: Array; else_path: Array; then_path: Array; }; /** @internal */ export const EscalationPathNodeIfElseV2$outboundSchema: z.ZodType< EscalationPathNodeIfElseV2$Outbound, z.ZodTypeDef, EscalationPathNodeIfElseV2 > = z.object({ conditions: z.array(ConditionV2$outboundSchema), elsePath: z.array(EscalationPathNodeV2$outboundSchema), thenPath: z.array(EscalationPathNodeV2$outboundSchema), }).transform((v) => { return remap$(v, { elsePath: "else_path", thenPath: "then_path", }); }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace EscalationPathNodeIfElseV2$ { /** @deprecated use `EscalationPathNodeIfElseV2$inboundSchema` instead. */ export const inboundSchema = EscalationPathNodeIfElseV2$inboundSchema; /** @deprecated use `EscalationPathNodeIfElseV2$outboundSchema` instead. */ export const outboundSchema = EscalationPathNodeIfElseV2$outboundSchema; /** @deprecated use `EscalationPathNodeIfElseV2$Outbound` instead. */ export type Outbound = EscalationPathNodeIfElseV2$Outbound; }