/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */

import * as z from "zod/v4-mini";

export type FilePatch = {
  name?: string | null | undefined;
  version?: string | null | undefined;
};

/** @internal */
export type FilePatch$Outbound = {
  name?: string | null | undefined;
  version?: string | null | undefined;
};

/** @internal */
export const FilePatch$outboundSchema: z.ZodMiniType<
  FilePatch$Outbound,
  FilePatch
> = z.object({
  name: z.optional(z.nullable(z.string())),
  version: z.optional(z.nullable(z.string())),
});

export function filePatchToJSON(filePatch: FilePatch): string {
  return JSON.stringify(FilePatch$outboundSchema.parse(filePatch));
}
