1.2.27 • Published 10 months ago
@astram/node-helper v1.2.27
Astram Node Helper
All Common Helper Functions will be used using this library
Installation
Install node-helper using npm
$ cd <working_directory>
$ npm i @astram/node-helperHelper Modules
S3 Module
This module is used to get all tasks related to S3 that includes following functionality
- Upload Files
- uploadToS3
- Directly Upload File from local system/server to S3
- uploadFromBuffer
- Upload data/content to a file onto S3
- uploadFromStream
- Upload using stream
- uploadToS3
- Get File
- getAllFiles
- Get all files of a folder
- getFileLink
- Get File as URL from S3 which is signed and will expires by default it is 5mins
- downloadFromS3
- Download File from S3 to local system or get content of file
- getAllFiles
- Check File Existance
- isFileExist
- Check whether a file exists corresponding to a bucket or not
- isFileExist
- Delete File
- deleteFile
- Delete file from S3
- deleteFile
Code Example
const { s3 } = require(`@astram/node-helper`);
const bucket = `astram-bucket`;
// check if file exists
const filePath = `test/test.pdf`;
const isFile = await s3.isFileExist(bucket, filePath);
// Get File Link
const filePath = `test/test.pdf`;
const isFile = await s3.getFileLink(bucket, filePath);
...1.2.18
10 months ago
1.2.19
10 months ago
1.2.20
10 months ago
1.2.23
10 months ago
1.2.24
10 months ago
1.2.21
10 months ago
1.2.22
10 months ago
1.2.27
10 months ago
1.2.25
10 months ago
1.2.26
10 months ago
1.2.13
1 year ago
1.2.16
11 months ago
1.2.17
10 months ago
1.2.14
11 months ago
1.2.15
11 months ago
1.2.8
2 years ago
1.2.7
2 years ago
1.2.6
2 years ago
1.2.5
2 years ago
1.2.4
2 years ago
1.2.3
2 years ago
1.2.2
2 years ago
1.2.1
2 years ago
1.2.9
2 years ago
1.2.10
1 year ago
1.2.11
1 year ago
1.2.0
2 years ago
1.1.9
2 years ago
1.1.8
2 years ago
1.1.7
2 years ago
1.1.6
2 years ago
1.1.5
2 years ago
1.1.4
2 years ago
1.1.3
2 years ago
1.1.2
2 years ago
1.1.1
2 years ago
1.1.0
2 years ago
1.0.1
2 years ago
1.0.0
2 years ago