files.com 1.0.121 → 1.0.126

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 (81) hide show
  1. checksums.yaml +4 -4
  2. data/_VERSION +1 -1
  3. data/docs/api_key.md +1 -4
  4. data/docs/app.md +1 -4
  5. data/docs/as2_key.md +1 -4
  6. data/docs/automation.md +38 -16
  7. data/docs/bandwidth_snapshot.md +1 -4
  8. data/docs/behavior.md +2 -8
  9. data/docs/bundle.md +11 -6
  10. data/docs/bundle_download.md +1 -4
  11. data/docs/bundle_recipient.md +1 -4
  12. data/docs/clickwrap.md +3 -5
  13. data/docs/dns_record.md +1 -4
  14. data/docs/external_event.md +1 -4
  15. data/docs/file_comment.md +1 -4
  16. data/docs/folder.md +1 -4
  17. data/docs/group.md +1 -4
  18. data/docs/group_user.md +1 -4
  19. data/docs/history.md +10 -30
  20. data/docs/history_export_result.md +1 -5
  21. data/docs/invoice.md +1 -4
  22. data/docs/ip_address.md +2 -8
  23. data/docs/lock.md +1 -4
  24. data/docs/message.md +1 -4
  25. data/docs/message_comment.md +1 -4
  26. data/docs/message_comment_reaction.md +1 -4
  27. data/docs/message_reaction.md +1 -4
  28. data/docs/notification.md +1 -4
  29. data/docs/payment.md +1 -4
  30. data/docs/permission.md +1 -4
  31. data/docs/project.md +1 -4
  32. data/docs/public_key.md +1 -4
  33. data/docs/remote_server.md +56 -4
  34. data/docs/request.md +2 -8
  35. data/docs/settings_change.md +1 -4
  36. data/docs/sso_strategy.md +5 -4
  37. data/docs/usage_daily_snapshot.md +1 -4
  38. data/docs/usage_snapshot.md +1 -4
  39. data/docs/user.md +1 -4
  40. data/docs/user_cipher_use.md +1 -4
  41. data/docs/user_request.md +1 -4
  42. data/lib/files.com/models/api_key.rb +2 -6
  43. data/lib/files.com/models/app.rb +2 -6
  44. data/lib/files.com/models/as2_key.rb +2 -6
  45. data/lib/files.com/models/automation.rb +52 -36
  46. data/lib/files.com/models/bandwidth_snapshot.rb +2 -6
  47. data/lib/files.com/models/behavior.rb +4 -12
  48. data/lib/files.com/models/bundle.rb +10 -6
  49. data/lib/files.com/models/bundle_download.rb +2 -6
  50. data/lib/files.com/models/bundle_recipient.rb +2 -6
  51. data/lib/files.com/models/clickwrap.rb +11 -15
  52. data/lib/files.com/models/dns_record.rb +2 -6
  53. data/lib/files.com/models/external_event.rb +2 -6
  54. data/lib/files.com/models/file_comment.rb +2 -6
  55. data/lib/files.com/models/folder.rb +2 -6
  56. data/lib/files.com/models/group.rb +2 -6
  57. data/lib/files.com/models/group_user.rb +2 -6
  58. data/lib/files.com/models/history.rb +10 -30
  59. data/lib/files.com/models/history_export_result.rb +2 -6
  60. data/lib/files.com/models/invoice.rb +2 -6
  61. data/lib/files.com/models/ip_address.rb +4 -12
  62. data/lib/files.com/models/lock.rb +2 -6
  63. data/lib/files.com/models/message.rb +2 -6
  64. data/lib/files.com/models/message_comment.rb +2 -6
  65. data/lib/files.com/models/message_comment_reaction.rb +2 -6
  66. data/lib/files.com/models/message_reaction.rb +2 -6
  67. data/lib/files.com/models/notification.rb +2 -6
  68. data/lib/files.com/models/payment.rb +2 -6
  69. data/lib/files.com/models/permission.rb +2 -6
  70. data/lib/files.com/models/project.rb +2 -6
  71. data/lib/files.com/models/public_key.rb +2 -6
  72. data/lib/files.com/models/remote_server.rb +84 -6
  73. data/lib/files.com/models/request.rb +4 -12
  74. data/lib/files.com/models/settings_change.rb +2 -6
  75. data/lib/files.com/models/sso_strategy.rb +12 -6
  76. data/lib/files.com/models/usage_daily_snapshot.rb +2 -6
  77. data/lib/files.com/models/usage_snapshot.rb +2 -6
  78. data/lib/files.com/models/user.rb +2 -6
  79. data/lib/files.com/models/user_cipher_use.rb +2 -6
  80. data/lib/files.com/models/user_request.rb +2 -6
  81. metadata +2 -2
@@ -26,7 +26,6 @@
26
26
  ```
27
27
  Files::PublicKey.list(
28
28
  user_id: 1,
29
- page: 1,
30
29
  per_page: 1
31
30
  )
32
31
  ```
@@ -34,10 +33,8 @@ Files::PublicKey.list(
34
33
  ### Parameters
35
34
 
36
35
  * `user_id` (int64): User ID. Provide a value of `0` to operate the current session's user.
37
- * `page` (int64): Current page number.
36
+ * `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 the X-Files-Cursor-Next header.
38
37
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
39
- * `action` (string): Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
40
- * `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.
41
38
 
42
39
 
43
40
  ---
@@ -84,17 +84,14 @@
84
84
 
85
85
  ```
86
86
  Files::RemoteServer.list(
87
- page: 1,
88
87
  per_page: 1
89
88
  )
90
89
  ```
91
90
 
92
91
  ### Parameters
93
92
 
94
- * `page` (int64): Current page number.
93
+ * `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 the X-Files-Cursor-Next header.
95
94
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
96
- * `action` (string): Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
97
- * `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.
98
95
 
99
96
 
100
97
  ---
@@ -110,6 +107,61 @@ Files::RemoteServer.find(id)
110
107
  * `id` (int64): Required - Remote Server ID.
111
108
 
112
109
 
110
+ ---
111
+
112
+ ## list_for_testing Remote Server
113
+
114
+ ```
115
+ Files::RemoteServer.list_for_testing(
116
+ remote_server_id: 1,
117
+ reset_authentication: true,
118
+ max_connections: 1,
119
+ port: 1
120
+ )
121
+ ```
122
+
123
+ ### Parameters
124
+
125
+ * `remote_server_id` (int64): RemoteServer ID
126
+ * `root` (string): Remote path to list
127
+ * `aws_access_key` (string): AWS Access Key.
128
+ * `aws_secret_key` (string): AWS secret key.
129
+ * `password` (string): Password if needed.
130
+ * `private_key` (string): Private key if needed.
131
+ * `ssl_certificate` (string): SSL client certificate.
132
+ * `google_cloud_storage_credentials_json` (string): A JSON file that contains the private key. To generate see https://cloud.google.com/storage/docs/json_api/v1/how-tos/authorizing#APIKey
133
+ * `wasabi_access_key` (string): Wasabi access key.
134
+ * `wasabi_secret_key` (string): Wasabi secret key.
135
+ * `backblaze_b2_key_id` (string): Backblaze B2 Cloud Storage keyID.
136
+ * `backblaze_b2_application_key` (string): Backblaze B2 Cloud Storage applicationKey.
137
+ * `rackspace_api_key` (string): Rackspace API key from the Rackspace Cloud Control Panel.
138
+ * `reset_authentication` (boolean): Reset authenticated account
139
+ * `azure_blob_storage_access_key` (string): Azure Blob Storage secret key.
140
+ * `hostname` (string):
141
+ * `name` (string):
142
+ * `max_connections` (int64):
143
+ * `port` (int64):
144
+ * `s3_bucket` (string):
145
+ * `s3_region` (string):
146
+ * `server_certificate` (string):
147
+ * `server_host_key` (string):
148
+ * `server_type` (string):
149
+ * `ssl` (string):
150
+ * `username` (string):
151
+ * `google_cloud_storage_bucket` (string):
152
+ * `google_cloud_storage_project_id` (string):
153
+ * `backblaze_b2_bucket` (string):
154
+ * `backblaze_b2_s3_endpoint` (string):
155
+ * `wasabi_bucket` (string):
156
+ * `wasabi_region` (string):
157
+ * `rackspace_username` (string):
158
+ * `rackspace_region` (string):
159
+ * `rackspace_container` (string):
160
+ * `one_drive_account_type` (string):
161
+ * `azure_blob_storage_account` (string):
162
+ * `azure_blob_storage_container` (string):
163
+
164
+
113
165
  ---
114
166
 
115
167
  ## Create Remote Server
@@ -29,7 +29,6 @@
29
29
 
30
30
  ```
31
31
  Files::Request.list(
32
- page: 1,
33
32
  per_page: 1,
34
33
  mine: true
35
34
  )
@@ -37,10 +36,8 @@ Files::Request.list(
37
36
 
38
37
  ### Parameters
39
38
 
40
- * `page` (int64): Current page number.
39
+ * `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 the X-Files-Cursor-Next header.
41
40
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
42
- * `action` (string): Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
43
- * `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.
44
41
  * `sort_by` (object): If set, sort records by the specified field in either 'asc' or 'desc' direction (e.g. sort_by[last_login_at]=desc). Valid fields are `site_id`, `folder_id` or `destination`.
45
42
  * `mine` (boolean): Only show requests of the current user? (Defaults to true if current user is not a site admin.)
46
43
  * `path` (string): Path to show requests for. If omitted, shows all paths. Send `/` to represent the root directory.
@@ -52,7 +49,6 @@ Files::Request.list(
52
49
 
53
50
  ```
54
51
  Files::Request.get_folder(path,
55
- page: 1,
56
52
  per_page: 1,
57
53
  mine: true
58
54
  )
@@ -60,10 +56,8 @@ Files::Request.get_folder(path,
60
56
 
61
57
  ### Parameters
62
58
 
63
- * `page` (int64): Current page number.
59
+ * `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 the X-Files-Cursor-Next header.
64
60
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
65
- * `action` (string): Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
66
- * `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.
67
61
  * `sort_by` (object): If set, sort records by the specified field in either 'asc' or 'desc' direction (e.g. sort_by[last_login_at]=desc). Valid fields are `site_id`, `folder_id` or `destination`.
68
62
  * `mine` (boolean): Only show requests of the current user? (Defaults to true if current user is not a site admin.)
69
63
  * `path` (string): Required - Path to show requests for. If omitted, shows all paths. Send `/` to represent the root directory.
@@ -21,17 +21,14 @@
21
21
 
22
22
  ```
23
23
  Files::SettingsChange.list(
24
- page: 1,
25
24
  per_page: 1
26
25
  )
27
26
  ```
28
27
 
29
28
  ### Parameters
30
29
 
31
- * `page` (int64): Current page number.
30
+ * `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 the X-Files-Cursor-Next header.
32
31
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
33
- * `action` (string): Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
34
- * `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.
35
32
  * `sort_by` (object): If set, sort records by the specified field in either 'asc' or 'desc' direction (e.g. sort_by[last_login_at]=desc). Valid fields are `site_id`, `api_key_id`, `created_at` or `user_id`.
36
33
  * `filter` (object): If set, return records where the specifiied field is equal to the supplied value. Valid fields are `api_key_id` and `user_id`.
37
34
  * `filter_gt` (object): If set, return records where the specifiied field is greater than the supplied value. Valid fields are `api_key_id` and `user_id`.
@@ -19,6 +19,8 @@
19
19
  "saml_provider_sso_target_url": "",
20
20
  "scim_authentication_method": "",
21
21
  "scim_username": "",
22
+ "scim_oauth_access_token": "",
23
+ "scim_oauth_access_token_expires_at": "",
22
24
  "subdomain": "my-site",
23
25
  "provision_users": true,
24
26
  "provision_groups": true,
@@ -62,6 +64,8 @@
62
64
  * `saml_provider_sso_target_url` (string): Identity provider SSO endpoint if saml_provider_metadata_url is not available.
63
65
  * `scim_authentication_method` (string): SCIM authentication type.
64
66
  * `scim_username` (string): SCIM username.
67
+ * `scim_oauth_access_token` (string): SCIM OAuth Access Token.
68
+ * `scim_oauth_access_token_expires_at` (string): SCIM OAuth Access Token Expiration Time.
65
69
  * `subdomain` (string): Subdomain
66
70
  * `provision_users` (boolean): Auto-provision users?
67
71
  * `provision_groups` (boolean): Auto-provision group membership based on group memberships on the SSO side?
@@ -97,17 +101,14 @@
97
101
 
98
102
  ```
99
103
  Files::SsoStrategy.list(
100
- page: 1,
101
104
  per_page: 1
102
105
  )
103
106
  ```
104
107
 
105
108
  ### Parameters
106
109
 
107
- * `page` (int64): Current page number.
110
+ * `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 the X-Files-Cursor-Next header.
108
111
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
109
- * `action` (string): Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
110
- * `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.
111
112
 
112
113
 
113
114
  ---
@@ -25,17 +25,14 @@
25
25
 
26
26
  ```
27
27
  Files::UsageDailySnapshot.list(
28
- page: 1,
29
28
  per_page: 1
30
29
  )
31
30
  ```
32
31
 
33
32
  ### Parameters
34
33
 
35
- * `page` (int64): Current page number.
34
+ * `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 the X-Files-Cursor-Next header.
36
35
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
37
- * `action` (string): Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
38
- * `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.
39
36
  * `sort_by` (object): If set, sort records by the specified field in either 'asc' or 'desc' direction (e.g. sort_by[last_login_at]=desc). Valid fields are `site_id`, `date` or `usage_snapshot_id`.
40
37
  * `filter` (object): If set, return records where the specifiied field is equal to the supplied value. Valid fields are `date` and `usage_snapshot_id`.
41
38
  * `filter_gt` (object): If set, return records where the specifiied field is greater than the supplied value. Valid fields are `date` and `usage_snapshot_id`.
@@ -41,14 +41,11 @@
41
41
 
42
42
  ```
43
43
  Files::UsageSnapshot.list(
44
- page: 1,
45
44
  per_page: 1
46
45
  )
47
46
  ```
48
47
 
49
48
  ### Parameters
50
49
 
51
- * `page` (int64): Current page number.
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 the X-Files-Cursor-Next header.
52
51
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
53
- * `action` (string): Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
54
- * `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.
@@ -120,17 +120,14 @@
120
120
 
121
121
  ```
122
122
  Files::User.list(
123
- page: 1,
124
123
  per_page: 1
125
124
  )
126
125
  ```
127
126
 
128
127
  ### Parameters
129
128
 
130
- * `page` (int64): Current page number.
129
+ * `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 the X-Files-Cursor-Next header.
131
130
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
132
- * `action` (string): Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
133
- * `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.
134
131
  * `sort_by` (object): If set, sort records by the specified field in either 'asc' or 'desc' direction (e.g. sort_by[last_login_at]=desc). Valid fields are `active`, `master_admin`, `site_id`, `authenticate_until`, `email`, `last_desktop_login_at`, `last_login_at`, `username`, `company`, `name`, `notes`, `site_admin`, `receive_admin_alerts`, `allowed_ips`, `password_validity_days`, `ssl_required` or `not_site_admin`.
135
132
  * `filter` (object): If set, return records where the specifiied field is equal to the supplied value. Valid fields are `username`, `email`, `company`, `notes`, `site_admin`, `allowed_ips`, `password_validity_days`, `ssl_required`, `last_login_at`, `authenticate_until` or `not_site_admin`.
136
133
  * `filter_gt` (object): If set, return records where the specifiied field is greater than the supplied value. Valid fields are `username`, `email`, `company`, `notes`, `site_admin`, `allowed_ips`, `password_validity_days`, `ssl_required`, `last_login_at`, `authenticate_until` or `not_site_admin`.
@@ -28,7 +28,6 @@
28
28
  ```
29
29
  Files::UserCipherUse.list(
30
30
  user_id: 1,
31
- page: 1,
32
31
  per_page: 1
33
32
  )
34
33
  ```
@@ -36,7 +35,5 @@ Files::UserCipherUse.list(
36
35
  ### Parameters
37
36
 
38
37
  * `user_id` (int64): User ID. Provide a value of `0` to operate the current session's user.
39
- * `page` (int64): Current page number.
38
+ * `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 the X-Files-Cursor-Next header.
40
39
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
41
- * `action` (string): Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
42
- * `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.
@@ -23,17 +23,14 @@
23
23
 
24
24
  ```
25
25
  Files::UserRequest.list(
26
- page: 1,
27
26
  per_page: 1
28
27
  )
29
28
  ```
30
29
 
31
30
  ### Parameters
32
31
 
33
- * `page` (int64): Current page number.
32
+ * `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 the X-Files-Cursor-Next header.
34
33
  * `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
35
- * `action` (string): Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
36
- * `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.
37
34
 
38
35
 
39
36
  ---
@@ -146,10 +146,8 @@ module Files
146
146
 
147
147
  # Parameters:
148
148
  # user_id - int64 - User ID. Provide a value of `0` to operate the current session's user.
149
- # page - int64 - Current page number.
149
+ # 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 the X-Files-Cursor-Next header.
150
150
  # per_page - int64 - Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
151
- # action - string - Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
152
- # 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.
153
151
  # sort_by - object - If set, sort records by the specified field in either 'asc' or 'desc' direction (e.g. sort_by[last_login_at]=desc). Valid fields are `deleted_at` and `expires_at`.
154
152
  # filter - object - If set, return records where the specifiied field is equal to the supplied value. Valid fields are `expires_at`.
155
153
  # filter_gt - object - If set, return records where the specifiied field is greater than the supplied value. Valid fields are `expires_at`.
@@ -159,10 +157,8 @@ module Files
159
157
  # filter_lteq - object - If set, return records where the specifiied field is less than or equal to the supplied value. Valid fields are `expires_at`.
160
158
  def self.list(params = {}, options = {})
161
159
  raise InvalidParameterError.new("Bad parameter: user_id must be an Integer") if params.dig(:user_id) and !params.dig(:user_id).is_a?(Integer)
162
- raise InvalidParameterError.new("Bad parameter: page must be an Integer") if params.dig(:page) and !params.dig(:page).is_a?(Integer)
163
- raise InvalidParameterError.new("Bad parameter: per_page must be an Integer") if params.dig(:per_page) and !params.dig(:per_page).is_a?(Integer)
164
- raise InvalidParameterError.new("Bad parameter: action must be an String") if params.dig(:action) and !params.dig(:action).is_a?(String)
165
160
  raise InvalidParameterError.new("Bad parameter: cursor must be an String") if params.dig(:cursor) and !params.dig(:cursor).is_a?(String)
161
+ raise InvalidParameterError.new("Bad parameter: per_page must be an Integer") if params.dig(:per_page) and !params.dig(:per_page).is_a?(Integer)
166
162
  raise InvalidParameterError.new("Bad parameter: sort_by must be an Hash") if params.dig(:sort_by) and !params.dig(:sort_by).is_a?(Hash)
167
163
  raise InvalidParameterError.new("Bad parameter: filter must be an Hash") if params.dig(:filter) and !params.dig(:filter).is_a?(Hash)
168
164
  raise InvalidParameterError.new("Bad parameter: filter_gt must be an Hash") if params.dig(:filter_gt) and !params.dig(:filter_gt).is_a?(Hash)
@@ -75,10 +75,8 @@ module Files
75
75
  end
76
76
 
77
77
  # Parameters:
78
- # page - int64 - Current page number.
78
+ # 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 the X-Files-Cursor-Next header.
79
79
  # per_page - int64 - Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
80
- # action - string - Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
81
- # 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.
82
80
  # sort_by - object - If set, sort records by the specified field in either 'asc' or 'desc' direction (e.g. sort_by[last_login_at]=desc). Valid fields are `name` and `app_type`.
83
81
  # filter - object - If set, return records where the specifiied field is equal to the supplied value. Valid fields are `name` and `app_type`.
84
82
  # filter_gt - object - If set, return records where the specifiied field is greater than the supplied value. Valid fields are `name` and `app_type`.
@@ -87,10 +85,8 @@ module Files
87
85
  # filter_lt - object - If set, return records where the specifiied field is less than the supplied value. Valid fields are `name` and `app_type`.
88
86
  # filter_lteq - object - If set, return records where the specifiied field is less than or equal to the supplied value. Valid fields are `name` and `app_type`.
89
87
  def self.list(params = {}, options = {})
90
- raise InvalidParameterError.new("Bad parameter: page must be an Integer") if params.dig(:page) and !params.dig(:page).is_a?(Integer)
91
- raise InvalidParameterError.new("Bad parameter: per_page must be an Integer") if params.dig(:per_page) and !params.dig(:per_page).is_a?(Integer)
92
- raise InvalidParameterError.new("Bad parameter: action must be an String") if params.dig(:action) and !params.dig(:action).is_a?(String)
93
88
  raise InvalidParameterError.new("Bad parameter: cursor must be an String") if params.dig(:cursor) and !params.dig(:cursor).is_a?(String)
89
+ raise InvalidParameterError.new("Bad parameter: per_page must be an Integer") if params.dig(:per_page) and !params.dig(:per_page).is_a?(Integer)
94
90
  raise InvalidParameterError.new("Bad parameter: sort_by must be an Hash") if params.dig(:sort_by) and !params.dig(:sort_by).is_a?(Hash)
95
91
  raise InvalidParameterError.new("Bad parameter: filter must be an Hash") if params.dig(:filter) and !params.dig(:filter).is_a?(Hash)
96
92
  raise InvalidParameterError.new("Bad parameter: filter_gt must be an Hash") if params.dig(:filter_gt) and !params.dig(:filter_gt).is_a?(Hash)
@@ -98,16 +98,12 @@ module Files
98
98
 
99
99
  # Parameters:
100
100
  # user_id - int64 - User ID. Provide a value of `0` to operate the current session's user.
101
- # page - int64 - Current page number.
101
+ # 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 the X-Files-Cursor-Next header.
102
102
  # per_page - int64 - Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
103
- # action - string - Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
104
- # 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.
105
103
  def self.list(params = {}, options = {})
106
104
  raise InvalidParameterError.new("Bad parameter: user_id must be an Integer") if params.dig(:user_id) and !params.dig(:user_id).is_a?(Integer)
107
- raise InvalidParameterError.new("Bad parameter: page must be an Integer") if params.dig(:page) and !params.dig(:page).is_a?(Integer)
108
- raise InvalidParameterError.new("Bad parameter: per_page must be an Integer") if params.dig(:per_page) and !params.dig(:per_page).is_a?(Integer)
109
- raise InvalidParameterError.new("Bad parameter: action must be an String") if params.dig(:action) and !params.dig(:action).is_a?(String)
110
105
  raise InvalidParameterError.new("Bad parameter: cursor must be an String") if params.dig(:cursor) and !params.dig(:cursor).is_a?(String)
106
+ raise InvalidParameterError.new("Bad parameter: per_page must be an Integer") if params.dig(:per_page) and !params.dig(:per_page).is_a?(Integer)
111
107
 
112
108
  List.new(As2Key, params) do
113
109
  Api.send_request("/as2_keys", :get, params, options)
@@ -27,6 +27,42 @@ module Files
27
27
  @attributes[:automation] = value
28
28
  end
29
29
 
30
+ # string - How this automation is triggered to run. One of: `realtime` or `custom_schedule`.
31
+ def trigger
32
+ @attributes[:trigger]
33
+ end
34
+
35
+ def trigger=(value)
36
+ @attributes[:trigger] = value
37
+ end
38
+
39
+ # string - If trigger is `daily`, this specifies how often to run this automation. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
40
+ def interval
41
+ @attributes[:interval]
42
+ end
43
+
44
+ def interval=(value)
45
+ @attributes[:interval] = value
46
+ end
47
+
48
+ # string - If trigger is `daily`, date this automation will next run.
49
+ def next_process_on
50
+ @attributes[:next_process_on]
51
+ end
52
+
53
+ def next_process_on=(value)
54
+ @attributes[:next_process_on] = value
55
+ end
56
+
57
+ # object - If trigger is `custom_schedule`, Custom schedule description for when the automation should be run.
58
+ def schedule
59
+ @attributes[:schedule]
60
+ end
61
+
62
+ def schedule=(value)
63
+ @attributes[:schedule] = value
64
+ end
65
+
30
66
  # string - Source Path
31
67
  def source
32
68
  @attributes[:source]
@@ -63,24 +99,6 @@ module Files
63
99
  @attributes[:destination_replace_to] = value
64
100
  end
65
101
 
66
- # string - How often to run this automation? One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
67
- def interval
68
- @attributes[:interval]
69
- end
70
-
71
- def interval=(value)
72
- @attributes[:interval] = value
73
- end
74
-
75
- # string - Date this automation will next run.
76
- def next_process_on
77
- @attributes[:next_process_on]
78
- end
79
-
80
- def next_process_on=(value)
81
- @attributes[:next_process_on] = value
82
- end
83
-
84
102
  # string - Path on which this Automation runs. Supports globs. This must be slash-delimited, but it must neither start nor end with a slash. Maximum of 5000 characters.
85
103
  def path
86
104
  @attributes[:path]
@@ -90,15 +108,6 @@ module Files
90
108
  @attributes[:path] = value
91
109
  end
92
110
 
93
- # boolean - Does this automation run in real time? This is a read-only property based on automation type.
94
- def realtime
95
- @attributes[:realtime]
96
- end
97
-
98
- def realtime=(value)
99
- @attributes[:realtime] = value
100
- end
101
-
102
111
  # int64 - User ID of the Automation's creator.
103
112
  def user_id
104
113
  @attributes[:user_id]
@@ -127,7 +136,7 @@ module Files
127
136
  end
128
137
 
129
138
  # Parameters:
130
- # automation (required) - string - Type of automation. One of: `create_folder`, `request_file`, `request_move`
139
+ # automation (required) - string - Automation type
131
140
  # source - string - Source Path
132
141
  # destination - string - Destination Path
133
142
  # destination_replace_from - string - If set, this string in the destination path will be replaced with the value in `destination_replace_to`.
@@ -136,6 +145,8 @@ module Files
136
145
  # path - string - Path on which this Automation runs. Supports globs.
137
146
  # user_ids - string - A list of user IDs the automation is associated with. If sent as a string, it should be comma-delimited.
138
147
  # group_ids - string - A list of group IDs the automation is associated with. If sent as a string, it should be comma-delimited.
148
+ # schedule - object - Custom schedule for running this automation.
149
+ # trigger - string - How this automation is triggered to run. One of: `realtime` or `custom_schedule`.
139
150
  def update(params = {})
140
151
  params ||= {}
141
152
  params[:id] = @attributes[:id]
@@ -150,6 +161,7 @@ module Files
150
161
  raise InvalidParameterError.new("Bad parameter: path must be an String") if params.dig(:path) and !params.dig(:path).is_a?(String)
151
162
  raise InvalidParameterError.new("Bad parameter: user_ids must be an String") if params.dig(:user_ids) and !params.dig(:user_ids).is_a?(String)
152
163
  raise InvalidParameterError.new("Bad parameter: group_ids must be an String") if params.dig(:group_ids) and !params.dig(:group_ids).is_a?(String)
164
+ raise InvalidParameterError.new("Bad parameter: trigger must be an String") if params.dig(:trigger) and !params.dig(:trigger).is_a?(String)
153
165
  raise MissingParameterError.new("Parameter missing: id") unless params.dig(:id)
154
166
  raise MissingParameterError.new("Parameter missing: automation") unless params.dig(:automation)
155
167
 
@@ -180,10 +192,8 @@ module Files
180
192
  end
181
193
 
182
194
  # Parameters:
183
- # page - int64 - Current page number.
195
+ # 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 the X-Files-Cursor-Next header.
184
196
  # per_page - int64 - Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
185
- # action - string - Deprecated: If set to `count` returns a count of matching records rather than the records themselves.
186
- # 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.
187
197
  # sort_by - object - If set, sort records by the specified field in either 'asc' or 'desc' direction (e.g. sort_by[last_login_at]=desc). Valid fields are `site_id` and `automation`.
188
198
  # filter - object - If set, return records where the specifiied field is equal to the supplied value. Valid fields are `automation`.
189
199
  # filter_gt - object - If set, return records where the specifiied field is greater than the supplied value. Valid fields are `automation`.
@@ -193,10 +203,8 @@ module Files
193
203
  # filter_lteq - object - If set, return records where the specifiied field is less than or equal to the supplied value. Valid fields are `automation`.
194
204
  # automation - string - DEPRECATED: Type of automation to filter by. Use `filter[automation]` instead.
195
205
  def self.list(params = {}, options = {})
196
- raise InvalidParameterError.new("Bad parameter: page must be an Integer") if params.dig(:page) and !params.dig(:page).is_a?(Integer)
197
- raise InvalidParameterError.new("Bad parameter: per_page must be an Integer") if params.dig(:per_page) and !params.dig(:per_page).is_a?(Integer)
198
- raise InvalidParameterError.new("Bad parameter: action must be an String") if params.dig(:action) and !params.dig(:action).is_a?(String)
199
206
  raise InvalidParameterError.new("Bad parameter: cursor must be an String") if params.dig(:cursor) and !params.dig(:cursor).is_a?(String)
207
+ raise InvalidParameterError.new("Bad parameter: per_page must be an Integer") if params.dig(:per_page) and !params.dig(:per_page).is_a?(Integer)
200
208
  raise InvalidParameterError.new("Bad parameter: sort_by must be an Hash") if params.dig(:sort_by) and !params.dig(:sort_by).is_a?(Hash)
201
209
  raise InvalidParameterError.new("Bad parameter: filter must be an Hash") if params.dig(:filter) and !params.dig(:filter).is_a?(Hash)
202
210
  raise InvalidParameterError.new("Bad parameter: filter_gt must be an Hash") if params.dig(:filter_gt) and !params.dig(:filter_gt).is_a?(Hash)
@@ -232,7 +240,7 @@ module Files
232
240
  end
233
241
 
234
242
  # Parameters:
235
- # automation (required) - string - Type of automation. One of: `create_folder`, `request_file`, `request_move`
243
+ # automation (required) - string - Automation type
236
244
  # source - string - Source Path
237
245
  # destination - string - Destination Path
238
246
  # destination_replace_from - string - If set, this string in the destination path will be replaced with the value in `destination_replace_to`.
@@ -241,6 +249,8 @@ module Files
241
249
  # path - string - Path on which this Automation runs. Supports globs.
242
250
  # user_ids - string - A list of user IDs the automation is associated with. If sent as a string, it should be comma-delimited.
243
251
  # group_ids - string - A list of group IDs the automation is associated with. If sent as a string, it should be comma-delimited.
252
+ # schedule - object - Custom schedule for running this automation.
253
+ # trigger - string - How this automation is triggered to run. One of: `realtime` or `custom_schedule`.
244
254
  def self.create(params = {}, options = {})
245
255
  raise InvalidParameterError.new("Bad parameter: automation must be an String") if params.dig(:automation) and !params.dig(:automation).is_a?(String)
246
256
  raise InvalidParameterError.new("Bad parameter: source must be an String") if params.dig(:source) and !params.dig(:source).is_a?(String)
@@ -251,6 +261,8 @@ module Files
251
261
  raise InvalidParameterError.new("Bad parameter: path must be an String") if params.dig(:path) and !params.dig(:path).is_a?(String)
252
262
  raise InvalidParameterError.new("Bad parameter: user_ids must be an String") if params.dig(:user_ids) and !params.dig(:user_ids).is_a?(String)
253
263
  raise InvalidParameterError.new("Bad parameter: group_ids must be an String") if params.dig(:group_ids) and !params.dig(:group_ids).is_a?(String)
264
+ raise InvalidParameterError.new("Bad parameter: schedule must be an Hash") if params.dig(:schedule) and !params.dig(:schedule).is_a?(Hash)
265
+ raise InvalidParameterError.new("Bad parameter: trigger must be an String") if params.dig(:trigger) and !params.dig(:trigger).is_a?(String)
254
266
  raise MissingParameterError.new("Parameter missing: automation") unless params.dig(:automation)
255
267
 
256
268
  response, options = Api.send_request("/automations", :post, params, options)
@@ -258,7 +270,7 @@ module Files
258
270
  end
259
271
 
260
272
  # Parameters:
261
- # automation (required) - string - Type of automation. One of: `create_folder`, `request_file`, `request_move`
273
+ # automation (required) - string - Automation type
262
274
  # source - string - Source Path
263
275
  # destination - string - Destination Path
264
276
  # destination_replace_from - string - If set, this string in the destination path will be replaced with the value in `destination_replace_to`.
@@ -267,6 +279,8 @@ module Files
267
279
  # path - string - Path on which this Automation runs. Supports globs.
268
280
  # user_ids - string - A list of user IDs the automation is associated with. If sent as a string, it should be comma-delimited.
269
281
  # group_ids - string - A list of group IDs the automation is associated with. If sent as a string, it should be comma-delimited.
282
+ # schedule - object - Custom schedule for running this automation.
283
+ # trigger - string - How this automation is triggered to run. One of: `realtime` or `custom_schedule`.
270
284
  def self.update(id, params = {}, options = {})
271
285
  params ||= {}
272
286
  params[:id] = id
@@ -280,6 +294,8 @@ module Files
280
294
  raise InvalidParameterError.new("Bad parameter: path must be an String") if params.dig(:path) and !params.dig(:path).is_a?(String)
281
295
  raise InvalidParameterError.new("Bad parameter: user_ids must be an String") if params.dig(:user_ids) and !params.dig(:user_ids).is_a?(String)
282
296
  raise InvalidParameterError.new("Bad parameter: group_ids must be an String") if params.dig(:group_ids) and !params.dig(:group_ids).is_a?(String)
297
+ raise InvalidParameterError.new("Bad parameter: schedule must be an Hash") if params.dig(:schedule) and !params.dig(:schedule).is_a?(Hash)
298
+ raise InvalidParameterError.new("Bad parameter: trigger must be an String") if params.dig(:trigger) and !params.dig(:trigger).is_a?(String)
283
299
  raise MissingParameterError.new("Parameter missing: id") unless params.dig(:id)
284
300
  raise MissingParameterError.new("Parameter missing: automation") unless params.dig(:automation)
285
301