/* * 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 ElasticSearchResultsNodeInfoClusterCombinedInfoIndicesStore = { reservedInBytes?: number | undefined; sizeInBytes?: number | undefined; }; /** @internal */ export const ElasticSearchResultsNodeInfoClusterCombinedInfoIndicesStore$inboundSchema: z.ZodType< ElasticSearchResultsNodeInfoClusterCombinedInfoIndicesStore, z.ZodTypeDef, unknown > = z.object({ reserved_in_bytes: z.number().int().optional(), size_in_bytes: z.number().int().optional(), }).transform((v) => { return remap$(v, { "reserved_in_bytes": "reservedInBytes", "size_in_bytes": "sizeInBytes", }); }); export function elasticSearchResultsNodeInfoClusterCombinedInfoIndicesStoreFromJSON( jsonString: string, ): SafeParseResult< ElasticSearchResultsNodeInfoClusterCombinedInfoIndicesStore, SDKValidationError > { return safeParse( jsonString, (x) => ElasticSearchResultsNodeInfoClusterCombinedInfoIndicesStore$inboundSchema .parse(JSON.parse(x)), `Failed to parse 'ElasticSearchResultsNodeInfoClusterCombinedInfoIndicesStore' from JSON`, ); }