/* * 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 { RoundType, RoundType$outboundSchema } from "./round-type.js"; export type PriceTransformQuantity = { /** * Divide quantity by this number */ divideBy?: number | undefined; round?: RoundType | undefined; }; /** @internal */ export type PriceTransformQuantity$Outbound = { divide_by?: number | undefined; round?: string | undefined; }; /** @internal */ export const PriceTransformQuantity$outboundSchema: z.ZodMiniType< PriceTransformQuantity$Outbound, PriceTransformQuantity > = z.pipe( z.object({ divideBy: z.optional(z.int()), round: z.optional(RoundType$outboundSchema), }), z.transform((v) => { return remap$(v, { divideBy: "divide_by", }); }), ); export function priceTransformQuantityToJSON( priceTransformQuantity: PriceTransformQuantity, ): string { return JSON.stringify( PriceTransformQuantity$outboundSchema.parse(priceTransformQuantity), ); }