/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. * @generated-id: 329f0d051bdb */ import * as z from "zod/v4"; import { TextChunk, TextChunk$Outbound, TextChunk$outboundSchema, } from "./textchunk.js"; import { ThinkChunk, ThinkChunk$Outbound, ThinkChunk$outboundSchema, } from "./thinkchunk.js"; export type SystemMessageContentChunks = | (TextChunk & { type: "text" }) | (ThinkChunk & { type: "thinking" }); /** @internal */ export type SystemMessageContentChunks$Outbound = | (TextChunk$Outbound & { type: "text" }) | (ThinkChunk$Outbound & { type: "thinking" }); /** @internal */ export const SystemMessageContentChunks$outboundSchema: z.ZodType< SystemMessageContentChunks$Outbound, SystemMessageContentChunks > = z.union([ TextChunk$outboundSchema.and(z.object({ type: z.literal("text") })), ThinkChunk$outboundSchema.and(z.object({ type: z.literal("thinking") })), ]); export function systemMessageContentChunksToJSON( systemMessageContentChunks: SystemMessageContentChunks, ): string { return JSON.stringify( SystemMessageContentChunks$outboundSchema.parse(systemMessageContentChunks), ); }