files.com 1.0.221 → 1.0.225
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/_VERSION +1 -1
- data/docs/file.md +5 -2
- data/docs/file_action.md +3 -3
- data/docs/folder.md +1 -2
- data/docs/preview.md +1 -3
- data/docs/session.md +1 -1
- data/lib/files.com/models/file.rb +4 -0
- data/lib/files.com/models/file_action.rb +2 -2
- data/lib/files.com/models/preview.rb +0 -5
- data/lib/files.com/models/session.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1a574f05e44afd663c1075e75c7c2b8dc407c90691e4edb778e81ba399229fdb
|
4
|
+
data.tar.gz: aa0858a5211a2059a9a8d1d6db80046232ca76850cebf52ddf22d4ab30847611
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c122e4c0f2506817a8ba9a9ddef7689daaee2bdb49f32a96c7c3d2e63bc6958763f7cdfb9c6af6456894e78d17b1f021a342d55b83429d91bd00b71f32725643
|
7
|
+
data.tar.gz: 84532fba3891c986190dbf086450bfd4257ba60180c3a34b462b8955d875da800e0d55f5bd20768d8353964d453e8bcac71622efec539e1248ab1470640b0f50
|
data/_VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.0.
|
1
|
+
1.0.225
|
data/docs/file.md
CHANGED
@@ -27,8 +27,7 @@ may places where a Ruby File object can be used.
|
|
27
27
|
"status": "complete",
|
28
28
|
"download_uri": "https://mysite.files.com/...",
|
29
29
|
"type": "complete",
|
30
|
-
"size": 1024
|
31
|
-
"status_message": ""
|
30
|
+
"size": 1024
|
32
31
|
}
|
33
32
|
}
|
34
33
|
```
|
@@ -213,6 +212,7 @@ Files::File.begin_upload(path,
|
|
213
212
|
parts: 1,
|
214
213
|
ref: "upload-1",
|
215
214
|
restart: 1,
|
215
|
+
size: 1,
|
216
216
|
with_rename: true
|
217
217
|
)
|
218
218
|
```
|
@@ -225,6 +225,7 @@ Files::File.begin_upload(path,
|
|
225
225
|
* `parts` (int64): How many parts to fetch?
|
226
226
|
* `ref` (string):
|
227
227
|
* `restart` (int64): File byte offset to restart from.
|
228
|
+
* `size` (int64): Total bytes of file being uploaded (include bytes being retained if appending/restarting).
|
228
229
|
* `with_rename` (boolean): Allow file rename instead of overwrite?
|
229
230
|
|
230
231
|
|
@@ -339,6 +340,7 @@ file.begin_upload(
|
|
339
340
|
parts: 1,
|
340
341
|
ref: "upload-1",
|
341
342
|
restart: 1,
|
343
|
+
size: 1,
|
342
344
|
with_rename: true
|
343
345
|
)
|
344
346
|
```
|
@@ -351,4 +353,5 @@ file.begin_upload(
|
|
351
353
|
* `parts` (int64): How many parts to fetch?
|
352
354
|
* `ref` (string):
|
353
355
|
* `restart` (int64): File byte offset to restart from.
|
356
|
+
* `size` (int64): Total bytes of file being uploaded (include bytes being retained if appending/restarting).
|
354
357
|
* `with_rename` (boolean): Allow file rename instead of overwrite?
|
data/docs/file_action.md
CHANGED
@@ -4,10 +4,10 @@
|
|
4
4
|
|
5
5
|
```
|
6
6
|
{
|
7
|
-
"status": "
|
7
|
+
"status": "pending",
|
8
8
|
"file_migration_id": "123"
|
9
9
|
}
|
10
10
|
```
|
11
11
|
|
12
|
-
* `status` (string): Status of file operation.
|
13
|
-
* `file_migration_id` (int64): If status is
|
12
|
+
* `status` (string): Status of file operation.
|
13
|
+
* `file_migration_id` (int64): If status is pending, this is the id of the FileMigration to check for status updates.
|
data/docs/folder.md
CHANGED
data/docs/preview.md
CHANGED
@@ -8,8 +8,7 @@
|
|
8
8
|
"status": "complete",
|
9
9
|
"download_uri": "https://mysite.files.com/...",
|
10
10
|
"type": "complete",
|
11
|
-
"size": 1024
|
12
|
-
"status_message": ""
|
11
|
+
"size": 1024
|
13
12
|
}
|
14
13
|
```
|
15
14
|
|
@@ -18,4 +17,3 @@
|
|
18
17
|
* `download_uri` (string): Link to download preview
|
19
18
|
* `type` (string): Preview status. Can be invalid, not_generated, generating, complete, or file_too_large
|
20
19
|
* `size` (int64): Preview size
|
21
|
-
* `status_message` (string): Preview status message. Addtional context from the preview generation process about the status
|
data/docs/session.md
CHANGED
@@ -37,7 +37,7 @@
|
|
37
37
|
* `sftp_insecure_ciphers` (boolean): Are insecure SFTP ciphers allowed for this user? (If this is set to true, the site administrator has signaled that it is ok to use less secure SSH ciphers for this user.)
|
38
38
|
* `site_id` (int64): Site ID
|
39
39
|
* `ssl_required` (boolean): Is SSL required for this user? (If so, ensure all your communications with this user use SSL.)
|
40
|
-
* `tls_disabled` (boolean):
|
40
|
+
* `tls_disabled` (boolean): Are insecure TLS versions allowed for this user? (If this is set to true, the site administrator has signaled that it is ok to use less secure TLS versions for this user.)
|
41
41
|
* `two_factor_setup_needed` (boolean): If true, this user needs to add a Two Factor Authentication method before performing any further actions.
|
42
42
|
* `allowed_2fa_method_sms` (boolean): Sent only if 2FA setup is needed. Is SMS two factor authentication allowed?
|
43
43
|
* `allowed_2fa_method_totp` (boolean): Sent only if 2FA setup is needed. Is TOTP two factor authentication allowed?
|
@@ -908,6 +908,7 @@ module Files
|
|
908
908
|
# parts - int64 - How many parts to fetch?
|
909
909
|
# ref - string -
|
910
910
|
# restart - int64 - File byte offset to restart from.
|
911
|
+
# size - int64 - Total bytes of file being uploaded (include bytes being retained if appending/restarting).
|
911
912
|
# with_rename - boolean - Allow file rename instead of overwrite?
|
912
913
|
def begin_upload(params = {})
|
913
914
|
params ||= {}
|
@@ -918,6 +919,7 @@ module Files
|
|
918
919
|
raise InvalidParameterError.new("Bad parameter: parts must be an Integer") if params.dig(:parts) and !params.dig(:parts).is_a?(Integer)
|
919
920
|
raise InvalidParameterError.new("Bad parameter: ref must be an String") if params.dig(:ref) and !params.dig(:ref).is_a?(String)
|
920
921
|
raise InvalidParameterError.new("Bad parameter: restart must be an Integer") if params.dig(:restart) and !params.dig(:restart).is_a?(Integer)
|
922
|
+
raise InvalidParameterError.new("Bad parameter: size must be an Integer") if params.dig(:size) and !params.dig(:size).is_a?(Integer)
|
921
923
|
raise MissingParameterError.new("Parameter missing: path") unless params.dig(:path)
|
922
924
|
|
923
925
|
Api.send_request("/file_actions/begin_upload/#{@attributes[:path]}", :post, params, @options)
|
@@ -1073,6 +1075,7 @@ module Files
|
|
1073
1075
|
# parts - int64 - How many parts to fetch?
|
1074
1076
|
# ref - string -
|
1075
1077
|
# restart - int64 - File byte offset to restart from.
|
1078
|
+
# size - int64 - Total bytes of file being uploaded (include bytes being retained if appending/restarting).
|
1076
1079
|
# with_rename - boolean - Allow file rename instead of overwrite?
|
1077
1080
|
def self.begin_upload(path, params = {}, options = {})
|
1078
1081
|
params ||= {}
|
@@ -1082,6 +1085,7 @@ module Files
|
|
1082
1085
|
raise InvalidParameterError.new("Bad parameter: parts must be an Integer") if params.dig(:parts) and !params.dig(:parts).is_a?(Integer)
|
1083
1086
|
raise InvalidParameterError.new("Bad parameter: ref must be an String") if params.dig(:ref) and !params.dig(:ref).is_a?(String)
|
1084
1087
|
raise InvalidParameterError.new("Bad parameter: restart must be an Integer") if params.dig(:restart) and !params.dig(:restart).is_a?(Integer)
|
1088
|
+
raise InvalidParameterError.new("Bad parameter: size must be an Integer") if params.dig(:size) and !params.dig(:size).is_a?(Integer)
|
1085
1089
|
raise MissingParameterError.new("Parameter missing: path") unless params.dig(:path)
|
1086
1090
|
|
1087
1091
|
response, options = Api.send_request("/file_actions/begin_upload/#{params[:path]}", :post, params, options)
|
@@ -9,12 +9,12 @@ module Files
|
|
9
9
|
@options = options || {}
|
10
10
|
end
|
11
11
|
|
12
|
-
# string - Status of file operation.
|
12
|
+
# string - Status of file operation.
|
13
13
|
def status
|
14
14
|
@attributes[:status]
|
15
15
|
end
|
16
16
|
|
17
|
-
# int64 - If status is
|
17
|
+
# int64 - If status is pending, this is the id of the FileMigration to check for status updates.
|
18
18
|
def file_migration_id
|
19
19
|
@attributes[:file_migration_id]
|
20
20
|
end
|
@@ -112,7 +112,7 @@ module Files
|
|
112
112
|
@attributes[:ssl_required] = value
|
113
113
|
end
|
114
114
|
|
115
|
-
# boolean -
|
115
|
+
# boolean - Are insecure TLS versions allowed for this user? (If this is set to true, the site administrator has signaled that it is ok to use less secure TLS versions for this user.)
|
116
116
|
def tls_disabled
|
117
117
|
@attributes[:tls_disabled]
|
118
118
|
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.0.
|
4
|
+
version: 1.0.225
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- files.com
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-10-
|
11
|
+
date: 2021-10-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: addressable
|