/* * 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 { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { EmployeeSection603HighEarnerStatus, EmployeeSection603HighEarnerStatus$inboundSchema, } from "../components/employeesection603highearnerstatus.js"; import { HTTPMetadata, HTTPMetadata$inboundSchema, } from "../components/httpmetadata.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; /** * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ export const GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearHeaderXGustoAPIVersion = { TwoThousandAndTwentyFiveMinus06Minus15: "2025-06-15", } as const; /** * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ export type GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearHeaderXGustoAPIVersion = ClosedEnum< typeof GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearHeaderXGustoAPIVersion >; export type GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearRequest = { /** * The UUID of the employee */ employeeUuid: string; /** * The effective year for the Section 603 status */ effectiveYear: number; /** * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ xGustoAPIVersion?: | GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearHeaderXGustoAPIVersion | undefined; }; export type GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearResponse = { httpMeta: HTTPMetadata; /** * successful */ employeeSection603HighEarnerStatus?: | EmployeeSection603HighEarnerStatus | undefined; }; /** @internal */ export const GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearHeaderXGustoAPIVersion$outboundSchema: z.ZodNativeEnum< typeof GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearHeaderXGustoAPIVersion > = z.nativeEnum( GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearHeaderXGustoAPIVersion, ); /** @internal */ export type GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearRequest$Outbound = { employee_uuid: string; effective_year: number; "X-Gusto-API-Version": string; }; /** @internal */ export const GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearRequest$outboundSchema: z.ZodType< GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearRequest$Outbound, z.ZodTypeDef, GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearRequest > = z.object({ employeeUuid: z.string(), effectiveYear: z.number().int(), xGustoAPIVersion: GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearHeaderXGustoAPIVersion$outboundSchema .default("2025-06-15"), }).transform((v) => { return remap$(v, { employeeUuid: "employee_uuid", effectiveYear: "effective_year", xGustoAPIVersion: "X-Gusto-API-Version", }); }); export function getV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearRequestToJSON( getV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearRequest: GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearRequest, ): string { return JSON.stringify( GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearRequest$outboundSchema .parse( getV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearRequest, ), ); } /** @internal */ export const GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearResponse$inboundSchema: z.ZodType< GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearResponse, z.ZodTypeDef, unknown > = z.object({ HttpMeta: HTTPMetadata$inboundSchema, "Employee-Section603-High-Earner-Status": EmployeeSection603HighEarnerStatus$inboundSchema.optional(), }).transform((v) => { return remap$(v, { "HttpMeta": "httpMeta", "Employee-Section603-High-Earner-Status": "employeeSection603HighEarnerStatus", }); }); export function getV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearResponseFromJSON( jsonString: string, ): SafeParseResult< GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearResponse, SDKValidationError > { return safeParse( jsonString, (x) => GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearResponse$inboundSchema .parse(JSON.parse(x)), `Failed to parse 'GetV1EmployeesEmployeeUuidSection603HighEarnerStatusesEffectiveYearResponse' from JSON`, ); }