import { z } from 'zod'; export type CollaborationMessage = WorkflowOpenedMessage | WorkflowClosedMessage | WriteAccessRequestedMessage | WriteAccessReleaseRequestedMessage | WriteAccessHeartbeatMessage | AgentOpenedMessage | AgentClosedMessage | AgentWriteAccessRequestedMessage | AgentWriteAccessReleaseRequestedMessage | AgentWriteAccessHeartbeatMessage; export declare const workflowOpenedMessageSchema: z.ZodObject<{ type: z.ZodLiteral<"workflowOpened">; workflowId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "workflowOpened"; workflowId: string; }, { type: "workflowOpened"; workflowId: string; }>; export declare const workflowClosedMessageSchema: z.ZodObject<{ type: z.ZodLiteral<"workflowClosed">; workflowId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "workflowClosed"; workflowId: string; }, { type: "workflowClosed"; workflowId: string; }>; export declare const writeAccessRequestedMessageSchema: z.ZodObject<{ type: z.ZodLiteral<"writeAccessRequested">; workflowId: z.ZodString; force: z.ZodOptional; }, "strict", z.ZodTypeAny, { type: "writeAccessRequested"; workflowId: string; force?: boolean | undefined; }, { type: "writeAccessRequested"; workflowId: string; force?: boolean | undefined; }>; export declare const writeAccessReleaseRequestedMessageSchema: z.ZodObject<{ type: z.ZodLiteral<"writeAccessReleaseRequested">; workflowId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "writeAccessReleaseRequested"; workflowId: string; }, { type: "writeAccessReleaseRequested"; workflowId: string; }>; export declare const writeAccessHeartbeatMessageSchema: z.ZodObject<{ type: z.ZodLiteral<"writeAccessHeartbeat">; workflowId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "writeAccessHeartbeat"; workflowId: string; }, { type: "writeAccessHeartbeat"; workflowId: string; }>; export declare const agentOpenedMessageSchema: z.ZodObject<{ type: z.ZodLiteral<"agentOpened">; agentId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "agentOpened"; agentId: string; }, { type: "agentOpened"; agentId: string; }>; export declare const agentClosedMessageSchema: z.ZodObject<{ type: z.ZodLiteral<"agentClosed">; agentId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "agentClosed"; agentId: string; }, { type: "agentClosed"; agentId: string; }>; export declare const agentWriteAccessRequestedMessageSchema: z.ZodObject<{ type: z.ZodLiteral<"agentWriteAccessRequested">; agentId: z.ZodString; force: z.ZodOptional; }, "strict", z.ZodTypeAny, { type: "agentWriteAccessRequested"; agentId: string; force?: boolean | undefined; }, { type: "agentWriteAccessRequested"; agentId: string; force?: boolean | undefined; }>; export declare const agentWriteAccessReleaseRequestedMessageSchema: z.ZodObject<{ type: z.ZodLiteral<"agentWriteAccessReleaseRequested">; agentId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "agentWriteAccessReleaseRequested"; agentId: string; }, { type: "agentWriteAccessReleaseRequested"; agentId: string; }>; export declare const agentWriteAccessHeartbeatMessageSchema: z.ZodObject<{ type: z.ZodLiteral<"agentWriteAccessHeartbeat">; agentId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "agentWriteAccessHeartbeat"; agentId: string; }, { type: "agentWriteAccessHeartbeat"; agentId: string; }>; export declare const workflowMessageSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{ type: z.ZodLiteral<"workflowOpened">; workflowId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "workflowOpened"; workflowId: string; }, { type: "workflowOpened"; workflowId: string; }>, z.ZodObject<{ type: z.ZodLiteral<"workflowClosed">; workflowId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "workflowClosed"; workflowId: string; }, { type: "workflowClosed"; workflowId: string; }>, z.ZodObject<{ type: z.ZodLiteral<"writeAccessRequested">; workflowId: z.ZodString; force: z.ZodOptional; }, "strict", z.ZodTypeAny, { type: "writeAccessRequested"; workflowId: string; force?: boolean | undefined; }, { type: "writeAccessRequested"; workflowId: string; force?: boolean | undefined; }>, z.ZodObject<{ type: z.ZodLiteral<"writeAccessReleaseRequested">; workflowId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "writeAccessReleaseRequested"; workflowId: string; }, { type: "writeAccessReleaseRequested"; workflowId: string; }>, z.ZodObject<{ type: z.ZodLiteral<"writeAccessHeartbeat">; workflowId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "writeAccessHeartbeat"; workflowId: string; }, { type: "writeAccessHeartbeat"; workflowId: string; }>, z.ZodObject<{ type: z.ZodLiteral<"agentOpened">; agentId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "agentOpened"; agentId: string; }, { type: "agentOpened"; agentId: string; }>, z.ZodObject<{ type: z.ZodLiteral<"agentClosed">; agentId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "agentClosed"; agentId: string; }, { type: "agentClosed"; agentId: string; }>, z.ZodObject<{ type: z.ZodLiteral<"agentWriteAccessRequested">; agentId: z.ZodString; force: z.ZodOptional; }, "strict", z.ZodTypeAny, { type: "agentWriteAccessRequested"; agentId: string; force?: boolean | undefined; }, { type: "agentWriteAccessRequested"; agentId: string; force?: boolean | undefined; }>, z.ZodObject<{ type: z.ZodLiteral<"agentWriteAccessReleaseRequested">; agentId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "agentWriteAccessReleaseRequested"; agentId: string; }, { type: "agentWriteAccessReleaseRequested"; agentId: string; }>, z.ZodObject<{ type: z.ZodLiteral<"agentWriteAccessHeartbeat">; agentId: z.ZodString; }, "strict", z.ZodTypeAny, { type: "agentWriteAccessHeartbeat"; agentId: string; }, { type: "agentWriteAccessHeartbeat"; agentId: string; }>]>; export type WorkflowOpenedMessage = z.infer; export type WorkflowClosedMessage = z.infer; export type WriteAccessRequestedMessage = z.infer; export type WriteAccessReleaseRequestedMessage = z.infer; export type WriteAccessHeartbeatMessage = z.infer; export type AgentOpenedMessage = z.infer; export type AgentClosedMessage = z.infer; export type AgentWriteAccessRequestedMessage = z.infer; export type AgentWriteAccessReleaseRequestedMessage = z.infer; export type AgentWriteAccessHeartbeatMessage = z.infer; export type WorkflowMessage = z.infer; export declare const parseWorkflowMessage: (msg: unknown) => Promise<{ type: "workflowOpened"; workflowId: string; } | { type: "workflowClosed"; workflowId: string; } | { type: "writeAccessRequested"; workflowId: string; force?: boolean | undefined; } | { type: "writeAccessReleaseRequested"; workflowId: string; } | { type: "writeAccessHeartbeat"; workflowId: string; } | { type: "agentOpened"; agentId: string; } | { type: "agentClosed"; agentId: string; } | { type: "agentWriteAccessRequested"; agentId: string; force?: boolean | undefined; } | { type: "agentWriteAccessReleaseRequested"; agentId: string; } | { type: "agentWriteAccessHeartbeat"; agentId: string; }>;