/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
import * as z from "zod";
import { safeParse } from "../../lib/schemas.js";
import { StreamPosition$inboundSchema, StreamPosition$outboundSchema, } from "./streamposition.js";
/** @internal */
export const AppendAck$inboundSchema = z.object({
    end: StreamPosition$inboundSchema,
    start: StreamPosition$inboundSchema,
    tail: StreamPosition$inboundSchema,
});
/** @internal */
export const AppendAck$outboundSchema = z.object({
    end: StreamPosition$outboundSchema,
    start: StreamPosition$outboundSchema,
    tail: StreamPosition$outboundSchema,
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
export var AppendAck$;
(function (AppendAck$) {
    /** @deprecated use `AppendAck$inboundSchema` instead. */
    AppendAck$.inboundSchema = AppendAck$inboundSchema;
    /** @deprecated use `AppendAck$outboundSchema` instead. */
    AppendAck$.outboundSchema = AppendAck$outboundSchema;
})(AppendAck$ || (AppendAck$ = {}));
export function appendAckToJSON(appendAck) {
    return JSON.stringify(AppendAck$outboundSchema.parse(appendAck));
}
export function appendAckFromJSON(jsonString) {
    return safeParse(jsonString, (x) => AppendAck$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'AppendAck' from JSON`);
}
//# sourceMappingURL=appendack.js.map