files.com 1.1.597 → 1.1.599
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/metadata_category.md +139 -0
- data/docs/notification.md +10 -0
- data/docs/sync.md +12 -1
- data/docs/sync_run.md +13 -1
- data/docs/sync_run_live_transfer.md +23 -0
- data/lib/files.com/models/metadata_category.rb +165 -0
- data/lib/files.com/models/notification.rb +20 -0
- data/lib/files.com/models/sync_run.rb +5 -0
- data/lib/files.com/models/sync_run_live_transfer.rb +47 -0
- data/lib/files.com/version.rb +1 -1
- data/lib/files.com.rb +2 -0
- metadata +6 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 64cc6a922c509ca8088eebf8f4588afe2ea532620b021d53fb9faa4d49819215
|
|
4
|
+
data.tar.gz: ff44b071a6ebc13928f00a09a306ac0efa58adec544eef2cc99ce7d824c0c8ea
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 84f3e3d529b8e7a654e1cf3809fa1b58ec30e97a62e2987b956d409f7884fb06131b73c48bf72f633b12716fc0dd3144549165e8d449d3bf3ad8c00cad02c955
|
|
7
|
+
data.tar.gz: b199981cfa1b82388525c337c0421be07caad4cc0d78209f9c99baf88b03416d0dabe809749fadb779b4e6163c1625289af65bf26150381c5aebb3c377d92ce3
|
data/_VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
1.1.
|
|
1
|
+
1.1.599
|
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
# MetadataCategory
|
|
2
|
+
|
|
3
|
+
## Example MetadataCategory Object
|
|
4
|
+
|
|
5
|
+
```
|
|
6
|
+
{
|
|
7
|
+
"id": 1,
|
|
8
|
+
"name": "Approval Workflow",
|
|
9
|
+
"definitions": {
|
|
10
|
+
"Approval Status": [
|
|
11
|
+
"Under Review",
|
|
12
|
+
"Approved",
|
|
13
|
+
"Rejected"
|
|
14
|
+
],
|
|
15
|
+
"Reviewer": [
|
|
16
|
+
|
|
17
|
+
]
|
|
18
|
+
},
|
|
19
|
+
"default_columns": [
|
|
20
|
+
"Approval Status"
|
|
21
|
+
]
|
|
22
|
+
}
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
* `id` (int64): Metadata Category ID
|
|
26
|
+
* `name` (string): Name of the metadata category.
|
|
27
|
+
* `definitions` (hash(string,array(string))): Map of key names to arrays of allowed values. An empty array means free-form text.
|
|
28
|
+
* `default_columns` (array(string)): Metadata keys that should appear as columns in the UI by default.
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
---
|
|
32
|
+
|
|
33
|
+
## List Metadata Categories
|
|
34
|
+
|
|
35
|
+
```
|
|
36
|
+
Files::MetadataCategory.list
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
### Parameters
|
|
40
|
+
|
|
41
|
+
* `cursor` (string): Used for pagination. When a list request has more records available, cursors are provided in the response headers `X-Files-Cursor-Next` and `X-Files-Cursor-Prev`. Send one of those cursor value here to resume an existing list from the next available record. Note: many of our SDKs have iterator methods that will automatically handle cursor-based pagination.
|
|
42
|
+
* `per_page` (int64): Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
|
|
43
|
+
* `sort_by` (object): If set, sort records by the specified field in either `asc` or `desc` direction. Valid fields are .
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
---
|
|
47
|
+
|
|
48
|
+
## Show Metadata Category
|
|
49
|
+
|
|
50
|
+
```
|
|
51
|
+
Files::MetadataCategory.find(id)
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
### Parameters
|
|
55
|
+
|
|
56
|
+
* `id` (int64): Required - Metadata Category ID.
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
---
|
|
60
|
+
|
|
61
|
+
## Create Metadata Category
|
|
62
|
+
|
|
63
|
+
```
|
|
64
|
+
Files::MetadataCategory.create(
|
|
65
|
+
name: "Approval Workflow",
|
|
66
|
+
default_columns: ["Approval Status"]
|
|
67
|
+
)
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
### Parameters
|
|
71
|
+
|
|
72
|
+
* `name` (string): Required - Name of the metadata category.
|
|
73
|
+
* `default_columns` (array(string)): Metadata keys that should appear as columns in the UI by default.
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
---
|
|
77
|
+
|
|
78
|
+
## Update Metadata Category
|
|
79
|
+
|
|
80
|
+
```
|
|
81
|
+
Files::MetadataCategory.update(id,
|
|
82
|
+
name: "Approval Workflow",
|
|
83
|
+
default_columns: ["Approval Status"]
|
|
84
|
+
)
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
### Parameters
|
|
88
|
+
|
|
89
|
+
* `id` (int64): Required - Metadata Category ID.
|
|
90
|
+
* `name` (string): Name of the metadata category.
|
|
91
|
+
* `default_columns` (array(string)): Metadata keys that should appear as columns in the UI by default.
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
---
|
|
95
|
+
|
|
96
|
+
## Delete Metadata Category
|
|
97
|
+
|
|
98
|
+
```
|
|
99
|
+
Files::MetadataCategory.delete(id)
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
### Parameters
|
|
103
|
+
|
|
104
|
+
* `id` (int64): Required - Metadata Category ID.
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
---
|
|
108
|
+
|
|
109
|
+
## Update Metadata Category
|
|
110
|
+
|
|
111
|
+
```
|
|
112
|
+
metadata_category = Files::MetadataCategory.find(id)
|
|
113
|
+
|
|
114
|
+
metadata_category.update(
|
|
115
|
+
name: "Approval Workflow",
|
|
116
|
+
default_columns: ["Approval Status"]
|
|
117
|
+
)
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
### Parameters
|
|
121
|
+
|
|
122
|
+
* `id` (int64): Required - Metadata Category ID.
|
|
123
|
+
* `name` (string): Name of the metadata category.
|
|
124
|
+
* `default_columns` (array(string)): Metadata keys that should appear as columns in the UI by default.
|
|
125
|
+
|
|
126
|
+
|
|
127
|
+
---
|
|
128
|
+
|
|
129
|
+
## Delete Metadata Category
|
|
130
|
+
|
|
131
|
+
```
|
|
132
|
+
metadata_category = Files::MetadataCategory.find(id)
|
|
133
|
+
|
|
134
|
+
metadata_category.delete
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
### Parameters
|
|
138
|
+
|
|
139
|
+
* `id` (int64): Required - Metadata Category ID.
|
data/docs/notification.md
CHANGED
|
@@ -8,6 +8,12 @@
|
|
|
8
8
|
"path": "",
|
|
9
9
|
"group_id": 1,
|
|
10
10
|
"group_name": "example",
|
|
11
|
+
"group_ids": [
|
|
12
|
+
1
|
|
13
|
+
],
|
|
14
|
+
"group_names": [
|
|
15
|
+
"example"
|
|
16
|
+
],
|
|
11
17
|
"triggering_group_ids": [
|
|
12
18
|
1
|
|
13
19
|
],
|
|
@@ -40,6 +46,8 @@
|
|
|
40
46
|
* `path` (string): Folder path to notify on. This must be slash-delimited, but it must neither start nor end with a slash. Maximum of 5000 characters.
|
|
41
47
|
* `group_id` (int64): ID of Group to receive notifications
|
|
42
48
|
* `group_name` (string): Group name, if a Group ID is set
|
|
49
|
+
* `group_ids` (array(int64)): Group IDs when the notification requires multiple groups
|
|
50
|
+
* `group_names` (array(string)): Group names when the notification requires multiple groups
|
|
43
51
|
* `triggering_group_ids` (array(int64)): If set, will only notify on actions made by a member of one of the specified groups
|
|
44
52
|
* `triggering_user_ids` (array(int64)): If set, will only notify on actions made one of the specified users
|
|
45
53
|
* `trigger_by_share_recipients` (boolean): Notify when actions are performed by a share recipient?
|
|
@@ -117,6 +125,7 @@ Files::Notification.create(
|
|
|
117
125
|
triggering_user_ids: [1],
|
|
118
126
|
trigger_by_share_recipients: true,
|
|
119
127
|
group_id: 1,
|
|
128
|
+
group_ids: [1],
|
|
120
129
|
username: "User"
|
|
121
130
|
)
|
|
122
131
|
```
|
|
@@ -138,6 +147,7 @@ Files::Notification.create(
|
|
|
138
147
|
* `triggering_user_ids` (array(int64)): If set, will only notify on actions made one of the specified users
|
|
139
148
|
* `trigger_by_share_recipients` (boolean): Notify when actions are performed by a share recipient?
|
|
140
149
|
* `group_id` (int64): The ID of the group to notify. Provide `user_id`, `username` or `group_id`.
|
|
150
|
+
* `group_ids` (string): Group IDs when the notification requires multiple groups. If sent as a string, it should be comma-delimited.
|
|
141
151
|
* `path` (string): Path
|
|
142
152
|
* `username` (string): The username of the user to notify. Provide `user_id`, `username` or `group_id`.
|
|
143
153
|
|
data/docs/sync.md
CHANGED
|
@@ -68,7 +68,18 @@
|
|
|
68
68
|
"successful_files": 1,
|
|
69
69
|
"sync_id": 1,
|
|
70
70
|
"sync_name": "Azure to SharePoint Sync",
|
|
71
|
-
"updated_at": "2000-01-01T01:00:00Z"
|
|
71
|
+
"updated_at": "2000-01-01T01:00:00Z",
|
|
72
|
+
"live_transfers": [
|
|
73
|
+
{
|
|
74
|
+
"path": "example",
|
|
75
|
+
"status": "example",
|
|
76
|
+
"bytes_copied": 1,
|
|
77
|
+
"bytes_total": 1,
|
|
78
|
+
"percentage": 1.0,
|
|
79
|
+
"eta": "example",
|
|
80
|
+
"started_at": "example"
|
|
81
|
+
}
|
|
82
|
+
]
|
|
72
83
|
}
|
|
73
84
|
}
|
|
74
85
|
```
|
data/docs/sync_run.md
CHANGED
|
@@ -27,7 +27,18 @@
|
|
|
27
27
|
"successful_files": 1,
|
|
28
28
|
"sync_id": 1,
|
|
29
29
|
"sync_name": "Azure to SharePoint Sync",
|
|
30
|
-
"updated_at": "2000-01-01T01:00:00Z"
|
|
30
|
+
"updated_at": "2000-01-01T01:00:00Z",
|
|
31
|
+
"live_transfers": [
|
|
32
|
+
{
|
|
33
|
+
"path": "example",
|
|
34
|
+
"status": "example",
|
|
35
|
+
"bytes_copied": 1,
|
|
36
|
+
"bytes_total": 1,
|
|
37
|
+
"percentage": 1.0,
|
|
38
|
+
"eta": "example",
|
|
39
|
+
"started_at": "example"
|
|
40
|
+
}
|
|
41
|
+
]
|
|
31
42
|
}
|
|
32
43
|
```
|
|
33
44
|
|
|
@@ -53,6 +64,7 @@
|
|
|
53
64
|
* `sync_id` (int64): ID of the Sync this run belongs to
|
|
54
65
|
* `sync_name` (string): Name of the Sync this run belongs to
|
|
55
66
|
* `updated_at` (date-time): When this run was last updated
|
|
67
|
+
* `live_transfers` (array(object)): Array of in-progress file transfers with progress data. Only present when the sync run status is in_progress.
|
|
56
68
|
|
|
57
69
|
|
|
58
70
|
---
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# SyncRunLiveTransfer
|
|
2
|
+
|
|
3
|
+
## Example SyncRunLiveTransfer Object
|
|
4
|
+
|
|
5
|
+
```
|
|
6
|
+
{
|
|
7
|
+
"path": "example",
|
|
8
|
+
"status": "example",
|
|
9
|
+
"bytes_copied": 1,
|
|
10
|
+
"bytes_total": 1,
|
|
11
|
+
"percentage": 1.0,
|
|
12
|
+
"eta": "example",
|
|
13
|
+
"started_at": "example"
|
|
14
|
+
}
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
* `path` (string): The file path being transferred. This must be slash-delimited, but it must neither start nor end with a slash. Maximum of 5000 characters.
|
|
18
|
+
* `status` (string): Status of this individual transfer
|
|
19
|
+
* `bytes_copied` (int64): Bytes transferred so far
|
|
20
|
+
* `bytes_total` (int64): Total bytes of the file being transferred
|
|
21
|
+
* `percentage` (double): Transfer progress from 0.0 to 1.0
|
|
22
|
+
* `eta` (string): Estimated time remaining (human-readable)
|
|
23
|
+
* `started_at` (string): When this individual transfer started
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Files
|
|
4
|
+
class MetadataCategory
|
|
5
|
+
attr_reader :options, :attributes
|
|
6
|
+
|
|
7
|
+
def initialize(attributes = {}, options = {})
|
|
8
|
+
@attributes = attributes || {}
|
|
9
|
+
@options = options || {}
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
# int64 - Metadata Category ID
|
|
13
|
+
def id
|
|
14
|
+
@attributes[:id]
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
def id=(value)
|
|
18
|
+
@attributes[:id] = value
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
# string - Name of the metadata category.
|
|
22
|
+
def name
|
|
23
|
+
@attributes[:name]
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
def name=(value)
|
|
27
|
+
@attributes[:name] = value
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
# hash(string,array(string)) - Map of key names to arrays of allowed values. An empty array means free-form text.
|
|
31
|
+
def definitions
|
|
32
|
+
@attributes[:definitions]
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
def definitions=(value)
|
|
36
|
+
@attributes[:definitions] = value
|
|
37
|
+
end
|
|
38
|
+
|
|
39
|
+
# array(string) - Metadata keys that should appear as columns in the UI by default.
|
|
40
|
+
def default_columns
|
|
41
|
+
@attributes[:default_columns]
|
|
42
|
+
end
|
|
43
|
+
|
|
44
|
+
def default_columns=(value)
|
|
45
|
+
@attributes[:default_columns] = value
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# Parameters:
|
|
49
|
+
# name - string - Name of the metadata category.
|
|
50
|
+
# default_columns - array(string) - Metadata keys that should appear as columns in the UI by default.
|
|
51
|
+
def update(params = {})
|
|
52
|
+
params ||= {}
|
|
53
|
+
params[:id] = @attributes[:id]
|
|
54
|
+
raise MissingParameterError.new("Current object doesn't have a id") unless @attributes[:id]
|
|
55
|
+
raise InvalidParameterError.new("Bad parameter: id must be an Integer") if params[:id] and !params[:id].is_a?(Integer)
|
|
56
|
+
raise InvalidParameterError.new("Bad parameter: name must be an String") if params[:name] and !params[:name].is_a?(String)
|
|
57
|
+
raise InvalidParameterError.new("Bad parameter: default_columns must be an Array") if params[:default_columns] and !params[:default_columns].is_a?(Array)
|
|
58
|
+
raise MissingParameterError.new("Parameter missing: id") unless params[:id]
|
|
59
|
+
|
|
60
|
+
Api.send_request("/metadata_categories/#{@attributes[:id]}", :patch, params, @options)
|
|
61
|
+
end
|
|
62
|
+
|
|
63
|
+
def delete(params = {})
|
|
64
|
+
params ||= {}
|
|
65
|
+
params[:id] = @attributes[:id]
|
|
66
|
+
raise MissingParameterError.new("Current object doesn't have a id") unless @attributes[:id]
|
|
67
|
+
raise InvalidParameterError.new("Bad parameter: id must be an Integer") if params[:id] and !params[:id].is_a?(Integer)
|
|
68
|
+
raise MissingParameterError.new("Parameter missing: id") unless params[:id]
|
|
69
|
+
|
|
70
|
+
Api.send_request("/metadata_categories/#{@attributes[:id]}", :delete, params, @options)
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
def destroy(params = {})
|
|
74
|
+
delete(params)
|
|
75
|
+
nil
|
|
76
|
+
end
|
|
77
|
+
|
|
78
|
+
def save
|
|
79
|
+
if @attributes[:id]
|
|
80
|
+
new_obj = update(@attributes)
|
|
81
|
+
else
|
|
82
|
+
new_obj = MetadataCategory.create(@attributes, @options)
|
|
83
|
+
end
|
|
84
|
+
|
|
85
|
+
@attributes = new_obj.attributes
|
|
86
|
+
true
|
|
87
|
+
end
|
|
88
|
+
|
|
89
|
+
# Parameters:
|
|
90
|
+
# cursor - string - Used for pagination. When a list request has more records available, cursors are provided in the response headers `X-Files-Cursor-Next` and `X-Files-Cursor-Prev`. Send one of those cursor value here to resume an existing list from the next available record. Note: many of our SDKs have iterator methods that will automatically handle cursor-based pagination.
|
|
91
|
+
# per_page - int64 - Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
|
|
92
|
+
# sort_by - object - If set, sort records by the specified field in either `asc` or `desc` direction. Valid fields are .
|
|
93
|
+
def self.list(params = {}, options = {})
|
|
94
|
+
raise InvalidParameterError.new("Bad parameter: cursor must be an String") if params[:cursor] and !params[:cursor].is_a?(String)
|
|
95
|
+
raise InvalidParameterError.new("Bad parameter: per_page must be an Integer") if params[:per_page] and !params[:per_page].is_a?(Integer)
|
|
96
|
+
raise InvalidParameterError.new("Bad parameter: sort_by must be an Hash") if params[:sort_by] and !params[:sort_by].is_a?(Hash)
|
|
97
|
+
|
|
98
|
+
List.new(MetadataCategory, params) do
|
|
99
|
+
Api.send_request("/metadata_categories", :get, params, options)
|
|
100
|
+
end
|
|
101
|
+
end
|
|
102
|
+
|
|
103
|
+
def self.all(params = {}, options = {})
|
|
104
|
+
list(params, options)
|
|
105
|
+
end
|
|
106
|
+
|
|
107
|
+
# Parameters:
|
|
108
|
+
# id (required) - int64 - Metadata Category ID.
|
|
109
|
+
def self.find(id, params = {}, options = {})
|
|
110
|
+
params ||= {}
|
|
111
|
+
params[:id] = id
|
|
112
|
+
raise InvalidParameterError.new("Bad parameter: id must be an Integer") if params[:id] and !params[:id].is_a?(Integer)
|
|
113
|
+
raise MissingParameterError.new("Parameter missing: id") unless params[:id]
|
|
114
|
+
|
|
115
|
+
response, options = Api.send_request("/metadata_categories/#{params[:id]}", :get, params, options)
|
|
116
|
+
MetadataCategory.new(response.data, options)
|
|
117
|
+
end
|
|
118
|
+
|
|
119
|
+
def self.get(id, params = {}, options = {})
|
|
120
|
+
find(id, params, options)
|
|
121
|
+
end
|
|
122
|
+
|
|
123
|
+
# Parameters:
|
|
124
|
+
# name (required) - string - Name of the metadata category.
|
|
125
|
+
# default_columns - array(string) - Metadata keys that should appear as columns in the UI by default.
|
|
126
|
+
def self.create(params = {}, options = {})
|
|
127
|
+
raise InvalidParameterError.new("Bad parameter: name must be an String") if params[:name] and !params[:name].is_a?(String)
|
|
128
|
+
raise InvalidParameterError.new("Bad parameter: default_columns must be an Array") if params[:default_columns] and !params[:default_columns].is_a?(Array)
|
|
129
|
+
raise MissingParameterError.new("Parameter missing: name") unless params[:name]
|
|
130
|
+
|
|
131
|
+
response, options = Api.send_request("/metadata_categories", :post, params, options)
|
|
132
|
+
MetadataCategory.new(response.data, options)
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
# Parameters:
|
|
136
|
+
# name - string - Name of the metadata category.
|
|
137
|
+
# default_columns - array(string) - Metadata keys that should appear as columns in the UI by default.
|
|
138
|
+
def self.update(id, params = {}, options = {})
|
|
139
|
+
params ||= {}
|
|
140
|
+
params[:id] = id
|
|
141
|
+
raise InvalidParameterError.new("Bad parameter: id must be an Integer") if params[:id] and !params[:id].is_a?(Integer)
|
|
142
|
+
raise InvalidParameterError.new("Bad parameter: name must be an String") if params[:name] and !params[:name].is_a?(String)
|
|
143
|
+
raise InvalidParameterError.new("Bad parameter: default_columns must be an Array") if params[:default_columns] and !params[:default_columns].is_a?(Array)
|
|
144
|
+
raise MissingParameterError.new("Parameter missing: id") unless params[:id]
|
|
145
|
+
|
|
146
|
+
response, options = Api.send_request("/metadata_categories/#{params[:id]}", :patch, params, options)
|
|
147
|
+
MetadataCategory.new(response.data, options)
|
|
148
|
+
end
|
|
149
|
+
|
|
150
|
+
def self.delete(id, params = {}, options = {})
|
|
151
|
+
params ||= {}
|
|
152
|
+
params[:id] = id
|
|
153
|
+
raise InvalidParameterError.new("Bad parameter: id must be an Integer") if params[:id] and !params[:id].is_a?(Integer)
|
|
154
|
+
raise MissingParameterError.new("Parameter missing: id") unless params[:id]
|
|
155
|
+
|
|
156
|
+
Api.send_request("/metadata_categories/#{params[:id]}", :delete, params, options)
|
|
157
|
+
nil
|
|
158
|
+
end
|
|
159
|
+
|
|
160
|
+
def self.destroy(id, params = {}, options = {})
|
|
161
|
+
delete(id, params, options)
|
|
162
|
+
nil
|
|
163
|
+
end
|
|
164
|
+
end
|
|
165
|
+
end
|
|
@@ -45,6 +45,24 @@ module Files
|
|
|
45
45
|
@attributes[:group_name] = value
|
|
46
46
|
end
|
|
47
47
|
|
|
48
|
+
# array(int64) - Group IDs when the notification requires multiple groups
|
|
49
|
+
def group_ids
|
|
50
|
+
@attributes[:group_ids]
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
def group_ids=(value)
|
|
54
|
+
@attributes[:group_ids] = value
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
# array(string) - Group names when the notification requires multiple groups
|
|
58
|
+
def group_names
|
|
59
|
+
@attributes[:group_names]
|
|
60
|
+
end
|
|
61
|
+
|
|
62
|
+
def group_names=(value)
|
|
63
|
+
@attributes[:group_names] = value
|
|
64
|
+
end
|
|
65
|
+
|
|
48
66
|
# array(int64) - If set, will only notify on actions made by a member of one of the specified groups
|
|
49
67
|
def triggering_group_ids
|
|
50
68
|
@attributes[:triggering_group_ids]
|
|
@@ -321,6 +339,7 @@ module Files
|
|
|
321
339
|
# triggering_user_ids - array(int64) - If set, will only notify on actions made one of the specified users
|
|
322
340
|
# trigger_by_share_recipients - boolean - Notify when actions are performed by a share recipient?
|
|
323
341
|
# group_id - int64 - The ID of the group to notify. Provide `user_id`, `username` or `group_id`.
|
|
342
|
+
# group_ids - string - Group IDs when the notification requires multiple groups. If sent as a string, it should be comma-delimited.
|
|
324
343
|
# path - string - Path
|
|
325
344
|
# username - string - The username of the user to notify. Provide `user_id`, `username` or `group_id`.
|
|
326
345
|
def self.create(params = {}, options = {})
|
|
@@ -331,6 +350,7 @@ module Files
|
|
|
331
350
|
raise InvalidParameterError.new("Bad parameter: triggering_group_ids must be an Array") if params[:triggering_group_ids] and !params[:triggering_group_ids].is_a?(Array)
|
|
332
351
|
raise InvalidParameterError.new("Bad parameter: triggering_user_ids must be an Array") if params[:triggering_user_ids] and !params[:triggering_user_ids].is_a?(Array)
|
|
333
352
|
raise InvalidParameterError.new("Bad parameter: group_id must be an Integer") if params[:group_id] and !params[:group_id].is_a?(Integer)
|
|
353
|
+
raise InvalidParameterError.new("Bad parameter: group_ids must be an String") if params[:group_ids] and !params[:group_ids].is_a?(String)
|
|
334
354
|
raise InvalidParameterError.new("Bad parameter: path must be an String") if params[:path] and !params[:path].is_a?(String)
|
|
335
355
|
raise InvalidParameterError.new("Bad parameter: username must be an String") if params[:username] and !params[:username].is_a?(String)
|
|
336
356
|
|
|
@@ -119,6 +119,11 @@ module Files
|
|
|
119
119
|
@attributes[:updated_at]
|
|
120
120
|
end
|
|
121
121
|
|
|
122
|
+
# array(object) - Array of in-progress file transfers with progress data. Only present when the sync run status is in_progress.
|
|
123
|
+
def live_transfers
|
|
124
|
+
@attributes[:live_transfers]
|
|
125
|
+
end
|
|
126
|
+
|
|
122
127
|
# Parameters:
|
|
123
128
|
# user_id - int64 - User ID. Provide a value of `0` to operate the current session's user.
|
|
124
129
|
# cursor - string - Used for pagination. When a list request has more records available, cursors are provided in the response headers `X-Files-Cursor-Next` and `X-Files-Cursor-Prev`. Send one of those cursor value here to resume an existing list from the next available record. Note: many of our SDKs have iterator methods that will automatically handle cursor-based pagination.
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Files
|
|
4
|
+
class SyncRunLiveTransfer
|
|
5
|
+
attr_reader :options, :attributes
|
|
6
|
+
|
|
7
|
+
def initialize(attributes = {}, options = {})
|
|
8
|
+
@attributes = attributes || {}
|
|
9
|
+
@options = options || {}
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
# string - The file path being transferred. This must be slash-delimited, but it must neither start nor end with a slash. Maximum of 5000 characters.
|
|
13
|
+
def path
|
|
14
|
+
@attributes[:path]
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
# string - Status of this individual transfer
|
|
18
|
+
def status
|
|
19
|
+
@attributes[:status]
|
|
20
|
+
end
|
|
21
|
+
|
|
22
|
+
# int64 - Bytes transferred so far
|
|
23
|
+
def bytes_copied
|
|
24
|
+
@attributes[:bytes_copied]
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
# int64 - Total bytes of the file being transferred
|
|
28
|
+
def bytes_total
|
|
29
|
+
@attributes[:bytes_total]
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
# double - Transfer progress from 0.0 to 1.0
|
|
33
|
+
def percentage
|
|
34
|
+
@attributes[:percentage]
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
# string - Estimated time remaining (human-readable)
|
|
38
|
+
def eta
|
|
39
|
+
@attributes[:eta]
|
|
40
|
+
end
|
|
41
|
+
|
|
42
|
+
# string - When this individual transfer started
|
|
43
|
+
def started_at
|
|
44
|
+
@attributes[:started_at]
|
|
45
|
+
end
|
|
46
|
+
end
|
|
47
|
+
end
|
data/lib/files.com/version.rb
CHANGED
data/lib/files.com.rb
CHANGED
|
@@ -102,6 +102,7 @@ require "files.com/models/message"
|
|
|
102
102
|
require "files.com/models/message_comment"
|
|
103
103
|
require "files.com/models/message_comment_reaction"
|
|
104
104
|
require "files.com/models/message_reaction"
|
|
105
|
+
require "files.com/models/metadata_category"
|
|
105
106
|
require "files.com/models/notification"
|
|
106
107
|
require "files.com/models/outbound_connection_log"
|
|
107
108
|
require "files.com/models/partner"
|
|
@@ -138,6 +139,7 @@ require "files.com/models/style"
|
|
|
138
139
|
require "files.com/models/sync"
|
|
139
140
|
require "files.com/models/sync_log"
|
|
140
141
|
require "files.com/models/sync_run"
|
|
142
|
+
require "files.com/models/sync_run_live_transfer"
|
|
141
143
|
require "files.com/models/usage_by_top_level_dir"
|
|
142
144
|
require "files.com/models/usage_daily_snapshot"
|
|
143
145
|
require "files.com/models/usage_snapshot"
|
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.
|
|
4
|
+
version: 1.1.599
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- files.com
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-04-
|
|
11
|
+
date: 2026-04-10 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: addressable
|
|
@@ -241,6 +241,7 @@ files:
|
|
|
241
241
|
- docs/message_comment.md
|
|
242
242
|
- docs/message_comment_reaction.md
|
|
243
243
|
- docs/message_reaction.md
|
|
244
|
+
- docs/metadata_category.md
|
|
244
245
|
- docs/notification.md
|
|
245
246
|
- docs/outbound_connection_log.md
|
|
246
247
|
- docs/partner.md
|
|
@@ -277,6 +278,7 @@ files:
|
|
|
277
278
|
- docs/sync.md
|
|
278
279
|
- docs/sync_log.md
|
|
279
280
|
- docs/sync_run.md
|
|
281
|
+
- docs/sync_run_live_transfer.md
|
|
280
282
|
- docs/usage_by_top_level_dir.md
|
|
281
283
|
- docs/usage_daily_snapshot.md
|
|
282
284
|
- docs/usage_snapshot.md
|
|
@@ -367,6 +369,7 @@ files:
|
|
|
367
369
|
- lib/files.com/models/message_comment.rb
|
|
368
370
|
- lib/files.com/models/message_comment_reaction.rb
|
|
369
371
|
- lib/files.com/models/message_reaction.rb
|
|
372
|
+
- lib/files.com/models/metadata_category.rb
|
|
370
373
|
- lib/files.com/models/notification.rb
|
|
371
374
|
- lib/files.com/models/outbound_connection_log.rb
|
|
372
375
|
- lib/files.com/models/partner.rb
|
|
@@ -403,6 +406,7 @@ files:
|
|
|
403
406
|
- lib/files.com/models/sync.rb
|
|
404
407
|
- lib/files.com/models/sync_log.rb
|
|
405
408
|
- lib/files.com/models/sync_run.rb
|
|
409
|
+
- lib/files.com/models/sync_run_live_transfer.rb
|
|
406
410
|
- lib/files.com/models/usage_by_top_level_dir.rb
|
|
407
411
|
- lib/files.com/models/usage_daily_snapshot.rb
|
|
408
412
|
- lib/files.com/models/usage_snapshot.rb
|