export declare class VideoAnalyticsService {
    /**
     * Hash IP address for privacy (SHA-256)
     */
    private hashIpAddress;
    /**
     * Hash user agent for privacy (SHA-256, truncate version numbers first)
     */
    private hashUserAgent;
    /**
     * Record a new video view
     */
    recordView(params: {
        videoId: number;
        userId?: string;
        ipAddress?: string;
        userAgent?: string;
        referer?: string;
    }): Promise<number>;
    /**
     * Record a video event (play, pause, seek, complete)
     */
    recordEvent(params: {
        videoId: number;
        viewId?: number;
        eventType: 'play' | 'pause' | 'seek' | 'complete';
        timestamp: number;
    }): Promise<void>;
    /**
     * Update watch time for a view (called periodically during playback)
     */
    updateWatchTime(viewId: number, watchTimeSeconds: number): Promise<void>;
    /**
     * Aggregate analytics for a video
     */
    aggregateVideoAnalytics(videoId: number): Promise<void>;
    /**
     * Get detailed analytics for a video
     */
    getVideoAnalytics(videoId: number, startDate?: Date, endDate?: Date): Promise<{
        overview: {
            totalViews: number;
            uniqueViewers: number;
            averageWatchTime: number;
            completionRate: number;
            totalWatchTime: number;
        };
        viewsOverTime: Array<{
            date: string;
            count: number;
        }>;
        topReferrers: Array<{
            referer: string;
            count: number;
        }>;
        registeredViewers: Array<{
            userId: string;
            userName: string | null;
            userEmail: string;
            watchTime: number;
            completed: boolean;
            viewedAt: Date;
        }>;
    }>;
    /**
     * Get top videos by a metric
     */
    getTopVideos(metric: 'views' | 'watchTime', limit?: number): Promise<Array<{
        id: number;
        title: string | null;
        value: number;
    }>>;
    /**
     * Reset analytics for a video
     */
    resetAnalytics(videoId: number): Promise<void>;
}
export declare const videoAnalyticsService: VideoAnalyticsService;
//# sourceMappingURL=video-analytics.service.d.ts.map