import { type MailboxRecord } from '../../runtime/bridge.js'; export interface TeamMailboxMessage { message_id: string; from_worker: string; to_worker: string; body: string; created_at: string; notified_at?: string; delivered_at?: string; } export interface TeamMailbox { worker: string; messages: TeamMailboxMessage[]; } interface MailboxDeps { teamName: string; cwd: string; withMailboxLock: (teamName: string, workerName: string, cwd: string, fn: () => Promise) => Promise; readMailbox: (teamName: string, workerName: string, cwd: string) => Promise; readLegacyMailbox?: (teamName: string, workerName: string, cwd: string) => Promise; writeMailbox: (teamName: string, mailbox: TeamMailbox, cwd: string) => Promise; appendTeamEvent: (teamName: string, event: { type: 'message_received'; worker: string; task_id?: string; message_id?: string | null; reason?: string; }, cwd: string) => Promise; readTeamConfig: (teamName: string, cwd: string) => Promise<{ created_at?: string; workers: Array<{ name: string; }>; } | null>; } export declare function normalizeBridgeMailboxMessage(record: MailboxRecord): TeamMailboxMessage; export declare function sendDirectMessage(fromWorker: string, toWorker: string, body: string, deps: MailboxDeps): Promise; export declare function broadcastMessage(fromWorker: string, body: string, deps: MailboxDeps): Promise; export declare function markMessageDelivered(workerName: string, messageId: string, deps: MailboxDeps): Promise; export declare function markMessageNotified(workerName: string, messageId: string, deps: MailboxDeps): Promise; export declare function listMailboxMessages(workerName: string, deps: MailboxDeps): Promise; export {}; //# sourceMappingURL=mailbox.d.ts.map