(function (global, factory) {
  if (typeof define === "function" && define.amd) {
    define(["exports", "rxjs", "rxjs/operators"], factory);
  } else if (typeof exports !== "undefined") {
    factory(exports, require("rxjs"), require("rxjs/operators"));
  } else {
    var mod = {
      exports: {}
    };
    factory(mod.exports, global.rxjs, global.operators);
    global.createMultipartUpload = mod.exports;
  }
})(typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : this, function (_exports, _rxjs, _operators) {
  "use strict";

  Object.defineProperty(_exports, "__esModule", {
    value: true
  });
  _exports.default = void 0;

  const createMultipartUpload = function createMultipartUpload({
    s3Bucket,
    s3Key,
    contentType,
    s3
  }) {
    const uploadOpts = {
      Key: s3Key,
      Bucket: s3Bucket,
      ContentType: contentType,
      ACL: 'private'
    };
    const response$ = (0, _rxjs.from)(s3.createMultipartUpload(uploadOpts).promise());
    const uploadId$ = response$.pipe((0, _operators.map)(response => response.UploadId));
    return uploadId$;
  };

  var _default = createMultipartUpload;
  _exports.default = _default;
});
//# sourceMappingURL=createMultipartUpload.js.map