files.com 1.2.161 → 1.2.163

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.2.161
1
+ 1.2.163
@@ -93,6 +93,7 @@
93
93
 
94
94
  ```
95
95
  await Folder.listFor(path, {
96
+ 'search': "some-partial-filename",
96
97
  'search_all': true,
97
98
  'with_previews': true,
98
99
  'with_priority_color': true,
@@ -105,10 +106,9 @@ await Folder.listFor(path, {
105
106
  * `cursor` (string): Send cursor to resume an existing list from the point at which you left off. Get a cursor from an existing list via the X-Files-Cursor-Next header or the X-Files-Cursor-Prev header.
106
107
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
107
108
  * `path` (string): Required - Path to operate on.
108
- * `filter` (string): If specified, will filter folders/files list by name. Ignores text before last `/`. This is the same API used by the search bar in the web UI when running 'Search This Folder'. Search results are a best effort, not real time, and not guaranteed to perfectly match the latest folder listing. This field should only be used for ad-hoc (human) searching, and not as part of an automated process.
109
109
  * `preview_size` (string): Request a preview size. Can be `small` (default), `large`, `xlarge`, or `pdf`.
110
110
  * `sort_by` (object): Search by field and direction. Valid fields are `path`, `size`, `modified_at_datetime`, `provided_modified_at`. Valid directions are `asc` and `desc`. Defaults to `{"path":"asc"}`.
111
- * `search` (string): If `search_all` is `true`, provide the search string here. Otherwise, this parameter acts like an alias of `filter`.
111
+ * `search` (string): If specified, will filter folders/files list by name. Ignores text before last `/`. This is the same API used by the search bar in the web UI when running 'Search This Folder'. Search results are a best effort, not real time, and not guaranteed to perfectly match the latest folder listing. This field should only be used for ad-hoc (human) searching, and not as part of an automated process.
112
112
  * `search_all` (boolean): Search entire site? If set, we will ignore the folder path provided and search the entire site. This is the same API used by the search bar in the web UI when running 'Search All Files'. Search results are a best effort, not real time, and not guaranteed to match every file. This field should only be used for ad-hoc (human) searching, and not as part of an automated process.
113
113
  * `with_previews` (boolean): Include file previews?
114
114
  * `with_priority_color` (boolean): Include file priority color information?
@@ -61,7 +61,7 @@
61
61
  "dav_enabled": true,
62
62
  "dav_user_root_enabled": true,
63
63
  "days_to_retain_backups": 30,
64
- "document_edits_in_bundle_allowed": "example",
64
+ "document_edits_in_bundle_allowed": true,
65
65
  "default_time_zone": "Pacific Time (US & Canada)",
66
66
  "desktop_app": true,
67
67
  "desktop_app_session_ip_pinning": true,
@@ -348,7 +348,7 @@
348
348
  * `dav_enabled` (boolean): Is WebDAV enabled?
349
349
  * `dav_user_root_enabled` (boolean): Use user FTP roots also for WebDAV?
350
350
  * `days_to_retain_backups` (int64): Number of days to keep deleted files
351
- * `document_edits_in_bundle_allowed` (string): If true, allow public viewers of Bundles with full permissions to use document editing integrations.
351
+ * `document_edits_in_bundle_allowed` (boolean): If true, allow public viewers of Bundles with full permissions to use document editing integrations.
352
352
  * `default_time_zone` (string): Site default time zone
353
353
  * `desktop_app` (boolean): Is the desktop app enabled?
354
354
  * `desktop_app_session_ip_pinning` (boolean): Is desktop app session IP pinning enabled?
@@ -571,7 +571,7 @@ await Site.update({
571
571
  'bundle_registration_notifications': "never",
572
572
  'bundle_activity_notifications': "never",
573
573
  'bundle_upload_receipt_notifications': "never",
574
- 'document_edits_in_bundle_allowed': "example",
574
+ 'document_edits_in_bundle_allowed': true,
575
575
  'password_requirements_apply_to_bundles': true,
576
576
  'prevent_root_permissions_for_non_site_admins': true,
577
577
  'opt_out_global': true,
@@ -730,7 +730,7 @@ await Site.update({
730
730
  * `bundle_registration_notifications` (string): Do Bundle owners receive registration notification?
731
731
  * `bundle_activity_notifications` (string): Do Bundle owners receive activity notifications?
732
732
  * `bundle_upload_receipt_notifications` (string): Do Bundle uploaders receive upload confirmation notifications?
733
- * `document_edits_in_bundle_allowed` (string): If true, allow public viewers of Bundles with full permissions to use document editing integrations.
733
+ * `document_edits_in_bundle_allowed` (boolean): If true, allow public viewers of Bundles with full permissions to use document editing integrations.
734
734
  * `password_requirements_apply_to_bundles` (boolean): Require bundles' passwords, and passwords for other items (inboxes, public shares, etc.) to conform to the same requirements as users' passwords?
735
735
  * `prevent_root_permissions_for_non_site_admins` (boolean): If true, we will prevent non-administrators from receiving any permissions directly on the root folder. This is commonly used to prevent the accidental application of permissions.
736
736
  * `opt_out_global` (boolean): Use servers in the USA only?
package/lib/Files.js CHANGED
@@ -11,7 +11,7 @@ var endpointPrefix = '/api/rest/v1';
11
11
  var apiKey;
12
12
  var baseUrl = 'https://app.files.com';
13
13
  var sessionId = null;
14
- var version = '1.2.161';
14
+ var version = '1.2.163';
15
15
  var userAgent = "Files.com JavaScript SDK v".concat(version);
16
16
  var logLevel = _Logger.LogLevel.INFO;
17
17
  var debugRequest = false;
@@ -314,10 +314,9 @@ var Folder = /*#__PURE__*/(0, _createClass2.default)(function Folder() {
314
314
  // cursor - string - Send cursor to resume an existing list from the point at which you left off. Get a cursor from an existing list via the X-Files-Cursor-Next header or the X-Files-Cursor-Prev header.
315
315
  // per_page - int64 - Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
316
316
  // path (required) - string - Path to operate on.
317
- // filter - string - If specified, will filter folders/files list by name. Ignores text before last `/`. This is the same API used by the search bar in the web UI when running 'Search This Folder'. Search results are a best effort, not real time, and not guaranteed to perfectly match the latest folder listing. This field should only be used for ad-hoc (human) searching, and not as part of an automated process.
318
317
  // preview_size - string - Request a preview size. Can be `small` (default), `large`, `xlarge`, or `pdf`.
319
318
  // sort_by - object - Search by field and direction. Valid fields are `path`, `size`, `modified_at_datetime`, `provided_modified_at`. Valid directions are `asc` and `desc`. Defaults to `{"path":"asc"}`.
320
- // search - string - If `search_all` is `true`, provide the search string here. Otherwise, this parameter acts like an alias of `filter`.
319
+ // search - string - If specified, will filter folders/files list by name. Ignores text before last `/`. This is the same API used by the search bar in the web UI when running 'Search This Folder'. Search results are a best effort, not real time, and not guaranteed to perfectly match the latest folder listing. This field should only be used for ad-hoc (human) searching, and not as part of an automated process.
321
320
  // search_all - boolean - Search entire site? If set, we will ignore the folder path provided and search the entire site. This is the same API used by the search bar in the web UI when running 'Search All Files'. Search results are a best effort, not real time, and not guaranteed to match every file. This field should only be used for ad-hoc (human) searching, and not as part of an automated process.
322
321
  // with_previews - boolean - Include file previews?
323
322
  // with_priority_color - boolean - Include file priority color information?
@@ -365,33 +364,27 @@ var Folder = /*#__PURE__*/(0, _createClass2.default)(function Folder() {
365
364
  }
366
365
  throw new errors.InvalidParameterError("Bad parameter: path must be of type String, received ".concat((0, _utils.getType)(params.path)));
367
366
  case 13:
368
- if (!(params.filter && !(0, _utils.isString)(params.filter))) {
369
- _context2.next = 15;
370
- break;
371
- }
372
- throw new errors.InvalidParameterError("Bad parameter: filter must be of type String, received ".concat((0, _utils.getType)(params.filter)));
373
- case 15:
374
367
  if (!(params.preview_size && !(0, _utils.isString)(params.preview_size))) {
375
- _context2.next = 17;
368
+ _context2.next = 15;
376
369
  break;
377
370
  }
378
371
  throw new errors.InvalidParameterError("Bad parameter: preview_size must be of type String, received ".concat((0, _utils.getType)(params.preview_size)));
379
- case 17:
372
+ case 15:
380
373
  if (!(params.search && !(0, _utils.isString)(params.search))) {
381
- _context2.next = 19;
374
+ _context2.next = 17;
382
375
  break;
383
376
  }
384
377
  throw new errors.InvalidParameterError("Bad parameter: search must be of type String, received ".concat((0, _utils.getType)(params.search)));
385
- case 19:
386
- _context2.next = 21;
378
+ case 17:
379
+ _context2.next = 19;
387
380
  return _Api.default.sendRequest("/folders/".concat(encodeURIComponent(params.path)), 'GET', params, options);
388
- case 21:
381
+ case 19:
389
382
  response = _context2.sent;
390
383
  File = require('./File.js').default;
391
384
  return _context2.abrupt("return", (response === null || response === void 0 || (_response$data = response.data) === null || _response$data === void 0 ? void 0 : _response$data.map(function (obj) {
392
385
  return new File(obj, options);
393
386
  })) || []);
394
- case 24:
387
+ case 22:
395
388
  case "end":
396
389
  return _context2.stop();
397
390
  }
@@ -225,7 +225,7 @@ var Site = /*#__PURE__*/(0, _createClass2.default)(function Site() {
225
225
  (0, _defineProperty2.default)(this, "getDaysToRetainBackups", function () {
226
226
  return _this.attributes.days_to_retain_backups;
227
227
  });
228
- // string # If true, allow public viewers of Bundles with full permissions to use document editing integrations.
228
+ // boolean # If true, allow public viewers of Bundles with full permissions to use document editing integrations.
229
229
  (0, _defineProperty2.default)(this, "getDocumentEditsInBundleAllowed", function () {
230
230
  return _this.attributes.document_edits_in_bundle_allowed;
231
231
  });
@@ -842,7 +842,7 @@ _Site = Site;
842
842
  // bundle_registration_notifications - string - Do Bundle owners receive registration notification?
843
843
  // bundle_activity_notifications - string - Do Bundle owners receive activity notifications?
844
844
  // bundle_upload_receipt_notifications - string - Do Bundle uploaders receive upload confirmation notifications?
845
- // document_edits_in_bundle_allowed - string - If true, allow public viewers of Bundles with full permissions to use document editing integrations.
845
+ // document_edits_in_bundle_allowed - boolean - If true, allow public viewers of Bundles with full permissions to use document editing integrations.
846
846
  // password_requirements_apply_to_bundles - boolean - Require bundles' passwords, and passwords for other items (inboxes, public shares, etc.) to conform to the same requirements as users' passwords?
847
847
  // prevent_root_permissions_for_non_site_admins - boolean - If true, we will prevent non-administrators from receiving any permissions directly on the root folder. This is commonly used to prevent the accidental application of permissions.
848
848
  // opt_out_global - boolean - Use servers in the USA only?
@@ -1129,234 +1129,228 @@ _Site = Site;
1129
1129
  }
1130
1130
  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)));
1131
1131
  case 66:
1132
- if (!(params.document_edits_in_bundle_allowed && !(0, _utils.isString)(params.document_edits_in_bundle_allowed))) {
1133
- _context3.next = 68;
1134
- break;
1135
- }
1136
- throw new errors.InvalidParameterError("Bad parameter: document_edits_in_bundle_allowed must be of type String, received ".concat((0, _utils.getType)(params.document_edits_in_bundle_allowed)));
1137
- case 68:
1138
1132
  if (!(params.disable_users_from_inactivity_period_days && !(0, _utils.isInt)(params.disable_users_from_inactivity_period_days))) {
1139
- _context3.next = 70;
1133
+ _context3.next = 68;
1140
1134
  break;
1141
1135
  }
1142
1136
  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)));
1143
- case 70:
1137
+ case 68:
1144
1138
  if (!(params.sftp_host_key_type && !(0, _utils.isString)(params.sftp_host_key_type))) {
1145
- _context3.next = 72;
1139
+ _context3.next = 70;
1146
1140
  break;
1147
1141
  }
1148
1142
  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)));
1149
- case 72:
1143
+ case 70:
1150
1144
  if (!(params.active_sftp_host_key_id && !(0, _utils.isInt)(params.active_sftp_host_key_id))) {
1151
- _context3.next = 74;
1145
+ _context3.next = 72;
1152
1146
  break;
1153
1147
  }
1154
1148
  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)));
1155
- case 74:
1149
+ case 72:
1156
1150
  if (!(params.bundle_recipient_blacklist_domains && !(0, _utils.isArray)(params.bundle_recipient_blacklist_domains))) {
1157
- _context3.next = 76;
1151
+ _context3.next = 74;
1158
1152
  break;
1159
1153
  }
1160
1154
  throw new errors.InvalidParameterError("Bad parameter: bundle_recipient_blacklist_domains must be of type Array, received ".concat((0, _utils.getType)(params.bundle_recipient_blacklist_domains)));
1161
- case 76:
1155
+ case 74:
1162
1156
  if (!(params.require_2fa_user_type && !(0, _utils.isString)(params.require_2fa_user_type))) {
1163
- _context3.next = 78;
1157
+ _context3.next = 76;
1164
1158
  break;
1165
1159
  }
1166
1160
  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)));
1167
- case 78:
1161
+ case 76:
1168
1162
  if (!(params.color2_top && !(0, _utils.isString)(params.color2_top))) {
1169
- _context3.next = 80;
1163
+ _context3.next = 78;
1170
1164
  break;
1171
1165
  }
1172
1166
  throw new errors.InvalidParameterError("Bad parameter: color2_top must be of type String, received ".concat((0, _utils.getType)(params.color2_top)));
1173
- case 80:
1167
+ case 78:
1174
1168
  if (!(params.color2_left && !(0, _utils.isString)(params.color2_left))) {
1175
- _context3.next = 82;
1169
+ _context3.next = 80;
1176
1170
  break;
1177
1171
  }
1178
1172
  throw new errors.InvalidParameterError("Bad parameter: color2_left must be of type String, received ".concat((0, _utils.getType)(params.color2_left)));
1179
- case 82:
1173
+ case 80:
1180
1174
  if (!(params.color2_link && !(0, _utils.isString)(params.color2_link))) {
1181
- _context3.next = 84;
1175
+ _context3.next = 82;
1182
1176
  break;
1183
1177
  }
1184
1178
  throw new errors.InvalidParameterError("Bad parameter: color2_link must be of type String, received ".concat((0, _utils.getType)(params.color2_link)));
1185
- case 84:
1179
+ case 82:
1186
1180
  if (!(params.color2_text && !(0, _utils.isString)(params.color2_text))) {
1187
- _context3.next = 86;
1181
+ _context3.next = 84;
1188
1182
  break;
1189
1183
  }
1190
1184
  throw new errors.InvalidParameterError("Bad parameter: color2_text must be of type String, received ".concat((0, _utils.getType)(params.color2_text)));
1191
- case 86:
1185
+ case 84:
1192
1186
  if (!(params.color2_top_text && !(0, _utils.isString)(params.color2_top_text))) {
1193
- _context3.next = 88;
1187
+ _context3.next = 86;
1194
1188
  break;
1195
1189
  }
1196
1190
  throw new errors.InvalidParameterError("Bad parameter: color2_top_text must be of type String, received ".concat((0, _utils.getType)(params.color2_top_text)));
1197
- case 88:
1191
+ case 86:
1198
1192
  if (!(params.site_header && !(0, _utils.isString)(params.site_header))) {
1199
- _context3.next = 90;
1193
+ _context3.next = 88;
1200
1194
  break;
1201
1195
  }
1202
1196
  throw new errors.InvalidParameterError("Bad parameter: site_header must be of type String, received ".concat((0, _utils.getType)(params.site_header)));
1203
- case 90:
1197
+ case 88:
1204
1198
  if (!(params.site_footer && !(0, _utils.isString)(params.site_footer))) {
1205
- _context3.next = 92;
1199
+ _context3.next = 90;
1206
1200
  break;
1207
1201
  }
1208
1202
  throw new errors.InvalidParameterError("Bad parameter: site_footer must be of type String, received ".concat((0, _utils.getType)(params.site_footer)));
1209
- case 92:
1203
+ case 90:
1210
1204
  if (!(params.login_help_text && !(0, _utils.isString)(params.login_help_text))) {
1211
- _context3.next = 94;
1205
+ _context3.next = 92;
1212
1206
  break;
1213
1207
  }
1214
1208
  throw new errors.InvalidParameterError("Bad parameter: login_help_text must be of type String, received ".concat((0, _utils.getType)(params.login_help_text)));
1215
- case 94:
1209
+ case 92:
1216
1210
  if (!(params.smtp_address && !(0, _utils.isString)(params.smtp_address))) {
1217
- _context3.next = 96;
1211
+ _context3.next = 94;
1218
1212
  break;
1219
1213
  }
1220
1214
  throw new errors.InvalidParameterError("Bad parameter: smtp_address must be of type String, received ".concat((0, _utils.getType)(params.smtp_address)));
1221
- case 96:
1215
+ case 94:
1222
1216
  if (!(params.smtp_authentication && !(0, _utils.isString)(params.smtp_authentication))) {
1223
- _context3.next = 98;
1217
+ _context3.next = 96;
1224
1218
  break;
1225
1219
  }
1226
1220
  throw new errors.InvalidParameterError("Bad parameter: smtp_authentication must be of type String, received ".concat((0, _utils.getType)(params.smtp_authentication)));
1227
- case 98:
1221
+ case 96:
1228
1222
  if (!(params.smtp_from && !(0, _utils.isString)(params.smtp_from))) {
1229
- _context3.next = 100;
1223
+ _context3.next = 98;
1230
1224
  break;
1231
1225
  }
1232
1226
  throw new errors.InvalidParameterError("Bad parameter: smtp_from must be of type String, received ".concat((0, _utils.getType)(params.smtp_from)));
1233
- case 100:
1227
+ case 98:
1234
1228
  if (!(params.smtp_username && !(0, _utils.isString)(params.smtp_username))) {
1235
- _context3.next = 102;
1229
+ _context3.next = 100;
1236
1230
  break;
1237
1231
  }
1238
1232
  throw new errors.InvalidParameterError("Bad parameter: smtp_username must be of type String, received ".concat((0, _utils.getType)(params.smtp_username)));
1239
- case 102:
1233
+ case 100:
1240
1234
  if (!(params.smtp_port && !(0, _utils.isInt)(params.smtp_port))) {
1241
- _context3.next = 104;
1235
+ _context3.next = 102;
1242
1236
  break;
1243
1237
  }
1244
1238
  throw new errors.InvalidParameterError("Bad parameter: smtp_port must be of type Int, received ".concat((0, _utils.getType)(params.smtp_port)));
1245
- case 104:
1239
+ case 102:
1246
1240
  if (!(params.ldap_type && !(0, _utils.isString)(params.ldap_type))) {
1247
- _context3.next = 106;
1241
+ _context3.next = 104;
1248
1242
  break;
1249
1243
  }
1250
1244
  throw new errors.InvalidParameterError("Bad parameter: ldap_type must be of type String, received ".concat((0, _utils.getType)(params.ldap_type)));
1251
- case 106:
1245
+ case 104:
1252
1246
  if (!(params.ldap_host && !(0, _utils.isString)(params.ldap_host))) {
1253
- _context3.next = 108;
1247
+ _context3.next = 106;
1254
1248
  break;
1255
1249
  }
1256
1250
  throw new errors.InvalidParameterError("Bad parameter: ldap_host must be of type String, received ".concat((0, _utils.getType)(params.ldap_host)));
1257
- case 108:
1251
+ case 106:
1258
1252
  if (!(params.ldap_host_2 && !(0, _utils.isString)(params.ldap_host_2))) {
1259
- _context3.next = 110;
1253
+ _context3.next = 108;
1260
1254
  break;
1261
1255
  }
1262
1256
  throw new errors.InvalidParameterError("Bad parameter: ldap_host_2 must be of type String, received ".concat((0, _utils.getType)(params.ldap_host_2)));
1263
- case 110:
1257
+ case 108:
1264
1258
  if (!(params.ldap_host_3 && !(0, _utils.isString)(params.ldap_host_3))) {
1265
- _context3.next = 112;
1259
+ _context3.next = 110;
1266
1260
  break;
1267
1261
  }
1268
1262
  throw new errors.InvalidParameterError("Bad parameter: ldap_host_3 must be of type String, received ".concat((0, _utils.getType)(params.ldap_host_3)));
1269
- case 112:
1263
+ case 110:
1270
1264
  if (!(params.ldap_port && !(0, _utils.isInt)(params.ldap_port))) {
1271
- _context3.next = 114;
1265
+ _context3.next = 112;
1272
1266
  break;
1273
1267
  }
1274
1268
  throw new errors.InvalidParameterError("Bad parameter: ldap_port must be of type Int, received ".concat((0, _utils.getType)(params.ldap_port)));
1275
- case 114:
1269
+ case 112:
1276
1270
  if (!(params.ldap_username && !(0, _utils.isString)(params.ldap_username))) {
1277
- _context3.next = 116;
1271
+ _context3.next = 114;
1278
1272
  break;
1279
1273
  }
1280
1274
  throw new errors.InvalidParameterError("Bad parameter: ldap_username must be of type String, received ".concat((0, _utils.getType)(params.ldap_username)));
1281
- case 116:
1275
+ case 114:
1282
1276
  if (!(params.ldap_username_field && !(0, _utils.isString)(params.ldap_username_field))) {
1283
- _context3.next = 118;
1277
+ _context3.next = 116;
1284
1278
  break;
1285
1279
  }
1286
1280
  throw new errors.InvalidParameterError("Bad parameter: ldap_username_field must be of type String, received ".concat((0, _utils.getType)(params.ldap_username_field)));
1287
- case 118:
1281
+ case 116:
1288
1282
  if (!(params.ldap_domain && !(0, _utils.isString)(params.ldap_domain))) {
1289
- _context3.next = 120;
1283
+ _context3.next = 118;
1290
1284
  break;
1291
1285
  }
1292
1286
  throw new errors.InvalidParameterError("Bad parameter: ldap_domain must be of type String, received ".concat((0, _utils.getType)(params.ldap_domain)));
1293
- case 120:
1287
+ case 118:
1294
1288
  if (!(params.ldap_user_action && !(0, _utils.isString)(params.ldap_user_action))) {
1295
- _context3.next = 122;
1289
+ _context3.next = 120;
1296
1290
  break;
1297
1291
  }
1298
1292
  throw new errors.InvalidParameterError("Bad parameter: ldap_user_action must be of type String, received ".concat((0, _utils.getType)(params.ldap_user_action)));
1299
- case 122:
1293
+ case 120:
1300
1294
  if (!(params.ldap_group_action && !(0, _utils.isString)(params.ldap_group_action))) {
1301
- _context3.next = 124;
1295
+ _context3.next = 122;
1302
1296
  break;
1303
1297
  }
1304
1298
  throw new errors.InvalidParameterError("Bad parameter: ldap_group_action must be of type String, received ".concat((0, _utils.getType)(params.ldap_group_action)));
1305
- case 124:
1299
+ case 122:
1306
1300
  if (!(params.ldap_user_include_groups && !(0, _utils.isString)(params.ldap_user_include_groups))) {
1307
- _context3.next = 126;
1301
+ _context3.next = 124;
1308
1302
  break;
1309
1303
  }
1310
1304
  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)));
1311
- case 126:
1305
+ case 124:
1312
1306
  if (!(params.ldap_group_exclusion && !(0, _utils.isString)(params.ldap_group_exclusion))) {
1313
- _context3.next = 128;
1307
+ _context3.next = 126;
1314
1308
  break;
1315
1309
  }
1316
1310
  throw new errors.InvalidParameterError("Bad parameter: ldap_group_exclusion must be of type String, received ".concat((0, _utils.getType)(params.ldap_group_exclusion)));
1317
- case 128:
1311
+ case 126:
1318
1312
  if (!(params.ldap_group_inclusion && !(0, _utils.isString)(params.ldap_group_inclusion))) {
1319
- _context3.next = 130;
1313
+ _context3.next = 128;
1320
1314
  break;
1321
1315
  }
1322
1316
  throw new errors.InvalidParameterError("Bad parameter: ldap_group_inclusion must be of type String, received ".concat((0, _utils.getType)(params.ldap_group_inclusion)));
1323
- case 130:
1317
+ case 128:
1324
1318
  if (!(params.ldap_base_dn && !(0, _utils.isString)(params.ldap_base_dn))) {
1325
- _context3.next = 132;
1319
+ _context3.next = 130;
1326
1320
  break;
1327
1321
  }
1328
1322
  throw new errors.InvalidParameterError("Bad parameter: ldap_base_dn must be of type String, received ".concat((0, _utils.getType)(params.ldap_base_dn)));
1329
- case 132:
1323
+ case 130:
1330
1324
  if (!(params.ldap_password_change && !(0, _utils.isString)(params.ldap_password_change))) {
1331
- _context3.next = 134;
1325
+ _context3.next = 132;
1332
1326
  break;
1333
1327
  }
1334
1328
  throw new errors.InvalidParameterError("Bad parameter: ldap_password_change must be of type String, received ".concat((0, _utils.getType)(params.ldap_password_change)));
1335
- case 134:
1329
+ case 132:
1336
1330
  if (!(params.ldap_password_change_confirmation && !(0, _utils.isString)(params.ldap_password_change_confirmation))) {
1337
- _context3.next = 136;
1331
+ _context3.next = 134;
1338
1332
  break;
1339
1333
  }
1340
1334
  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)));
1341
- case 136:
1335
+ case 134:
1342
1336
  if (!(params.smtp_password && !(0, _utils.isString)(params.smtp_password))) {
1343
- _context3.next = 138;
1337
+ _context3.next = 136;
1344
1338
  break;
1345
1339
  }
1346
1340
  throw new errors.InvalidParameterError("Bad parameter: smtp_password must be of type String, received ".concat((0, _utils.getType)(params.smtp_password)));
1347
- case 138:
1341
+ case 136:
1348
1342
  if (!(params.session_expiry_minutes && !(0, _utils.isInt)(params.session_expiry_minutes))) {
1349
- _context3.next = 140;
1343
+ _context3.next = 138;
1350
1344
  break;
1351
1345
  }
1352
1346
  throw new errors.InvalidParameterError("Bad parameter: session_expiry_minutes must be of type Int, received ".concat((0, _utils.getType)(params.session_expiry_minutes)));
1353
- case 140:
1354
- _context3.next = 142;
1347
+ case 138:
1348
+ _context3.next = 140;
1355
1349
  return _Api.default.sendRequest('/site', 'PATCH', params, options);
1356
- case 142:
1350
+ case 140:
1357
1351
  response = _context3.sent;
1358
1352
  return _context3.abrupt("return", new _Site(response === null || response === void 0 ? void 0 : response.data, options));
1359
- case 144:
1353
+ case 142:
1360
1354
  case "end":
1361
1355
  return _context3.stop();
1362
1356
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "files.com",
3
- "version": "1.2.161",
3
+ "version": "1.2.163",
4
4
  "description": "Files.com SDK for JavaScript",
5
5
  "keywords": [
6
6
  "files.com",
package/src/Files.js CHANGED
@@ -5,7 +5,7 @@ const endpointPrefix = '/api/rest/v1'
5
5
  let apiKey
6
6
  let baseUrl = 'https://app.files.com'
7
7
  let sessionId = null
8
- const version = '1.2.161'
8
+ const version = '1.2.163'
9
9
  let userAgent = `Files.com JavaScript SDK v${version}`
10
10
 
11
11
  let logLevel = LogLevel.INFO
@@ -286,10 +286,9 @@ class Folder {
286
286
  // cursor - string - Send cursor to resume an existing list from the point at which you left off. Get a cursor from an existing list via the X-Files-Cursor-Next header or the X-Files-Cursor-Prev header.
287
287
  // per_page - int64 - Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
288
288
  // path (required) - string - Path to operate on.
289
- // filter - string - If specified, will filter folders/files list by name. Ignores text before last `/`. This is the same API used by the search bar in the web UI when running 'Search This Folder'. Search results are a best effort, not real time, and not guaranteed to perfectly match the latest folder listing. This field should only be used for ad-hoc (human) searching, and not as part of an automated process.
290
289
  // preview_size - string - Request a preview size. Can be `small` (default), `large`, `xlarge`, or `pdf`.
291
290
  // sort_by - object - Search by field and direction. Valid fields are `path`, `size`, `modified_at_datetime`, `provided_modified_at`. Valid directions are `asc` and `desc`. Defaults to `{"path":"asc"}`.
292
- // search - string - If `search_all` is `true`, provide the search string here. Otherwise, this parameter acts like an alias of `filter`.
291
+ // search - string - If specified, will filter folders/files list by name. Ignores text before last `/`. This is the same API used by the search bar in the web UI when running 'Search This Folder'. Search results are a best effort, not real time, and not guaranteed to perfectly match the latest folder listing. This field should only be used for ad-hoc (human) searching, and not as part of an automated process.
293
292
  // search_all - boolean - Search entire site? If set, we will ignore the folder path provided and search the entire site. This is the same API used by the search bar in the web UI when running 'Search All Files'. Search results are a best effort, not real time, and not guaranteed to match every file. This field should only be used for ad-hoc (human) searching, and not as part of an automated process.
294
293
  // with_previews - boolean - Include file previews?
295
294
  // with_priority_color - boolean - Include file priority color information?
@@ -316,10 +315,6 @@ class Folder {
316
315
  throw new errors.InvalidParameterError(`Bad parameter: path must be of type String, received ${getType(params.path)}`)
317
316
  }
318
317
 
319
- if (params.filter && !isString(params.filter)) {
320
- throw new errors.InvalidParameterError(`Bad parameter: filter must be of type String, received ${getType(params.filter)}`)
321
- }
322
-
323
318
  if (params.preview_size && !isString(params.preview_size)) {
324
319
  throw new errors.InvalidParameterError(`Bad parameter: preview_size must be of type String, received ${getType(params.preview_size)}`)
325
320
  }
@@ -172,7 +172,7 @@ class Site {
172
172
  // int64 # Number of days to keep deleted files
173
173
  getDaysToRetainBackups = () => this.attributes.days_to_retain_backups
174
174
 
175
- // string # If true, allow public viewers of Bundles with full permissions to use document editing integrations.
175
+ // boolean # If true, allow public viewers of Bundles with full permissions to use document editing integrations.
176
176
  getDocumentEditsInBundleAllowed = () => this.attributes.document_edits_in_bundle_allowed
177
177
 
178
178
  // string # Site default time zone
@@ -627,7 +627,7 @@ class Site {
627
627
  // bundle_registration_notifications - string - Do Bundle owners receive registration notification?
628
628
  // bundle_activity_notifications - string - Do Bundle owners receive activity notifications?
629
629
  // bundle_upload_receipt_notifications - string - Do Bundle uploaders receive upload confirmation notifications?
630
- // document_edits_in_bundle_allowed - string - If true, allow public viewers of Bundles with full permissions to use document editing integrations.
630
+ // document_edits_in_bundle_allowed - boolean - If true, allow public viewers of Bundles with full permissions to use document editing integrations.
631
631
  // password_requirements_apply_to_bundles - boolean - Require bundles' passwords, and passwords for other items (inboxes, public shares, etc.) to conform to the same requirements as users' passwords?
632
632
  // prevent_root_permissions_for_non_site_admins - boolean - If true, we will prevent non-administrators from receiving any permissions directly on the root folder. This is commonly used to prevent the accidental application of permissions.
633
633
  // opt_out_global - boolean - Use servers in the USA only?
@@ -841,10 +841,6 @@ class Site {
841
841
  throw new errors.InvalidParameterError(`Bad parameter: bundle_upload_receipt_notifications must be of type String, received ${getType(params.bundle_upload_receipt_notifications)}`)
842
842
  }
843
843
 
844
- if (params.document_edits_in_bundle_allowed && !isString(params.document_edits_in_bundle_allowed)) {
845
- throw new errors.InvalidParameterError(`Bad parameter: document_edits_in_bundle_allowed must be of type String, received ${getType(params.document_edits_in_bundle_allowed)}`)
846
- }
847
-
848
844
  if (params.disable_users_from_inactivity_period_days && !isInt(params.disable_users_from_inactivity_period_days)) {
849
845
  throw new errors.InvalidParameterError(`Bad parameter: disable_users_from_inactivity_period_days must be of type Int, received ${getType(params.disable_users_from_inactivity_period_days)}`)
850
846
  }