import { z } from 'zod'; /** Draft: no shared exports until server/client fixed-route support is integrated. */ export declare const PAGE_STREAM_MAX_FRAME_BYTES: number; export declare const PAGE_STREAM_MAX_BUFFER_BYTES: number; export declare const PAGE_STREAM_MAX_BUFFER_EVENTS = 2048; export declare const PAGE_STREAM_MAX_CURSOR_LENGTH = 2048; export declare const PAGE_STREAM_MAX_INPUT_BYTES = 8192; export declare const PAGE_STREAM_MAX_EVENT_ITEMS = 256; /** Opaque handle, never authorization. Server binds principal/team/release/page/binding/scope * and reauthorizes each connect/control. Neither URLs nor caller-authored scope are accepted. */ export declare const PageStreamDescriptorSchema: z.ZodObject<{ contract: z.ZodLiteral<"PageStreamDescriptor">; schemaVersion: z.ZodLiteral<1>; streamId: z.ZodString; expiresAt: z.ZodString; channel: z.ZodEnum<{ terminal: "terminal"; events: "events"; }>; cursor: z.ZodOptional; }, z.core.$strict>; export declare const PageStreamConnectSchema: z.ZodObject<{ cursor: z.ZodOptional; }, z.core.$strict>; /** First accepted frame must be snapshot. Exact duplicates compare cursor+payload; * conflicting duplicates/gaps reconnect using only last verified cursor. Transport rejects * oversized SSE frames before parsing and bounds retained bytes/events to constants above. */ export declare const PageStreamEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{ type: z.ZodLiteral<"snapshot">; payload: z.ZodObject<{ model: z.ZodRecord>>; }, z.core.$strict>; contract: z.ZodLiteral<"PageStreamEvent">; schemaVersion: z.ZodLiteral<1>; streamId: z.ZodString; sequence: z.ZodNumber; cursor: z.ZodString; }, z.core.$strict>, z.ZodObject<{ type: z.ZodLiteral<"delta">; payload: z.ZodObject<{ events: z.ZodArray>>>; }, z.core.$strict>; contract: z.ZodLiteral<"PageStreamEvent">; schemaVersion: z.ZodLiteral<1>; streamId: z.ZodString; sequence: z.ZodNumber; cursor: z.ZodString; }, z.core.$strict>, z.ZodObject<{ type: z.ZodLiteral<"end">; payload: z.ZodObject<{}, z.core.$strict>; contract: z.ZodLiteral<"PageStreamEvent">; schemaVersion: z.ZodLiteral<1>; streamId: z.ZodString; sequence: z.ZodNumber; cursor: z.ZodString; }, z.core.$strict>, z.ZodObject<{ type: z.ZodLiteral<"error">; payload: z.ZodObject<{ code: z.ZodString; retryable: z.ZodBoolean; }, z.core.$strict>; contract: z.ZodLiteral<"PageStreamEvent">; schemaVersion: z.ZodLiteral<1>; streamId: z.ZodString; sequence: z.ZodNumber; cursor: z.ZodString; }, z.core.$strict>], "type">; /** Reuse requestId on retries. Server deduplicates before PTY mutation; credentials never * travel in payload. stream.disconnect closes this descriptor lease, not the backing workload. */ export declare const PageStreamControlSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{ requestId: z.ZodString; port: z.ZodLiteral<"terminal.input">; payload: z.ZodObject<{ data: z.ZodString; }, z.core.$strict>; }, z.core.$strict>, z.ZodObject<{ requestId: z.ZodString; port: z.ZodLiteral<"terminal.resize">; payload: z.ZodObject<{ columns: z.ZodNumber; rows: z.ZodNumber; }, z.core.$strict>; }, z.core.$strict>, z.ZodObject<{ requestId: z.ZodString; port: z.ZodLiteral<"stream.disconnect">; payload: z.ZodObject<{}, z.core.$strict>; }, z.core.$strict>], "port">; export declare const pageStreamRoutes: { readonly events: (releaseSlotId: string, bindingId: string, streamId: string) => string; readonly terminal: (releaseSlotId: string, bindingId: string, streamId: string) => string; readonly control: (releaseSlotId: string, bindingId: string, streamId: string) => string; }; export declare const PageStreamControlResultSchema: z.ZodObject<{ requestId: z.ZodString; accepted: z.ZodLiteral; }, z.core.$strict>; export type PageStreamControlResult = z.infer; export type PageStreamDescriptor = z.infer; export type PageStreamEvent = z.infer; export type PageStreamControl = z.infer; //# sourceMappingURL=page-stream.d.ts.map