AWS S3 object listing

0 votes

I am using AWS-SDK using node.js. I want to list images in a specified folder e.g.This is the directory that i want to fetch

There is a list Object function in AWS-SDK but it is listing all the nested files also.

Here is the code :

var AWS = require('aws-sdk');
AWS.config.update({accessKeyId: 'mykey', secretAccessKey: 'mysecret', region: 'myregion'});
var s3 = new AWS.S3();

var params = { 
  Bucket: 'mystore.in',
  Delimiter: '',
  Prefix: 's/5469b2f5b4292d22522e84e0/ms.files' 
}

s3.listObjects(params, function (err, data) {
  if(err)throw err;
  console.log(data);
});


Is it possible to list all files and folders in this location but not folder (images) content? 

Apr 23, 2022 in Others by Kichu
• 19,050 points
923 views

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.

Related Questions In Others

0 votes
1 answer

What does it mean when owner is None on an AWS S3 object?

S3 Object Ownership is an Amazon S3 ...READ MORE

answered Mar 15, 2022 in Others by gaurav
• 23,260 points
1,152 views
0 votes
1 answer

Get last modified object from S3 using AWS CLI

With aws s3 ls $BUCKET —recursive, you ...READ MORE

answered Mar 24, 2022 in Others by gaurav
• 23,260 points
4,201 views
0 votes
0 answers
+1 vote
0 answers
0 votes
1 answer

How to add S3 BucketPolicy with AWS CDK?

In AWS CDK, there are two ways ...READ MORE

answered Mar 9, 2022 in Others by gaurav
• 23,260 points
2,718 views
0 votes
0 answers

How to add S3 BucketPolicy with AWS CDK?

I wanna translate this CloudFormation piece into ...READ MORE

Mar 11, 2022 in Others by Edureka
• 13,670 points
900 views
0 votes
1 answer

AWS S3 uploading hidden files by default

versioning is enabled in your bucket. docs.aws.amazon.com/AmazonS3/latest/user-guide/….... the ...READ MORE

answered Oct 4, 2018 in AWS by Priyaj
• 58,090 points
5,436 views
–1 vote
1 answer

How to decrypt the encrypted S3 file using aws-encryption-cli --decrypt

Use command : aws s3 presign s3://mybucket/abc_count.png you get ...READ MORE

answered Oct 22, 2018 in AWS by Priyaj
• 58,090 points
4,857 views
0 votes
1 answer

Import my AWS credentials using python script

Using AWS Cli  Configure your IAM user then ...READ MORE

answered Nov 16, 2018 in AWS by Jino
• 5,810 points
2,584 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP