import { Kysely } from 'kysely';
import { DB } from "../../database/database.type";
import { Logger } from 'pino-nestjs';
import { RewardEngineService } from './reward-engine.service';
import { NotificationsService } from '../notifications/notifications.service';
type ReferralContext = {
    ip?: string | null;
    userAgent?: string | null;
    deviceId?: string | null;
};
type ShareLogContext = {
    ip?: string | null;
    userAgent?: string | null;
    deviceId?: string | null;
    shareIntentToken?: string | null;
    shareDurationMs?: number | null;
};
export declare class ReferralsService {
    private readonly db;
    private readonly logger;
    private readonly rewardEngine;
    private readonly notificationsService;
    constructor(db: Kysely<DB>, logger: Logger, rewardEngine: RewardEngineService, notificationsService: NotificationsService);
    private evaluateReferralRisk;
    private finalizeReferralStatus;
    private countValidReferrals;
    private applyReferralRewards;
    private processSingleReferral;
    processReferralValidationForUser(userId: string): Promise<void>;
    createPendingReferralFromSignup(input: {
        referrerUserId: string;
        refereeUserId: string;
        referralCodeUsed?: string | null;
        context?: ReferralContext;
    }): Promise<void>;
    private processPendingSharesForUser;
    private maybeGrantShareReward;
    logShare(user_id: string, platformRaw: string, context?: ShareLogContext): Promise<{
        status: boolean;
        statusCode: number;
        data: {
            message: string;
            shareStatus: "PENDING" | "VALID" | "FRAUD";
            validationReason: string;
            fraudScore: number;
            sharesThisMonth: number;
            rewardEarned: boolean;
        };
    }>;
    getReferralData(user_id: string): Promise<{
        status: boolean;
        statusCode: number;
        data: {
            referralCode: string;
            referralCount: number;
            pendingReferralCount: number;
            premiumUntil: string | null;
            rewards: any[];
            referrals: {
                id: any;
                name: any;
                emailMasked: string;
                joinedAt: string | null;
                isEmailVerified: boolean;
                emailVerifiedAt: string | null;
                status: any;
                validationReason: any;
            }[];
            sharesThisMonth: number;
            sharesLoggedThisMonth: number;
            shares: any[];
        };
    }>;
}
export {};
