files.com 1.0.245 → 1.0.247

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.245
1
+ 1.0.247
@@ -49,7 +49,8 @@
49
49
  "enable_dedicated_ips": true,
50
50
  "files_agent_permission_set": "read_write",
51
51
  "files_agent_root": "example",
52
- "files_agent_api_token": "example"
52
+ "files_agent_api_token": "example",
53
+ "filebase_bucket": "my-bucket"
53
54
  }
54
55
  ```
55
56
 
@@ -99,6 +100,7 @@
99
100
  * `files_agent_permission_set` (string): Local permissions for files agent. read_only, write_only, or read_write
100
101
  * `files_agent_root` (string): Agent local root path
101
102
  * `files_agent_api_token` (string): Files Agent API Token
103
+ * `filebase_bucket` (string): Filebase Bucket name
102
104
  * `aws_secret_key` (string): AWS secret key.
103
105
  * `password` (string): Password if needed.
104
106
  * `private_key` (string): Private key if needed.
@@ -276,6 +278,7 @@ await remote_server.configuration_file({
276
278
  'private_key': "example",
277
279
  'public_key': "example",
278
280
  'server_host_key': "example",
281
+ 'subdomain': "example",
279
282
  })
280
283
  ```
281
284
 
@@ -292,6 +295,7 @@ await remote_server.configuration_file({
292
295
  * `private_key` (string): private key
293
296
  * `public_key` (string): public key
294
297
  * `server_host_key` (string):
298
+ * `subdomain` (string):
295
299
 
296
300
  ### Example Response
297
301
 
@@ -307,7 +311,8 @@ await remote_server.configuration_file({
307
311
  "private_key": "example",
308
312
  "status": "example",
309
313
  "config_version": "example",
310
- "server_host_key": "example"
314
+ "server_host_key": "example",
315
+ "subdomain": "example"
311
316
  }
312
317
  ```
313
318
 
@@ -464,7 +469,8 @@ await remote_server.update({
464
469
  "enable_dedicated_ips": true,
465
470
  "files_agent_permission_set": "read_write",
466
471
  "files_agent_root": "example",
467
- "files_agent_api_token": "example"
472
+ "files_agent_api_token": "example",
473
+ "filebase_bucket": "my-bucket"
468
474
  }
469
475
  ```
470
476
 
@@ -14,7 +14,8 @@
14
14
  "private_key": "example",
15
15
  "status": "example",
16
16
  "config_version": "example",
17
- "server_host_key": "example"
17
+ "server_host_key": "example",
18
+ "subdomain": "example"
18
19
  }
19
20
  ```
20
21
 
@@ -29,3 +30,4 @@
29
30
  * `status` (string): either running or shutdown
30
31
  * `config_version` (string): agent config version
31
32
  * `server_host_key` (string):
33
+ * `subdomain` (string):
@@ -307,6 +307,12 @@ var RemoteServer = /*#__PURE__*/(0, _createClass2.default)(function RemoteServer
307
307
  (0, _defineProperty2.default)(this, "setFilesAgentApiToken", function (value) {
308
308
  _this.attributes.files_agent_api_token = value;
309
309
  });
310
+ (0, _defineProperty2.default)(this, "getFilebaseBucket", function () {
311
+ return _this.attributes.filebase_bucket;
312
+ });
313
+ (0, _defineProperty2.default)(this, "setFilebaseBucket", function (value) {
314
+ _this.attributes.filebase_bucket = value;
315
+ });
310
316
  (0, _defineProperty2.default)(this, "getAwsSecretKey", function () {
311
317
  return _this.attributes.aws_secret_key;
312
318
  });
@@ -478,26 +484,32 @@ var RemoteServer = /*#__PURE__*/(0, _createClass2.default)(function RemoteServer
478
484
  }
479
485
  throw new errors.InvalidParameterError("Bad parameter: server_host_key must be of type String, received ".concat((0, _utils.getType)(server_host_key)));
480
486
  case 28:
487
+ if (!(params['subdomain'] && !(0, _utils.isString)(params['subdomain']))) {
488
+ _context.next = 30;
489
+ break;
490
+ }
491
+ throw new errors.InvalidParameterError("Bad parameter: subdomain must be of type String, received ".concat((0, _utils.getType)(subdomain)));
492
+ case 30:
481
493
  if (params['id']) {
482
- _context.next = 34;
494
+ _context.next = 36;
483
495
  break;
484
496
  }
485
497
  if (!_this.attributes.id) {
486
- _context.next = 33;
498
+ _context.next = 35;
487
499
  break;
488
500
  }
489
501
  params['id'] = _this.id;
490
- _context.next = 34;
502
+ _context.next = 36;
491
503
  break;
492
- case 33:
504
+ case 35:
493
505
  throw new errors.MissingParameterError('Parameter missing: id');
494
- case 34:
495
- _context.next = 36;
496
- return _Api.default.sendRequest("/remote_servers/".concat(encodeURIComponent(params['id']), "/configuration_file"), 'POST', params, _this.options);
497
506
  case 36:
507
+ _context.next = 38;
508
+ return _Api.default.sendRequest("/remote_servers/".concat(encodeURIComponent(params['id']), "/configuration_file"), 'POST', params, _this.options);
509
+ case 38:
498
510
  response = _context.sent;
499
511
  return _context.abrupt("return", new RemoteServerConfigurationFile(response === null || response === void 0 ? void 0 : response.data, _this.options));
500
- case 38:
512
+ case 40:
501
513
  case "end":
502
514
  return _context.stop();
503
515
  }
@@ -62,6 +62,9 @@ var RemoteServerConfigurationFile = /*#__PURE__*/(0, _createClass2.default)(func
62
62
  (0, _defineProperty2.default)(this, "getServerHostKey", function () {
63
63
  return _this.attributes.server_host_key;
64
64
  });
65
+ (0, _defineProperty2.default)(this, "getSubdomain", function () {
66
+ return _this.attributes.subdomain;
67
+ });
65
68
  Object.entries(attributes).forEach(function (_ref) {
66
69
  var _ref2 = (0, _slicedToArray2.default)(_ref, 2),
67
70
  key = _ref2[0],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "files.com",
3
- "version": "1.0.245",
3
+ "version": "1.0.247",
4
4
  "description": "Files.com SDK for JavaScript",
5
5
  "keywords": [
6
6
  "files.com",
@@ -345,6 +345,13 @@ class RemoteServer {
345
345
  this.attributes.files_agent_api_token = value
346
346
  }
347
347
 
348
+ // string # Filebase Bucket name
349
+ getFilebaseBucket = () => this.attributes.filebase_bucket
350
+
351
+ setFilebaseBucket = value => {
352
+ this.attributes.filebase_bucket = value
353
+ }
354
+
348
355
  // string # AWS secret key.
349
356
  getAwsSecretKey = () => this.attributes.aws_secret_key
350
357
 
@@ -457,6 +464,7 @@ class RemoteServer {
457
464
  // private_key - string - private key
458
465
  // public_key - string - public key
459
466
  // server_host_key - string
467
+ // subdomain - string
460
468
  configurationFile = async (params = {}) => {
461
469
  if (!this.attributes.id) {
462
470
  throw new errors.EmptyPropertyError('Current object has no id')
@@ -500,6 +508,9 @@ class RemoteServer {
500
508
  if (params['server_host_key'] && !isString(params['server_host_key'])) {
501
509
  throw new errors.InvalidParameterError(`Bad parameter: server_host_key must be of type String, received ${getType(server_host_key)}`)
502
510
  }
511
+ if (params['subdomain'] && !isString(params['subdomain'])) {
512
+ throw new errors.InvalidParameterError(`Bad parameter: subdomain must be of type String, received ${getType(subdomain)}`)
513
+ }
503
514
 
504
515
  if (!params['id']) {
505
516
  if (this.attributes.id) {
@@ -56,6 +56,9 @@ class RemoteServerConfigurationFile {
56
56
  // string
57
57
  getServerHostKey = () => this.attributes.server_host_key
58
58
 
59
+ // string
60
+ getSubdomain = () => this.attributes.subdomain
61
+
59
62
  }
60
63
 
61
64
  export default RemoteServerConfigurationFile