/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { lazySchema as lazySchema$, safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import * as types from "../../types/primitives.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; export type ProfitAndLossIndicator = { /** * The total amount of the transaction or record */ total?: number | null | undefined; }; /** @internal */ export const ProfitAndLossIndicator$inboundSchema: z.ZodType< ProfitAndLossIndicator, z.ZodTypeDef, unknown > = /* @__PURE__ */ lazySchema$(() => z.object({ total: z.nullable(types.number()).optional(), }) ); export function profitAndLossIndicatorFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => ProfitAndLossIndicator$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ProfitAndLossIndicator' from JSON`, ); }