import type { PayloadRequest } from '../types/index.js'; export type ClientUploadData = { clientUploadContext?: unknown; collectionSlug: string; filename: string; mimeType: string; size: number; }; /** * `req.context` key `unlinkClientUploadTempFile` reads to find a materializer-created temp file * once `req.file` is gone - plugin-cloud-storage's afterChange hook clears `req.file` after * uploading generated image sizes, before cleanup runs, so tracking it only on `req.file` * would leak the temp file. */ export declare const CLIENT_UPLOAD_TEMP_FILE_PATH_CONTEXT_KEY = "payloadClientUploadTempFilePath"; /** * `req.context` key that keeps the client upload context once `generateFileData` removes it from * a processed file, so a storage adapter can find the object the browser uploaded. Comes from a * verified receipt only when the collection sets `requiresClientUploadReceipt`. */ export declare const CLIENT_UPLOAD_CONTEXT_CONTEXT_KEY = "payloadClientUploadContext"; export declare function getFileFromClientUpload({ file, req, }: { file: ClientUploadData; req: PayloadRequest; }): Promise>; //# sourceMappingURL=getFileFromClientUpload.d.ts.map