files.com 1.0.123 → 1.0.128
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 +4 -4
- data/_VERSION +1 -1
- data/docs/account_line_item.md +18 -2
- data/docs/api_key.md +1 -1
- data/docs/app.md +3 -1
- data/docs/automation.md +51 -16
- data/docs/bandwidth_snapshot.md +5 -1
- data/docs/behavior.md +2 -2
- data/docs/bundle.md +40 -2
- data/docs/bundle_download.md +5 -1
- data/docs/bundle_recipient.md +7 -0
- data/docs/bundle_registration.md +23 -0
- data/docs/external_event.md +1 -1
- data/docs/file.md +7 -1
- data/docs/file_action.md +13 -0
- data/docs/file_comment.md +4 -1
- data/docs/folder.md +7 -1
- data/docs/form_field.md +29 -0
- data/docs/form_field_set.md +154 -0
- data/docs/group.md +13 -7
- data/docs/group_user.md +1 -1
- data/docs/history.md +1 -1
- data/docs/inbox_registration.md +21 -0
- data/docs/inbox_upload.md +35 -0
- data/docs/invoice.md +18 -2
- data/docs/ip_address.md +1 -1
- data/docs/message.md +10 -1
- data/docs/message_comment.md +4 -1
- data/docs/notification.md +1 -1
- data/docs/payment.md +18 -2
- data/docs/permission.md +1 -1
- data/docs/request.md +2 -2
- data/docs/settings_change.md +1 -1
- data/docs/site.md +91 -7
- data/docs/sso_strategy.md +1 -1
- data/docs/status.md +7 -0
- data/docs/style.md +1 -1
- data/docs/usage_daily_snapshot.md +1 -1
- data/docs/user.md +8 -8
- data/lib/files.com.rb +5 -0
- data/lib/files.com/models/api_key.rb +1 -1
- data/lib/files.com/models/automation.rb +60 -31
- data/lib/files.com/models/bandwidth_snapshot.rb +11 -1
- data/lib/files.com/models/behavior.rb +2 -2
- data/lib/files.com/models/bundle.rb +29 -1
- data/lib/files.com/models/bundle_download.rb +7 -2
- data/lib/files.com/models/bundle_recipient.rb +14 -0
- data/lib/files.com/models/bundle_registration.rb +47 -0
- data/lib/files.com/models/external_event.rb +1 -1
- data/lib/files.com/models/file_action.rb +14 -4
- data/lib/files.com/models/form_field.rb +52 -0
- data/lib/files.com/models/form_field_set.rb +171 -0
- data/lib/files.com/models/group.rb +1 -1
- data/lib/files.com/models/history.rb +1 -1
- data/lib/files.com/models/inbox_registration.rb +42 -0
- data/lib/files.com/models/inbox_upload.rb +46 -0
- data/lib/files.com/models/notification.rb +1 -1
- data/lib/files.com/models/permission.rb +1 -1
- data/lib/files.com/models/request.rb +2 -2
- data/lib/files.com/models/settings_change.rb +1 -1
- data/lib/files.com/models/usage_daily_snapshot.rb +1 -1
- data/lib/files.com/models/user.rb +7 -7
- metadata +12 -2
data/docs/message_comment.md
CHANGED
data/docs/notification.md
CHANGED
@@ -53,7 +53,7 @@ Files::Notification.list(
|
|
53
53
|
* `user_id` (int64): DEPRECATED: Show notifications for this User ID. Use `filter[user_id]` instead.
|
54
54
|
* `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.
|
55
55
|
* `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
|
56
|
-
* `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 `
|
56
|
+
* `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 `path`, `user_id` or `group_id`.
|
57
57
|
* `filter` (object): If set, return records where the specifiied field is equal to the supplied value. Valid fields are `user_id`, `group_id` or `path`.
|
58
58
|
* `filter_gt` (object): If set, return records where the specifiied field is greater than the supplied value. Valid fields are `user_id`, `group_id` or `path`.
|
59
59
|
* `filter_gteq` (object): If set, return records where the specifiied field is greater than or equal to the supplied value. Valid fields are `user_id`, `group_id` or `path`.
|
data/docs/payment.md
CHANGED
@@ -11,11 +11,27 @@
|
|
11
11
|
"currency": "USD",
|
12
12
|
"download_uri": "https://url...",
|
13
13
|
"invoice_line_items": [
|
14
|
-
|
14
|
+
{
|
15
|
+
"amount": 1.0,
|
16
|
+
"created_at": "2000-01-01T01:00:00Z",
|
17
|
+
"description": "Service from 2019-01-01 through 2019-12-31",
|
18
|
+
"type": "invoice",
|
19
|
+
"service_end_at": "2000-01-01T01:00:00Z",
|
20
|
+
"service_start_at": "2000-01-01T01:00:00Z",
|
21
|
+
"updated_at": "2000-01-01T01:00:00Z",
|
22
|
+
"plan": "Enterprise",
|
23
|
+
"site": "My site"
|
24
|
+
}
|
15
25
|
],
|
16
26
|
"method": "paypal",
|
17
27
|
"payment_line_items": [
|
18
|
-
|
28
|
+
{
|
29
|
+
"amount": 1.0,
|
30
|
+
"created_at": "2000-01-01T01:00:00Z",
|
31
|
+
"invoice_id": 1,
|
32
|
+
"payment_id": 1,
|
33
|
+
"updated_at": "2000-01-01T01:00:00Z"
|
34
|
+
}
|
19
35
|
],
|
20
36
|
"payment_reversed_at": "2000-01-01T01:00:00Z",
|
21
37
|
"payment_type": "",
|
data/docs/permission.md
CHANGED
@@ -42,7 +42,7 @@ Files::Permission.list(
|
|
42
42
|
|
43
43
|
* `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.
|
44
44
|
* `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
|
45
|
-
* `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 `
|
45
|
+
* `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 `group_id`, `path`, `user_id` or `permission`.
|
46
46
|
* `filter` (object): If set, return records where the specifiied field is equal to the supplied value. Valid fields are `group_id`, `user_id` or `path`.
|
47
47
|
* `filter_gt` (object): If set, return records where the specifiied field is greater than the supplied value. Valid fields are `group_id`, `user_id` or `path`.
|
48
48
|
* `filter_gteq` (object): If set, return records where the specifiied field is greater than or equal to the supplied value. Valid fields are `group_id`, `user_id` or `path`.
|
data/docs/request.md
CHANGED
@@ -38,7 +38,7 @@ Files::Request.list(
|
|
38
38
|
|
39
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.
|
40
40
|
* `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
|
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 `
|
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 `destination`.
|
42
42
|
* `mine` (boolean): Only show requests of the current user? (Defaults to true if current user is not a site admin.)
|
43
43
|
* `path` (string): Path to show requests for. If omitted, shows all paths. Send `/` to represent the root directory.
|
44
44
|
|
@@ -58,7 +58,7 @@ Files::Request.get_folder(path,
|
|
58
58
|
|
59
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.
|
60
60
|
* `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
|
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 `
|
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 `destination`.
|
62
62
|
* `mine` (boolean): Only show requests of the current user? (Defaults to true if current user is not a site admin.)
|
63
63
|
* `path` (string): Required - Path to show requests for. If omitted, shows all paths. Send `/` to represent the root directory.
|
64
64
|
|
data/docs/settings_change.md
CHANGED
@@ -29,7 +29,7 @@ Files::SettingsChange.list(
|
|
29
29
|
|
30
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.
|
31
31
|
* `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
|
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 `
|
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 `api_key_id`, `created_at` or `user_id`.
|
33
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`.
|
34
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`.
|
35
35
|
* `filter_gteq` (object): If set, return records where the specifiied field is greater than or equal to the supplied value. Valid fields are `api_key_id` and `user_id`.
|
data/docs/site.md
CHANGED
@@ -39,10 +39,22 @@
|
|
39
39
|
"non_sso_users_allowed": true,
|
40
40
|
"folder_permissions_groups_only": true,
|
41
41
|
"hipaa": true,
|
42
|
-
"icon128":
|
43
|
-
|
44
|
-
|
45
|
-
|
42
|
+
"icon128": {
|
43
|
+
"name": "My logo",
|
44
|
+
"uri": "https://mysite.files.com/.../my_image.png"
|
45
|
+
},
|
46
|
+
"icon16": {
|
47
|
+
"name": "My logo",
|
48
|
+
"uri": "https://mysite.files.com/.../my_image.png"
|
49
|
+
},
|
50
|
+
"icon32": {
|
51
|
+
"name": "My logo",
|
52
|
+
"uri": "https://mysite.files.com/.../my_image.png"
|
53
|
+
},
|
54
|
+
"icon48": {
|
55
|
+
"name": "My logo",
|
56
|
+
"uri": "https://mysite.files.com/.../my_image.png"
|
57
|
+
},
|
46
58
|
"immutable_files_set_at": "2000-01-01T01:00:00Z",
|
47
59
|
"include_password_in_welcome_email": true,
|
48
60
|
"language": "en",
|
@@ -63,7 +75,10 @@
|
|
63
75
|
"ldap_username": "[ldap username]",
|
64
76
|
"ldap_username_field": "sAMAccountName",
|
65
77
|
"login_help_text": "Login page help text.",
|
66
|
-
"logo":
|
78
|
+
"logo": {
|
79
|
+
"name": "My logo",
|
80
|
+
"uri": "https://mysite.files.com/.../my_image.png"
|
81
|
+
},
|
67
82
|
"max_prior_passwords": 1,
|
68
83
|
"next_billing_amount": 1.0,
|
69
84
|
"next_billing_date": "Apr 20",
|
@@ -84,7 +99,26 @@
|
|
84
99
|
"require_2fa": true,
|
85
100
|
"require_2fa_stop_time": "2000-01-01T01:00:00Z",
|
86
101
|
"require_2fa_user_type": "`site_admins`",
|
87
|
-
"session":
|
102
|
+
"session": {
|
103
|
+
"id": "60525f92e859c4c3d74cb02fd176b1525901b525",
|
104
|
+
"language": "en",
|
105
|
+
"login_token": "@tok-randomcode",
|
106
|
+
"login_token_domain": "https://mysite.files.com",
|
107
|
+
"max_dir_listing_size": false,
|
108
|
+
"multiple_regions": true,
|
109
|
+
"read_only": true,
|
110
|
+
"root_path": "",
|
111
|
+
"site_id": 1,
|
112
|
+
"ssl_required": true,
|
113
|
+
"tls_disabled": false,
|
114
|
+
"two_factor_setup_needed": false,
|
115
|
+
"allowed_2fa_method_sms": true,
|
116
|
+
"allowed_2fa_method_totp": true,
|
117
|
+
"allowed_2fa_method_u2f": true,
|
118
|
+
"allowed_2fa_method_yubi": true,
|
119
|
+
"use_provided_modified_at": true,
|
120
|
+
"windows_mode_ftp": false
|
121
|
+
},
|
88
122
|
"session_pinned_by_ip": true,
|
89
123
|
"sftp_user_root_enabled": true,
|
90
124
|
"sharing_enabled": true,
|
@@ -105,7 +139,57 @@
|
|
105
139
|
"trial_until": "2000-01-01T01:00:00Z",
|
106
140
|
"updated_at": "2000-01-01T01:00:00Z",
|
107
141
|
"use_provided_modified_at": true,
|
108
|
-
"user":
|
142
|
+
"user": {
|
143
|
+
"id": 1,
|
144
|
+
"username": "user",
|
145
|
+
"admin_group_ids": [
|
146
|
+
1
|
147
|
+
],
|
148
|
+
"allowed_ips": "127.0.0.1",
|
149
|
+
"attachments_permission": true,
|
150
|
+
"api_keys_count": 1,
|
151
|
+
"authenticate_until": "2000-01-01T01:00:00Z",
|
152
|
+
"authentication_method": "password",
|
153
|
+
"avatar_url": "",
|
154
|
+
"billing_permission": false,
|
155
|
+
"bypass_site_allowed_ips": false,
|
156
|
+
"bypass_inactive_disable": false,
|
157
|
+
"created_at": "2000-01-01T01:00:00Z",
|
158
|
+
"dav_permission": true,
|
159
|
+
"disabled": true,
|
160
|
+
"email": "john.doe@files.com",
|
161
|
+
"ftp_permission": true,
|
162
|
+
"group_ids": "",
|
163
|
+
"header_text": "User-specific message.",
|
164
|
+
"language": "en",
|
165
|
+
"last_login_at": "2000-01-01T01:00:00Z",
|
166
|
+
"last_protocol_cipher": "",
|
167
|
+
"lockout_expires": "2000-01-01T01:00:00Z",
|
168
|
+
"name": "John Doe",
|
169
|
+
"company": "ACME Corp.",
|
170
|
+
"notes": "Internal notes on this user.",
|
171
|
+
"notification_daily_send_time": 18,
|
172
|
+
"office_integration_enabled": true,
|
173
|
+
"password_set_at": "2000-01-01T01:00:00Z",
|
174
|
+
"password_validity_days": 1,
|
175
|
+
"public_keys_count": 1,
|
176
|
+
"receive_admin_alerts": true,
|
177
|
+
"require_2fa": "always_require",
|
178
|
+
"active_2fa": true,
|
179
|
+
"require_password_change": true,
|
180
|
+
"restapi_permission": true,
|
181
|
+
"self_managed": true,
|
182
|
+
"sftp_permission": true,
|
183
|
+
"site_admin": true,
|
184
|
+
"skip_welcome_screen": true,
|
185
|
+
"ssl_required": "always_require",
|
186
|
+
"sso_strategy_id": 1,
|
187
|
+
"subscribe_to_newsletter": true,
|
188
|
+
"externally_managed": true,
|
189
|
+
"time_zone": "Pacific Time (US & Canada)",
|
190
|
+
"type_of_2fa": "",
|
191
|
+
"user_root": ""
|
192
|
+
},
|
109
193
|
"user_lockout": true,
|
110
194
|
"user_lockout_lock_period": 1,
|
111
195
|
"user_lockout_tries": 1,
|
data/docs/sso_strategy.md
CHANGED
data/docs/status.md
CHANGED
data/docs/style.md
CHANGED
@@ -33,7 +33,7 @@ Files::UsageDailySnapshot.list(
|
|
33
33
|
|
34
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.
|
35
35
|
* `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
|
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 `
|
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 `date` and `usage_snapshot_id`.
|
37
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`.
|
38
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`.
|
39
39
|
* `filter_gteq` (object): If set, return records where the specifiied field is greater than or equal to the supplied value. Valid fields are `date` and `usage_snapshot_id`.
|
data/docs/user.md
CHANGED
@@ -7,7 +7,7 @@
|
|
7
7
|
"id": 1,
|
8
8
|
"username": "user",
|
9
9
|
"admin_group_ids": [
|
10
|
-
|
10
|
+
1
|
11
11
|
],
|
12
12
|
"allowed_ips": "127.0.0.1",
|
13
13
|
"attachments_permission": true,
|
@@ -128,13 +128,13 @@ Files::User.list(
|
|
128
128
|
|
129
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.
|
130
130
|
* `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
|
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 `
|
132
|
-
* `filter` (object): If set, return records where the specifiied field is equal to the supplied value. Valid fields are `username`, `email`, `company`, `
|
133
|
-
* `filter_gt` (object): If set, return records where the specifiied field is greater than the supplied value. Valid fields are `username`, `email`, `company`, `
|
134
|
-
* `filter_gteq` (object): If set, return records where the specifiied field is greater than or equal to the supplied value. Valid fields are `username`, `email`, `company`, `
|
135
|
-
* `filter_like` (object): If set, return records where the specifiied field is equal to the supplied value. Valid fields are `username`, `email`, `company`, `
|
136
|
-
* `filter_lt` (object): If set, return records where the specifiied field is less than the supplied value. Valid fields are `username`, `email`, `company`, `
|
137
|
-
* `filter_lteq` (object): If set, return records where the specifiied field is less than or equal to the supplied value. Valid fields are `username`, `email`, `company`, `
|
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 `authenticate_until`, `email`, `last_desktop_login_at`, `last_login_at`, `username`, `company`, `name`, `site_admin`, `receive_admin_alerts`, `password_validity_days`, `ssl_required` or `not_site_admin`.
|
132
|
+
* `filter` (object): If set, return records where the specifiied field is equal to the supplied value. Valid fields are `username`, `email`, `company`, `site_admin`, `password_validity_days`, `ssl_required`, `last_login_at`, `authenticate_until` or `not_site_admin`.
|
133
|
+
* `filter_gt` (object): If set, return records where the specifiied field is greater than the supplied value. Valid fields are `username`, `email`, `company`, `site_admin`, `password_validity_days`, `ssl_required`, `last_login_at`, `authenticate_until` or `not_site_admin`.
|
134
|
+
* `filter_gteq` (object): If set, return records where the specifiied field is greater than or equal to the supplied value. Valid fields are `username`, `email`, `company`, `site_admin`, `password_validity_days`, `ssl_required`, `last_login_at`, `authenticate_until` or `not_site_admin`.
|
135
|
+
* `filter_like` (object): If set, return records where the specifiied field is equal to the supplied value. Valid fields are `username`, `email`, `company`, `site_admin`, `password_validity_days`, `ssl_required`, `last_login_at`, `authenticate_until` or `not_site_admin`.
|
136
|
+
* `filter_lt` (object): If set, return records where the specifiied field is less than the supplied value. Valid fields are `username`, `email`, `company`, `site_admin`, `password_validity_days`, `ssl_required`, `last_login_at`, `authenticate_until` or `not_site_admin`.
|
137
|
+
* `filter_lteq` (object): If set, return records where the specifiied field is less than or equal to the supplied value. Valid fields are `username`, `email`, `company`, `site_admin`, `password_validity_days`, `ssl_required`, `last_login_at`, `authenticate_until` or `not_site_admin`.
|
138
138
|
* `ids` (string): comma-separated list of User IDs
|
139
139
|
* `q[username]` (string): List users matching username.
|
140
140
|
* `q[email]` (string): List users matching email.
|
data/lib/files.com.rb
CHANGED
@@ -39,6 +39,7 @@ require "files.com/models/behavior"
|
|
39
39
|
require "files.com/models/bundle"
|
40
40
|
require "files.com/models/bundle_download"
|
41
41
|
require "files.com/models/bundle_recipient"
|
42
|
+
require "files.com/models/bundle_registration"
|
42
43
|
require "files.com/models/clickwrap"
|
43
44
|
require "files.com/models/dns_record"
|
44
45
|
require "files.com/models/errors"
|
@@ -49,12 +50,16 @@ require "files.com/models/file_comment"
|
|
49
50
|
require "files.com/models/file_comment_reaction"
|
50
51
|
require "files.com/models/file_upload_part"
|
51
52
|
require "files.com/models/folder"
|
53
|
+
require "files.com/models/form_field"
|
54
|
+
require "files.com/models/form_field_set"
|
52
55
|
require "files.com/models/group"
|
53
56
|
require "files.com/models/group_user"
|
54
57
|
require "files.com/models/history"
|
55
58
|
require "files.com/models/history_export"
|
56
59
|
require "files.com/models/history_export_result"
|
57
60
|
require "files.com/models/image"
|
61
|
+
require "files.com/models/inbox_registration"
|
62
|
+
require "files.com/models/inbox_upload"
|
58
63
|
require "files.com/models/invoice"
|
59
64
|
require "files.com/models/invoice_line_item"
|
60
65
|
require "files.com/models/ip_address"
|
@@ -148,7 +148,7 @@ module Files
|
|
148
148
|
# user_id - int64 - User ID. Provide a value of `0` to operate the current session's user.
|
149
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
|
-
# 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 `
|
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 `expires_at`.
|
152
152
|
# filter - object - If set, return records where the specifiied field is equal to the supplied value. Valid fields are `expires_at`.
|
153
153
|
# filter_gt - object - If set, return records where the specifiied field is greater than the supplied value. Valid fields are `expires_at`.
|
154
154
|
# filter_gteq - object - If set, return records where the specifiied field is greater than or equal to the supplied value. Valid fields are `expires_at`.
|
@@ -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`, `daily`, `custom_schedule`, `webhook`, or `email`.
|
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]
|
@@ -126,8 +135,17 @@ module Files
|
|
126
135
|
@attributes[:group_ids] = value
|
127
136
|
end
|
128
137
|
|
138
|
+
# string - If trigger is `webhook`, this is the URL of the webhook to trigger the Automation.
|
139
|
+
def webhook_url
|
140
|
+
@attributes[:webhook_url]
|
141
|
+
end
|
142
|
+
|
143
|
+
def webhook_url=(value)
|
144
|
+
@attributes[:webhook_url] = value
|
145
|
+
end
|
146
|
+
|
129
147
|
# Parameters:
|
130
|
-
# automation (required) - string -
|
148
|
+
# automation (required) - string - Automation type
|
131
149
|
# source - string - Source Path
|
132
150
|
# destination - string - Destination Path
|
133
151
|
# destination_replace_from - string - If set, this string in the destination path will be replaced with the value in `destination_replace_to`.
|
@@ -136,6 +154,8 @@ module Files
|
|
136
154
|
# path - string - Path on which this Automation runs. Supports globs.
|
137
155
|
# user_ids - string - A list of user IDs the automation is associated with. If sent as a string, it should be comma-delimited.
|
138
156
|
# group_ids - string - A list of group IDs the automation is associated with. If sent as a string, it should be comma-delimited.
|
157
|
+
# schedule - object - Custom schedule for running this automation.
|
158
|
+
# trigger - string - How this automation is triggered to run. One of: `realtime`, `daily`, `custom_schedule`, `webhook`, or `email`.
|
139
159
|
def update(params = {})
|
140
160
|
params ||= {}
|
141
161
|
params[:id] = @attributes[:id]
|
@@ -150,6 +170,7 @@ module Files
|
|
150
170
|
raise InvalidParameterError.new("Bad parameter: path must be an String") if params.dig(:path) and !params.dig(:path).is_a?(String)
|
151
171
|
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
172
|
raise InvalidParameterError.new("Bad parameter: group_ids must be an String") if params.dig(:group_ids) and !params.dig(:group_ids).is_a?(String)
|
173
|
+
raise InvalidParameterError.new("Bad parameter: trigger must be an String") if params.dig(:trigger) and !params.dig(:trigger).is_a?(String)
|
153
174
|
raise MissingParameterError.new("Parameter missing: id") unless params.dig(:id)
|
154
175
|
raise MissingParameterError.new("Parameter missing: automation") unless params.dig(:automation)
|
155
176
|
|
@@ -182,7 +203,7 @@ module Files
|
|
182
203
|
# Parameters:
|
183
204
|
# 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
205
|
# per_page - int64 - Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
|
185
|
-
# 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 `
|
206
|
+
# 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 `automation`.
|
186
207
|
# filter - object - If set, return records where the specifiied field is equal to the supplied value. Valid fields are `automation`.
|
187
208
|
# filter_gt - object - If set, return records where the specifiied field is greater than the supplied value. Valid fields are `automation`.
|
188
209
|
# filter_gteq - object - If set, return records where the specifiied field is greater than or equal to the supplied value. Valid fields are `automation`.
|
@@ -228,7 +249,7 @@ module Files
|
|
228
249
|
end
|
229
250
|
|
230
251
|
# Parameters:
|
231
|
-
# automation (required) - string -
|
252
|
+
# automation (required) - string - Automation type
|
232
253
|
# source - string - Source Path
|
233
254
|
# destination - string - Destination Path
|
234
255
|
# destination_replace_from - string - If set, this string in the destination path will be replaced with the value in `destination_replace_to`.
|
@@ -237,6 +258,8 @@ module Files
|
|
237
258
|
# path - string - Path on which this Automation runs. Supports globs.
|
238
259
|
# user_ids - string - A list of user IDs the automation is associated with. If sent as a string, it should be comma-delimited.
|
239
260
|
# group_ids - string - A list of group IDs the automation is associated with. If sent as a string, it should be comma-delimited.
|
261
|
+
# schedule - object - Custom schedule for running this automation.
|
262
|
+
# trigger - string - How this automation is triggered to run. One of: `realtime`, `daily`, `custom_schedule`, `webhook`, or `email`.
|
240
263
|
def self.create(params = {}, options = {})
|
241
264
|
raise InvalidParameterError.new("Bad parameter: automation must be an String") if params.dig(:automation) and !params.dig(:automation).is_a?(String)
|
242
265
|
raise InvalidParameterError.new("Bad parameter: source must be an String") if params.dig(:source) and !params.dig(:source).is_a?(String)
|
@@ -247,6 +270,8 @@ module Files
|
|
247
270
|
raise InvalidParameterError.new("Bad parameter: path must be an String") if params.dig(:path) and !params.dig(:path).is_a?(String)
|
248
271
|
raise InvalidParameterError.new("Bad parameter: user_ids must be an String") if params.dig(:user_ids) and !params.dig(:user_ids).is_a?(String)
|
249
272
|
raise InvalidParameterError.new("Bad parameter: group_ids must be an String") if params.dig(:group_ids) and !params.dig(:group_ids).is_a?(String)
|
273
|
+
raise InvalidParameterError.new("Bad parameter: schedule must be an Hash") if params.dig(:schedule) and !params.dig(:schedule).is_a?(Hash)
|
274
|
+
raise InvalidParameterError.new("Bad parameter: trigger must be an String") if params.dig(:trigger) and !params.dig(:trigger).is_a?(String)
|
250
275
|
raise MissingParameterError.new("Parameter missing: automation") unless params.dig(:automation)
|
251
276
|
|
252
277
|
response, options = Api.send_request("/automations", :post, params, options)
|
@@ -254,7 +279,7 @@ module Files
|
|
254
279
|
end
|
255
280
|
|
256
281
|
# Parameters:
|
257
|
-
# automation (required) - string -
|
282
|
+
# automation (required) - string - Automation type
|
258
283
|
# source - string - Source Path
|
259
284
|
# destination - string - Destination Path
|
260
285
|
# destination_replace_from - string - If set, this string in the destination path will be replaced with the value in `destination_replace_to`.
|
@@ -263,6 +288,8 @@ module Files
|
|
263
288
|
# path - string - Path on which this Automation runs. Supports globs.
|
264
289
|
# user_ids - string - A list of user IDs the automation is associated with. If sent as a string, it should be comma-delimited.
|
265
290
|
# group_ids - string - A list of group IDs the automation is associated with. If sent as a string, it should be comma-delimited.
|
291
|
+
# schedule - object - Custom schedule for running this automation.
|
292
|
+
# trigger - string - How this automation is triggered to run. One of: `realtime`, `daily`, `custom_schedule`, `webhook`, or `email`.
|
266
293
|
def self.update(id, params = {}, options = {})
|
267
294
|
params ||= {}
|
268
295
|
params[:id] = id
|
@@ -276,6 +303,8 @@ module Files
|
|
276
303
|
raise InvalidParameterError.new("Bad parameter: path must be an String") if params.dig(:path) and !params.dig(:path).is_a?(String)
|
277
304
|
raise InvalidParameterError.new("Bad parameter: user_ids must be an String") if params.dig(:user_ids) and !params.dig(:user_ids).is_a?(String)
|
278
305
|
raise InvalidParameterError.new("Bad parameter: group_ids must be an String") if params.dig(:group_ids) and !params.dig(:group_ids).is_a?(String)
|
306
|
+
raise InvalidParameterError.new("Bad parameter: schedule must be an Hash") if params.dig(:schedule) and !params.dig(:schedule).is_a?(Hash)
|
307
|
+
raise InvalidParameterError.new("Bad parameter: trigger must be an String") if params.dig(:trigger) and !params.dig(:trigger).is_a?(String)
|
279
308
|
raise MissingParameterError.new("Parameter missing: id") unless params.dig(:id)
|
280
309
|
raise MissingParameterError.new("Parameter missing: automation") unless params.dig(:automation)
|
281
310
|
|