AWS s3 api error: specified bucket does not exist

The error is stating that bucket does not yet exist. By the looks of your code, the bucket name is not correct, which is why a file cannot be found. Either make the call createBucket() or create the bucket in your AWS console.

You might adding a file as well, instead of just making the API call. Check the AWS API docs for what to put where. Their docs are really good.

Here’s what I do:

    var stream = fs.createReadStream( 'path/to/file' );
    stream.on( 'error', function( error ) {
      seriesCb( error );
    } );
    //TODO: Other useful options here would be MD5 hash in the `ContentMD5` field,
    s3.putObject( {
      "Bucket": 'siv.io',
      "Key": 'name_of/new_file',
      "ContentType": "application/pdf", //might not apply to you
      "Body": stream
    }, function( s3err, s3results ) {
      if ( s3err ) return console.log('Bad stuff. ' + s3err.toString() );
      console.log( "Saved to S3. uri:" + s3uri);
    } );