///
import { S3ClientConfig } from "@aws-sdk/client-s3";
export * from "./get-aws-configurations";
export type AWSConnectionOptions = {
endpointUrl: string;
region?: string;
accessKeyId: string;
secretAccessKey: string;
bucketName: string;
providerName: string;
/**
* If you're using cloudfront, then you can specify the cloudfront URL here
* Just add the cloudfront URL and it will be used instead of the bucket URL
*/
cloudfront?: string;
} & Partial;
export type AWSConfigurations = {
parseFileName?: (options: {
fileName: string;
hash: string;
}) => string;
connectionOptions: AWSConnectionOptions | (() => Promise);
};
export type AWSUploadOptions = {
filePath?: string;
fileBuffer?: Buffer;
fileName: string;
hash: string;
mimeType: string;
isCachedFile?: boolean;
} & AWSConfigurations;
export declare function createAWSClient(connectionOptions: AWSConfigurations["connectionOptions"]): Promise<{
client: any;
bucketName: any;
providerName: any;
endpointUrl: any;
region: any;
}>;
export declare function uploadToAWS({ filePath, fileBuffer, fileName, hash, mimeType, isCachedFile, parseFileName, connectionOptions, }: AWSUploadOptions): Promise<{
path: any;
name: any;
bucket: any;
region: any;
fileName: string;
url: string;
}>;
export declare function deleteFromAWS({ fileName, connectionOptions, }: {
fileName: string;
connectionOptions: AWSConfigurations["connectionOptions"];
}): Promise;
export declare function downloadFromAWS({ fileName, connectionOptions, }: {
fileName: string;
connectionOptions: AWSConfigurations["connectionOptions"];
}): Promise;
export declare function streamFromAWS({ fileName, connectionOptions, start, end, }: {
fileName: string;
connectionOptions: AWSConfigurations["connectionOptions"];
start: number;
end: number;
}): Promise;
//# sourceMappingURL=index.d.ts.map