aws-s3-operations
v1.1.0
Published
Communicating AWS s3 with node script
Downloads
5
Maintainers
Readme
AWS-S3-OPERATIONS
Download S3 object
Usage
Make sure to add the below environmental variables in .env file
- AWS_ACCESS_KEY,
- AWS_SECRET_ACCESS_KEY,
- AWS_REGION,
- AWS_BUCKET_NAME
const { downloadS3Object } = require('aws-s3-operations');
const {
AWS_ACCESS_KEY,
AWS_SECRET_ACCESS_KEY,
AWS_BUCKET_NAME,
AWS_REGION
} = process.env
downloadS3Object(
<Aws file link to download>,
AWS_ACCESS_KEY,
AWS_SECRET_ACCESS_KEY,
AWS_REGION,
AWS_BUCKET_NAME
)
The file will get download in the root directory with the filename in the given aws file link