/* * 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 PayrollTaxesType = { /** * The tax name */ name?: string | undefined; /** * Whether this tax is an employer or employee tax */ employer?: boolean | undefined; /** * The total tax for the payroll */ amount?: number | undefined; }; /** @internal */ export const PayrollTaxesType$inboundSchema: z.ZodType< PayrollTaxesType, z.ZodTypeDef, unknown > = z.object({ name: z.string().optional(), employer: z.boolean().optional(), amount: z.number().optional(), }); export function payrollTaxesTypeFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => PayrollTaxesType$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PayrollTaxesType' from JSON`, ); }