/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { remap as remap$ } from "../../lib/primitives.js"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; /** * Pay schedule assignment first pay period information. */ export type PayScheduleAssignmentPayPeriod = { /** * The pay schedule UUID. */ payScheduleUuid?: string | undefined; /** * Pay period start date. */ startDate?: string | undefined; /** * Pay period end date. */ endDate?: string | undefined; /** * Pay period check date. */ checkDate?: string | undefined; }; /** @internal */ export const PayScheduleAssignmentPayPeriod$inboundSchema: z.ZodType< PayScheduleAssignmentPayPeriod, z.ZodTypeDef, unknown > = z.object({ pay_schedule_uuid: z.string().optional(), start_date: z.string().optional(), end_date: z.string().optional(), check_date: z.string().optional(), }).transform((v) => { return remap$(v, { "pay_schedule_uuid": "payScheduleUuid", "start_date": "startDate", "end_date": "endDate", "check_date": "checkDate", }); }); export function payScheduleAssignmentPayPeriodFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => PayScheduleAssignmentPayPeriod$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PayScheduleAssignmentPayPeriod' from JSON`, ); }