/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v4-mini"; import { remap as remap$ } from "../../lib/primitives.js"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import * as types from "../../types/primitives.js"; import { SDKValidationError } from "./sdk-validation-error.js"; export type PlanSummary = { /** * description of the plan */ description?: string | undefined; /** * id of the plan */ id?: string | undefined; /** * lookup_key of the plan */ lookupKey?: string | undefined; /** * name of the plan */ name?: string | undefined; }; /** @internal */ export const PlanSummary$inboundSchema: z.ZodMiniType = z .pipe( z.object({ description: types.optional(types.string()), id: types.optional(types.string()), lookup_key: types.optional(types.string()), name: types.optional(types.string()), }), z.transform((v) => { return remap$(v, { "lookup_key": "lookupKey", }); }), ); export function planSummaryFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => PlanSummary$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PlanSummary' from JSON`, ); }