@foxpage/foxpage-plugin-aws-s3
TypeScript icon, indicating that this package has built-in type declarations

0.4.2 • Public • Published

@foxpage/foxpage-plugin-aws-s3

The plugin for foxpage to get resource list

Usage

Import this plugin in foxpage-server env config file

export default {
  ...
    "plugins": ["@foxpage/foxpage-plugin-aws-s3"],
  ...
}

Methods

storageInit(options:S3ConfigType)

Init plugin config

storageObjectUpload( objectName: string,content: string | Uint8Array | Buffer)

Upload object to s3 with content

storageObjectUploadByPath( objectName: string,pathName: string,options?: { bucket?: string; prefix?: string })

Upload object to s3 with content path

storageObjectDownload(objectName: string, targetName?: string)

Download object from s3 by object name (path)

storageObjectDelete(objectName: string)

Remove s3 object

storageObjectContent(objectName: string)

Get s3 object content detail

storageObjectList(prefix: string, options?: StorageListOptions)

Get s3 the special path's object list

storageDownloadFolders( prefix: string,target: string = '',options?: { bucketName?: string })

Download objects from s3 by the special path

storageZipFolders(source: string, target: string)

Zip the download objects folder to a file

storageZipFileContent(target: string)

Get the local zip file content

Package Sidebar

Install

npm i @foxpage/foxpage-plugin-aws-s3

Weekly Downloads

1

Version

0.4.2

License

MIT

Unpacked Size

38.2 kB

Total Files

6

Last publish

Collaborators

  • shumingzhang
  • milkrong
  • songzinpm
  • yhdeng
  • xdrxdr
  • wangyilong