import { FilterAppointmentDto } from './dto/filter-appointment.dto';
import { UpdateAppointmentDto } from './dto/update-appointment.dto';
import { ModelService } from '../model/model.service';
import { Types } from 'mongoose';
import { Appointment } from '../model/schemas/appointment.schema';
import { GetStylistAppointmentsDto } from './dto/get-appointments.dto';
import { AppointmentGeneratedBy, AppointmentStatus } from '../common/enums';
import { AvailabilityService } from './appointmenthelper';
import { FirebaseService } from '../firebase/firebase.service';
import { SalonPaymentService } from '../salon-payment/salon-payment.service';
export declare class AppointmentService {
    private readonly modelservice;
    private readonly availabilityService;
    private readonly firebaseService;
    private readonly salonPaymentService;
    private readonly logger;
    constructor(modelservice: ModelService, availabilityService: AvailabilityService, firebaseService: FirebaseService, salonPaymentService: SalonPaymentService);
    findBySalon(salonId: string, filter: FilterAppointmentDto): Promise<any>;
    getAppointmentDetails(id: string): Promise<{
        _id: Types.ObjectId;
        salonId: Types.ObjectId;
        start: Date;
        end: Date;
        status: AppointmentStatus;
        appointmentFee: number;
        depositAmount: any;
        remainingAmount: any;
        generatedBy: AppointmentGeneratedBy;
        payment_type: string;
        payment_status: string;
        payment_provider: string;
        payment_intent_id: string;
        service: (import("mongoose").FlattenMaps<import("../model/schemas/service.schema").Service> & Required<{
            _id: Types.ObjectId;
        }> & {
            __v: number;
        }) | null;
        services: (import("mongoose").FlattenMaps<import("../model/schemas/service.schema").Service> & Required<{
            _id: Types.ObjectId;
        }> & {
            __v: number;
        })[];
        client: (import("mongoose").FlattenMaps<import("../model/schemas/client.schema").Client> & Required<{
            _id: Types.ObjectId;
        }> & {
            __v: number;
        }) | null;
        stylist: (import("mongoose").FlattenMaps<import("../model/schemas/stylist.schema").Stylist> & Required<{
            _id: Types.ObjectId;
        }> & {
            __v: number;
        }) | null;
        createdAt: any;
        updatedAt: any;
    }>;
    findBySalonWithFilters(salonId: string, filter: GetStylistAppointmentsDto): Promise<{
        page: number;
        limit: number;
        total: number;
        data: {
            _id: Types.ObjectId;
            start: Date;
            end: Date;
            status: AppointmentStatus;
            client: string | null;
        }[];
    }>;
    update(id: string, dto: UpdateAppointmentDto): Promise<import("mongoose").Document<unknown, {}, Appointment, {}, {}> & Appointment & {
        _id: Types.ObjectId;
    } & {
        __v: number;
    }>;
    delete(id: string): Promise<(import("mongoose").Document<unknown, {}, Appointment, {}, {}> & Appointment & {
        _id: Types.ObjectId;
    } & {
        __v: number;
    }) | null>;
    markAsNoshow(bookingId: string): Promise<{
        success: boolean;
        reason?: undefined;
    } | {
        success: boolean;
        reason: string;
    }>;
    modifyBooking(bookingId: string, salonId: string, updates: {
        date?: string;
        time?: string;
        delete?: boolean;
    }): Promise<{
        success: boolean;
        reason: string;
        availability: {
            stylistId: Types.ObjectId;
            name: string;
            days: {
                date: string;
                slots: {
                    start: string;
                    end: string;
                }[];
            }[];
        }[];
        stylistId?: undefined;
        appointmentId?: undefined;
        payment_type?: undefined;
        payment_status?: undefined;
        payment_provider?: undefined;
        payment_intent_id?: undefined;
        clientSecret?: undefined;
        publishableKey?: undefined;
        chargeAmount?: undefined;
        depositAmount?: undefined;
        remainingAmount?: undefined;
        totalAmount?: undefined;
    } | {
        success: boolean;
        stylistId: any;
        appointmentId: Types.ObjectId;
        payment_type: string;
        payment_status: string;
        payment_provider: string;
        payment_intent_id: string;
        clientSecret: string | null;
        publishableKey: string;
        chargeAmount: number;
        depositAmount: number;
        remainingAmount: number;
        totalAmount: number;
        reason?: undefined;
        availability?: undefined;
    } | {
        success: boolean;
        stylistId: any;
        appointmentId: Types.ObjectId;
        reason?: undefined;
        availability?: undefined;
        payment_type?: undefined;
        payment_status?: undefined;
        payment_provider?: undefined;
        payment_intent_id?: undefined;
        clientSecret?: undefined;
        publishableKey?: undefined;
        chargeAmount?: undefined;
        depositAmount?: undefined;
        remainingAmount?: undefined;
        totalAmount?: undefined;
    } | {
        success: boolean;
        reason: string;
        cancelled?: undefined;
    } | {
        success: boolean;
        cancelled: boolean;
        reason?: undefined;
    } | undefined>;
    bookAppointmenthelperPermissive({ salonId, serviceId, requestedStart, clientId, stylistId, offerId, generatedBy, }: {
        salonId: string;
        serviceId: string;
        requestedStart: {
            date: string;
            time: string;
        };
        clientId: string;
        stylistId?: string;
        offerId?: string;
        generatedBy?: AppointmentGeneratedBy;
    }): Promise<{
        success: boolean;
        reason: string;
        availability: never[];
        stylistId?: undefined;
        appointmentId?: undefined;
    } | {
        success: boolean;
        stylistId: string;
        appointmentId: Types.ObjectId;
        reason?: undefined;
        availability?: undefined;
    }>;
    bookAppointmenthelper({ salonId, serviceId, serviceIds, requestedStart, clientId, stylistId, offerId, generatedBy, clientGender, clientName, clientEmail, clientPhone, payment_type, }: {
        salonId: string;
        serviceId?: string;
        serviceIds?: string[];
        requestedStart: {
            date: string;
            time: string;
        };
        clientId?: string;
        stylistId?: string;
        offerId?: string;
        generatedBy?: AppointmentGeneratedBy;
        clientGender?: string;
        clientName?: string;
        clientEmail?: string;
        clientPhone?: string;
        payment_type?: string;
    }): Promise<{
        success: boolean;
        reason: string;
        availability: {
            stylistId: Types.ObjectId;
            name: string;
            days: {
                date: string;
                slots: {
                    start: string;
                    end: string;
                }[];
            }[];
        }[];
        stylistId?: undefined;
        appointmentId?: undefined;
        payment_type?: undefined;
        payment_status?: undefined;
        payment_provider?: undefined;
        payment_intent_id?: undefined;
        clientSecret?: undefined;
        publishableKey?: undefined;
        chargeAmount?: undefined;
        depositAmount?: undefined;
        remainingAmount?: undefined;
        totalAmount?: undefined;
    } | {
        success: boolean;
        stylistId: any;
        appointmentId: Types.ObjectId;
        payment_type: string;
        payment_status: string;
        payment_provider: string;
        payment_intent_id: string;
        clientSecret: string | null;
        publishableKey: string;
        chargeAmount: number;
        depositAmount: number;
        remainingAmount: number;
        totalAmount: number;
        reason?: undefined;
        availability?: undefined;
    } | {
        success: boolean;
        stylistId: any;
        appointmentId: Types.ObjectId;
        reason?: undefined;
        availability?: undefined;
        payment_type?: undefined;
        payment_status?: undefined;
        payment_provider?: undefined;
        payment_intent_id?: undefined;
        clientSecret?: undefined;
        publishableKey?: undefined;
        chargeAmount?: undefined;
        depositAmount?: undefined;
        remainingAmount?: undefined;
        totalAmount?: undefined;
    }>;
    rescheduleAppointmentLogic(oldId: string, bookingData: any): Promise<{
        message: string;
        success: boolean;
        stylistId: any;
        appointmentId: Types.ObjectId;
        payment_type: string;
        payment_status: string;
        payment_provider: string;
        payment_intent_id: string;
        clientSecret: string | null;
        publishableKey: string;
        chargeAmount: number;
        depositAmount: number;
        remainingAmount: number;
        totalAmount: number;
        reason?: undefined;
        availability?: undefined;
        error?: undefined;
    } | {
        message: string;
        success: boolean;
        stylistId: any;
        appointmentId: Types.ObjectId;
        reason?: undefined;
        availability?: undefined;
        payment_type?: undefined;
        payment_status?: undefined;
        payment_provider?: undefined;
        payment_intent_id?: undefined;
        clientSecret?: undefined;
        publishableKey?: undefined;
        chargeAmount?: undefined;
        depositAmount?: undefined;
        remainingAmount?: undefined;
        totalAmount?: undefined;
        error?: undefined;
    } | {
        success: boolean;
        reason: string;
        availability: {
            stylistId: Types.ObjectId;
            name: string;
            days: {
                date: string;
                slots: {
                    start: string;
                    end: string;
                }[];
            }[];
        }[];
        stylistId?: undefined;
        appointmentId?: undefined;
        payment_type?: undefined;
        payment_status?: undefined;
        payment_provider?: undefined;
        payment_intent_id?: undefined;
        clientSecret?: undefined;
        publishableKey?: undefined;
        chargeAmount?: undefined;
        depositAmount?: undefined;
        remainingAmount?: undefined;
        totalAmount?: undefined;
        message?: undefined;
        error?: undefined;
    } | {
        success: boolean;
        stylistId: any;
        appointmentId: Types.ObjectId;
        payment_type: string;
        payment_status: string;
        payment_provider: string;
        payment_intent_id: string;
        clientSecret: string | null;
        publishableKey: string;
        chargeAmount: number;
        depositAmount: number;
        remainingAmount: number;
        totalAmount: number;
        reason?: undefined;
        availability?: undefined;
        message?: undefined;
        error?: undefined;
    } | {
        success: boolean;
        stylistId: any;
        appointmentId: Types.ObjectId;
        reason?: undefined;
        availability?: undefined;
        payment_type?: undefined;
        payment_status?: undefined;
        payment_provider?: undefined;
        payment_intent_id?: undefined;
        clientSecret?: undefined;
        publishableKey?: undefined;
        chargeAmount?: undefined;
        depositAmount?: undefined;
        remainingAmount?: undefined;
        totalAmount?: undefined;
        message?: undefined;
        error?: undefined;
    } | {
        success: boolean;
        message: string;
        error: any;
    }>;
    getAvailableStylists(serviceId: string, requested: Date, timezone: string): Promise<{
        _id: string;
        hasFreeSlot: boolean;
        isRequestedTimeAvailable: boolean;
        freeIntervals: {
            start: string;
            end: string;
        }[];
    }[]>;
    private subtractInterval;
    getServiceAvailabilityForCall(salonId: string, serviceId: string, date?: Date | string, timezone?: string): Promise<string>;
    getDailyAvailableStylists(requested: Date, timezone: string, serviceId?: string): Promise<{
        _id: string;
        hasFreeSlot: boolean;
        isRequestedTimeAvailable: boolean;
        freeIntervals: {
            start: string;
            end: string;
        }[];
    }[]>;
    getCancelledAppointments(stylistId: string): Promise<(import("mongoose").FlattenMaps<{
        appointmentId: Types.ObjectId;
        salonId: Types.ObjectId;
        stylistId: Types.ObjectId;
        clientId: Types.ObjectId;
        cancelledAt: Date;
        cancelledBy: AppointmentGeneratedBy;
        client_name: string;
        client_phone: string;
        client_email: string;
        reason?: string | undefined;
    }> & {
        _id: Types.ObjectId;
    } & {
        __v: number;
    })[]>;
}
