import { StreamableFile } from '@nestjs/common';
import { Response } from 'express';
import { AdminPrincipal } from '../common/auth/principal';
import { AdminFlagDto } from './dto/jobs.dto';
import { AdminApplicationsService } from './admin-applications.service';
declare const APPLICATION_STATUSES: readonly ["APPLIED", "INTERVIEW", "OFFER", "REJECTED", "WITHDRAWN"];
declare class AdminApplicationsQueryDto {
    q?: string;
    status?: string;
    jobId?: string;
    flagged?: string;
    materials?: string;
    from?: string;
    to?: string;
    sort?: string;
    limit?: string;
    offset?: string;
}
declare class AdminApplicationPatchDto {
    status: (typeof APPLICATION_STATUSES)[number];
    note?: string;
}
declare class AdminApplicationsBulkDto {
    ids: string[];
    status: (typeof APPLICATION_STATUSES)[number];
    note?: string;
}
export declare class AdminApplicationsController {
    private readonly applications;
    constructor(applications: AdminApplicationsService);
    list(query: AdminApplicationsQueryDto): Promise<{
        data: {
            items: {
                id: string;
                status: import(".prisma/client").$Enums.ApplicationStatus;
                note: string | null;
                employerNote: string | null;
                createdAt: string;
                updatedAt: string;
                ageHours: number;
                sharedSkills: string[];
                overlap: number | null;
                flagged: boolean;
                flagReason: string | null;
                hasResume: boolean;
                hasCoverLetter: boolean;
                hasOriginalResumeFile: boolean;
                hasOriginalCoverLetterFile: boolean;
                answerCount: number;
                eventCount: number;
                interviewCount: number;
                nextInterview: {
                    id: string;
                    stage: string;
                    mode: string;
                    startsAt: string;
                    status: string;
                } | null;
                job: {
                    id: string;
                    title: string;
                    city: string | null;
                    status: import(".prisma/client").$Enums.JobStatus;
                    companyName: string | null;
                };
                member: {
                    id: string;
                    email: string;
                    displayName: string;
                    occupation: string | null;
                    city: string | null;
                    hasPhoto: boolean;
                    photoUrl: string | null;
                    status: import(".prisma/client").$Enums.UserStatus;
                    isDemo: boolean;
                    skills: string[];
                };
            }[];
            total: number;
            limit: number;
            offset: number;
            stats: {
                total: number;
                byStatus: Record<import(".prisma/client").$Enums.ApplicationStatus, number>;
                flagged: number;
                withResume: number;
                withCoverLetter: number;
                recentApplied: number;
                upcomingInterviews: number;
                conversionPercent: number;
                offerRate: number;
                openPipeline: number;
            };
            facets: {
                jobs: {
                    id: string;
                    title: string;
                    companyName: string | null;
                    city: string | null;
                    count: number;
                }[];
            };
        };
        message: string;
    }>;
    pipeline(query: AdminApplicationsQueryDto): Promise<{
        data: {
            columns: Record<import(".prisma/client").$Enums.ApplicationStatus, {
                id: string;
                status: import(".prisma/client").$Enums.ApplicationStatus;
                note: string | null;
                employerNote: string | null;
                createdAt: string;
                updatedAt: string;
                ageHours: number;
                sharedSkills: string[];
                overlap: number | null;
                flagged: boolean;
                flagReason: string | null;
                hasResume: boolean;
                hasCoverLetter: boolean;
                hasOriginalResumeFile: boolean;
                hasOriginalCoverLetterFile: boolean;
                answerCount: number;
                eventCount: number;
                interviewCount: number;
                nextInterview: {
                    id: string;
                    stage: string;
                    mode: string;
                    startsAt: string;
                    status: string;
                } | null;
                job: {
                    id: string;
                    title: string;
                    city: string | null;
                    status: import(".prisma/client").$Enums.JobStatus;
                    companyName: string | null;
                };
                member: {
                    id: string;
                    email: string;
                    displayName: string;
                    occupation: string | null;
                    city: string | null;
                    hasPhoto: boolean;
                    photoUrl: string | null;
                    status: import(".prisma/client").$Enums.UserStatus;
                    isDemo: boolean;
                    skills: string[];
                };
            }[]>;
            stats: {
                total: number;
                byStatus: Record<import(".prisma/client").$Enums.ApplicationStatus, number>;
                flagged: number;
                withResume: number;
                withCoverLetter: number;
                recentApplied: number;
                upcomingInterviews: number;
                conversionPercent: number;
                offerRate: number;
                openPipeline: number;
            };
            facets: {
                jobs: {
                    id: string;
                    title: string;
                    companyName: string | null;
                    city: string | null;
                    count: number;
                }[];
            };
            total: number;
        };
        message: string;
    }>;
    timeline(limit?: string): Promise<{
        data: {
            items: {
                id: string;
                status: import(".prisma/client").$Enums.ApplicationStatus;
                note: string | null;
                createdAt: string;
                applicationId: string;
                member: {
                    id: string;
                    displayName: string;
                    email: string;
                };
                job: {
                    id: string;
                    title: string;
                    companyName: string | null;
                };
            }[];
        };
        message: string;
    }>;
    bulk(principal: AdminPrincipal, dto: AdminApplicationsBulkDto): Promise<{
        data: {
            requested: number;
            updated: number;
            status: import(".prisma/client").$Enums.ApplicationStatus;
        };
        message: string;
    }>;
    detail(id: string): Promise<{
        data: {
            id: string;
            status: import(".prisma/client").$Enums.ApplicationStatus;
            note: string | null;
            employerNote: string | null;
            createdAt: string;
            updatedAt: string;
            flagged: boolean;
            flagReason: string | null;
            flagDetails: string | null;
            job: {
                id: string;
                title: string;
                city: string | null;
                status: import(".prisma/client").$Enums.JobStatus;
                companyName: string | null;
            };
            member: {
                id: string;
                email: string;
                displayName: string;
                occupation: string | null;
                bio: string | null;
                city: string | null;
                hasPhoto: boolean;
                status: import(".prisma/client").$Enums.UserStatus;
                isDemo: boolean;
                skills: string[];
            };
            answers: {
                questionId: string;
                prompt: string;
                required: boolean;
                answer: string;
            }[];
            events: {
                status: import(".prisma/client").$Enums.ApplicationStatus;
                note: string | null;
                createdAt: string;
            }[];
            interviews: {
                id: string;
                stage: string;
                mode: string;
                locationNote: string | null;
                startsAt: string;
                endsAt: string | null;
                status: string;
                message: string | null;
            }[];
            experiences: {
                title: string;
                company: string;
                isCurrent: boolean;
            }[];
            education: {
                institution: string;
                qualification: string;
                field: string | null;
            }[];
            files: ({
                downloadUrl: string;
                kind: "resume";
                id: string;
                title: string;
                source: "linked" | "inferred";
                updatedAt: string;
                preview: string | null;
                fileName: string | null;
                mimeType: string;
                format: string;
            } | {
                downloadUrl: string;
                kind: "cover_letter";
                id: string;
                title: string;
                source: "note" | "linked" | "inferred";
                updatedAt: string;
                preview: string | null;
                fileName: string | null;
                mimeType: string;
                format: string;
            })[];
            resume: {
                sourceFile: {
                    id: string;
                    originalName: string | null;
                    mimeType: string;
                    sizeBytes: number;
                } | null;
                id: string;
                title: string;
                updatedAt: string;
                source: Exclude<"note" | "linked" | "inferred", "note">;
                version: {
                    version: number;
                    label: string;
                    sections: {
                        id: string;
                        kind: string;
                        heading: string;
                        body: string;
                    }[];
                } | null;
            } | null;
            coverLetter: {
                sourceFile: {
                    id: string;
                    originalName: string | null;
                    mimeType: string;
                    sizeBytes: number;
                } | null;
                id: string;
                title: string;
                updatedAt: string;
                source: "note" | "linked" | "inferred";
                body: string;
            } | null;
        };
        message: string;
    }>;
    downloadResume(id: string, res: Response): Promise<StreamableFile>;
    downloadCoverLetter(id: string, res: Response): Promise<StreamableFile>;
    update(principal: AdminPrincipal, id: string, dto: AdminApplicationPatchDto): Promise<{
        data: {
            id: string;
            status: import(".prisma/client").$Enums.ApplicationStatus;
            employerNote: string | null;
        };
        message: string;
    }>;
    flag(principal: AdminPrincipal, id: string, dto: AdminFlagDto): Promise<{
        data: {
            id: string;
            status: import(".prisma/client").$Enums.ApplicationStatus;
            note: string | null;
            employerNote: string | null;
            createdAt: string;
            updatedAt: string;
            flagged: boolean;
            flagReason: string | null;
            flagDetails: string | null;
            job: {
                id: string;
                title: string;
                city: string | null;
                status: import(".prisma/client").$Enums.JobStatus;
                companyName: string | null;
            };
            member: {
                id: string;
                email: string;
                displayName: string;
                occupation: string | null;
                bio: string | null;
                city: string | null;
                hasPhoto: boolean;
                status: import(".prisma/client").$Enums.UserStatus;
                isDemo: boolean;
                skills: string[];
            };
            answers: {
                questionId: string;
                prompt: string;
                required: boolean;
                answer: string;
            }[];
            events: {
                status: import(".prisma/client").$Enums.ApplicationStatus;
                note: string | null;
                createdAt: string;
            }[];
            interviews: {
                id: string;
                stage: string;
                mode: string;
                locationNote: string | null;
                startsAt: string;
                endsAt: string | null;
                status: string;
                message: string | null;
            }[];
            experiences: {
                title: string;
                company: string;
                isCurrent: boolean;
            }[];
            education: {
                institution: string;
                qualification: string;
                field: string | null;
            }[];
            files: ({
                downloadUrl: string;
                kind: "resume";
                id: string;
                title: string;
                source: "linked" | "inferred";
                updatedAt: string;
                preview: string | null;
                fileName: string | null;
                mimeType: string;
                format: string;
            } | {
                downloadUrl: string;
                kind: "cover_letter";
                id: string;
                title: string;
                source: "note" | "linked" | "inferred";
                updatedAt: string;
                preview: string | null;
                fileName: string | null;
                mimeType: string;
                format: string;
            })[];
            resume: {
                sourceFile: {
                    id: string;
                    originalName: string | null;
                    mimeType: string;
                    sizeBytes: number;
                } | null;
                id: string;
                title: string;
                updatedAt: string;
                source: Exclude<"note" | "linked" | "inferred", "note">;
                version: {
                    version: number;
                    label: string;
                    sections: {
                        id: string;
                        kind: string;
                        heading: string;
                        body: string;
                    }[];
                } | null;
            } | null;
            coverLetter: {
                sourceFile: {
                    id: string;
                    originalName: string | null;
                    mimeType: string;
                    sizeBytes: number;
                } | null;
                id: string;
                title: string;
                updatedAt: string;
                source: "note" | "linked" | "inferred";
                body: string;
            } | null;
        };
        message: string;
    }>;
}
export {};
