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