files.com 1.2.249 → 1.2.251

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.
Files changed (90) hide show
  1. package/_VERSION +1 -1
  2. package/docs/models/User.md +4 -1
  3. package/lib/Api.js +72 -71
  4. package/lib/Files.js +1 -1
  5. package/lib/isomorphic/File.node.js +5 -5
  6. package/lib/models/ActionNotificationExport.js +38 -38
  7. package/lib/models/ActionNotificationExportResult.js +14 -14
  8. package/lib/models/ApiKey.js +100 -100
  9. package/lib/models/ApiRequestLog.js +8 -8
  10. package/lib/models/App.js +8 -8
  11. package/lib/models/As2IncomingMessage.js +10 -10
  12. package/lib/models/As2OutgoingMessage.js +10 -10
  13. package/lib/models/As2Partner.js +101 -101
  14. package/lib/models/As2Station.js +81 -81
  15. package/lib/models/Automation.js +167 -167
  16. package/lib/models/AutomationLog.js +8 -8
  17. package/lib/models/AutomationRun.js +24 -24
  18. package/lib/models/BandwidthSnapshot.js +8 -8
  19. package/lib/models/Behavior.js +106 -106
  20. package/lib/models/Bundle.js +143 -143
  21. package/lib/models/BundleAction.js +10 -10
  22. package/lib/models/BundleDownload.js +12 -12
  23. package/lib/models/BundleNotification.js +69 -69
  24. package/lib/models/BundleRecipient.js +40 -40
  25. package/lib/models/BundleRegistration.js +12 -12
  26. package/lib/models/Clickwrap.js +79 -79
  27. package/lib/models/DnsRecord.js +8 -8
  28. package/lib/models/EmailIncomingMessage.js +8 -8
  29. package/lib/models/EmailLog.js +8 -8
  30. package/lib/models/ExavaultApiRequestLog.js +8 -8
  31. package/lib/models/ExternalEvent.js +36 -36
  32. package/lib/models/File.js +269 -269
  33. package/lib/models/FileComment.js +70 -70
  34. package/lib/models/FileCommentReaction.js +34 -34
  35. package/lib/models/FileMigration.js +10 -10
  36. package/lib/models/FileMigrationLog.js +8 -8
  37. package/lib/models/Folder.js +36 -36
  38. package/lib/models/FormFieldSet.js +71 -71
  39. package/lib/models/FtpActionLog.js +8 -8
  40. package/lib/models/GpgKey.js +81 -81
  41. package/lib/models/Group.js +83 -83
  42. package/lib/models/GroupUser.js +89 -89
  43. package/lib/models/History.js +88 -88
  44. package/lib/models/HistoryExport.js +64 -64
  45. package/lib/models/HistoryExportResult.js +14 -14
  46. package/lib/models/InboxRecipient.js +36 -36
  47. package/lib/models/InboxRegistration.js +10 -10
  48. package/lib/models/InboxUpload.js +8 -8
  49. package/lib/models/Invoice.js +18 -18
  50. package/lib/models/IpAddress.js +32 -32
  51. package/lib/models/Lock.js +51 -51
  52. package/lib/models/Message.js +100 -100
  53. package/lib/models/MessageComment.js +78 -78
  54. package/lib/models/MessageCommentReaction.js +54 -54
  55. package/lib/models/MessageReaction.js +54 -54
  56. package/lib/models/Notification.js +91 -91
  57. package/lib/models/OutboundConnectionLog.js +8 -8
  58. package/lib/models/Payment.js +18 -18
  59. package/lib/models/Permission.js +54 -54
  60. package/lib/models/Priority.js +14 -14
  61. package/lib/models/Project.js +70 -70
  62. package/lib/models/PublicHostingRequestLog.js +8 -8
  63. package/lib/models/PublicKey.js +78 -78
  64. package/lib/models/RemoteBandwidthSnapshot.js +8 -8
  65. package/lib/models/RemoteServer.js +362 -362
  66. package/lib/models/Request.js +60 -60
  67. package/lib/models/Restore.js +24 -24
  68. package/lib/models/Session.js +21 -21
  69. package/lib/models/SettingsChange.js +8 -8
  70. package/lib/models/SftpActionLog.js +8 -8
  71. package/lib/models/SftpHostKey.js +67 -67
  72. package/lib/models/ShareGroup.js +79 -79
  73. package/lib/models/SiemHttpDestination.js +158 -158
  74. package/lib/models/Site.js +150 -150
  75. package/lib/models/Snapshot.js +85 -85
  76. package/lib/models/SsoStrategy.js +32 -32
  77. package/lib/models/Style.js +48 -48
  78. package/lib/models/SyncLog.js +8 -8
  79. package/lib/models/UsageDailySnapshot.js +8 -8
  80. package/lib/models/UsageSnapshot.js +8 -8
  81. package/lib/models/User.js +223 -215
  82. package/lib/models/UserCipherUse.js +10 -10
  83. package/lib/models/UserLifecycleRule.js +92 -92
  84. package/lib/models/UserRequest.js +56 -56
  85. package/lib/models/UserSftpClientUse.js +10 -10
  86. package/lib/models/WebDavActionLog.js +8 -8
  87. package/lib/models/WebhookTest.js +24 -24
  88. package/package.json +1 -1
  89. package/src/Files.js +1 -1
  90. package/src/models/User.js +6 -0
@@ -91,46 +91,46 @@ var Request = /*#__PURE__*/(0, _createClass2.default)(function Request() {
91
91
  (0, _defineProperty2.default)(this, "delete", /*#__PURE__*/(0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee() {
92
92
  var params,
93
93
  _args = arguments;
94
- return _regenerator.default.wrap(function _callee$(_context) {
94
+ return _regenerator.default.wrap(function (_context) {
95
95
  while (1) switch (_context.prev = _context.next) {
96
96
  case 0:
97
97
  params = _args.length > 0 && _args[0] !== undefined ? _args[0] : {};
98
98
  if (_this.attributes.id) {
99
- _context.next = 3;
99
+ _context.next = 1;
100
100
  break;
101
101
  }
102
102
  throw new errors.EmptyPropertyError('Current object has no id');
103
- case 3:
103
+ case 1:
104
104
  if ((0, _utils.isObject)(params)) {
105
- _context.next = 5;
105
+ _context.next = 2;
106
106
  break;
107
107
  }
108
108
  throw new errors.InvalidParameterError("Bad parameter: params must be of type object, received ".concat((0, _utils.getType)(params)));
109
- case 5:
109
+ case 2:
110
110
  params.id = _this.attributes.id;
111
111
  if (!(params.id && !(0, _utils.isInt)(params.id))) {
112
- _context.next = 8;
112
+ _context.next = 3;
113
113
  break;
114
114
  }
115
115
  throw new errors.InvalidParameterError("Bad parameter: id must be of type Int, received ".concat((0, _utils.getType)(params.id)));
116
- case 8:
116
+ case 3:
117
117
  if (params.id) {
118
- _context.next = 14;
118
+ _context.next = 5;
119
119
  break;
120
120
  }
121
121
  if (!_this.attributes.id) {
122
- _context.next = 13;
122
+ _context.next = 4;
123
123
  break;
124
124
  }
125
125
  params.id = _this.id;
126
- _context.next = 14;
126
+ _context.next = 5;
127
127
  break;
128
- case 13:
128
+ case 4:
129
129
  throw new errors.MissingParameterError('Parameter missing: id');
130
- case 14:
131
- _context.next = 16;
130
+ case 5:
131
+ _context.next = 6;
132
132
  return _Api.default.sendRequest("/requests/".concat(encodeURIComponent(params.id)), 'DELETE', params, _this.options);
133
- case 16:
133
+ case 6:
134
134
  case "end":
135
135
  return _context.stop();
136
136
  }
@@ -142,22 +142,22 @@ var Request = /*#__PURE__*/(0, _createClass2.default)(function Request() {
142
142
  });
143
143
  (0, _defineProperty2.default)(this, "save", /*#__PURE__*/(0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee2() {
144
144
  var newObject;
145
- return _regenerator.default.wrap(function _callee2$(_context2) {
145
+ return _regenerator.default.wrap(function (_context2) {
146
146
  while (1) switch (_context2.prev = _context2.next) {
147
147
  case 0:
148
148
  if (!_this.attributes.id) {
149
- _context2.next = 4;
149
+ _context2.next = 1;
150
150
  break;
151
151
  }
152
152
  throw new errors.NotImplementedError('The Request object doesn\'t support updates.');
153
- case 4:
154
- _context2.next = 6;
153
+ case 1:
154
+ _context2.next = 2;
155
155
  return Request.create(_this.attributes, _this.options);
156
- case 6:
156
+ case 2:
157
157
  newObject = _context2.sent;
158
158
  _this.attributes = _objectSpread({}, newObject.attributes);
159
159
  return _context2.abrupt("return", true);
160
- case 9:
160
+ case 3:
161
161
  case "end":
162
162
  return _context2.stop();
163
163
  }
@@ -189,37 +189,37 @@ _Request = Request;
189
189
  options,
190
190
  response,
191
191
  _args3 = arguments;
192
- return _regenerator.default.wrap(function _callee3$(_context3) {
192
+ return _regenerator.default.wrap(function (_context3) {
193
193
  while (1) switch (_context3.prev = _context3.next) {
194
194
  case 0:
195
195
  params = _args3.length > 0 && _args3[0] !== undefined ? _args3[0] : {};
196
196
  options = _args3.length > 1 && _args3[1] !== undefined ? _args3[1] : {};
197
197
  if (!(params.cursor && !(0, _utils.isString)(params.cursor))) {
198
- _context3.next = 4;
198
+ _context3.next = 1;
199
199
  break;
200
200
  }
201
201
  throw new errors.InvalidParameterError("Bad parameter: cursor must be of type String, received ".concat((0, _utils.getType)(params.cursor)));
202
- case 4:
202
+ case 1:
203
203
  if (!(params.per_page && !(0, _utils.isInt)(params.per_page))) {
204
- _context3.next = 6;
204
+ _context3.next = 2;
205
205
  break;
206
206
  }
207
207
  throw new errors.InvalidParameterError("Bad parameter: per_page must be of type Int, received ".concat((0, _utils.getType)(params.per_page)));
208
- case 6:
208
+ case 2:
209
209
  if (!(params.path && !(0, _utils.isString)(params.path))) {
210
- _context3.next = 8;
210
+ _context3.next = 3;
211
211
  break;
212
212
  }
213
213
  throw new errors.InvalidParameterError("Bad parameter: path must be of type String, received ".concat((0, _utils.getType)(params.path)));
214
- case 8:
215
- _context3.next = 10;
214
+ case 3:
215
+ _context3.next = 4;
216
216
  return _Api.default.sendRequest('/requests', 'GET', params, options);
217
- case 10:
217
+ case 4:
218
218
  response = _context3.sent;
219
219
  return _context3.abrupt("return", (response === null || response === void 0 || (_response$data = response.data) === null || _response$data === void 0 ? void 0 : _response$data.map(function (obj) {
220
220
  return new _Request(obj, options);
221
221
  })) || []);
222
- case 12:
222
+ case 5:
223
223
  case "end":
224
224
  return _context3.stop();
225
225
  }
@@ -243,50 +243,50 @@ _Request = Request;
243
243
  options,
244
244
  response,
245
245
  _args4 = arguments;
246
- return _regenerator.default.wrap(function _callee4$(_context4) {
246
+ return _regenerator.default.wrap(function (_context4) {
247
247
  while (1) switch (_context4.prev = _context4.next) {
248
248
  case 0:
249
249
  params = _args4.length > 1 && _args4[1] !== undefined ? _args4[1] : {};
250
250
  options = _args4.length > 2 && _args4[2] !== undefined ? _args4[2] : {};
251
251
  if ((0, _utils.isObject)(params)) {
252
- _context4.next = 4;
252
+ _context4.next = 1;
253
253
  break;
254
254
  }
255
255
  throw new errors.InvalidParameterError("Bad parameter: params must be of type object, received ".concat((0, _utils.getType)(params)));
256
- case 4:
256
+ case 1:
257
257
  params.path = path;
258
258
  if (params.path) {
259
- _context4.next = 7;
259
+ _context4.next = 2;
260
260
  break;
261
261
  }
262
262
  throw new errors.MissingParameterError('Parameter missing: path');
263
- case 7:
263
+ case 2:
264
264
  if (!(params.cursor && !(0, _utils.isString)(params.cursor))) {
265
- _context4.next = 9;
265
+ _context4.next = 3;
266
266
  break;
267
267
  }
268
268
  throw new errors.InvalidParameterError("Bad parameter: cursor must be of type String, received ".concat((0, _utils.getType)(params.cursor)));
269
- case 9:
269
+ case 3:
270
270
  if (!(params.per_page && !(0, _utils.isInt)(params.per_page))) {
271
- _context4.next = 11;
271
+ _context4.next = 4;
272
272
  break;
273
273
  }
274
274
  throw new errors.InvalidParameterError("Bad parameter: per_page must be of type Int, received ".concat((0, _utils.getType)(params.per_page)));
275
- case 11:
275
+ case 4:
276
276
  if (!(params.path && !(0, _utils.isString)(params.path))) {
277
- _context4.next = 13;
277
+ _context4.next = 5;
278
278
  break;
279
279
  }
280
280
  throw new errors.InvalidParameterError("Bad parameter: path must be of type String, received ".concat((0, _utils.getType)(params.path)));
281
- case 13:
282
- _context4.next = 15;
281
+ case 5:
282
+ _context4.next = 6;
283
283
  return _Api.default.sendRequest("/requests/folders/".concat(encodeURIComponent(params.path)), 'GET', params, options);
284
- case 15:
284
+ case 6:
285
285
  response = _context4.sent;
286
286
  return _context4.abrupt("return", (response === null || response === void 0 || (_response$data2 = response.data) === null || _response$data2 === void 0 ? void 0 : _response$data2.map(function (obj) {
287
287
  return new _Request(obj, options);
288
288
  })) || []);
289
- case 17:
289
+ case 7:
290
290
  case "end":
291
291
  return _context4.stop();
292
292
  }
@@ -306,53 +306,53 @@ _Request = Request;
306
306
  options,
307
307
  response,
308
308
  _args5 = arguments;
309
- return _regenerator.default.wrap(function _callee5$(_context5) {
309
+ return _regenerator.default.wrap(function (_context5) {
310
310
  while (1) switch (_context5.prev = _context5.next) {
311
311
  case 0:
312
312
  params = _args5.length > 0 && _args5[0] !== undefined ? _args5[0] : {};
313
313
  options = _args5.length > 1 && _args5[1] !== undefined ? _args5[1] : {};
314
314
  if (params.path) {
315
- _context5.next = 4;
315
+ _context5.next = 1;
316
316
  break;
317
317
  }
318
318
  throw new errors.MissingParameterError('Parameter missing: path');
319
- case 4:
319
+ case 1:
320
320
  if (params.destination) {
321
- _context5.next = 6;
321
+ _context5.next = 2;
322
322
  break;
323
323
  }
324
324
  throw new errors.MissingParameterError('Parameter missing: destination');
325
- case 6:
325
+ case 2:
326
326
  if (!(params.path && !(0, _utils.isString)(params.path))) {
327
- _context5.next = 8;
327
+ _context5.next = 3;
328
328
  break;
329
329
  }
330
330
  throw new errors.InvalidParameterError("Bad parameter: path must be of type String, received ".concat((0, _utils.getType)(params.path)));
331
- case 8:
331
+ case 3:
332
332
  if (!(params.destination && !(0, _utils.isString)(params.destination))) {
333
- _context5.next = 10;
333
+ _context5.next = 4;
334
334
  break;
335
335
  }
336
336
  throw new errors.InvalidParameterError("Bad parameter: destination must be of type String, received ".concat((0, _utils.getType)(params.destination)));
337
- case 10:
337
+ case 4:
338
338
  if (!(params.user_ids && !(0, _utils.isString)(params.user_ids))) {
339
- _context5.next = 12;
339
+ _context5.next = 5;
340
340
  break;
341
341
  }
342
342
  throw new errors.InvalidParameterError("Bad parameter: user_ids must be of type String, received ".concat((0, _utils.getType)(params.user_ids)));
343
- case 12:
343
+ case 5:
344
344
  if (!(params.group_ids && !(0, _utils.isString)(params.group_ids))) {
345
- _context5.next = 14;
345
+ _context5.next = 6;
346
346
  break;
347
347
  }
348
348
  throw new errors.InvalidParameterError("Bad parameter: group_ids must be of type String, received ".concat((0, _utils.getType)(params.group_ids)));
349
- case 14:
350
- _context5.next = 16;
349
+ case 6:
350
+ _context5.next = 7;
351
351
  return _Api.default.sendRequest('/requests', 'POST', params, options);
352
- case 16:
352
+ case 7:
353
353
  response = _context5.sent;
354
354
  return _context5.abrupt("return", new _Request(response === null || response === void 0 ? void 0 : response.data, options));
355
- case 18:
355
+ case 8:
356
356
  case "end":
357
357
  return _context5.stop();
358
358
  }
@@ -132,22 +132,22 @@ var Restore = /*#__PURE__*/(0, _createClass2.default)(function Restore() {
132
132
  });
133
133
  (0, _defineProperty2.default)(this, "save", /*#__PURE__*/(0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee() {
134
134
  var newObject;
135
- return _regenerator.default.wrap(function _callee$(_context) {
135
+ return _regenerator.default.wrap(function (_context) {
136
136
  while (1) switch (_context.prev = _context.next) {
137
137
  case 0:
138
138
  if (!_this.attributes.id) {
139
- _context.next = 4;
139
+ _context.next = 1;
140
140
  break;
141
141
  }
142
142
  throw new errors.NotImplementedError('The Restore object doesn\'t support updates.');
143
- case 4:
144
- _context.next = 6;
143
+ case 1:
144
+ _context.next = 2;
145
145
  return Restore.create(_this.attributes, _this.options);
146
- case 6:
146
+ case 2:
147
147
  newObject = _context.sent;
148
148
  _this.attributes = _objectSpread({}, newObject.attributes);
149
149
  return _context.abrupt("return", true);
150
- case 9:
150
+ case 3:
151
151
  case "end":
152
152
  return _context.stop();
153
153
  }
@@ -176,31 +176,31 @@ _Restore = Restore;
176
176
  options,
177
177
  response,
178
178
  _args2 = arguments;
179
- return _regenerator.default.wrap(function _callee2$(_context2) {
179
+ return _regenerator.default.wrap(function (_context2) {
180
180
  while (1) switch (_context2.prev = _context2.next) {
181
181
  case 0:
182
182
  params = _args2.length > 0 && _args2[0] !== undefined ? _args2[0] : {};
183
183
  options = _args2.length > 1 && _args2[1] !== undefined ? _args2[1] : {};
184
184
  if (!(params.cursor && !(0, _utils.isString)(params.cursor))) {
185
- _context2.next = 4;
185
+ _context2.next = 1;
186
186
  break;
187
187
  }
188
188
  throw new errors.InvalidParameterError("Bad parameter: cursor must be of type String, received ".concat((0, _utils.getType)(params.cursor)));
189
- case 4:
189
+ case 1:
190
190
  if (!(params.per_page && !(0, _utils.isInt)(params.per_page))) {
191
- _context2.next = 6;
191
+ _context2.next = 2;
192
192
  break;
193
193
  }
194
194
  throw new errors.InvalidParameterError("Bad parameter: per_page must be of type Int, received ".concat((0, _utils.getType)(params.per_page)));
195
- case 6:
196
- _context2.next = 8;
195
+ case 2:
196
+ _context2.next = 3;
197
197
  return _Api.default.sendRequest('/restores', 'GET', params, options);
198
- case 8:
198
+ case 3:
199
199
  response = _context2.sent;
200
200
  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) {
201
201
  return new _Restore(obj, options);
202
202
  })) || []);
203
- case 10:
203
+ case 4:
204
204
  case "end":
205
205
  return _context2.stop();
206
206
  }
@@ -222,35 +222,35 @@ _Restore = Restore;
222
222
  options,
223
223
  response,
224
224
  _args3 = arguments;
225
- return _regenerator.default.wrap(function _callee3$(_context3) {
225
+ return _regenerator.default.wrap(function (_context3) {
226
226
  while (1) switch (_context3.prev = _context3.next) {
227
227
  case 0:
228
228
  params = _args3.length > 0 && _args3[0] !== undefined ? _args3[0] : {};
229
229
  options = _args3.length > 1 && _args3[1] !== undefined ? _args3[1] : {};
230
230
  if (params.earliest_date) {
231
- _context3.next = 4;
231
+ _context3.next = 1;
232
232
  break;
233
233
  }
234
234
  throw new errors.MissingParameterError('Parameter missing: earliest_date');
235
- case 4:
235
+ case 1:
236
236
  if (!(params.earliest_date && !(0, _utils.isString)(params.earliest_date))) {
237
- _context3.next = 6;
237
+ _context3.next = 2;
238
238
  break;
239
239
  }
240
240
  throw new errors.InvalidParameterError("Bad parameter: earliest_date must be of type String, received ".concat((0, _utils.getType)(params.earliest_date)));
241
- case 6:
241
+ case 2:
242
242
  if (!(params.prefix && !(0, _utils.isString)(params.prefix))) {
243
- _context3.next = 8;
243
+ _context3.next = 3;
244
244
  break;
245
245
  }
246
246
  throw new errors.InvalidParameterError("Bad parameter: prefix must be of type String, received ".concat((0, _utils.getType)(params.prefix)));
247
- case 8:
248
- _context3.next = 10;
247
+ case 3:
248
+ _context3.next = 4;
249
249
  return _Api.default.sendRequest('/restores', 'POST', params, options);
250
- case 10:
250
+ case 4:
251
251
  response = _context3.sent;
252
252
  return _context3.abrupt("return", new _Restore(response === null || response === void 0 ? void 0 : response.data, options));
253
- case 12:
253
+ case 5:
254
254
  case "end":
255
255
  return _context3.stop();
256
256
  }
@@ -90,22 +90,22 @@ var Session = /*#__PURE__*/(0, _createClass2.default)(function Session() {
90
90
  });
91
91
  (0, _defineProperty2.default)(this, "save", /*#__PURE__*/(0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee() {
92
92
  var newObject;
93
- return _regenerator.default.wrap(function _callee$(_context) {
93
+ return _regenerator.default.wrap(function (_context) {
94
94
  while (1) switch (_context.prev = _context.next) {
95
95
  case 0:
96
96
  if (!_this.attributes.id) {
97
- _context.next = 4;
97
+ _context.next = 1;
98
98
  break;
99
99
  }
100
100
  throw new errors.NotImplementedError('The Session object doesn\'t support updates.');
101
- case 4:
102
- _context.next = 6;
101
+ case 1:
102
+ _context.next = 2;
103
103
  return Session.create(_this.attributes, _this.options);
104
- case 6:
104
+ case 2:
105
105
  newObject = _context.sent;
106
106
  _this.attributes = _objectSpread({}, newObject.attributes);
107
107
  return _context.abrupt("return", true);
108
- case 9:
108
+ case 3:
109
109
  case "end":
110
110
  return _context.stop();
111
111
  }
@@ -135,41 +135,41 @@ _Session = Session;
135
135
  options,
136
136
  response,
137
137
  _args2 = arguments;
138
- return _regenerator.default.wrap(function _callee2$(_context2) {
138
+ return _regenerator.default.wrap(function (_context2) {
139
139
  while (1) switch (_context2.prev = _context2.next) {
140
140
  case 0:
141
141
  params = _args2.length > 0 && _args2[0] !== undefined ? _args2[0] : {};
142
142
  options = _args2.length > 1 && _args2[1] !== undefined ? _args2[1] : {};
143
143
  if (!(params.username && !(0, _utils.isString)(params.username))) {
144
- _context2.next = 4;
144
+ _context2.next = 1;
145
145
  break;
146
146
  }
147
147
  throw new errors.InvalidParameterError("Bad parameter: username must be of type String, received ".concat((0, _utils.getType)(params.username)));
148
- case 4:
148
+ case 1:
149
149
  if (!(params.password && !(0, _utils.isString)(params.password))) {
150
- _context2.next = 6;
150
+ _context2.next = 2;
151
151
  break;
152
152
  }
153
153
  throw new errors.InvalidParameterError("Bad parameter: password must be of type String, received ".concat((0, _utils.getType)(params.password)));
154
- case 6:
154
+ case 2:
155
155
  if (!(params.otp && !(0, _utils.isString)(params.otp))) {
156
- _context2.next = 8;
156
+ _context2.next = 3;
157
157
  break;
158
158
  }
159
159
  throw new errors.InvalidParameterError("Bad parameter: otp must be of type String, received ".concat((0, _utils.getType)(params.otp)));
160
- case 8:
160
+ case 3:
161
161
  if (!(params.partial_session_id && !(0, _utils.isString)(params.partial_session_id))) {
162
- _context2.next = 10;
162
+ _context2.next = 4;
163
163
  break;
164
164
  }
165
165
  throw new errors.InvalidParameterError("Bad parameter: partial_session_id must be of type String, received ".concat((0, _utils.getType)(params.partial_session_id)));
166
- case 10:
167
- _context2.next = 12;
166
+ case 4:
167
+ _context2.next = 5;
168
168
  return _Api.default.sendRequest('/sessions', 'POST', params, options);
169
- case 12:
169
+ case 5:
170
170
  response = _context2.sent;
171
171
  return _context2.abrupt("return", new _Session(response === null || response === void 0 ? void 0 : response.data, options));
172
- case 14:
172
+ case 6:
173
173
  case "end":
174
174
  return _context2.stop();
175
175
  }
@@ -178,13 +178,13 @@ _Session = Session;
178
178
  (0, _defineProperty2.default)(Session, "delete", /*#__PURE__*/(0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee3() {
179
179
  var options,
180
180
  _args3 = arguments;
181
- return _regenerator.default.wrap(function _callee3$(_context3) {
181
+ return _regenerator.default.wrap(function (_context3) {
182
182
  while (1) switch (_context3.prev = _context3.next) {
183
183
  case 0:
184
184
  options = _args3.length > 0 && _args3[0] !== undefined ? _args3[0] : {};
185
- _context3.next = 3;
185
+ _context3.next = 1;
186
186
  return _Api.default.sendRequest('/sessions', 'DELETE', {}, options);
187
- case 3:
187
+ case 1:
188
188
  case "end":
189
189
  return _context3.stop();
190
190
  }
@@ -85,31 +85,31 @@ _SettingsChange = SettingsChange;
85
85
  options,
86
86
  response,
87
87
  _args = arguments;
88
- return _regenerator.default.wrap(function _callee$(_context) {
88
+ return _regenerator.default.wrap(function (_context) {
89
89
  while (1) switch (_context.prev = _context.next) {
90
90
  case 0:
91
91
  params = _args.length > 0 && _args[0] !== undefined ? _args[0] : {};
92
92
  options = _args.length > 1 && _args[1] !== undefined ? _args[1] : {};
93
93
  if (!(params.cursor && !(0, _utils.isString)(params.cursor))) {
94
- _context.next = 4;
94
+ _context.next = 1;
95
95
  break;
96
96
  }
97
97
  throw new errors.InvalidParameterError("Bad parameter: cursor must be of type String, received ".concat((0, _utils.getType)(params.cursor)));
98
- case 4:
98
+ case 1:
99
99
  if (!(params.per_page && !(0, _utils.isInt)(params.per_page))) {
100
- _context.next = 6;
100
+ _context.next = 2;
101
101
  break;
102
102
  }
103
103
  throw new errors.InvalidParameterError("Bad parameter: per_page must be of type Int, received ".concat((0, _utils.getType)(params.per_page)));
104
- case 6:
105
- _context.next = 8;
104
+ case 2:
105
+ _context.next = 3;
106
106
  return _Api.default.sendRequest('/settings_changes', 'GET', params, options);
107
- case 8:
107
+ case 3:
108
108
  response = _context.sent;
109
109
  return _context.abrupt("return", (response === null || response === void 0 || (_response$data = response.data) === null || _response$data === void 0 ? void 0 : _response$data.map(function (obj) {
110
110
  return new _SettingsChange(obj, options);
111
111
  })) || []);
112
- case 10:
112
+ case 4:
113
113
  case "end":
114
114
  return _context.stop();
115
115
  }
@@ -149,31 +149,31 @@ _SftpActionLog = SftpActionLog;
149
149
  options,
150
150
  response,
151
151
  _args = arguments;
152
- return _regenerator.default.wrap(function _callee$(_context) {
152
+ return _regenerator.default.wrap(function (_context) {
153
153
  while (1) switch (_context.prev = _context.next) {
154
154
  case 0:
155
155
  params = _args.length > 0 && _args[0] !== undefined ? _args[0] : {};
156
156
  options = _args.length > 1 && _args[1] !== undefined ? _args[1] : {};
157
157
  if (!(params.cursor && !(0, _utils.isString)(params.cursor))) {
158
- _context.next = 4;
158
+ _context.next = 1;
159
159
  break;
160
160
  }
161
161
  throw new errors.InvalidParameterError("Bad parameter: cursor must be of type String, received ".concat((0, _utils.getType)(params.cursor)));
162
- case 4:
162
+ case 1:
163
163
  if (!(params.per_page && !(0, _utils.isInt)(params.per_page))) {
164
- _context.next = 6;
164
+ _context.next = 2;
165
165
  break;
166
166
  }
167
167
  throw new errors.InvalidParameterError("Bad parameter: per_page must be of type Int, received ".concat((0, _utils.getType)(params.per_page)));
168
- case 6:
169
- _context.next = 8;
168
+ case 2:
169
+ _context.next = 3;
170
170
  return _Api.default.sendRequest('/sftp_action_logs', 'GET', params, options);
171
- case 8:
171
+ case 3:
172
172
  response = _context.sent;
173
173
  return _context.abrupt("return", (response === null || response === void 0 || (_response$data = response.data) === null || _response$data === void 0 ? void 0 : _response$data.map(function (obj) {
174
174
  return new _SftpActionLog(obj, options);
175
175
  })) || []);
176
- case 10:
176
+ case 4:
177
177
  case "end":
178
178
  return _context.stop();
179
179
  }