import { PaginationService } from '@hed-hog/api-pagination';
import { PrismaService } from '@hed-hog/api-prisma';
import { OnModuleDestroy, OnModuleInit } from '@nestjs/common';
import type { Request, Response } from 'express';
import { CreateNotificationDto } from './dto/create-notification.dto';
import { UpdateProgressDto } from './dto/update-progress.dto';
export declare class NotificationService implements OnModuleInit, OnModuleDestroy {
    private readonly prisma;
    private readonly pagination;
    private readonly logger;
    private readonly notificationEvents;
    private readonly instanceId;
    private readonly channelName;
    private pgClient;
    constructor(prisma: PrismaService, pagination: PaginationService);
    onModuleInit(): Promise<void>;
    onModuleDestroy(): Promise<void>;
    list(userId: number, paginationParams: any): Promise<{
        total: any;
        lastPage: number;
        page: number;
        pageSize: number;
        prev: number;
        next: number;
        data: any[];
    }>;
    unreadCount(userId: number): Promise<{
        count: number;
    }>;
    markRead(userId: number, id: number): Promise<{
        type: import("@prisma/client").$Enums.notification_type_enum;
        progress: number | null;
        id: number;
        body: string | null;
        title: string;
        status: import("@prisma/client").$Enums.notification_status_enum;
        icon: string | null;
        user_id: number;
        created_at: Date;
        updated_at: Date;
        started_at: Date | null;
        finished_at: Date | null;
        action_url: string | null;
        action_type: import("@prisma/client").$Enums.notification_action_type_enum | null;
        action_data: import("@prisma/client/runtime/library").JsonValue | null;
        auto_remove: boolean;
    }>;
    markAllRead(userId: number): Promise<import("@prisma/client").Prisma.BatchPayload>;
    delete(userId: number, id: number): Promise<{
        type: import("@prisma/client").$Enums.notification_type_enum;
        progress: number | null;
        id: number;
        body: string | null;
        title: string;
        status: import("@prisma/client").$Enums.notification_status_enum;
        icon: string | null;
        user_id: number;
        created_at: Date;
        updated_at: Date;
        started_at: Date | null;
        finished_at: Date | null;
        action_url: string | null;
        action_type: import("@prisma/client").$Enums.notification_action_type_enum | null;
        action_data: import("@prisma/client/runtime/library").JsonValue | null;
        auto_remove: boolean;
    }>;
    deleteAll(userId: number): Promise<import("@prisma/client").Prisma.BatchPayload>;
    create(data: CreateNotificationDto): Promise<{
        type: import("@prisma/client").$Enums.notification_type_enum;
        progress: number | null;
        id: number;
        body: string | null;
        title: string;
        status: import("@prisma/client").$Enums.notification_status_enum;
        icon: string | null;
        user_id: number;
        created_at: Date;
        updated_at: Date;
        started_at: Date | null;
        finished_at: Date | null;
        action_url: string | null;
        action_type: import("@prisma/client").$Enums.notification_action_type_enum | null;
        action_data: import("@prisma/client/runtime/library").JsonValue | null;
        auto_remove: boolean;
    }>;
    updateProgress(userId: number, id: number, dto: UpdateProgressDto): Promise<{
        type: import("@prisma/client").$Enums.notification_type_enum;
        progress: number | null;
        id: number;
        body: string | null;
        title: string;
        status: import("@prisma/client").$Enums.notification_status_enum;
        icon: string | null;
        user_id: number;
        created_at: Date;
        updated_at: Date;
        started_at: Date | null;
        finished_at: Date | null;
        action_url: string | null;
        action_type: import("@prisma/client").$Enums.notification_action_type_enum | null;
        action_data: import("@prisma/client/runtime/library").JsonValue | null;
        auto_remove: boolean;
    }>;
    stream(userId: number, req: Request, res: Response): void;
    clearOldNotifications(retentionDays: number, batchLimit: number): Promise<number>;
    private assertOwnership;
    private isActiveAsyncNotification;
    private broadcastNotificationEvent;
    private getEventKey;
    private emitLocalNotificationEvent;
    private handleClusterNotification;
}
//# sourceMappingURL=notification.service.d.ts.map