/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; import { IntegrationBasedPersonInfoSource, IntegrationBasedPersonInfoSource$inboundSchema, } from "./integrationbasedpersoninfosource.js"; import { ScimBasedPersonInfoSource, ScimBasedPersonInfoSource$inboundSchema, } from "./scimbasedpersoninfosource.js"; import { VantaBasedPersonInfoSource, VantaBasedPersonInfoSource$inboundSchema, } from "./vantabasedpersoninfosource.js"; /** * The source of the person's information. */ export type PersonInfoSource = | VantaBasedPersonInfoSource | ScimBasedPersonInfoSource | IntegrationBasedPersonInfoSource; /** @internal */ export const PersonInfoSource$inboundSchema: z.ZodType< PersonInfoSource, z.ZodTypeDef, unknown > = z.union([ VantaBasedPersonInfoSource$inboundSchema, ScimBasedPersonInfoSource$inboundSchema, IntegrationBasedPersonInfoSource$inboundSchema, ]); export function personInfoSourceFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => PersonInfoSource$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PersonInfoSource' from JSON`, ); }