modern-aws-tools
Version:
modern aws tools
29 lines (25 loc) • 620 B
text/typescript
interface S3UploadOptions {
credential: {
accessKeyId: string;
expiration: string;
secretAccessKey: string;
sessionToken: string;
};
region: string;
bucket: string;
host: string;
prefix?: string;
file: any;
key: string;
finalKey?: string;
}
/**
* 上传单个文件到s3
* @param req S3UploadOptions
* @returns
*/
declare const s3Upload: (req: S3UploadOptions) => Promise<unknown>;
declare const modernAWSTools: {
s3Upload: (req: S3UploadOptions) => Promise<unknown>;
};
export { type S3UploadOptions, modernAWSTools as default, s3Upload };