Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

371
Views
aws s3 Cannot read properties of undefined (reading 'Stream')

When trying to download a file from s3, through s3.getObject(params),createReadStream() method,

 var AWS = require('aws-sdk');
  var s3 = new AWS.S3({
    accessKeyId: 'xx',
    secretAccessKey: 'xx',
    region: 'x',x
    httpOptions: { timeout: 200000 }
  });
  var params = {
    Bucket: "xx",
    Key: 'xx'
  }
  var s3Stream = s3.getObject(params).createReadStream()
    .on('error', function (err) {          
      console.log('READSTREAM error');
      console.log(err);
    })
    .on('end', function () { });

it gives me the error:

TypeError: Cannot read properties of undefined (reading 'Stream')

use "@aws-sdk/client-s3": "^3.54.1", "aws-sdk": "^2.1095.0",

any idea what can happen?

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!