files.com 1.0.302 → 1.0.304

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 496cd9b7ad247912026b953ce566db761e510116b2e727509877f28cbb08ae42
4
- data.tar.gz: c4be723d45a6d3ea682002fe0edde74332614186cde843db52eee40b81af268b
3
+ metadata.gz: 1fcb5c03ed7252b5d2d30e71cf585b7c6ada9442ae0291e2a506f3967f9960fa
4
+ data.tar.gz: 1c84b5a3e13d2a689fdd1cbcc7fd8400a3ba0cdda977f8d43087b5f26c8327ee
5
5
  SHA512:
6
- metadata.gz: aed6145b17a2968d41f91a20527c999c78dea843770a97dd903d81fe74dd0fcb2dec41e8aea2bf47f2d03359a83d91de6e792aed6ad79026b57ec362571d4573
7
- data.tar.gz: bbb3043bd36dcb9c2e82b9ab6a8b183ec135748093f0e51148e58d55f9aa2c6f0cdff8eaebe824ac39bad4fd79659445fb87b1cd42fcd66749458c433aa9bd08
6
+ metadata.gz: 8edc81e91884af3574259578c047d8a19e2a4e6daee541c850f3f052bcc7c4b51121e680b4c6bd6798aba8a8d4d60930d980f62e171100bbe1b369802fc31fff
7
+ data.tar.gz: 5a306785f8cd643d79bd54abba1b426261dbeab3e79c3d75f461c68bd47f4fcbe4131837070b41f4279928fe7b13736ca2a29ffc15dd7c40a1c258f97b3784fd
data/_VERSION CHANGED
@@ -1 +1 @@
1
- 1.0.302
1
+ 1.0.304
@@ -20,7 +20,7 @@
20
20
  * `path` (string): Source path This must be slash-delimited, but it must neither start nor end with a slash. Maximum of 5000 characters.
21
21
  * `dest_path` (string): Destination path
22
22
  * `files_moved` (int64): Number of files processed
23
- * `files_total` (int64): Total number of files to process
23
+ * `files_total` (int64): Deprecated: used to return a count of the applicable files. Currently returns 0 always. On remote servers, it is not possible to reliably determine the number of affected files for every migration operation.
24
24
  * `operation` (string): The type of operation
25
25
  * `region` (string): Region
26
26
  * `status` (string): Status
data/docs/ip_address.md CHANGED
@@ -35,6 +35,22 @@ Files::IpAddress.list(
35
35
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
36
36
 
37
37
 
38
+ ---
39
+
40
+ ## List all possible public ExaVault IP addresses
41
+
42
+ ```
43
+ Files::IpAddress.get_exavault_reserved(
44
+ per_page: 1
45
+ )
46
+ ```
47
+
48
+ ### Parameters
49
+
50
+ * `cursor` (string): Used for pagination. Send a cursor value to resume an existing list from the point at which you left off. Get a cursor from an existing list via either the X-Files-Cursor-Next header or the X-Files-Cursor-Prev header.
51
+ * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
52
+
53
+
38
54
  ---
39
55
 
40
56
  ## List all possible public IP addresses
@@ -46,7 +46,10 @@
46
46
  "s3_compatible_endpoint": "mys3platform.com",
47
47
  "s3_compatible_region": "us-east-1",
48
48
  "s3_compatible_access_key": "example",
49
- "enable_dedicated_ips": true
49
+ "enable_dedicated_ips": true,
50
+ "files_agent_permission_set": "read_write",
51
+ "files_agent_root": "example",
52
+ "files_agent_api_token": "example"
50
53
  }
51
54
  ```
52
55
 
@@ -93,6 +96,9 @@
93
96
  * `s3_compatible_region` (string): S3-compatible endpoint
94
97
  * `s3_compatible_access_key` (string): S3-compatible Access Key.
95
98
  * `enable_dedicated_ips` (boolean): `true` if remote server only accepts connections from dedicated IPs
99
+ * `files_agent_permission_set` (string): Local permissions for files agent. read_only, write_only, or read_write
100
+ * `files_agent_root` (string): Agent local root path
101
+ * `files_agent_api_token` (string): Files Agent API Token
96
102
  * `aws_secret_key` (string): AWS secret key.
97
103
  * `password` (string): Password if needed.
98
104
  * `private_key` (string): Private key if needed.
@@ -138,6 +144,19 @@ Files::RemoteServer.find(id)
138
144
  * `id` (int64): Required - Remote Server ID.
139
145
 
140
146
 
147
+ ---
148
+
149
+ ## Download configuration file (required for some Remote Server integrations, such as the Files.com Agent)
150
+
151
+ ```
152
+ Files::RemoteServer.find_configuration_file(id)
153
+ ```
154
+
155
+ ### Parameters
156
+
157
+ * `id` (int64): Required - Remote Server ID.
158
+
159
+
141
160
  ---
142
161
 
143
162
  ## Create Remote Server
@@ -179,7 +198,9 @@ Files::RemoteServer.create(
179
198
  s3_compatible_endpoint: "mys3platform.com",
180
199
  s3_compatible_region: "us-east-1",
181
200
  enable_dedicated_ips: true,
182
- s3_compatible_access_key: "example"
201
+ s3_compatible_access_key: "example",
202
+ files_agent_root: "example",
203
+ files_agent_permission_set: "read_write"
183
204
  )
184
205
  ```
185
206
 
@@ -234,6 +255,40 @@ Files::RemoteServer.create(
234
255
  * `enable_dedicated_ips` (boolean): `true` if remote server only accepts connections from dedicated IPs
235
256
  * `s3_compatible_access_key` (string): S3-compatible Access Key.
236
257
  * `s3_compatible_secret_key` (string): S3-compatible secret key
258
+ * `files_agent_root` (string): Agent local root path
259
+ * `files_agent_permission_set` (string): Local permissions for files agent. read_only, write_only, or read_write
260
+
261
+
262
+ ---
263
+
264
+ ## Post local changes, check in, and download configuration file (used by some Remote Server integrations, such as the Files.com Agent)
265
+
266
+ ```
267
+ Files::RemoteServer.configuration_file(id,
268
+ api_token: "example",
269
+ permission_set: "full",
270
+ root: "example",
271
+ hostname: "example",
272
+ port: 1,
273
+ status: "example",
274
+ config_version: "example",
275
+ private_key: "example",
276
+ public_key: "example"
277
+ )
278
+ ```
279
+
280
+ ### Parameters
281
+
282
+ * `id` (int64): Required - Remote Server ID.
283
+ * `api_token` (string): Files Agent API Token
284
+ * `permission_set` (string):
285
+ * `root` (string): Agent local root path
286
+ * `hostname` (string):
287
+ * `port` (int64): Incoming port for files agent connections
288
+ * `status` (string): either running or shutdown
289
+ * `config_version` (string): agent config version
290
+ * `private_key` (string): private key
291
+ * `public_key` (string): public key
237
292
 
238
293
 
239
294
  ---
@@ -277,7 +332,9 @@ Files::RemoteServer.update(id,
277
332
  s3_compatible_endpoint: "mys3platform.com",
278
333
  s3_compatible_region: "us-east-1",
279
334
  enable_dedicated_ips: true,
280
- s3_compatible_access_key: "example"
335
+ s3_compatible_access_key: "example",
336
+ files_agent_root: "example",
337
+ files_agent_permission_set: "read_write"
281
338
  )
282
339
  ```
283
340
 
@@ -333,6 +390,8 @@ Files::RemoteServer.update(id,
333
390
  * `enable_dedicated_ips` (boolean): `true` if remote server only accepts connections from dedicated IPs
334
391
  * `s3_compatible_access_key` (string): S3-compatible Access Key.
335
392
  * `s3_compatible_secret_key` (string): S3-compatible secret key
393
+ * `files_agent_root` (string): Agent local root path
394
+ * `files_agent_permission_set` (string): Local permissions for files agent. read_only, write_only, or read_write
336
395
 
337
396
 
338
397
  ---
@@ -348,6 +407,40 @@ Files::RemoteServer.delete(id)
348
407
  * `id` (int64): Required - Remote Server ID.
349
408
 
350
409
 
410
+ ---
411
+
412
+ ## Post local changes, check in, and download configuration file (used by some Remote Server integrations, such as the Files.com Agent)
413
+
414
+ ```
415
+ remote_server = Files::RemoteServer.list.first
416
+
417
+ remote_server.configuration_file(
418
+ api_token: "example",
419
+ permission_set: "full",
420
+ root: "example",
421
+ hostname: "example",
422
+ port: 1,
423
+ status: "example",
424
+ config_version: "example",
425
+ private_key: "example",
426
+ public_key: "example"
427
+ )
428
+ ```
429
+
430
+ ### Parameters
431
+
432
+ * `id` (int64): Required - Remote Server ID.
433
+ * `api_token` (string): Files Agent API Token
434
+ * `permission_set` (string):
435
+ * `root` (string): Agent local root path
436
+ * `hostname` (string):
437
+ * `port` (int64): Incoming port for files agent connections
438
+ * `status` (string): either running or shutdown
439
+ * `config_version` (string): agent config version
440
+ * `private_key` (string): private key
441
+ * `public_key` (string): public key
442
+
443
+
351
444
  ---
352
445
 
353
446
  ## Update Remote Server
@@ -391,7 +484,9 @@ remote_server.update(
391
484
  s3_compatible_endpoint: "mys3platform.com",
392
485
  s3_compatible_region: "us-east-1",
393
486
  enable_dedicated_ips: true,
394
- s3_compatible_access_key: "example"
487
+ s3_compatible_access_key: "example",
488
+ files_agent_root: "example",
489
+ files_agent_permission_set: "read_write"
395
490
  )
396
491
  ```
397
492
 
@@ -447,6 +542,8 @@ remote_server.update(
447
542
  * `enable_dedicated_ips` (boolean): `true` if remote server only accepts connections from dedicated IPs
448
543
  * `s3_compatible_access_key` (string): S3-compatible Access Key.
449
544
  * `s3_compatible_secret_key` (string): S3-compatible secret key
545
+ * `files_agent_root` (string): Agent local root path
546
+ * `files_agent_permission_set` (string): Local permissions for files agent. read_only, write_only, or read_write
450
547
 
451
548
 
452
549
  ---
@@ -0,0 +1,29 @@
1
+ # RemoteServerConfigurationFile
2
+
3
+ ## Example RemoteServerConfigurationFile Object
4
+
5
+ ```
6
+ {
7
+ "id": 1,
8
+ "permission_set": "full",
9
+ "api_token": "example",
10
+ "root": "example",
11
+ "port": 1,
12
+ "hostname": "example",
13
+ "public_key": "example",
14
+ "private_key": "example",
15
+ "status": "example",
16
+ "config_version": "example"
17
+ }
18
+ ```
19
+
20
+ * `id` (int64): Agent ID
21
+ * `permission_set` (string):
22
+ * `api_token` (string): Files Agent API Token
23
+ * `root` (string): Agent local root path
24
+ * `port` (int64): Incoming port for files agent connections
25
+ * `hostname` (string):
26
+ * `public_key` (string): public key
27
+ * `private_key` (string): private key
28
+ * `status` (string): either running or shutdown
29
+ * `config_version` (string): agent config version
data/docs/site.md CHANGED
@@ -18,6 +18,7 @@
18
18
  "ask_about_overwrites": true,
19
19
  "bundle_expiration": 1,
20
20
  "bundle_password_required": true,
21
+ "bundle_registration_notifications": "never",
21
22
  "bundle_require_share_recipient": true,
22
23
  "bundle_watermark_attachment": "",
23
24
  "bundle_watermark_value": {
@@ -160,6 +161,7 @@
160
161
  * `ask_about_overwrites` (boolean): If false, rename conflicting files instead of asking for overwrite confirmation. Only applies to web interface.
161
162
  * `bundle_expiration` (int64): Site-wide Bundle expiration in days
162
163
  * `bundle_password_required` (boolean): Do Bundles require password protection?
164
+ * `bundle_registration_notifications` (string): Do Bundle owners receive registration notification?
163
165
  * `bundle_require_share_recipient` (boolean): Do Bundles require recipients for sharing?
164
166
  * `bundle_watermark_attachment` (Image): Preview watermark image applied to all bundle items.
165
167
  * `bundle_watermark_value` (object): Preview watermark settings applied to all bundle items. Uses the same keys as Behavior.value
@@ -369,6 +371,7 @@ Files::Site.update(
369
371
  session_pinned_by_ip: true,
370
372
  bundle_password_required: true,
371
373
  bundle_require_share_recipient: true,
374
+ bundle_registration_notifications: "never",
372
375
  password_requirements_apply_to_bundles: true,
373
376
  opt_out_global: true,
374
377
  use_provided_modified_at: true,
@@ -493,6 +496,7 @@ Files::Site.update(
493
496
  * `session_pinned_by_ip` (boolean): Are sessions locked to the same IP? (i.e. do users need to log in again if they change IPs?)
494
497
  * `bundle_password_required` (boolean): Do Bundles require password protection?
495
498
  * `bundle_require_share_recipient` (boolean): Do Bundles require recipients for sharing?
499
+ * `bundle_registration_notifications` (string): Do Bundle owners receive registration notification?
496
500
  * `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?
497
501
  * `opt_out_global` (boolean): Use servers in the USA only?
498
502
  * `use_provided_modified_at` (boolean): Allow uploaders to set `provided_modified_at` for uploaded files?
@@ -45,6 +45,7 @@ module Files
45
45
  end
46
46
 
47
47
  class BadRequestError < APIError; end
48
+ class AgentUpgradeRequiredError < BadRequestError; end
48
49
  class AttachmentTooLargeError < BadRequestError; end
49
50
  class CannotDownloadDirectoryError < BadRequestError; end
50
51
  class CantMoveWithMultipleLocationsError < BadRequestError; end
@@ -84,6 +85,7 @@ module Files
84
85
  class NotAuthenticatedError < APIError; end
85
86
  class AuthenticationRequiredError < NotAuthenticatedError; end
86
87
  class BundleRegistrationCodeFailedError < NotAuthenticatedError; end
88
+ class FilesAgentTokenFailedError < NotAuthenticatedError; end
87
89
  class InboxRegistrationCodeFailedError < NotAuthenticatedError; end
88
90
  class InvalidCredentialsError < NotAuthenticatedError; end
89
91
  class InvalidOauthError < NotAuthenticatedError; end
@@ -29,7 +29,7 @@ module Files
29
29
  @attributes[:files_moved]
30
30
  end
31
31
 
32
- # int64 - Total number of files to process
32
+ # int64 - Deprecated: used to return a count of the applicable files. Currently returns 0 always. On remote servers, it is not possible to reliably determine the number of affected files for every migration operation.
33
33
  def files_total
34
34
  @attributes[:files_total]
35
35
  end
@@ -45,6 +45,18 @@ module Files
45
45
  list(params, options)
46
46
  end
47
47
 
48
+ # Parameters:
49
+ # cursor - string - Used for pagination. Send a cursor value to resume an existing list from the point at which you left off. Get a cursor from an existing list via either the X-Files-Cursor-Next header or the X-Files-Cursor-Prev header.
50
+ # per_page - int64 - Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
51
+ def self.get_exavault_reserved(params = {}, options = {})
52
+ raise InvalidParameterError.new("Bad parameter: cursor must be an String") if params[:cursor] and !params[:cursor].is_a?(String)
53
+ raise InvalidParameterError.new("Bad parameter: per_page must be an Integer") if params[:per_page] and !params[:per_page].is_a?(Integer)
54
+
55
+ List.new(PublicIpAddress, params) do
56
+ Api.send_request("/ip_addresses/exavault-reserved", :get, params, options)
57
+ end
58
+ end
59
+
48
60
  # Parameters:
49
61
  # cursor - string - Used for pagination. Send a cursor value to resume an existing list from the point at which you left off. Get a cursor from an existing list via either the X-Files-Cursor-Next header or the X-Files-Cursor-Prev header.
50
62
  # per_page - int64 - Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
@@ -396,6 +396,33 @@ module Files
396
396
  @attributes[:enable_dedicated_ips] = value
397
397
  end
398
398
 
399
+ # string - Local permissions for files agent. read_only, write_only, or read_write
400
+ def files_agent_permission_set
401
+ @attributes[:files_agent_permission_set]
402
+ end
403
+
404
+ def files_agent_permission_set=(value)
405
+ @attributes[:files_agent_permission_set] = value
406
+ end
407
+
408
+ # string - Agent local root path
409
+ def files_agent_root
410
+ @attributes[:files_agent_root]
411
+ end
412
+
413
+ def files_agent_root=(value)
414
+ @attributes[:files_agent_root] = value
415
+ end
416
+
417
+ # string - Files Agent API Token
418
+ def files_agent_api_token
419
+ @attributes[:files_agent_api_token]
420
+ end
421
+
422
+ def files_agent_api_token=(value)
423
+ @attributes[:files_agent_api_token] = value
424
+ end
425
+
399
426
  # string - AWS secret key.
400
427
  def aws_secret_key
401
428
  @attributes[:aws_secret_key]
@@ -522,6 +549,37 @@ module Files
522
549
  @attributes[:s3_compatible_secret_key] = value
523
550
  end
524
551
 
552
+ # Post local changes, check in, and download configuration file (used by some Remote Server integrations, such as the Files.com Agent)
553
+ #
554
+ # Parameters:
555
+ # api_token - string - Files Agent API Token
556
+ # permission_set - string -
557
+ # root - string - Agent local root path
558
+ # hostname - string
559
+ # port - int64 - Incoming port for files agent connections
560
+ # status - string - either running or shutdown
561
+ # config_version - string - agent config version
562
+ # private_key - string - private key
563
+ # public_key - string - public key
564
+ def configuration_file(params = {})
565
+ params ||= {}
566
+ params[:id] = @attributes[:id]
567
+ raise MissingParameterError.new("Current object doesn't have a id") unless @attributes[:id]
568
+ raise InvalidParameterError.new("Bad parameter: id must be an Integer") if params[:id] and !params[:id].is_a?(Integer)
569
+ raise InvalidParameterError.new("Bad parameter: api_token must be an String") if params[:api_token] and !params[:api_token].is_a?(String)
570
+ raise InvalidParameterError.new("Bad parameter: permission_set must be an String") if params[:permission_set] and !params[:permission_set].is_a?(String)
571
+ raise InvalidParameterError.new("Bad parameter: root must be an String") if params[:root] and !params[:root].is_a?(String)
572
+ raise InvalidParameterError.new("Bad parameter: hostname must be an String") if params[:hostname] and !params[:hostname].is_a?(String)
573
+ raise InvalidParameterError.new("Bad parameter: port must be an Integer") if params[:port] and !params[:port].is_a?(Integer)
574
+ raise InvalidParameterError.new("Bad parameter: status must be an String") if params[:status] and !params[:status].is_a?(String)
575
+ raise InvalidParameterError.new("Bad parameter: config_version must be an String") if params[:config_version] and !params[:config_version].is_a?(String)
576
+ raise InvalidParameterError.new("Bad parameter: private_key must be an String") if params[:private_key] and !params[:private_key].is_a?(String)
577
+ raise InvalidParameterError.new("Bad parameter: public_key must be an String") if params[:public_key] and !params[:public_key].is_a?(String)
578
+ raise MissingParameterError.new("Parameter missing: id") unless params[:id]
579
+
580
+ Api.send_request("/remote_servers/#{@attributes[:id]}/configuration_file", :post, params, @options)
581
+ end
582
+
525
583
  # Parameters:
526
584
  # aws_access_key - string - AWS Access Key.
527
585
  # aws_secret_key - string - AWS secret key.
@@ -572,6 +630,8 @@ module Files
572
630
  # enable_dedicated_ips - boolean - `true` if remote server only accepts connections from dedicated IPs
573
631
  # s3_compatible_access_key - string - S3-compatible Access Key.
574
632
  # s3_compatible_secret_key - string - S3-compatible secret key
633
+ # files_agent_root - string - Agent local root path
634
+ # files_agent_permission_set - string - Local permissions for files agent. read_only, write_only, or read_write
575
635
  def update(params = {})
576
636
  params ||= {}
577
637
  params[:id] = @attributes[:id]
@@ -623,6 +683,8 @@ module Files
623
683
  raise InvalidParameterError.new("Bad parameter: s3_compatible_region must be an String") if params[:s3_compatible_region] and !params[:s3_compatible_region].is_a?(String)
624
684
  raise InvalidParameterError.new("Bad parameter: s3_compatible_access_key must be an String") if params[:s3_compatible_access_key] and !params[:s3_compatible_access_key].is_a?(String)
625
685
  raise InvalidParameterError.new("Bad parameter: s3_compatible_secret_key must be an String") if params[:s3_compatible_secret_key] and !params[:s3_compatible_secret_key].is_a?(String)
686
+ raise InvalidParameterError.new("Bad parameter: files_agent_root must be an String") if params[:files_agent_root] and !params[:files_agent_root].is_a?(String)
687
+ raise InvalidParameterError.new("Bad parameter: files_agent_permission_set must be an String") if params[:files_agent_permission_set] and !params[:files_agent_permission_set].is_a?(String)
626
688
  raise MissingParameterError.new("Parameter missing: id") unless params[:id]
627
689
 
628
690
  Api.send_request("/remote_servers/#{@attributes[:id]}", :patch, params, @options)
@@ -683,6 +745,18 @@ module Files
683
745
  find(id, params, options)
684
746
  end
685
747
 
748
+ # Parameters:
749
+ # id (required) - int64 - Remote Server ID.
750
+ def self.find_configuration_file(id, params = {}, options = {})
751
+ params ||= {}
752
+ params[:id] = id
753
+ raise InvalidParameterError.new("Bad parameter: id must be an Integer") if params[:id] and !params[:id].is_a?(Integer)
754
+ raise MissingParameterError.new("Parameter missing: id") unless params[:id]
755
+
756
+ response, options = Api.send_request("/remote_servers/#{params[:id]}/configuration_file", :get, params, options)
757
+ RemoteServerConfigurationFile.new(response.data, options)
758
+ end
759
+
686
760
  # Parameters:
687
761
  # aws_access_key - string - AWS Access Key.
688
762
  # aws_secret_key - string - AWS secret key.
@@ -733,6 +807,8 @@ module Files
733
807
  # enable_dedicated_ips - boolean - `true` if remote server only accepts connections from dedicated IPs
734
808
  # s3_compatible_access_key - string - S3-compatible Access Key.
735
809
  # s3_compatible_secret_key - string - S3-compatible secret key
810
+ # files_agent_root - string - Agent local root path
811
+ # files_agent_permission_set - string - Local permissions for files agent. read_only, write_only, or read_write
736
812
  def self.create(params = {}, options = {})
737
813
  raise InvalidParameterError.new("Bad parameter: aws_access_key must be an String") if params[:aws_access_key] and !params[:aws_access_key].is_a?(String)
738
814
  raise InvalidParameterError.new("Bad parameter: aws_secret_key must be an String") if params[:aws_secret_key] and !params[:aws_secret_key].is_a?(String)
@@ -780,11 +856,44 @@ module Files
780
856
  raise InvalidParameterError.new("Bad parameter: s3_compatible_region must be an String") if params[:s3_compatible_region] and !params[:s3_compatible_region].is_a?(String)
781
857
  raise InvalidParameterError.new("Bad parameter: s3_compatible_access_key must be an String") if params[:s3_compatible_access_key] and !params[:s3_compatible_access_key].is_a?(String)
782
858
  raise InvalidParameterError.new("Bad parameter: s3_compatible_secret_key must be an String") if params[:s3_compatible_secret_key] and !params[:s3_compatible_secret_key].is_a?(String)
859
+ raise InvalidParameterError.new("Bad parameter: files_agent_root must be an String") if params[:files_agent_root] and !params[:files_agent_root].is_a?(String)
860
+ raise InvalidParameterError.new("Bad parameter: files_agent_permission_set must be an String") if params[:files_agent_permission_set] and !params[:files_agent_permission_set].is_a?(String)
783
861
 
784
862
  response, options = Api.send_request("/remote_servers", :post, params, options)
785
863
  RemoteServer.new(response.data, options)
786
864
  end
787
865
 
866
+ # Post local changes, check in, and download configuration file (used by some Remote Server integrations, such as the Files.com Agent)
867
+ #
868
+ # Parameters:
869
+ # api_token - string - Files Agent API Token
870
+ # permission_set - string -
871
+ # root - string - Agent local root path
872
+ # hostname - string
873
+ # port - int64 - Incoming port for files agent connections
874
+ # status - string - either running or shutdown
875
+ # config_version - string - agent config version
876
+ # private_key - string - private key
877
+ # public_key - string - public key
878
+ def self.configuration_file(id, params = {}, options = {})
879
+ params ||= {}
880
+ params[:id] = id
881
+ raise InvalidParameterError.new("Bad parameter: id must be an Integer") if params[:id] and !params[:id].is_a?(Integer)
882
+ raise InvalidParameterError.new("Bad parameter: api_token must be an String") if params[:api_token] and !params[:api_token].is_a?(String)
883
+ raise InvalidParameterError.new("Bad parameter: permission_set must be an String") if params[:permission_set] and !params[:permission_set].is_a?(String)
884
+ raise InvalidParameterError.new("Bad parameter: root must be an String") if params[:root] and !params[:root].is_a?(String)
885
+ raise InvalidParameterError.new("Bad parameter: hostname must be an String") if params[:hostname] and !params[:hostname].is_a?(String)
886
+ raise InvalidParameterError.new("Bad parameter: port must be an Integer") if params[:port] and !params[:port].is_a?(Integer)
887
+ raise InvalidParameterError.new("Bad parameter: status must be an String") if params[:status] and !params[:status].is_a?(String)
888
+ raise InvalidParameterError.new("Bad parameter: config_version must be an String") if params[:config_version] and !params[:config_version].is_a?(String)
889
+ raise InvalidParameterError.new("Bad parameter: private_key must be an String") if params[:private_key] and !params[:private_key].is_a?(String)
890
+ raise InvalidParameterError.new("Bad parameter: public_key must be an String") if params[:public_key] and !params[:public_key].is_a?(String)
891
+ raise MissingParameterError.new("Parameter missing: id") unless params[:id]
892
+
893
+ response, options = Api.send_request("/remote_servers/#{params[:id]}/configuration_file", :post, params, options)
894
+ RemoteServerConfigurationFile.new(response.data, options)
895
+ end
896
+
788
897
  # Parameters:
789
898
  # aws_access_key - string - AWS Access Key.
790
899
  # aws_secret_key - string - AWS secret key.
@@ -835,6 +944,8 @@ module Files
835
944
  # enable_dedicated_ips - boolean - `true` if remote server only accepts connections from dedicated IPs
836
945
  # s3_compatible_access_key - string - S3-compatible Access Key.
837
946
  # s3_compatible_secret_key - string - S3-compatible secret key
947
+ # files_agent_root - string - Agent local root path
948
+ # files_agent_permission_set - string - Local permissions for files agent. read_only, write_only, or read_write
838
949
  def self.update(id, params = {}, options = {})
839
950
  params ||= {}
840
951
  params[:id] = id
@@ -885,6 +996,8 @@ module Files
885
996
  raise InvalidParameterError.new("Bad parameter: s3_compatible_region must be an String") if params[:s3_compatible_region] and !params[:s3_compatible_region].is_a?(String)
886
997
  raise InvalidParameterError.new("Bad parameter: s3_compatible_access_key must be an String") if params[:s3_compatible_access_key] and !params[:s3_compatible_access_key].is_a?(String)
887
998
  raise InvalidParameterError.new("Bad parameter: s3_compatible_secret_key must be an String") if params[:s3_compatible_secret_key] and !params[:s3_compatible_secret_key].is_a?(String)
999
+ raise InvalidParameterError.new("Bad parameter: files_agent_root must be an String") if params[:files_agent_root] and !params[:files_agent_root].is_a?(String)
1000
+ raise InvalidParameterError.new("Bad parameter: files_agent_permission_set must be an String") if params[:files_agent_permission_set] and !params[:files_agent_permission_set].is_a?(String)
888
1001
  raise MissingParameterError.new("Parameter missing: id") unless params[:id]
889
1002
 
890
1003
  response, options = Api.send_request("/remote_servers/#{params[:id]}", :patch, params, options)
@@ -0,0 +1,62 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Files
4
+ class RemoteServerConfigurationFile
5
+ attr_reader :options, :attributes
6
+
7
+ def initialize(attributes = {}, options = {})
8
+ @attributes = attributes || {}
9
+ @options = options || {}
10
+ end
11
+
12
+ # int64 - Agent ID
13
+ def id
14
+ @attributes[:id]
15
+ end
16
+
17
+ # string -
18
+ def permission_set
19
+ @attributes[:permission_set]
20
+ end
21
+
22
+ # string - Files Agent API Token
23
+ def api_token
24
+ @attributes[:api_token]
25
+ end
26
+
27
+ # string - Agent local root path
28
+ def root
29
+ @attributes[:root]
30
+ end
31
+
32
+ # int64 - Incoming port for files agent connections
33
+ def port
34
+ @attributes[:port]
35
+ end
36
+
37
+ # string
38
+ def hostname
39
+ @attributes[:hostname]
40
+ end
41
+
42
+ # string - public key
43
+ def public_key
44
+ @attributes[:public_key]
45
+ end
46
+
47
+ # string - private key
48
+ def private_key
49
+ @attributes[:private_key]
50
+ end
51
+
52
+ # string - either running or shutdown
53
+ def status
54
+ @attributes[:status]
55
+ end
56
+
57
+ # string - agent config version
58
+ def config_version
59
+ @attributes[:config_version]
60
+ end
61
+ end
62
+ end
@@ -79,6 +79,11 @@ module Files
79
79
  @attributes[:bundle_password_required]
80
80
  end
81
81
 
82
+ # string - Do Bundle owners receive registration notification?
83
+ def bundle_registration_notifications
84
+ @attributes[:bundle_registration_notifications]
85
+ end
86
+
82
87
  # boolean - Do Bundles require recipients for sharing?
83
88
  def bundle_require_share_recipient
84
89
  @attributes[:bundle_require_share_recipient]
@@ -765,6 +770,7 @@ module Files
765
770
  # session_pinned_by_ip - boolean - Are sessions locked to the same IP? (i.e. do users need to log in again if they change IPs?)
766
771
  # bundle_password_required - boolean - Do Bundles require password protection?
767
772
  # bundle_require_share_recipient - boolean - Do Bundles require recipients for sharing?
773
+ # bundle_registration_notifications - string - Do Bundle owners receive registration notification?
768
774
  # 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?
769
775
  # opt_out_global - boolean - Use servers in the USA only?
770
776
  # use_provided_modified_at - boolean - Allow uploaders to set `provided_modified_at` for uploaded files?
@@ -861,6 +867,7 @@ module Files
861
867
  raise InvalidParameterError.new("Bad parameter: max_prior_passwords must be an Integer") if params[:max_prior_passwords] and !params[:max_prior_passwords].is_a?(Integer)
862
868
  raise InvalidParameterError.new("Bad parameter: password_validity_days must be an Integer") if params[:password_validity_days] and !params[:password_validity_days].is_a?(Integer)
863
869
  raise InvalidParameterError.new("Bad parameter: password_min_length must be an Integer") if params[:password_min_length] and !params[:password_min_length].is_a?(Integer)
870
+ raise InvalidParameterError.new("Bad parameter: bundle_registration_notifications must be an String") if params[:bundle_registration_notifications] and !params[:bundle_registration_notifications].is_a?(String)
864
871
  raise InvalidParameterError.new("Bad parameter: disable_users_from_inactivity_period_days must be an Integer") if params[:disable_users_from_inactivity_period_days] and !params[:disable_users_from_inactivity_period_days].is_a?(Integer)
865
872
  raise InvalidParameterError.new("Bad parameter: sftp_host_key_type must be an String") if params[:sftp_host_key_type] and !params[:sftp_host_key_type].is_a?(String)
866
873
  raise InvalidParameterError.new("Bad parameter: active_sftp_host_key_id must be an Integer") if params[:active_sftp_host_key_id] and !params[:active_sftp_host_key_id].is_a?(Integer)
data/lib/files.com.rb CHANGED
@@ -92,6 +92,7 @@ require "files.com/models/public_ip_address"
92
92
  require "files.com/models/public_key"
93
93
  require "files.com/models/remote_bandwidth_snapshot"
94
94
  require "files.com/models/remote_server"
95
+ require "files.com/models/remote_server_configuration_file"
95
96
  require "files.com/models/request"
96
97
  require "files.com/models/session"
97
98
  require "files.com/models/settings_change"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: files.com
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.302
4
+ version: 1.0.304
5
5
  platform: ruby
6
6
  authors:
7
7
  - files.com
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-10-26 00:00:00.000000000 Z
11
+ date: 2022-11-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: addressable
@@ -176,6 +176,7 @@ files:
176
176
  - docs/public_key.md
177
177
  - docs/remote_bandwidth_snapshot.md
178
178
  - docs/remote_server.md
179
+ - docs/remote_server_configuration_file.md
179
180
  - docs/request.md
180
181
  - docs/session.md
181
182
  - docs/settings_change.md
@@ -259,6 +260,7 @@ files:
259
260
  - lib/files.com/models/public_key.rb
260
261
  - lib/files.com/models/remote_bandwidth_snapshot.rb
261
262
  - lib/files.com/models/remote_server.rb
263
+ - lib/files.com/models/remote_server_configuration_file.rb
262
264
  - lib/files.com/models/request.rb
263
265
  - lib/files.com/models/session.rb
264
266
  - lib/files.com/models/settings_change.rb