import { AssetFile } from "../database";
import { BulkIdResponseDto } from "../dtos/asset-ids.response.dto";
import { AuthDto } from "../dtos/auth.dto";
import { AssetFileType, AssetType, AssetVisibility, Permission } from "../enum";
import { AuthRequest } from "../middleware/auth.guard";
import { AccessRepository } from "../repositories/access.repository";
import { AssetRepository } from "../repositories/asset.repository";
import { EventRepository } from "../repositories/event.repository";
import { PartnerRepository } from "../repositories/partner.repository";
import { IBulkAsset, ImmichFile, UploadFile, UploadRequest } from "../types";
export declare const getAssetFile: (files: AssetFile[], type: AssetFileType, { isEdited }: {
    isEdited: boolean;
}) => AssetFile | undefined;
export declare const getAssetFiles: (files: AssetFile[]) => {
    fullsizeFile: AssetFile | undefined;
    previewFile: AssetFile | undefined;
    thumbnailFile: AssetFile | undefined;
    sidecarFile: AssetFile | undefined;
    editedFullsizeFile: AssetFile | undefined;
    editedPreviewFile: AssetFile | undefined;
    editedThumbnailFile: AssetFile | undefined;
    encodedVideoFile: AssetFile | undefined;
};
export declare const addAssets: (auth: AuthDto, repositories: {
    access: AccessRepository;
    bulk: IBulkAsset;
}, dto: {
    parentId: string;
    assetIds: string[];
}) => Promise<BulkIdResponseDto[]>;
export declare const removeAssets: (auth: AuthDto, repositories: {
    access: AccessRepository;
    bulk: IBulkAsset;
}, dto: {
    parentId: string;
    assetIds: string[];
    canAlwaysRemove: Permission;
}) => Promise<BulkIdResponseDto[]>;
export type PartnerIdOptions = {
    userId: string;
    repository: PartnerRepository;
    timelineEnabled?: boolean;
};
export declare const getMyPartnerIds: ({ userId, repository, timelineEnabled }: PartnerIdOptions) => Promise<string[]>;
export type AssetHookRepositories = {
    asset: AssetRepository;
    event: EventRepository;
};
export declare const onBeforeLink: ({ asset: assetRepository, event: eventRepository }: AssetHookRepositories, { userId, livePhotoVideoId }: {
    userId: string;
    livePhotoVideoId: string;
}) => Promise<void>;
export declare const onBeforeUnlink: ({ asset: assetRepository }: AssetHookRepositories, { livePhotoVideoId }: {
    livePhotoVideoId: string;
}) => Promise<{
    id: string;
    createdAt: Date;
    type: AssetType;
    duration: number | null;
    updatedAt: Date;
    deletedAt: Date | null;
    status: import("src/enum").AssetStatus;
    updateId: string;
    ownerId: string;
    width: number | null;
    height: number | null;
    originalPath: string;
    fileCreatedAt: Date;
    fileModifiedAt: Date;
    isFavorite: boolean;
    checksum: Buffer<ArrayBufferLike>;
    checksumAlgorithm: import("src/enum").ChecksumAlgorithm;
    livePhotoVideoId: string | null;
    originalFileName: string;
    thumbhash: Buffer<ArrayBufferLike> | null;
    isOffline: boolean;
    libraryId: string | null;
    isExternal: boolean;
    localDateTime: Date;
    stackId: string | null;
    duplicateId: string | null;
    visibility: AssetVisibility;
    isEdited: boolean;
    exifInfo?: import("kysely").ShallowDehydrateObject<{
        description: string;
        colorspace: string | null;
        assetId: string;
        state: string | null;
        updatedAt: Date;
        updateId: string;
        make: string | null;
        model: string | null;
        exifImageWidth: number | null;
        exifImageHeight: number | null;
        fileSizeInByte: number | null;
        orientation: string | null;
        dateTimeOriginal: Date | null;
        modifyDate: Date | null;
        lensModel: string | null;
        fNumber: number | null;
        focalLength: number | null;
        iso: number | null;
        latitude: number | null;
        longitude: number | null;
        city: string | null;
        country: string | null;
        fps: number | null;
        exposureTime: string | null;
        livePhotoCID: string | null;
        timeZone: string | null;
        projectionType: string | null;
        profileDescription: string | null;
        bitsPerSample: number | null;
        autoStackId: string | null;
        rating: number | null;
        tags: string[] | null;
        lockedProperties: ("description" | "dateTimeOriginal" | "latitude" | "longitude" | "timeZone" | "rating" | "tags")[] | null;
    }> | null | undefined;
    faces?: {
        id: string;
        assetId: string;
        updatedAt: string;
        deletedAt: string | null;
        updateId: string;
        personId: string | null;
        imageWidth: number;
        imageHeight: number;
        boundingBoxX1: number;
        boundingBoxY1: number;
        boundingBoxX2: number;
        boundingBoxY2: number;
        sourceType: import("src/enum").SourceType;
        isVisible: boolean;
    }[] | undefined;
    library?: {
        id: string;
        createdAt: string;
        name: string;
        updatedAt: string;
        deletedAt: string | null;
        updateId: string;
        ownerId: string;
        importPaths: string[];
        exclusionPatterns: string[];
        refreshedAt: string | null;
    } | null | undefined;
    owner?: {
        id: string;
        email: string;
        name: string;
        profileImagePath: string;
        avatarColor: import("kysely").ExtractColumnType<import("../schema").DB, "asset" | "user", "avatarColor">;
        profileChangedAt: string;
    } | null | undefined;
    smartSearch?: {
        assetId: string | null;
        embedding: string | null;
    } | null | undefined;
    stack?: import("src/database").Stack | null | undefined;
    files?: {
        id: string;
        type: AssetFileType;
        path: string;
        isEdited: boolean;
    }[] | undefined;
    tags?: {
        id: string;
        value: string;
        createdAt: string;
        updatedAt: string;
        color: string | null;
        parentId: string | null;
    }[] | undefined;
    edits?: ({
        action: import("../dtos/editing.dto").AssetEditAction.Crop;
        parameters: {
            x: number;
            y: number;
            width: number;
            height: number;
        };
    } | {
        action: import("../dtos/editing.dto").AssetEditAction.Rotate;
        parameters: {
            angle: number;
        };
    } | {
        action: import("../dtos/editing.dto").AssetEditAction.Mirror;
        parameters: {
            axis: "horizontal" | "vertical";
        };
    })[] | undefined;
} | null>;
export declare const onAfterUnlink: ({ asset: assetRepository, event: eventRepository }: AssetHookRepositories, { userId, livePhotoVideoId, visibility }: {
    userId: string;
    livePhotoVideoId: string;
    visibility: AssetVisibility;
}) => Promise<void>;
export declare function mapToUploadFile(file: ImmichFile): UploadFile;
export declare const asUploadRequest: (request: AuthRequest, file: Express.Multer.File) => UploadRequest;
export declare const getDimensions: ({ exifImageHeight: height, exifImageWidth: width, orientation, }: {
    exifImageHeight: number | null;
    exifImageWidth: number | null;
    orientation: string | null;
}) => {
    width: number;
    height: number;
};
export declare const isPanorama: (asset: {
    projectionType: string | null;
    originalFileName: string;
}) => boolean;
