/* * 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"; export type RepresentativeResponsibilitiesError = { isController?: string | undefined; isOwner?: string | undefined; ownershipPercentage?: string | undefined; jobTitle?: string | undefined; }; /** @internal */ export const RepresentativeResponsibilitiesError$inboundSchema: z.ZodType< RepresentativeResponsibilitiesError, z.ZodTypeDef, unknown > = z.object({ isController: z.string().optional(), isOwner: z.string().optional(), ownershipPercentage: z.string().optional(), jobTitle: z.string().optional(), }); /** @internal */ export type RepresentativeResponsibilitiesError$Outbound = { isController?: string | undefined; isOwner?: string | undefined; ownershipPercentage?: string | undefined; jobTitle?: string | undefined; }; /** @internal */ export const RepresentativeResponsibilitiesError$outboundSchema: z.ZodType< RepresentativeResponsibilitiesError$Outbound, z.ZodTypeDef, RepresentativeResponsibilitiesError > = z.object({ isController: z.string().optional(), isOwner: z.string().optional(), ownershipPercentage: z.string().optional(), jobTitle: z.string().optional(), }); export function representativeResponsibilitiesErrorToJSON( representativeResponsibilitiesError: RepresentativeResponsibilitiesError, ): string { return JSON.stringify( RepresentativeResponsibilitiesError$outboundSchema.parse( representativeResponsibilitiesError, ), ); } export function representativeResponsibilitiesErrorFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => RepresentativeResponsibilitiesError$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'RepresentativeResponsibilitiesError' from JSON`, ); }