export interface NotificationPreferences { channels: ChannelPreferences; categories: CategoryPreferences; schedule: SchedulePreferences; delivery: DeliveryPreferences; } export interface ChannelPreferences { toast: ChannelPreference; bell: ChannelPreference; push: ChannelPreference; email: ChannelPreference; } export interface ChannelPreference { enabled: boolean; types?: NotificationTypePreference[]; sound?: boolean; vibrate?: boolean; priority?: 'all' | 'high' | 'none'; } export interface NotificationTypePreference { type: string; enabled: boolean; channels?: string[]; } export interface CategoryPreferences { [category: string]: { enabled: boolean; channels: string[]; priority?: 'high' | 'normal' | 'low'; }; } export interface SchedulePreferences { timezone?: string; quietHours?: { enabled: boolean; start: string; end: string; allowUrgent?: boolean; }; workingHours?: { enabled: boolean; days: number[]; start: string; end: string; }; } export interface DeliveryPreferences { batching?: { enabled: boolean; window: number; // minutes maxSize: number; }; frequency?: { maxPerHour?: number; maxPerDay?: number; }; grouping?: { enabled: boolean; by: 'sender' | 'type' | 'category'; }; } export interface PreferenceUpdate { path: string; value: any; userId?: string; } export interface PreferenceTemplate { id: string; name: string; description?: string; preferences: NotificationPreferences; isDefault?: boolean; }