@lansweeper/multitenant-api-grpc 0.2.2 → 0.2.4
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.
- package/CHANGELOG.md +16 -0
- package/gen-proto/image.json +1 -1
- package/gen-proto/multitenant_grpc_pb.d.ts +17 -0
- package/gen-proto/multitenant_grpc_pb.js +33 -0
- package/gen-proto/multitenant_pb.d.ts +158 -0
- package/gen-proto/multitenant_pb.js +3031 -1758
- package/package.json +2 -2
- package/proto/multitenant.proto +132 -102
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lansweeper/multitenant-api-grpc",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.4",
|
|
4
4
|
"description": "Multitenant grpc",
|
|
5
5
|
"main": "gen-proto/index.js",
|
|
6
6
|
"types": "gen-proto/index.d.ts",
|
|
@@ -12,5 +12,5 @@
|
|
|
12
12
|
"devDependencies": {
|
|
13
13
|
"@types/google-protobuf": "^3.15.5"
|
|
14
14
|
},
|
|
15
|
-
"gitHead": "
|
|
15
|
+
"gitHead": "37e728e6d02465713106797578e06295b3b2f242"
|
|
16
16
|
}
|
package/proto/multitenant.proto
CHANGED
|
@@ -3,20 +3,20 @@ syntax = "proto3";
|
|
|
3
3
|
package lansweeper.multitenant.v1;
|
|
4
4
|
|
|
5
5
|
message PreviewAccount {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
6
|
+
string id = 1;
|
|
7
|
+
string username = 2;
|
|
8
|
+
string name = 3;
|
|
9
|
+
string surname = 4;
|
|
10
|
+
string email = 5;
|
|
11
|
+
string image_url = 6;
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
message GetPreviewAccountByIdRequest {
|
|
15
|
-
|
|
14
|
+
message GetPreviewAccountByIdRequest {
|
|
15
|
+
string id = 1;
|
|
16
16
|
}
|
|
17
17
|
|
|
18
|
-
message GetPreviewAccountByIdResponse {
|
|
19
|
-
|
|
18
|
+
message GetPreviewAccountByIdResponse {
|
|
19
|
+
PreviewAccount account = 1;
|
|
20
20
|
}
|
|
21
21
|
|
|
22
22
|
|
|
@@ -29,53 +29,58 @@ enum SiteMode {
|
|
|
29
29
|
}
|
|
30
30
|
|
|
31
31
|
message PreviewSite {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
32
|
+
string id = 1;
|
|
33
|
+
string name = 2;
|
|
34
|
+
string company_name = 3;
|
|
35
|
+
string logo_url = 4;
|
|
36
|
+
SiteMode mode = 5;
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
|
|
40
40
|
message PatchSiteModeRequest {
|
|
41
|
-
|
|
42
|
-
|
|
41
|
+
string id = 1;
|
|
42
|
+
SiteMode mode = 2;
|
|
43
43
|
}
|
|
44
44
|
|
|
45
45
|
message PatchSiteModeResponse {
|
|
46
|
-
|
|
46
|
+
bool success = 1;
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
message Profile {
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
50
|
+
string id = 1;
|
|
51
|
+
string site_id = 2;
|
|
52
|
+
PreviewSite site = 3;
|
|
53
|
+
bool is_owner = 4;
|
|
54
54
|
}
|
|
55
55
|
|
|
56
56
|
message ListProfilesByAccountIdRequest{
|
|
57
|
-
|
|
58
|
-
|
|
57
|
+
string account_id = 1;
|
|
58
|
+
bool include_blocks = 2;
|
|
59
59
|
}
|
|
60
60
|
|
|
61
61
|
message ListProfilesByAccountIdResponse {
|
|
62
|
-
|
|
62
|
+
repeated Profile profile = 1;
|
|
63
63
|
}
|
|
64
64
|
|
|
65
65
|
message CheckAccessToSiteByAccountIdRequest {
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
66
|
+
string account_id = 1;
|
|
67
|
+
string site_id = 2;
|
|
68
|
+
bool only_owner = 3;
|
|
69
|
+
message UserInfo {
|
|
70
|
+
bool has_mfa = 1;
|
|
71
|
+
bool is_sso_login = 2;
|
|
72
|
+
}
|
|
73
|
+
UserInfo user_info = 4;
|
|
69
74
|
}
|
|
70
75
|
|
|
71
76
|
message CheckAccessToSiteByAccountIdResponse {
|
|
72
|
-
|
|
77
|
+
bool access = 1;
|
|
73
78
|
}
|
|
74
79
|
|
|
75
80
|
enum InstallStateValue {
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
81
|
+
INSTALL_STATE_VALUE_UNESPECIFIED = 0;
|
|
82
|
+
INSTALL_STATE_VALUE_SYNC = 1;
|
|
83
|
+
INSTALL_STATE_VALUE_UNSYNC = 2;
|
|
79
84
|
}
|
|
80
85
|
|
|
81
86
|
message Install {
|
|
@@ -101,143 +106,168 @@ message InstallCredentials {
|
|
|
101
106
|
}
|
|
102
107
|
|
|
103
108
|
message GetInstallsCountBySiteRequest {
|
|
104
|
-
|
|
109
|
+
string site_id = 1;
|
|
105
110
|
}
|
|
106
111
|
|
|
107
112
|
message GetInstallsCountResponse {
|
|
108
|
-
|
|
113
|
+
int64 count = 1;
|
|
109
114
|
}
|
|
110
115
|
|
|
111
116
|
message GetInstallsBySiteRequest {
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
+
string site_id = 1;
|
|
118
|
+
message Filter {
|
|
119
|
+
InstallStateValue state = 1;
|
|
120
|
+
}
|
|
121
|
+
Filter filter = 2;
|
|
117
122
|
}
|
|
118
123
|
|
|
119
124
|
message GetInstallsBySiteResponse {
|
|
120
|
-
|
|
125
|
+
repeated Install install = 1;
|
|
121
126
|
}
|
|
122
127
|
|
|
123
128
|
message GetInstallbyClientIdRequest {
|
|
124
|
-
|
|
129
|
+
string client_id = 1;
|
|
125
130
|
}
|
|
126
131
|
|
|
127
132
|
message GetInstallbyClientIdResponse {
|
|
128
|
-
|
|
133
|
+
Install install = 1;
|
|
129
134
|
}
|
|
130
135
|
|
|
131
136
|
message CreateInstallRequest{
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
137
|
+
string site_id = 1;
|
|
138
|
+
string global_id = 9;
|
|
139
|
+
string display_name = 3;
|
|
140
|
+
string description = 4;
|
|
141
|
+
string status = 5;
|
|
142
|
+
string fqdn = 6;
|
|
143
|
+
string created_by_id = 7;
|
|
139
144
|
|
|
140
|
-
|
|
145
|
+
bool create_sqs_queue = 8;
|
|
141
146
|
}
|
|
142
147
|
|
|
143
148
|
message CreateInstallResponse{
|
|
144
|
-
|
|
145
|
-
|
|
149
|
+
Install install = 1;
|
|
150
|
+
InstallCredentials credentials = 2;
|
|
146
151
|
}
|
|
147
152
|
|
|
148
153
|
message UpdateInstallByClientIdRequest{
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
154
|
+
string client_id = 1;
|
|
155
|
+
string display_name = 2;
|
|
156
|
+
string description = 3;
|
|
157
|
+
string status = 4;
|
|
158
|
+
string fqdn = 5;
|
|
159
|
+
|
|
160
|
+
message SyncerSettings {
|
|
161
|
+
string send_changed_data_timeout = 1;
|
|
162
|
+
string send_fast_changing_data_timeout = 2;
|
|
163
|
+
string send_non_changed_data_timeout = 3;
|
|
164
|
+
string sync_interval_in_seconds = 4;
|
|
165
|
+
}
|
|
161
166
|
|
|
162
|
-
|
|
167
|
+
SyncerSettings syncer_settings = 6;
|
|
163
168
|
}
|
|
164
169
|
|
|
165
170
|
message UpdateInstallByClientIdResponse{
|
|
166
|
-
|
|
171
|
+
Install install = 1;
|
|
167
172
|
}
|
|
168
173
|
|
|
169
174
|
message RotateInstallByClientIdRequest{
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
}
|
|
175
|
+
string client_id = 1;
|
|
176
|
+
string track_id = 2;
|
|
177
|
+
}
|
|
173
178
|
|
|
174
179
|
message RotateInstallByClientIdResponse {
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
180
|
+
bool success = 1;
|
|
181
|
+
string site_id = 2;
|
|
182
|
+
string old_install_id = 3;
|
|
183
|
+
string new_install_id = 4;
|
|
179
184
|
}
|
|
180
185
|
|
|
181
186
|
message UnlinkInstallByClientIdRequest {
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
187
|
+
string client_id = 1;
|
|
188
|
+
string track_id = 2;
|
|
189
|
+
bool remove_data = 3;
|
|
190
|
+
bool from_onprem = 4;
|
|
186
191
|
}
|
|
187
192
|
|
|
188
193
|
message UnlinkInstallByClientIdResponse {
|
|
189
|
-
|
|
194
|
+
bool success = 1;
|
|
190
195
|
}
|
|
191
196
|
|
|
192
197
|
message RemoveInstallDataBySiteIdRequest {
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
198
|
+
string site_id = 1;
|
|
199
|
+
repeated string install_ids = 2;
|
|
200
|
+
string user_id = 3;
|
|
196
201
|
}
|
|
197
202
|
|
|
198
203
|
message RemoveInstallDataBySiteIdResponse {
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
+
message Result {
|
|
205
|
+
string install_id = 1;
|
|
206
|
+
bool queued = 2;
|
|
207
|
+
}
|
|
208
|
+
repeated Result result = 1;
|
|
204
209
|
}
|
|
205
210
|
|
|
206
211
|
message GetDuplicatedInstallsByGlobalIdRequest {
|
|
207
|
-
|
|
208
|
-
|
|
212
|
+
string site_id = 1;
|
|
213
|
+
string global_id = 2;
|
|
209
214
|
}
|
|
210
215
|
|
|
211
216
|
message GetDuplicatedInstallsByGlobalIdResponse {
|
|
212
|
-
|
|
217
|
+
repeated Install install = 1;
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
message GetUserPermissionsRequest {
|
|
221
|
+
string site_id = 1;
|
|
222
|
+
string account_id = 2;
|
|
213
223
|
}
|
|
214
224
|
|
|
225
|
+
message GetUserPermissionsResponse {
|
|
226
|
+
message AuthorizationAction {
|
|
227
|
+
string key = 1;
|
|
228
|
+
bytes derived_permissions = 2;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
message Scope {
|
|
232
|
+
string id = 1;
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
message Role {
|
|
236
|
+
string id = 1;
|
|
237
|
+
repeated AuthorizationAction actions = 2;
|
|
238
|
+
repeated Install installations = 3;
|
|
239
|
+
repeated Scope scopes = 4;
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
repeated Role roles = 1;
|
|
243
|
+
}
|
|
215
244
|
|
|
216
245
|
service Multitenant {
|
|
217
|
-
|
|
246
|
+
rpc CheckAccessToSiteByAccountId(CheckAccessToSiteByAccountIdRequest) returns (CheckAccessToSiteByAccountIdResponse) {}
|
|
218
247
|
|
|
219
|
-
|
|
248
|
+
rpc GetPreviewAccountById(GetPreviewAccountByIdRequest) returns (GetPreviewAccountByIdResponse) {}
|
|
220
249
|
|
|
221
|
-
|
|
250
|
+
rpc ListProfilesByAccountId(ListProfilesByAccountIdRequest) returns (ListProfilesByAccountIdResponse) {}
|
|
222
251
|
|
|
223
|
-
|
|
252
|
+
rpc PatchSiteMode(PatchSiteModeRequest) returns (PatchSiteModeResponse) {}
|
|
224
253
|
|
|
225
|
-
|
|
254
|
+
rpc CreateInstall(CreateInstallRequest) returns (CreateInstallResponse) {}
|
|
226
255
|
|
|
227
|
-
|
|
256
|
+
rpc GetInstallsBySite(GetInstallsBySiteRequest) returns (GetInstallsBySiteResponse) {}
|
|
228
257
|
|
|
229
|
-
|
|
258
|
+
rpc GetInstallsCountBySite(GetInstallsCountBySiteRequest) returns (GetInstallsCountResponse) {}
|
|
230
259
|
|
|
231
|
-
|
|
260
|
+
rpc GetInstallbyClientId(GetInstallbyClientIdRequest) returns (GetInstallbyClientIdResponse) {}
|
|
232
261
|
|
|
233
|
-
|
|
262
|
+
rpc UpdateInstallByClientId(UpdateInstallByClientIdRequest) returns (UpdateInstallByClientIdResponse) {}
|
|
234
263
|
|
|
235
|
-
|
|
264
|
+
rpc RotateInstallByClientId(RotateInstallByClientIdRequest) returns (RotateInstallByClientIdResponse) {}
|
|
236
265
|
|
|
237
|
-
|
|
266
|
+
rpc UnlinkInstallByClientId(UnlinkInstallByClientIdRequest) returns (UnlinkInstallByClientIdResponse) {}
|
|
238
267
|
|
|
239
|
-
|
|
268
|
+
rpc RemoveInstallDataBySiteId(RemoveInstallDataBySiteIdRequest) returns (RemoveInstallDataBySiteIdResponse) {}
|
|
240
269
|
|
|
241
|
-
|
|
270
|
+
rpc GetDuplicatedInstallsByGlobalId(GetDuplicatedInstallsByGlobalIdRequest) returns (GetDuplicatedInstallsByGlobalIdResponse) {}
|
|
242
271
|
|
|
272
|
+
rpc GetUserPermissions(GetUserPermissionsRequest) returns (GetUserPermissionsResponse) {}
|
|
243
273
|
}
|