files.com 1.1.426 → 1.1.428

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: deb5cfa450dd6091f1cac32fa2968ee1496e3e9c9a633b3ded728b2fb08106c2
4
- data.tar.gz: 79afabe81f376f94b69c6f8ed7f04ecd5aa10f89558a98aebe9392e2b61df413
3
+ metadata.gz: 2a48bd2f8c6acac4645cb64fa4e178b85821fe1710980168744873cc4003d75c
4
+ data.tar.gz: 07ca10acd6d6d93554e3ff0af81e3cef7c89403b0cd8c49238a8708855d6f3ce
5
5
  SHA512:
6
- metadata.gz: 32fe5f53e92790f7d38f102e83d531212c8b4cfd783767300f0a1b96daa1a44f8c13f57fe671df79b91a1d6fe128f4c64d4818cea48f020a1d5a90d457ee4868
7
- data.tar.gz: f7ab73d8e7c20b68e948b5c6dea8e264585c8e232a8b6fa034f6e694fc54094b84f6e6ecd27f88ea95018e9e3eef5268d190b0d5fe22211cf906a7aaddde9517
6
+ metadata.gz: 184405ca59c7c796167dd64aad18c363e5eb9179ea834e18d3e2d929bb9ccbb6094cdd44854ba4139c05bc81f7c3a69a69313b4cfdc10fcb08452bae9ad301f7
7
+ data.tar.gz: ad7c427adfb9b638720eb38087586643143c17def9ea9ac854ee1a919dcafa9ef8a7c0cd52d6cafa5528185cd6ffa0ad66e042fefc231e22f88da0eb360efe59
data/_VERSION CHANGED
@@ -1 +1 @@
1
- 1.1.426
1
+ 1.1.428
data/docs/restore.md CHANGED
@@ -13,8 +13,15 @@
13
13
  "files_errored": 1,
14
14
  "files_total": 1,
15
15
  "prefix": "foo/bar/baz.txt",
16
+ "restoration_type": "files",
16
17
  "restore_in_place": true,
17
18
  "restore_deleted_permissions": true,
19
+ "users_restored": 1,
20
+ "users_errored": 1,
21
+ "users_total": 1,
22
+ "api_keys_restored": 1,
23
+ "public_keys_restored": 1,
24
+ "two_factor_authentication_methods_restored": 1,
18
25
  "status": "pending",
19
26
  "update_timestamps": true,
20
27
  "error_messages": [
@@ -32,8 +39,15 @@
32
39
  * `files_errored` (int64): Number of files that were not able to be restored.
33
40
  * `files_total` (int64): Total number of files processed.
34
41
  * `prefix` (string): Prefix of the files/folders to restore. To restore a folder, add a trailing slash to the folder name. Do not use a leading slash. To restore all deleted items, specify an empty string (`''`) in the prefix field or omit the field from the request.
42
+ * `restoration_type` (string): Type of restoration to perform. `files` restores deleted filesystem items. `users` restores deleted users and associated access/authentication records.
35
43
  * `restore_in_place` (boolean): If true, we will restore the files in place (into their original paths). If false, we will create a new restoration folder in the root and restore files there.
36
44
  * `restore_deleted_permissions` (boolean): If true, we will also restore any Permissions that match the same path prefix from the same dates.
45
+ * `users_restored` (int64): Number of users successfully restored (only present for `restoration_type=users`).
46
+ * `users_errored` (int64): Number of users that failed to restore (only present for `restoration_type=users`).
47
+ * `users_total` (int64): Total number of users processed (only present for `restoration_type=users`).
48
+ * `api_keys_restored` (int64): Number of API keys restored (only present for `restoration_type=users`).
49
+ * `public_keys_restored` (int64): Number of public keys restored (only present for `restoration_type=users`).
50
+ * `two_factor_authentication_methods_restored` (int64): Number of two factor authentication methods restored (only present for `restoration_type=users`).
37
51
  * `status` (string): Status of the restoration process.
38
52
  * `update_timestamps` (boolean): If true, we will update the last modified timestamp of restored files to today's date. If false, we might trigger File Expiration to delete the file again.
39
53
  * `error_messages` (array(string)): Error messages received while restoring files and/or directories. Only present if there were errors.
@@ -61,6 +75,7 @@ Files::Restore.list
61
75
  Files::Restore.create(
62
76
  earliest_date: "2000-01-01T01:00:00Z",
63
77
  prefix: "foo/bar/baz.txt",
78
+ restoration_type: "files",
64
79
  restore_deleted_permissions: true,
65
80
  restore_in_place: true,
66
81
  update_timestamps: true
@@ -71,6 +86,7 @@ Files::Restore.create(
71
86
 
72
87
  * `earliest_date` (string): Required - Restore all files deleted after this date/time. Don't set this earlier than you need. Can not be greater than 365 days prior to the restore request.
73
88
  * `prefix` (string): Prefix of the files/folders to restore. To restore a folder, add a trailing slash to the folder name. Do not use a leading slash. To restore all deleted items, specify an empty string (`''`) in the prefix field or omit the field from the request.
89
+ * `restoration_type` (string): Type of restoration to perform. `files` restores deleted filesystem items. `users` restores deleted users and associated access/authentication records.
74
90
  * `restore_deleted_permissions` (boolean): If true, we will also restore any Permissions that match the same path prefix from the same dates.
75
91
  * `restore_in_place` (boolean): If true, we will restore the files in place (into their original paths). If false, we will create a new restoration folder in the root and restore files there.
76
92
  * `update_timestamps` (boolean): If true, we will update the last modified timestamp of restored files to today's date. If false, we might trigger File Expiration to delete the file again.
@@ -90,6 +90,15 @@ module Files
90
90
  @attributes[:prefix] = value
91
91
  end
92
92
 
93
+ # string - Type of restoration to perform. `files` restores deleted filesystem items. `users` restores deleted users and associated access/authentication records.
94
+ def restoration_type
95
+ @attributes[:restoration_type]
96
+ end
97
+
98
+ def restoration_type=(value)
99
+ @attributes[:restoration_type] = value
100
+ end
101
+
93
102
  # boolean - If true, we will restore the files in place (into their original paths). If false, we will create a new restoration folder in the root and restore files there.
94
103
  def restore_in_place
95
104
  @attributes[:restore_in_place]
@@ -108,6 +117,60 @@ module Files
108
117
  @attributes[:restore_deleted_permissions] = value
109
118
  end
110
119
 
120
+ # int64 - Number of users successfully restored (only present for `restoration_type=users`).
121
+ def users_restored
122
+ @attributes[:users_restored]
123
+ end
124
+
125
+ def users_restored=(value)
126
+ @attributes[:users_restored] = value
127
+ end
128
+
129
+ # int64 - Number of users that failed to restore (only present for `restoration_type=users`).
130
+ def users_errored
131
+ @attributes[:users_errored]
132
+ end
133
+
134
+ def users_errored=(value)
135
+ @attributes[:users_errored] = value
136
+ end
137
+
138
+ # int64 - Total number of users processed (only present for `restoration_type=users`).
139
+ def users_total
140
+ @attributes[:users_total]
141
+ end
142
+
143
+ def users_total=(value)
144
+ @attributes[:users_total] = value
145
+ end
146
+
147
+ # int64 - Number of API keys restored (only present for `restoration_type=users`).
148
+ def api_keys_restored
149
+ @attributes[:api_keys_restored]
150
+ end
151
+
152
+ def api_keys_restored=(value)
153
+ @attributes[:api_keys_restored] = value
154
+ end
155
+
156
+ # int64 - Number of public keys restored (only present for `restoration_type=users`).
157
+ def public_keys_restored
158
+ @attributes[:public_keys_restored]
159
+ end
160
+
161
+ def public_keys_restored=(value)
162
+ @attributes[:public_keys_restored] = value
163
+ end
164
+
165
+ # int64 - Number of two factor authentication methods restored (only present for `restoration_type=users`).
166
+ def two_factor_authentication_methods_restored
167
+ @attributes[:two_factor_authentication_methods_restored]
168
+ end
169
+
170
+ def two_factor_authentication_methods_restored=(value)
171
+ @attributes[:two_factor_authentication_methods_restored] = value
172
+ end
173
+
111
174
  # string - Status of the restoration process.
112
175
  def status
113
176
  @attributes[:status]
@@ -165,12 +228,14 @@ module Files
165
228
  # Parameters:
166
229
  # earliest_date (required) - string - Restore all files deleted after this date/time. Don't set this earlier than you need. Can not be greater than 365 days prior to the restore request.
167
230
  # prefix - string - Prefix of the files/folders to restore. To restore a folder, add a trailing slash to the folder name. Do not use a leading slash. To restore all deleted items, specify an empty string (`''`) in the prefix field or omit the field from the request.
231
+ # restoration_type - string - Type of restoration to perform. `files` restores deleted filesystem items. `users` restores deleted users and associated access/authentication records.
168
232
  # restore_deleted_permissions - boolean - If true, we will also restore any Permissions that match the same path prefix from the same dates.
169
233
  # restore_in_place - boolean - If true, we will restore the files in place (into their original paths). If false, we will create a new restoration folder in the root and restore files there.
170
234
  # update_timestamps - boolean - If true, we will update the last modified timestamp of restored files to today's date. If false, we might trigger File Expiration to delete the file again.
171
235
  def self.create(params = {}, options = {})
172
236
  raise InvalidParameterError.new("Bad parameter: earliest_date must be an String") if params[:earliest_date] and !params[:earliest_date].is_a?(String)
173
237
  raise InvalidParameterError.new("Bad parameter: prefix must be an String") if params[:prefix] and !params[:prefix].is_a?(String)
238
+ raise InvalidParameterError.new("Bad parameter: restoration_type must be an String") if params[:restoration_type] and !params[:restoration_type].is_a?(String)
174
239
  raise MissingParameterError.new("Parameter missing: earliest_date") unless params[:earliest_date]
175
240
 
176
241
  response, options = Api.send_request("/restores", :post, params, options)
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Files
4
- VERSION = "1.1.426"
4
+ VERSION = "1.1.428"
5
5
  end
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.1.426
4
+ version: 1.1.428
5
5
  platform: ruby
6
6
  authors:
7
7
  - files.com
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-12-18 00:00:00.000000000 Z
11
+ date: 2025-12-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: addressable