import type { Notification, NotificationSeverity } from "./types.js"; export declare const notificationsStore: import("../db/store-registry.js").Store; export declare function ensureTable(): Promise; export interface InsertNotificationInput { owner: string; severity: NotificationSeverity; title: string; body?: string; metadata?: Record; deliveredChannels?: string[]; idempotencyKey?: string; } export declare function insertNotification(input: InsertNotificationInput): Promise; export declare function notificationIdForIdempotencyKey(owner: string, idempotencyKey: string): string; /** * Claims one idempotent notification side effect. Expired pending claims may * be retried. Event claims may also be replayed after their dispatch lease * expires because event subscribers deduplicate by the stable event ID; * channel deliveries remain non-replayable once dispatch starts. */ export declare function claimNotificationDelivery(notificationId: string, key: string, kind?: "channel" | "event"): Promise; export declare function markNotificationDeliveryDispatching(notificationId: string, key: string, claimToken: string, kind?: "channel" | "event"): Promise; export declare function completeNotificationDelivery(notificationId: string, key: string, claimToken: string, kind?: "channel" | "event"): Promise; export declare function markNotificationDeliveryUncertain(notificationId: string, key: string, claimToken: string, kind?: "channel" | "event"): Promise; export declare function releaseNotificationDelivery(notificationId: string, key: string, claimToken: string, kind?: "channel" | "event"): Promise; export declare function listCompletedNotificationChannels(notificationId: string): Promise; export declare function updateDeliveredChannels(id: string, channels: string[]): Promise; export declare function addDeliveredChannel(id: string, channel: string): Promise; export interface ListNotificationsOptions { unreadOnly?: boolean; limit?: number; before?: string; } export declare function hasNotificationWithMetadata(owner: string, expected: Record): Promise; export declare function listNotifications(owner: string, options?: ListNotificationsOptions): Promise; export declare function countUnread(owner: string): Promise; export declare function markNotificationRead(id: string, owner: string): Promise; export declare function markAllNotificationsRead(owner: string): Promise; export declare function deleteNotification(id: string, owner: string): Promise;