/* * 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"; export type ModbusMEIResponse = { conformityLevel?: number | undefined; moreFollows?: boolean | undefined; objects?: { [k: string]: string } | undefined; }; /** @internal */ export const ModbusMEIResponse$inboundSchema: z.ZodType< ModbusMEIResponse, z.ZodTypeDef, unknown > = z.object({ conformity_level: z.number().int().optional(), more_follows: z.boolean().optional(), objects: z.record(z.string()).optional(), }).transform((v) => { return remap$(v, { "conformity_level": "conformityLevel", "more_follows": "moreFollows", }); }); export function modbusMEIResponseFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => ModbusMEIResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ModbusMEIResponse' from JSON`, ); }