import { Repository } from 'typeorm';
import { Payout } from '../payouts/payout.entity';
import { Application } from '../applications/application.entity';
import { Campaign } from '../campaigns/campaign.entity';
import { Contract } from '../contracts/contract.entity';
import { PaymentTransaction } from './payment-transaction.entity';
import { NotificationsService } from '../notifications/notifications.service';
import { TelegramService } from '../telegram/telegram.service';
import { PayoutAccount } from '../invitations/payout-account.entity';
import { User } from '../users/user.entity';
import { EmailService } from '../email/email.service';
export declare class PaymentService {
    private payoutsRepository;
    private applicationsRepository;
    private transactionsRepository;
    private campaignsRepository;
    private contractsRepository;
    private payoutAccountRepo;
    private userRepo;
    private notificationsService;
    private telegramService;
    private emailService;
    private flwPublicKey;
    private flwSecretKey;
    constructor(payoutsRepository: Repository<Payout>, applicationsRepository: Repository<Application>, transactionsRepository: Repository<PaymentTransaction>, campaignsRepository: Repository<Campaign>, contractsRepository: Repository<Contract>, payoutAccountRepo: Repository<PayoutAccount>, userRepo: Repository<User>, notificationsService: NotificationsService, telegramService: TelegramService, emailService: EmailService);
    private isProviderSuccessStatus;
    private resolveCampaignIdForPayment;
    private ensurePayoutRequestForTransaction;
    reconcileMissingPayoutRequests(): Promise<number>;
    initiatePayment(data: {
        amount: number;
        currency: string;
        email: string;
        name: string;
        campaignTitle: string;
        applicationId: string;
        redirectUrl: string;
        userId?: string;
        campaignId?: string;
        payeeId?: string;
        paymentMethod?: string;
    }): Promise<{
        txRef: string;
        status: string;
        paymentLink: any;
        orderId: any;
        paymentMethod: string;
    } | {
        txRef: string;
        status: string;
        telebirrRawRequest: string;
        paymentLink: any;
        paymentMethod: string;
    } | {
        txRef: string;
        status: string;
        paymentLink: any;
        data: {
            tx_ref: string;
            amount: string;
            currency: string;
            redirect_url: string;
            customer: {
                email: string;
                name: string;
            };
            customizations: {
                title: string;
                description: string;
                logo: string;
            };
            meta: {
                applicationId: string;
            };
        };
    } | {
        txRef: string;
        status: string;
        data: {
            tx_ref: string;
            amount: number;
            currency: string;
            redirect_url: string;
            customer: {
                email: string;
                name: string;
            };
            customizations: {
                title: string;
                description: string;
            };
        };
        paymentLink?: undefined;
    }>;
    verifyPayment(transactionId?: string, txRef?: string): Promise<any>;
    confirmClientPayment(data: {
        userId: string;
        txRef: string;
        transactionId?: string;
        status?: string;
    }): Promise<{
        ok: boolean;
        tx_ref: string;
        status: string;
    }>;
    handleWebhook(payload: any): Promise<{
        status: string;
        tx_ref?: undefined;
    } | {
        status: string;
        tx_ref: any;
    }>;
    triggerFlutterwaveTransfer(userId: string, amount: number, narration: string): Promise<{
        success: boolean;
        reason: string;
        data?: undefined;
    } | {
        success: boolean;
        data: {
            status: string;
        };
        reason?: undefined;
    }>;
    createPayoutRecord(data: {
        brandId: string;
        creatorId: string;
        campaignId: string;
        amount: number;
        txRef: string;
    }): Promise<Payout>;
    getBrandCampaignEscrow(brandId: string, campaignId: string): Promise<{
        deposited: number;
        committed: number;
        available: number;
    }>;
    getUserTransactions(userId: string): Promise<PaymentTransaction[]>;
    getTransactionsForUser(userId: string, role: string): Promise<PaymentTransaction[]>;
    getTransactionByRef(txRef: string, userId?: string, role?: string): Promise<PaymentTransaction>;
    getAllTransactions(): Promise<PaymentTransaction[]>;
    initiatePaypalPayment(data: any, txRef: string, transaction: PaymentTransaction): Promise<{
        txRef: string;
        status: string;
        paymentLink: any;
        orderId: any;
        paymentMethod: string;
    }>;
    capturePaypalOrder(orderId: string): Promise<any>;
    private telebirrConfig;
    private telebirrHttpsAgent;
    private getTelebirrTimestamp;
    private getTelebirrNonce;
    private signTelebirrPayload;
    private getTelebirrFabricToken;
    initiateTelebirrPayment(data: any, txRef: string, transaction: PaymentTransaction): Promise<{
        txRef: string;
        status: string;
        telebirrRawRequest: string;
        paymentLink: any;
        paymentMethod: string;
    }>;
    verifyTelebirrPayment(outTradeNo: string): Promise<{
        tx_ref: string;
        status: string;
        amount: number;
        currency: string;
        payment_method: string;
    }>;
    handleTelebirrWebhook(payload: string): Promise<{
        status: string;
        tx_ref?: undefined;
    } | {
        status: string;
        tx_ref: any;
    }>;
    triggerTelebirrTransfer(userId: string, amount: number, narration: string): Promise<{
        success: boolean;
        reason: string;
        data?: undefined;
    } | {
        success: boolean;
        data: {
            status: string;
        };
        reason?: undefined;
    }>;
}
