files.com 1.0.243 → 1.0.245

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/_VERSION CHANGED
@@ -1 +1 @@
1
- 1.0.243
1
+ 1.0.245
@@ -67,7 +67,7 @@ await BundleNotification.create({
67
67
 
68
68
  ### Parameters
69
69
 
70
- * `user_id` (int64): Required - The id of the user to notify.
70
+ * `user_id` (int64): The id of the user to notify.
71
71
  * `notify_on_registration` (boolean): Triggers bundle notification when a registration action occurs for it.
72
72
  * `notify_on_upload` (boolean): Triggers bundle notification when a upload action occurs for it.
73
73
  * `bundle_id` (int64): Required - Bundle ID to notify on
@@ -89,6 +89,7 @@
89
89
  "next_billing_amount": 1.0,
90
90
  "next_billing_date": "Apr 20",
91
91
  "office_integration_available": true,
92
+ "office_integration_type": "example",
92
93
  "oncehub_link": "https://go.oncehub.com/files",
93
94
  "opt_out_global": true,
94
95
  "overage_notified_at": "2000-01-01T01:00:00Z",
@@ -233,6 +234,7 @@
233
234
  * `next_billing_amount` (double): Next billing amount
234
235
  * `next_billing_date` (string): Next billing date
235
236
  * `office_integration_available` (boolean): Allow users to use Office for the web?
237
+ * `office_integration_type` (string): Office integration application used to edit and view the MS Office documents
236
238
  * `oncehub_link` (string): Link to scheduling a meeting with our Sales team
237
239
  * `opt_out_global` (boolean): Use servers in the USA only?
238
240
  * `overage_notified_at` (date-time): Last time the site was notified about an overage
@@ -344,6 +346,7 @@ await Site.update({
344
346
  'folder_permissions_groups_only': true,
345
347
  'welcome_screen': "user_controlled",
346
348
  'office_integration_available': true,
349
+ 'office_integration_type': "example",
347
350
  'pin_all_remote_servers_to_site_region': true,
348
351
  'motd_text': "example",
349
352
  'motd_use_for_ftp': true,
@@ -473,6 +476,7 @@ await Site.update({
473
476
  * `folder_permissions_groups_only` (boolean): If true, permissions for this site must be bound to a group (not a user). Otherwise, permissions must be bound to a user.
474
477
  * `welcome_screen` (string): Does the welcome screen appear?
475
478
  * `office_integration_available` (boolean): Allow users to use Office for the web?
479
+ * `office_integration_type` (string): Office integration application used to edit and view the MS Office documents
476
480
  * `pin_all_remote_servers_to_site_region` (boolean): If true, we will ensure that all internal communications with any remote server are made through the primary region of the site. This setting overrides individual remote server settings.
477
481
  * `motd_text` (string): A message to show users when they connect via FTP or SFTP.
478
482
  * `motd_use_for_ftp` (boolean): Show message to users connecting via FTP
@@ -304,36 +304,30 @@ var BundleNotification = /*#__PURE__*/(0, _createClass2.default)(function Bundle
304
304
  case 0:
305
305
  params = _args5.length > 0 && _args5[0] !== undefined ? _args5[0] : {};
306
306
  options = _args5.length > 1 && _args5[1] !== undefined ? _args5[1] : {};
307
- if (params['user_id']) {
308
- _context5.next = 4;
309
- break;
310
- }
311
- throw new errors.MissingParameterError('Parameter missing: user_id');
312
- case 4:
313
307
  if (params['bundle_id']) {
314
- _context5.next = 6;
308
+ _context5.next = 4;
315
309
  break;
316
310
  }
317
311
  throw new errors.MissingParameterError('Parameter missing: bundle_id');
318
- case 6:
312
+ case 4:
319
313
  if (!(params['user_id'] && !(0, _utils.isInt)(params['user_id']))) {
320
- _context5.next = 8;
314
+ _context5.next = 6;
321
315
  break;
322
316
  }
323
317
  throw new errors.InvalidParameterError("Bad parameter: user_id must be of type Int, received ".concat((0, _utils.getType)(params['user_id'])));
324
- case 8:
318
+ case 6:
325
319
  if (!(params['bundle_id'] && !(0, _utils.isInt)(params['bundle_id']))) {
326
- _context5.next = 10;
320
+ _context5.next = 8;
327
321
  break;
328
322
  }
329
323
  throw new errors.InvalidParameterError("Bad parameter: bundle_id must be of type Int, received ".concat((0, _utils.getType)(params['bundle_id'])));
330
- case 10:
331
- _context5.next = 12;
324
+ case 8:
325
+ _context5.next = 10;
332
326
  return _Api.default.sendRequest("/bundle_notifications", 'POST', params, options);
333
- case 12:
327
+ case 10:
334
328
  response = _context5.sent;
335
329
  return _context5.abrupt("return", new BundleNotification(response === null || response === void 0 ? void 0 : response.data, options));
336
- case 14:
330
+ case 12:
337
331
  case "end":
338
332
  return _context5.stop();
339
333
  }
@@ -280,6 +280,9 @@ var Site = /*#__PURE__*/(0, _createClass2.default)(function Site() {
280
280
  (0, _defineProperty2.default)(this, "getOfficeIntegrationAvailable", function () {
281
281
  return _this.attributes.office_integration_available;
282
282
  });
283
+ (0, _defineProperty2.default)(this, "getOfficeIntegrationType", function () {
284
+ return _this.attributes.office_integration_type;
285
+ });
283
286
  (0, _defineProperty2.default)(this, "getOncehubLink", function () {
284
287
  return _this.attributes.oncehub_link;
285
288
  });
@@ -605,306 +608,312 @@ var Site = /*#__PURE__*/(0, _createClass2.default)(function Site() {
605
608
  }
606
609
  throw new errors.InvalidParameterError("Bad parameter: welcome_screen must be of type String, received ".concat((0, _utils.getType)(params['welcome_screen'])));
607
610
  case 32:
608
- if (!(params['motd_text'] && !(0, _utils.isString)(params['motd_text']))) {
611
+ if (!(params['office_integration_type'] && !(0, _utils.isString)(params['office_integration_type']))) {
609
612
  _context3.next = 34;
610
613
  break;
611
614
  }
612
- throw new errors.InvalidParameterError("Bad parameter: motd_text must be of type String, received ".concat((0, _utils.getType)(params['motd_text'])));
615
+ throw new errors.InvalidParameterError("Bad parameter: office_integration_type must be of type String, received ".concat((0, _utils.getType)(params['office_integration_type'])));
613
616
  case 34:
614
- if (!(params['user_lockout_tries'] && !(0, _utils.isInt)(params['user_lockout_tries']))) {
617
+ if (!(params['motd_text'] && !(0, _utils.isString)(params['motd_text']))) {
615
618
  _context3.next = 36;
616
619
  break;
617
620
  }
618
- throw new errors.InvalidParameterError("Bad parameter: user_lockout_tries must be of type Int, received ".concat((0, _utils.getType)(params['user_lockout_tries'])));
621
+ throw new errors.InvalidParameterError("Bad parameter: motd_text must be of type String, received ".concat((0, _utils.getType)(params['motd_text'])));
619
622
  case 36:
620
- if (!(params['user_lockout_within'] && !(0, _utils.isInt)(params['user_lockout_within']))) {
623
+ if (!(params['user_lockout_tries'] && !(0, _utils.isInt)(params['user_lockout_tries']))) {
621
624
  _context3.next = 38;
622
625
  break;
623
626
  }
624
- throw new errors.InvalidParameterError("Bad parameter: user_lockout_within must be of type Int, received ".concat((0, _utils.getType)(params['user_lockout_within'])));
627
+ throw new errors.InvalidParameterError("Bad parameter: user_lockout_tries must be of type Int, received ".concat((0, _utils.getType)(params['user_lockout_tries'])));
625
628
  case 38:
626
- if (!(params['user_lockout_lock_period'] && !(0, _utils.isInt)(params['user_lockout_lock_period']))) {
629
+ if (!(params['user_lockout_within'] && !(0, _utils.isInt)(params['user_lockout_within']))) {
627
630
  _context3.next = 40;
628
631
  break;
629
632
  }
630
- throw new errors.InvalidParameterError("Bad parameter: user_lockout_lock_period must be of type Int, received ".concat((0, _utils.getType)(params['user_lockout_lock_period'])));
633
+ throw new errors.InvalidParameterError("Bad parameter: user_lockout_within must be of type Int, received ".concat((0, _utils.getType)(params['user_lockout_within'])));
631
634
  case 40:
632
- if (!(params['allowed_countries'] && !(0, _utils.isString)(params['allowed_countries']))) {
635
+ if (!(params['user_lockout_lock_period'] && !(0, _utils.isInt)(params['user_lockout_lock_period']))) {
633
636
  _context3.next = 42;
634
637
  break;
635
638
  }
636
- throw new errors.InvalidParameterError("Bad parameter: allowed_countries must be of type String, received ".concat((0, _utils.getType)(params['allowed_countries'])));
639
+ throw new errors.InvalidParameterError("Bad parameter: user_lockout_lock_period must be of type Int, received ".concat((0, _utils.getType)(params['user_lockout_lock_period'])));
637
640
  case 42:
638
- if (!(params['allowed_ips'] && !(0, _utils.isString)(params['allowed_ips']))) {
641
+ if (!(params['allowed_countries'] && !(0, _utils.isString)(params['allowed_countries']))) {
639
642
  _context3.next = 44;
640
643
  break;
641
644
  }
642
- throw new errors.InvalidParameterError("Bad parameter: allowed_ips must be of type String, received ".concat((0, _utils.getType)(params['allowed_ips'])));
645
+ throw new errors.InvalidParameterError("Bad parameter: allowed_countries must be of type String, received ".concat((0, _utils.getType)(params['allowed_countries'])));
643
646
  case 44:
644
- if (!(params['disallowed_countries'] && !(0, _utils.isString)(params['disallowed_countries']))) {
647
+ if (!(params['allowed_ips'] && !(0, _utils.isString)(params['allowed_ips']))) {
645
648
  _context3.next = 46;
646
649
  break;
647
650
  }
648
- throw new errors.InvalidParameterError("Bad parameter: disallowed_countries must be of type String, received ".concat((0, _utils.getType)(params['disallowed_countries'])));
651
+ throw new errors.InvalidParameterError("Bad parameter: allowed_ips must be of type String, received ".concat((0, _utils.getType)(params['allowed_ips'])));
649
652
  case 46:
650
- if (!(params['days_to_retain_backups'] && !(0, _utils.isInt)(params['days_to_retain_backups']))) {
653
+ if (!(params['disallowed_countries'] && !(0, _utils.isString)(params['disallowed_countries']))) {
651
654
  _context3.next = 48;
652
655
  break;
653
656
  }
654
- throw new errors.InvalidParameterError("Bad parameter: days_to_retain_backups must be of type Int, received ".concat((0, _utils.getType)(params['days_to_retain_backups'])));
657
+ throw new errors.InvalidParameterError("Bad parameter: disallowed_countries must be of type String, received ".concat((0, _utils.getType)(params['disallowed_countries'])));
655
658
  case 48:
656
- if (!(params['max_prior_passwords'] && !(0, _utils.isInt)(params['max_prior_passwords']))) {
659
+ if (!(params['days_to_retain_backups'] && !(0, _utils.isInt)(params['days_to_retain_backups']))) {
657
660
  _context3.next = 50;
658
661
  break;
659
662
  }
660
- throw new errors.InvalidParameterError("Bad parameter: max_prior_passwords must be of type Int, received ".concat((0, _utils.getType)(params['max_prior_passwords'])));
663
+ throw new errors.InvalidParameterError("Bad parameter: days_to_retain_backups must be of type Int, received ".concat((0, _utils.getType)(params['days_to_retain_backups'])));
661
664
  case 50:
662
- if (!(params['password_validity_days'] && !(0, _utils.isInt)(params['password_validity_days']))) {
665
+ if (!(params['max_prior_passwords'] && !(0, _utils.isInt)(params['max_prior_passwords']))) {
663
666
  _context3.next = 52;
664
667
  break;
665
668
  }
666
- throw new errors.InvalidParameterError("Bad parameter: password_validity_days must be of type Int, received ".concat((0, _utils.getType)(params['password_validity_days'])));
669
+ throw new errors.InvalidParameterError("Bad parameter: max_prior_passwords must be of type Int, received ".concat((0, _utils.getType)(params['max_prior_passwords'])));
667
670
  case 52:
668
- if (!(params['password_min_length'] && !(0, _utils.isInt)(params['password_min_length']))) {
671
+ if (!(params['password_validity_days'] && !(0, _utils.isInt)(params['password_validity_days']))) {
669
672
  _context3.next = 54;
670
673
  break;
671
674
  }
672
- throw new errors.InvalidParameterError("Bad parameter: password_min_length must be of type Int, received ".concat((0, _utils.getType)(params['password_min_length'])));
675
+ throw new errors.InvalidParameterError("Bad parameter: password_validity_days must be of type Int, received ".concat((0, _utils.getType)(params['password_validity_days'])));
673
676
  case 54:
674
- if (!(params['bundle_registration_notifications'] && !(0, _utils.isString)(params['bundle_registration_notifications']))) {
677
+ if (!(params['password_min_length'] && !(0, _utils.isInt)(params['password_min_length']))) {
675
678
  _context3.next = 56;
676
679
  break;
677
680
  }
678
- throw new errors.InvalidParameterError("Bad parameter: bundle_registration_notifications must be of type String, received ".concat((0, _utils.getType)(params['bundle_registration_notifications'])));
681
+ throw new errors.InvalidParameterError("Bad parameter: password_min_length must be of type Int, received ".concat((0, _utils.getType)(params['password_min_length'])));
679
682
  case 56:
680
- if (!(params['bundle_activity_notifications'] && !(0, _utils.isString)(params['bundle_activity_notifications']))) {
683
+ if (!(params['bundle_registration_notifications'] && !(0, _utils.isString)(params['bundle_registration_notifications']))) {
681
684
  _context3.next = 58;
682
685
  break;
683
686
  }
684
- throw new errors.InvalidParameterError("Bad parameter: bundle_activity_notifications must be of type String, received ".concat((0, _utils.getType)(params['bundle_activity_notifications'])));
687
+ throw new errors.InvalidParameterError("Bad parameter: bundle_registration_notifications must be of type String, received ".concat((0, _utils.getType)(params['bundle_registration_notifications'])));
685
688
  case 58:
686
- if (!(params['bundle_upload_receipt_notifications'] && !(0, _utils.isString)(params['bundle_upload_receipt_notifications']))) {
689
+ if (!(params['bundle_activity_notifications'] && !(0, _utils.isString)(params['bundle_activity_notifications']))) {
687
690
  _context3.next = 60;
688
691
  break;
689
692
  }
690
- throw new errors.InvalidParameterError("Bad parameter: bundle_upload_receipt_notifications must be of type String, received ".concat((0, _utils.getType)(params['bundle_upload_receipt_notifications'])));
693
+ throw new errors.InvalidParameterError("Bad parameter: bundle_activity_notifications must be of type String, received ".concat((0, _utils.getType)(params['bundle_activity_notifications'])));
691
694
  case 60:
692
- if (!(params['disable_users_from_inactivity_period_days'] && !(0, _utils.isInt)(params['disable_users_from_inactivity_period_days']))) {
695
+ if (!(params['bundle_upload_receipt_notifications'] && !(0, _utils.isString)(params['bundle_upload_receipt_notifications']))) {
693
696
  _context3.next = 62;
694
697
  break;
695
698
  }
696
- throw new errors.InvalidParameterError("Bad parameter: disable_users_from_inactivity_period_days must be of type Int, received ".concat((0, _utils.getType)(params['disable_users_from_inactivity_period_days'])));
699
+ throw new errors.InvalidParameterError("Bad parameter: bundle_upload_receipt_notifications must be of type String, received ".concat((0, _utils.getType)(params['bundle_upload_receipt_notifications'])));
697
700
  case 62:
698
- if (!(params['sftp_host_key_type'] && !(0, _utils.isString)(params['sftp_host_key_type']))) {
701
+ if (!(params['disable_users_from_inactivity_period_days'] && !(0, _utils.isInt)(params['disable_users_from_inactivity_period_days']))) {
699
702
  _context3.next = 64;
700
703
  break;
701
704
  }
702
- throw new errors.InvalidParameterError("Bad parameter: sftp_host_key_type must be of type String, received ".concat((0, _utils.getType)(params['sftp_host_key_type'])));
705
+ throw new errors.InvalidParameterError("Bad parameter: disable_users_from_inactivity_period_days must be of type Int, received ".concat((0, _utils.getType)(params['disable_users_from_inactivity_period_days'])));
703
706
  case 64:
704
- if (!(params['active_sftp_host_key_id'] && !(0, _utils.isInt)(params['active_sftp_host_key_id']))) {
707
+ if (!(params['sftp_host_key_type'] && !(0, _utils.isString)(params['sftp_host_key_type']))) {
705
708
  _context3.next = 66;
706
709
  break;
707
710
  }
708
- throw new errors.InvalidParameterError("Bad parameter: active_sftp_host_key_id must be of type Int, received ".concat((0, _utils.getType)(params['active_sftp_host_key_id'])));
711
+ throw new errors.InvalidParameterError("Bad parameter: sftp_host_key_type must be of type String, received ".concat((0, _utils.getType)(params['sftp_host_key_type'])));
709
712
  case 66:
710
- if (!(params['require_2fa_user_type'] && !(0, _utils.isString)(params['require_2fa_user_type']))) {
713
+ if (!(params['active_sftp_host_key_id'] && !(0, _utils.isInt)(params['active_sftp_host_key_id']))) {
711
714
  _context3.next = 68;
712
715
  break;
713
716
  }
714
- throw new errors.InvalidParameterError("Bad parameter: require_2fa_user_type must be of type String, received ".concat((0, _utils.getType)(params['require_2fa_user_type'])));
717
+ throw new errors.InvalidParameterError("Bad parameter: active_sftp_host_key_id must be of type Int, received ".concat((0, _utils.getType)(params['active_sftp_host_key_id'])));
715
718
  case 68:
716
- if (!(params['color2_top'] && !(0, _utils.isString)(params['color2_top']))) {
719
+ if (!(params['require_2fa_user_type'] && !(0, _utils.isString)(params['require_2fa_user_type']))) {
717
720
  _context3.next = 70;
718
721
  break;
719
722
  }
720
- throw new errors.InvalidParameterError("Bad parameter: color2_top must be of type String, received ".concat((0, _utils.getType)(params['color2_top'])));
723
+ throw new errors.InvalidParameterError("Bad parameter: require_2fa_user_type must be of type String, received ".concat((0, _utils.getType)(params['require_2fa_user_type'])));
721
724
  case 70:
722
- if (!(params['color2_left'] && !(0, _utils.isString)(params['color2_left']))) {
725
+ if (!(params['color2_top'] && !(0, _utils.isString)(params['color2_top']))) {
723
726
  _context3.next = 72;
724
727
  break;
725
728
  }
726
- throw new errors.InvalidParameterError("Bad parameter: color2_left must be of type String, received ".concat((0, _utils.getType)(params['color2_left'])));
729
+ throw new errors.InvalidParameterError("Bad parameter: color2_top must be of type String, received ".concat((0, _utils.getType)(params['color2_top'])));
727
730
  case 72:
728
- if (!(params['color2_link'] && !(0, _utils.isString)(params['color2_link']))) {
731
+ if (!(params['color2_left'] && !(0, _utils.isString)(params['color2_left']))) {
729
732
  _context3.next = 74;
730
733
  break;
731
734
  }
732
- throw new errors.InvalidParameterError("Bad parameter: color2_link must be of type String, received ".concat((0, _utils.getType)(params['color2_link'])));
735
+ throw new errors.InvalidParameterError("Bad parameter: color2_left must be of type String, received ".concat((0, _utils.getType)(params['color2_left'])));
733
736
  case 74:
734
- if (!(params['color2_text'] && !(0, _utils.isString)(params['color2_text']))) {
737
+ if (!(params['color2_link'] && !(0, _utils.isString)(params['color2_link']))) {
735
738
  _context3.next = 76;
736
739
  break;
737
740
  }
738
- throw new errors.InvalidParameterError("Bad parameter: color2_text must be of type String, received ".concat((0, _utils.getType)(params['color2_text'])));
741
+ throw new errors.InvalidParameterError("Bad parameter: color2_link must be of type String, received ".concat((0, _utils.getType)(params['color2_link'])));
739
742
  case 76:
740
- if (!(params['color2_top_text'] && !(0, _utils.isString)(params['color2_top_text']))) {
743
+ if (!(params['color2_text'] && !(0, _utils.isString)(params['color2_text']))) {
741
744
  _context3.next = 78;
742
745
  break;
743
746
  }
744
- throw new errors.InvalidParameterError("Bad parameter: color2_top_text must be of type String, received ".concat((0, _utils.getType)(params['color2_top_text'])));
747
+ throw new errors.InvalidParameterError("Bad parameter: color2_text must be of type String, received ".concat((0, _utils.getType)(params['color2_text'])));
745
748
  case 78:
746
- if (!(params['site_header'] && !(0, _utils.isString)(params['site_header']))) {
749
+ if (!(params['color2_top_text'] && !(0, _utils.isString)(params['color2_top_text']))) {
747
750
  _context3.next = 80;
748
751
  break;
749
752
  }
750
- throw new errors.InvalidParameterError("Bad parameter: site_header must be of type String, received ".concat((0, _utils.getType)(params['site_header'])));
753
+ throw new errors.InvalidParameterError("Bad parameter: color2_top_text must be of type String, received ".concat((0, _utils.getType)(params['color2_top_text'])));
751
754
  case 80:
752
- if (!(params['site_footer'] && !(0, _utils.isString)(params['site_footer']))) {
755
+ if (!(params['site_header'] && !(0, _utils.isString)(params['site_header']))) {
753
756
  _context3.next = 82;
754
757
  break;
755
758
  }
756
- throw new errors.InvalidParameterError("Bad parameter: site_footer must be of type String, received ".concat((0, _utils.getType)(params['site_footer'])));
759
+ throw new errors.InvalidParameterError("Bad parameter: site_header must be of type String, received ".concat((0, _utils.getType)(params['site_header'])));
757
760
  case 82:
758
- if (!(params['login_help_text'] && !(0, _utils.isString)(params['login_help_text']))) {
761
+ if (!(params['site_footer'] && !(0, _utils.isString)(params['site_footer']))) {
759
762
  _context3.next = 84;
760
763
  break;
761
764
  }
762
- throw new errors.InvalidParameterError("Bad parameter: login_help_text must be of type String, received ".concat((0, _utils.getType)(params['login_help_text'])));
765
+ throw new errors.InvalidParameterError("Bad parameter: site_footer must be of type String, received ".concat((0, _utils.getType)(params['site_footer'])));
763
766
  case 84:
764
- if (!(params['smtp_address'] && !(0, _utils.isString)(params['smtp_address']))) {
767
+ if (!(params['login_help_text'] && !(0, _utils.isString)(params['login_help_text']))) {
765
768
  _context3.next = 86;
766
769
  break;
767
770
  }
768
- throw new errors.InvalidParameterError("Bad parameter: smtp_address must be of type String, received ".concat((0, _utils.getType)(params['smtp_address'])));
771
+ throw new errors.InvalidParameterError("Bad parameter: login_help_text must be of type String, received ".concat((0, _utils.getType)(params['login_help_text'])));
769
772
  case 86:
770
- if (!(params['smtp_authentication'] && !(0, _utils.isString)(params['smtp_authentication']))) {
773
+ if (!(params['smtp_address'] && !(0, _utils.isString)(params['smtp_address']))) {
771
774
  _context3.next = 88;
772
775
  break;
773
776
  }
774
- throw new errors.InvalidParameterError("Bad parameter: smtp_authentication must be of type String, received ".concat((0, _utils.getType)(params['smtp_authentication'])));
777
+ throw new errors.InvalidParameterError("Bad parameter: smtp_address must be of type String, received ".concat((0, _utils.getType)(params['smtp_address'])));
775
778
  case 88:
776
- if (!(params['smtp_from'] && !(0, _utils.isString)(params['smtp_from']))) {
779
+ if (!(params['smtp_authentication'] && !(0, _utils.isString)(params['smtp_authentication']))) {
777
780
  _context3.next = 90;
778
781
  break;
779
782
  }
780
- throw new errors.InvalidParameterError("Bad parameter: smtp_from must be of type String, received ".concat((0, _utils.getType)(params['smtp_from'])));
783
+ throw new errors.InvalidParameterError("Bad parameter: smtp_authentication must be of type String, received ".concat((0, _utils.getType)(params['smtp_authentication'])));
781
784
  case 90:
782
- if (!(params['smtp_username'] && !(0, _utils.isString)(params['smtp_username']))) {
785
+ if (!(params['smtp_from'] && !(0, _utils.isString)(params['smtp_from']))) {
783
786
  _context3.next = 92;
784
787
  break;
785
788
  }
786
- throw new errors.InvalidParameterError("Bad parameter: smtp_username must be of type String, received ".concat((0, _utils.getType)(params['smtp_username'])));
789
+ throw new errors.InvalidParameterError("Bad parameter: smtp_from must be of type String, received ".concat((0, _utils.getType)(params['smtp_from'])));
787
790
  case 92:
788
- if (!(params['smtp_port'] && !(0, _utils.isInt)(params['smtp_port']))) {
791
+ if (!(params['smtp_username'] && !(0, _utils.isString)(params['smtp_username']))) {
789
792
  _context3.next = 94;
790
793
  break;
791
794
  }
792
- throw new errors.InvalidParameterError("Bad parameter: smtp_port must be of type Int, received ".concat((0, _utils.getType)(params['smtp_port'])));
795
+ throw new errors.InvalidParameterError("Bad parameter: smtp_username must be of type String, received ".concat((0, _utils.getType)(params['smtp_username'])));
793
796
  case 94:
794
- if (!(params['ldap_type'] && !(0, _utils.isString)(params['ldap_type']))) {
797
+ if (!(params['smtp_port'] && !(0, _utils.isInt)(params['smtp_port']))) {
795
798
  _context3.next = 96;
796
799
  break;
797
800
  }
798
- throw new errors.InvalidParameterError("Bad parameter: ldap_type must be of type String, received ".concat((0, _utils.getType)(params['ldap_type'])));
801
+ throw new errors.InvalidParameterError("Bad parameter: smtp_port must be of type Int, received ".concat((0, _utils.getType)(params['smtp_port'])));
799
802
  case 96:
800
- if (!(params['ldap_host'] && !(0, _utils.isString)(params['ldap_host']))) {
803
+ if (!(params['ldap_type'] && !(0, _utils.isString)(params['ldap_type']))) {
801
804
  _context3.next = 98;
802
805
  break;
803
806
  }
804
- throw new errors.InvalidParameterError("Bad parameter: ldap_host must be of type String, received ".concat((0, _utils.getType)(params['ldap_host'])));
807
+ throw new errors.InvalidParameterError("Bad parameter: ldap_type must be of type String, received ".concat((0, _utils.getType)(params['ldap_type'])));
805
808
  case 98:
806
- if (!(params['ldap_host_2'] && !(0, _utils.isString)(params['ldap_host_2']))) {
809
+ if (!(params['ldap_host'] && !(0, _utils.isString)(params['ldap_host']))) {
807
810
  _context3.next = 100;
808
811
  break;
809
812
  }
810
- throw new errors.InvalidParameterError("Bad parameter: ldap_host_2 must be of type String, received ".concat((0, _utils.getType)(params['ldap_host_2'])));
813
+ throw new errors.InvalidParameterError("Bad parameter: ldap_host must be of type String, received ".concat((0, _utils.getType)(params['ldap_host'])));
811
814
  case 100:
812
- if (!(params['ldap_host_3'] && !(0, _utils.isString)(params['ldap_host_3']))) {
815
+ if (!(params['ldap_host_2'] && !(0, _utils.isString)(params['ldap_host_2']))) {
813
816
  _context3.next = 102;
814
817
  break;
815
818
  }
816
- throw new errors.InvalidParameterError("Bad parameter: ldap_host_3 must be of type String, received ".concat((0, _utils.getType)(params['ldap_host_3'])));
819
+ throw new errors.InvalidParameterError("Bad parameter: ldap_host_2 must be of type String, received ".concat((0, _utils.getType)(params['ldap_host_2'])));
817
820
  case 102:
818
- if (!(params['ldap_port'] && !(0, _utils.isInt)(params['ldap_port']))) {
821
+ if (!(params['ldap_host_3'] && !(0, _utils.isString)(params['ldap_host_3']))) {
819
822
  _context3.next = 104;
820
823
  break;
821
824
  }
822
- throw new errors.InvalidParameterError("Bad parameter: ldap_port must be of type Int, received ".concat((0, _utils.getType)(params['ldap_port'])));
825
+ throw new errors.InvalidParameterError("Bad parameter: ldap_host_3 must be of type String, received ".concat((0, _utils.getType)(params['ldap_host_3'])));
823
826
  case 104:
824
- if (!(params['ldap_username'] && !(0, _utils.isString)(params['ldap_username']))) {
827
+ if (!(params['ldap_port'] && !(0, _utils.isInt)(params['ldap_port']))) {
825
828
  _context3.next = 106;
826
829
  break;
827
830
  }
828
- throw new errors.InvalidParameterError("Bad parameter: ldap_username must be of type String, received ".concat((0, _utils.getType)(params['ldap_username'])));
831
+ throw new errors.InvalidParameterError("Bad parameter: ldap_port must be of type Int, received ".concat((0, _utils.getType)(params['ldap_port'])));
829
832
  case 106:
830
- if (!(params['ldap_username_field'] && !(0, _utils.isString)(params['ldap_username_field']))) {
833
+ if (!(params['ldap_username'] && !(0, _utils.isString)(params['ldap_username']))) {
831
834
  _context3.next = 108;
832
835
  break;
833
836
  }
834
- throw new errors.InvalidParameterError("Bad parameter: ldap_username_field must be of type String, received ".concat((0, _utils.getType)(params['ldap_username_field'])));
837
+ throw new errors.InvalidParameterError("Bad parameter: ldap_username must be of type String, received ".concat((0, _utils.getType)(params['ldap_username'])));
835
838
  case 108:
836
- if (!(params['ldap_domain'] && !(0, _utils.isString)(params['ldap_domain']))) {
839
+ if (!(params['ldap_username_field'] && !(0, _utils.isString)(params['ldap_username_field']))) {
837
840
  _context3.next = 110;
838
841
  break;
839
842
  }
840
- throw new errors.InvalidParameterError("Bad parameter: ldap_domain must be of type String, received ".concat((0, _utils.getType)(params['ldap_domain'])));
843
+ throw new errors.InvalidParameterError("Bad parameter: ldap_username_field must be of type String, received ".concat((0, _utils.getType)(params['ldap_username_field'])));
841
844
  case 110:
842
- if (!(params['ldap_user_action'] && !(0, _utils.isString)(params['ldap_user_action']))) {
845
+ if (!(params['ldap_domain'] && !(0, _utils.isString)(params['ldap_domain']))) {
843
846
  _context3.next = 112;
844
847
  break;
845
848
  }
846
- throw new errors.InvalidParameterError("Bad parameter: ldap_user_action must be of type String, received ".concat((0, _utils.getType)(params['ldap_user_action'])));
849
+ throw new errors.InvalidParameterError("Bad parameter: ldap_domain must be of type String, received ".concat((0, _utils.getType)(params['ldap_domain'])));
847
850
  case 112:
848
- if (!(params['ldap_group_action'] && !(0, _utils.isString)(params['ldap_group_action']))) {
851
+ if (!(params['ldap_user_action'] && !(0, _utils.isString)(params['ldap_user_action']))) {
849
852
  _context3.next = 114;
850
853
  break;
851
854
  }
852
- throw new errors.InvalidParameterError("Bad parameter: ldap_group_action must be of type String, received ".concat((0, _utils.getType)(params['ldap_group_action'])));
855
+ throw new errors.InvalidParameterError("Bad parameter: ldap_user_action must be of type String, received ".concat((0, _utils.getType)(params['ldap_user_action'])));
853
856
  case 114:
854
- if (!(params['ldap_user_include_groups'] && !(0, _utils.isString)(params['ldap_user_include_groups']))) {
857
+ if (!(params['ldap_group_action'] && !(0, _utils.isString)(params['ldap_group_action']))) {
855
858
  _context3.next = 116;
856
859
  break;
857
860
  }
858
- throw new errors.InvalidParameterError("Bad parameter: ldap_user_include_groups must be of type String, received ".concat((0, _utils.getType)(params['ldap_user_include_groups'])));
861
+ throw new errors.InvalidParameterError("Bad parameter: ldap_group_action must be of type String, received ".concat((0, _utils.getType)(params['ldap_group_action'])));
859
862
  case 116:
860
- if (!(params['ldap_group_exclusion'] && !(0, _utils.isString)(params['ldap_group_exclusion']))) {
863
+ if (!(params['ldap_user_include_groups'] && !(0, _utils.isString)(params['ldap_user_include_groups']))) {
861
864
  _context3.next = 118;
862
865
  break;
863
866
  }
864
- throw new errors.InvalidParameterError("Bad parameter: ldap_group_exclusion must be of type String, received ".concat((0, _utils.getType)(params['ldap_group_exclusion'])));
867
+ throw new errors.InvalidParameterError("Bad parameter: ldap_user_include_groups must be of type String, received ".concat((0, _utils.getType)(params['ldap_user_include_groups'])));
865
868
  case 118:
866
- if (!(params['ldap_group_inclusion'] && !(0, _utils.isString)(params['ldap_group_inclusion']))) {
869
+ if (!(params['ldap_group_exclusion'] && !(0, _utils.isString)(params['ldap_group_exclusion']))) {
867
870
  _context3.next = 120;
868
871
  break;
869
872
  }
870
- throw new errors.InvalidParameterError("Bad parameter: ldap_group_inclusion must be of type String, received ".concat((0, _utils.getType)(params['ldap_group_inclusion'])));
873
+ throw new errors.InvalidParameterError("Bad parameter: ldap_group_exclusion must be of type String, received ".concat((0, _utils.getType)(params['ldap_group_exclusion'])));
871
874
  case 120:
872
- if (!(params['ldap_base_dn'] && !(0, _utils.isString)(params['ldap_base_dn']))) {
875
+ if (!(params['ldap_group_inclusion'] && !(0, _utils.isString)(params['ldap_group_inclusion']))) {
873
876
  _context3.next = 122;
874
877
  break;
875
878
  }
876
- throw new errors.InvalidParameterError("Bad parameter: ldap_base_dn must be of type String, received ".concat((0, _utils.getType)(params['ldap_base_dn'])));
879
+ throw new errors.InvalidParameterError("Bad parameter: ldap_group_inclusion must be of type String, received ".concat((0, _utils.getType)(params['ldap_group_inclusion'])));
877
880
  case 122:
878
- if (!(params['ldap_password_change'] && !(0, _utils.isString)(params['ldap_password_change']))) {
881
+ if (!(params['ldap_base_dn'] && !(0, _utils.isString)(params['ldap_base_dn']))) {
879
882
  _context3.next = 124;
880
883
  break;
881
884
  }
882
- throw new errors.InvalidParameterError("Bad parameter: ldap_password_change must be of type String, received ".concat((0, _utils.getType)(params['ldap_password_change'])));
885
+ throw new errors.InvalidParameterError("Bad parameter: ldap_base_dn must be of type String, received ".concat((0, _utils.getType)(params['ldap_base_dn'])));
883
886
  case 124:
884
- if (!(params['ldap_password_change_confirmation'] && !(0, _utils.isString)(params['ldap_password_change_confirmation']))) {
887
+ if (!(params['ldap_password_change'] && !(0, _utils.isString)(params['ldap_password_change']))) {
885
888
  _context3.next = 126;
886
889
  break;
887
890
  }
888
- throw new errors.InvalidParameterError("Bad parameter: ldap_password_change_confirmation must be of type String, received ".concat((0, _utils.getType)(params['ldap_password_change_confirmation'])));
891
+ throw new errors.InvalidParameterError("Bad parameter: ldap_password_change must be of type String, received ".concat((0, _utils.getType)(params['ldap_password_change'])));
889
892
  case 126:
890
- if (!(params['smtp_password'] && !(0, _utils.isString)(params['smtp_password']))) {
893
+ if (!(params['ldap_password_change_confirmation'] && !(0, _utils.isString)(params['ldap_password_change_confirmation']))) {
891
894
  _context3.next = 128;
892
895
  break;
893
896
  }
894
- throw new errors.InvalidParameterError("Bad parameter: smtp_password must be of type String, received ".concat((0, _utils.getType)(params['smtp_password'])));
897
+ throw new errors.InvalidParameterError("Bad parameter: ldap_password_change_confirmation must be of type String, received ".concat((0, _utils.getType)(params['ldap_password_change_confirmation'])));
895
898
  case 128:
896
- if (!(params['session_expiry_minutes'] && !(0, _utils.isInt)(params['session_expiry_minutes']))) {
899
+ if (!(params['smtp_password'] && !(0, _utils.isString)(params['smtp_password']))) {
897
900
  _context3.next = 130;
898
901
  break;
899
902
  }
900
- throw new errors.InvalidParameterError("Bad parameter: session_expiry_minutes must be of type Int, received ".concat((0, _utils.getType)(params['session_expiry_minutes'])));
903
+ throw new errors.InvalidParameterError("Bad parameter: smtp_password must be of type String, received ".concat((0, _utils.getType)(params['smtp_password'])));
901
904
  case 130:
902
- _context3.next = 132;
903
- return _Api.default.sendRequest("/site", 'PATCH', params, options);
905
+ if (!(params['session_expiry_minutes'] && !(0, _utils.isInt)(params['session_expiry_minutes']))) {
906
+ _context3.next = 132;
907
+ break;
908
+ }
909
+ throw new errors.InvalidParameterError("Bad parameter: session_expiry_minutes must be of type Int, received ".concat((0, _utils.getType)(params['session_expiry_minutes'])));
904
910
  case 132:
911
+ _context3.next = 134;
912
+ return _Api.default.sendRequest("/site", 'PATCH', params, options);
913
+ case 134:
905
914
  response = _context3.sent;
906
915
  return _context3.abrupt("return", new Site(response === null || response === void 0 ? void 0 : response.data, options));
907
- case 134:
916
+ case 136:
908
917
  case "end":
909
918
  return _context3.stop();
910
919
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "files.com",
3
- "version": "1.0.243",
3
+ "version": "1.0.245",
4
4
  "description": "Files.com SDK for JavaScript",
5
5
  "keywords": [
6
6
  "files.com",
@@ -185,15 +185,11 @@ class BundleNotification {
185
185
  BundleNotification.find(id, params, options)
186
186
 
187
187
  // Parameters:
188
- // user_id (required) - int64 - The id of the user to notify.
188
+ // user_id - int64 - The id of the user to notify.
189
189
  // notify_on_registration - boolean - Triggers bundle notification when a registration action occurs for it.
190
190
  // notify_on_upload - boolean - Triggers bundle notification when a upload action occurs for it.
191
191
  // bundle_id (required) - int64 - Bundle ID to notify on
192
192
  static create = async (params = {}, options = {}) => {
193
- if (!params['user_id']) {
194
- throw new errors.MissingParameterError('Parameter missing: user_id')
195
- }
196
-
197
193
  if (!params['bundle_id']) {
198
194
  throw new errors.MissingParameterError('Parameter missing: bundle_id')
199
195
  }
@@ -272,6 +272,9 @@ class Site {
272
272
  // boolean # Allow users to use Office for the web?
273
273
  getOfficeIntegrationAvailable = () => this.attributes.office_integration_available
274
274
 
275
+ // string # Office integration application used to edit and view the MS Office documents
276
+ getOfficeIntegrationType = () => this.attributes.office_integration_type
277
+
275
278
  // string # Link to scheduling a meeting with our Sales team
276
279
  getOncehubLink = () => this.attributes.oncehub_link
277
280
 
@@ -488,6 +491,7 @@ class Site {
488
491
  // folder_permissions_groups_only - boolean - If true, permissions for this site must be bound to a group (not a user). Otherwise, permissions must be bound to a user.
489
492
  // welcome_screen - string - Does the welcome screen appear?
490
493
  // office_integration_available - boolean - Allow users to use Office for the web?
494
+ // office_integration_type - string - Office integration application used to edit and view the MS Office documents
491
495
  // pin_all_remote_servers_to_site_region - boolean - If true, we will ensure that all internal communications with any remote server are made through the primary region of the site. This setting overrides individual remote server settings.
492
496
  // motd_text - string - A message to show users when they connect via FTP or SFTP.
493
497
  // motd_use_for_ftp - boolean - Show message to users connecting via FTP
@@ -653,6 +657,10 @@ class Site {
653
657
  throw new errors.InvalidParameterError(`Bad parameter: welcome_screen must be of type String, received ${getType(params['welcome_screen'])}`)
654
658
  }
655
659
 
660
+ if (params['office_integration_type'] && !isString(params['office_integration_type'])) {
661
+ throw new errors.InvalidParameterError(`Bad parameter: office_integration_type must be of type String, received ${getType(params['office_integration_type'])}`)
662
+ }
663
+
656
664
  if (params['motd_text'] && !isString(params['motd_text'])) {
657
665
  throw new errors.InvalidParameterError(`Bad parameter: motd_text must be of type String, received ${getType(params['motd_text'])}`)
658
666
  }