@scalekit-sdk/node 2.1.2 → 2.1.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/README.md +47 -11
- package/buf.gen.yaml +3 -0
- package/lib/core.js +1 -1
- package/lib/permission.d.ts +68 -0
- package/lib/permission.js +131 -0
- package/lib/permission.js.map +1 -0
- package/lib/pkg/grpc/scalekit/v1/auditlogs/auditlogs_connect.d.ts +19 -0
- package/lib/pkg/grpc/scalekit/v1/auditlogs/auditlogs_connect.js +27 -0
- package/lib/pkg/grpc/scalekit/v1/auditlogs/auditlogs_connect.js.map +1 -0
- package/lib/pkg/grpc/scalekit/v1/auditlogs/auditlogs_pb.d.ts +154 -0
- package/lib/pkg/grpc/scalekit/v1/auditlogs/auditlogs_pb.js +226 -0
- package/lib/pkg/grpc/scalekit/v1/auditlogs/auditlogs_pb.js.map +1 -0
- package/lib/pkg/grpc/scalekit/v1/commons/commons_pb.d.ts +2 -2
- package/lib/pkg/grpc/scalekit/v1/commons/commons_pb.js +1 -1
- package/lib/pkg/grpc/scalekit/v1/commons/commons_pb.js.map +1 -1
- package/lib/pkg/grpc/scalekit/v1/connections/connections_pb.d.ts +16 -0
- package/lib/pkg/grpc/scalekit/v1/connections/connections_pb.js +4 -0
- package/lib/pkg/grpc/scalekit/v1/connections/connections_pb.js.map +1 -1
- package/lib/pkg/grpc/scalekit/v1/domains/domains_pb.d.ts +0 -8
- package/lib/pkg/grpc/scalekit/v1/domains/domains_pb.js +0 -6
- package/lib/pkg/grpc/scalekit/v1/domains/domains_pb.js.map +1 -1
- package/lib/pkg/grpc/scalekit/v1/roles/roles_connect.d.ts +250 -0
- package/lib/pkg/grpc/scalekit/v1/roles/roles_connect.js +258 -0
- package/lib/pkg/grpc/scalekit/v1/roles/roles_connect.js.map +1 -0
- package/lib/pkg/grpc/scalekit/v1/roles/roles_pb.d.ts +1157 -0
- package/lib/pkg/grpc/scalekit/v1/roles/roles_pb.js +1799 -0
- package/lib/pkg/grpc/scalekit/v1/roles/roles_pb.js.map +1 -0
- package/lib/pkg/grpc/scalekit/v1/sessions/sessions_connect.d.ts +46 -0
- package/lib/pkg/grpc/scalekit/v1/sessions/sessions_connect.js +54 -0
- package/lib/pkg/grpc/scalekit/v1/sessions/sessions_connect.js.map +1 -0
- package/lib/pkg/grpc/scalekit/v1/sessions/sessions_pb.d.ts +377 -0
- package/lib/pkg/grpc/scalekit/v1/sessions/sessions_pb.js +513 -0
- package/lib/pkg/grpc/scalekit/v1/sessions/sessions_pb.js.map +1 -0
- package/lib/pkg/grpc/scalekit/v1/users/users_pb.d.ts +2 -2
- package/lib/pkg/grpc/scalekit/v1/users/users_pb.js +1 -1
- package/lib/pkg/grpc/scalekit/v1/users/users_pb.js.map +1 -1
- package/lib/role.d.ts +104 -0
- package/lib/role.js +205 -0
- package/lib/role.js.map +1 -0
- package/lib/scalekit.d.ts +6 -0
- package/lib/scalekit.js +6 -0
- package/lib/scalekit.js.map +1 -1
- package/lib/session.d.ts +48 -0
- package/lib/session.js +101 -0
- package/lib/session.js.map +1 -0
- package/package.json +1 -1
- package/src/core.ts +1 -1
- package/src/permission.ts +164 -0
- package/src/pkg/grpc/scalekit/v1/auditlogs/auditlogs_connect.ts +26 -0
- package/src/pkg/grpc/scalekit/v1/auditlogs/auditlogs_pb.ts +282 -0
- package/src/pkg/grpc/scalekit/v1/commons/commons_pb.ts +3 -3
- package/src/pkg/grpc/scalekit/v1/connections/connections_pb.ts +24 -0
- package/src/pkg/grpc/scalekit/v1/domains/domains_pb.ts +0 -12
- package/src/pkg/grpc/scalekit/v1/roles/roles_connect.ts +257 -0
- package/src/pkg/grpc/scalekit/v1/roles/roles_pb.ts +2357 -0
- package/src/pkg/grpc/scalekit/v1/sessions/sessions_connect.ts +53 -0
- package/src/pkg/grpc/scalekit/v1/sessions/sessions_pb.ts +697 -0
- package/src/pkg/grpc/scalekit/v1/users/users_pb.ts +3 -3
- package/src/role.ts +261 -0
- package/src/scalekit.ts +18 -0
- package/src/session.ts +134 -0
- package/tests/permission.test.ts +399 -0
- package/tests/role.test.ts +323 -0
- package/tests/utils/test-data.ts +168 -1
|
@@ -0,0 +1,697 @@
|
|
|
1
|
+
// @generated by protoc-gen-es v1.10.0 with parameter "target=ts"
|
|
2
|
+
// @generated from file scalekit/v1/sessions/sessions.proto (package scalekit.v1.sessions, syntax proto3)
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
// @ts-nocheck
|
|
5
|
+
|
|
6
|
+
import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage } from "@bufbuild/protobuf";
|
|
7
|
+
import { Message, proto3, Timestamp } from "@bufbuild/protobuf";
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* @generated from message scalekit.v1.sessions.SessionDetailsRequest
|
|
11
|
+
*/
|
|
12
|
+
export class SessionDetailsRequest extends Message<SessionDetailsRequest> {
|
|
13
|
+
/**
|
|
14
|
+
* @generated from field: string session_id = 1;
|
|
15
|
+
*/
|
|
16
|
+
sessionId = "";
|
|
17
|
+
|
|
18
|
+
constructor(data?: PartialMessage<SessionDetailsRequest>) {
|
|
19
|
+
super();
|
|
20
|
+
proto3.util.initPartial(data, this);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
static readonly runtime: typeof proto3 = proto3;
|
|
24
|
+
static readonly typeName = "scalekit.v1.sessions.SessionDetailsRequest";
|
|
25
|
+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
|
|
26
|
+
{ no: 1, name: "session_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
27
|
+
]);
|
|
28
|
+
|
|
29
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): SessionDetailsRequest {
|
|
30
|
+
return new SessionDetailsRequest().fromBinary(bytes, options);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): SessionDetailsRequest {
|
|
34
|
+
return new SessionDetailsRequest().fromJson(jsonValue, options);
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): SessionDetailsRequest {
|
|
38
|
+
return new SessionDetailsRequest().fromJsonString(jsonString, options);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
static equals(a: SessionDetailsRequest | PlainMessage<SessionDetailsRequest> | undefined, b: SessionDetailsRequest | PlainMessage<SessionDetailsRequest> | undefined): boolean {
|
|
42
|
+
return proto3.util.equals(SessionDetailsRequest, a, b);
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* @generated from message scalekit.v1.sessions.UserSessionDetailsRequest
|
|
48
|
+
*/
|
|
49
|
+
export class UserSessionDetailsRequest extends Message<UserSessionDetailsRequest> {
|
|
50
|
+
/**
|
|
51
|
+
* @generated from field: string user_id = 1;
|
|
52
|
+
*/
|
|
53
|
+
userId = "";
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* @generated from field: uint32 page_size = 2;
|
|
57
|
+
*/
|
|
58
|
+
pageSize = 0;
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* @generated from field: string page_token = 3;
|
|
62
|
+
*/
|
|
63
|
+
pageToken = "";
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* @generated from field: scalekit.v1.sessions.UserSessionFilter filter = 4;
|
|
67
|
+
*/
|
|
68
|
+
filter?: UserSessionFilter;
|
|
69
|
+
|
|
70
|
+
constructor(data?: PartialMessage<UserSessionDetailsRequest>) {
|
|
71
|
+
super();
|
|
72
|
+
proto3.util.initPartial(data, this);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
static readonly runtime: typeof proto3 = proto3;
|
|
76
|
+
static readonly typeName = "scalekit.v1.sessions.UserSessionDetailsRequest";
|
|
77
|
+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
|
|
78
|
+
{ no: 1, name: "user_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
79
|
+
{ no: 2, name: "page_size", kind: "scalar", T: 13 /* ScalarType.UINT32 */ },
|
|
80
|
+
{ no: 3, name: "page_token", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
81
|
+
{ no: 4, name: "filter", kind: "message", T: UserSessionFilter },
|
|
82
|
+
]);
|
|
83
|
+
|
|
84
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UserSessionDetailsRequest {
|
|
85
|
+
return new UserSessionDetailsRequest().fromBinary(bytes, options);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UserSessionDetailsRequest {
|
|
89
|
+
return new UserSessionDetailsRequest().fromJson(jsonValue, options);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UserSessionDetailsRequest {
|
|
93
|
+
return new UserSessionDetailsRequest().fromJsonString(jsonString, options);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
static equals(a: UserSessionDetailsRequest | PlainMessage<UserSessionDetailsRequest> | undefined, b: UserSessionDetailsRequest | PlainMessage<UserSessionDetailsRequest> | undefined): boolean {
|
|
97
|
+
return proto3.util.equals(UserSessionDetailsRequest, a, b);
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
/**
|
|
102
|
+
* @generated from message scalekit.v1.sessions.UserSessionFilter
|
|
103
|
+
*/
|
|
104
|
+
export class UserSessionFilter extends Message<UserSessionFilter> {
|
|
105
|
+
/**
|
|
106
|
+
* @generated from field: repeated string status = 1;
|
|
107
|
+
*/
|
|
108
|
+
status: string[] = [];
|
|
109
|
+
|
|
110
|
+
/**
|
|
111
|
+
* @generated from field: google.protobuf.Timestamp start_time = 2;
|
|
112
|
+
*/
|
|
113
|
+
startTime?: Timestamp;
|
|
114
|
+
|
|
115
|
+
/**
|
|
116
|
+
* @generated from field: google.protobuf.Timestamp end_time = 3;
|
|
117
|
+
*/
|
|
118
|
+
endTime?: Timestamp;
|
|
119
|
+
|
|
120
|
+
constructor(data?: PartialMessage<UserSessionFilter>) {
|
|
121
|
+
super();
|
|
122
|
+
proto3.util.initPartial(data, this);
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
static readonly runtime: typeof proto3 = proto3;
|
|
126
|
+
static readonly typeName = "scalekit.v1.sessions.UserSessionFilter";
|
|
127
|
+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
|
|
128
|
+
{ no: 1, name: "status", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true },
|
|
129
|
+
{ no: 2, name: "start_time", kind: "message", T: Timestamp },
|
|
130
|
+
{ no: 3, name: "end_time", kind: "message", T: Timestamp },
|
|
131
|
+
]);
|
|
132
|
+
|
|
133
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UserSessionFilter {
|
|
134
|
+
return new UserSessionFilter().fromBinary(bytes, options);
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UserSessionFilter {
|
|
138
|
+
return new UserSessionFilter().fromJson(jsonValue, options);
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UserSessionFilter {
|
|
142
|
+
return new UserSessionFilter().fromJsonString(jsonString, options);
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
static equals(a: UserSessionFilter | PlainMessage<UserSessionFilter> | undefined, b: UserSessionFilter | PlainMessage<UserSessionFilter> | undefined): boolean {
|
|
146
|
+
return proto3.util.equals(UserSessionFilter, a, b);
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
/**
|
|
151
|
+
* @generated from message scalekit.v1.sessions.RevokeSessionRequest
|
|
152
|
+
*/
|
|
153
|
+
export class RevokeSessionRequest extends Message<RevokeSessionRequest> {
|
|
154
|
+
/**
|
|
155
|
+
* @generated from field: string session_id = 1;
|
|
156
|
+
*/
|
|
157
|
+
sessionId = "";
|
|
158
|
+
|
|
159
|
+
constructor(data?: PartialMessage<RevokeSessionRequest>) {
|
|
160
|
+
super();
|
|
161
|
+
proto3.util.initPartial(data, this);
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
static readonly runtime: typeof proto3 = proto3;
|
|
165
|
+
static readonly typeName = "scalekit.v1.sessions.RevokeSessionRequest";
|
|
166
|
+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
|
|
167
|
+
{ no: 1, name: "session_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
168
|
+
]);
|
|
169
|
+
|
|
170
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): RevokeSessionRequest {
|
|
171
|
+
return new RevokeSessionRequest().fromBinary(bytes, options);
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): RevokeSessionRequest {
|
|
175
|
+
return new RevokeSessionRequest().fromJson(jsonValue, options);
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): RevokeSessionRequest {
|
|
179
|
+
return new RevokeSessionRequest().fromJsonString(jsonString, options);
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
static equals(a: RevokeSessionRequest | PlainMessage<RevokeSessionRequest> | undefined, b: RevokeSessionRequest | PlainMessage<RevokeSessionRequest> | undefined): boolean {
|
|
183
|
+
return proto3.util.equals(RevokeSessionRequest, a, b);
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
/**
|
|
188
|
+
* @generated from message scalekit.v1.sessions.RevokeSessionResponse
|
|
189
|
+
*/
|
|
190
|
+
export class RevokeSessionResponse extends Message<RevokeSessionResponse> {
|
|
191
|
+
/**
|
|
192
|
+
* @generated from field: scalekit.v1.sessions.RevokedSessionDetails revoked_session = 1;
|
|
193
|
+
*/
|
|
194
|
+
revokedSession?: RevokedSessionDetails;
|
|
195
|
+
|
|
196
|
+
constructor(data?: PartialMessage<RevokeSessionResponse>) {
|
|
197
|
+
super();
|
|
198
|
+
proto3.util.initPartial(data, this);
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
static readonly runtime: typeof proto3 = proto3;
|
|
202
|
+
static readonly typeName = "scalekit.v1.sessions.RevokeSessionResponse";
|
|
203
|
+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
|
|
204
|
+
{ no: 1, name: "revoked_session", kind: "message", T: RevokedSessionDetails },
|
|
205
|
+
]);
|
|
206
|
+
|
|
207
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): RevokeSessionResponse {
|
|
208
|
+
return new RevokeSessionResponse().fromBinary(bytes, options);
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): RevokeSessionResponse {
|
|
212
|
+
return new RevokeSessionResponse().fromJson(jsonValue, options);
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): RevokeSessionResponse {
|
|
216
|
+
return new RevokeSessionResponse().fromJsonString(jsonString, options);
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
static equals(a: RevokeSessionResponse | PlainMessage<RevokeSessionResponse> | undefined, b: RevokeSessionResponse | PlainMessage<RevokeSessionResponse> | undefined): boolean {
|
|
220
|
+
return proto3.util.equals(RevokeSessionResponse, a, b);
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
/**
|
|
225
|
+
* @generated from message scalekit.v1.sessions.RevokeAllUserSessionsRequest
|
|
226
|
+
*/
|
|
227
|
+
export class RevokeAllUserSessionsRequest extends Message<RevokeAllUserSessionsRequest> {
|
|
228
|
+
/**
|
|
229
|
+
* @generated from field: string user_id = 1;
|
|
230
|
+
*/
|
|
231
|
+
userId = "";
|
|
232
|
+
|
|
233
|
+
constructor(data?: PartialMessage<RevokeAllUserSessionsRequest>) {
|
|
234
|
+
super();
|
|
235
|
+
proto3.util.initPartial(data, this);
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
static readonly runtime: typeof proto3 = proto3;
|
|
239
|
+
static readonly typeName = "scalekit.v1.sessions.RevokeAllUserSessionsRequest";
|
|
240
|
+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
|
|
241
|
+
{ no: 1, name: "user_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
242
|
+
]);
|
|
243
|
+
|
|
244
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): RevokeAllUserSessionsRequest {
|
|
245
|
+
return new RevokeAllUserSessionsRequest().fromBinary(bytes, options);
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): RevokeAllUserSessionsRequest {
|
|
249
|
+
return new RevokeAllUserSessionsRequest().fromJson(jsonValue, options);
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): RevokeAllUserSessionsRequest {
|
|
253
|
+
return new RevokeAllUserSessionsRequest().fromJsonString(jsonString, options);
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
static equals(a: RevokeAllUserSessionsRequest | PlainMessage<RevokeAllUserSessionsRequest> | undefined, b: RevokeAllUserSessionsRequest | PlainMessage<RevokeAllUserSessionsRequest> | undefined): boolean {
|
|
257
|
+
return proto3.util.equals(RevokeAllUserSessionsRequest, a, b);
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
/**
|
|
262
|
+
* @generated from message scalekit.v1.sessions.RevokeAllUserSessionsResponse
|
|
263
|
+
*/
|
|
264
|
+
export class RevokeAllUserSessionsResponse extends Message<RevokeAllUserSessionsResponse> {
|
|
265
|
+
/**
|
|
266
|
+
* @generated from field: repeated scalekit.v1.sessions.RevokedSessionDetails revoked_sessions = 1;
|
|
267
|
+
*/
|
|
268
|
+
revokedSessions: RevokedSessionDetails[] = [];
|
|
269
|
+
|
|
270
|
+
/**
|
|
271
|
+
* @generated from field: uint32 total_revoked = 2;
|
|
272
|
+
*/
|
|
273
|
+
totalRevoked = 0;
|
|
274
|
+
|
|
275
|
+
constructor(data?: PartialMessage<RevokeAllUserSessionsResponse>) {
|
|
276
|
+
super();
|
|
277
|
+
proto3.util.initPartial(data, this);
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
static readonly runtime: typeof proto3 = proto3;
|
|
281
|
+
static readonly typeName = "scalekit.v1.sessions.RevokeAllUserSessionsResponse";
|
|
282
|
+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
|
|
283
|
+
{ no: 1, name: "revoked_sessions", kind: "message", T: RevokedSessionDetails, repeated: true },
|
|
284
|
+
{ no: 2, name: "total_revoked", kind: "scalar", T: 13 /* ScalarType.UINT32 */ },
|
|
285
|
+
]);
|
|
286
|
+
|
|
287
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): RevokeAllUserSessionsResponse {
|
|
288
|
+
return new RevokeAllUserSessionsResponse().fromBinary(bytes, options);
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): RevokeAllUserSessionsResponse {
|
|
292
|
+
return new RevokeAllUserSessionsResponse().fromJson(jsonValue, options);
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): RevokeAllUserSessionsResponse {
|
|
296
|
+
return new RevokeAllUserSessionsResponse().fromJsonString(jsonString, options);
|
|
297
|
+
}
|
|
298
|
+
|
|
299
|
+
static equals(a: RevokeAllUserSessionsResponse | PlainMessage<RevokeAllUserSessionsResponse> | undefined, b: RevokeAllUserSessionsResponse | PlainMessage<RevokeAllUserSessionsResponse> | undefined): boolean {
|
|
300
|
+
return proto3.util.equals(RevokeAllUserSessionsResponse, a, b);
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
/**
|
|
305
|
+
* @generated from message scalekit.v1.sessions.UserSessionDetails
|
|
306
|
+
*/
|
|
307
|
+
export class UserSessionDetails extends Message<UserSessionDetails> {
|
|
308
|
+
/**
|
|
309
|
+
* @generated from field: repeated scalekit.v1.sessions.SessionDetails sessions = 1;
|
|
310
|
+
*/
|
|
311
|
+
sessions: SessionDetails[] = [];
|
|
312
|
+
|
|
313
|
+
/**
|
|
314
|
+
* @generated from field: string next_page_token = 2;
|
|
315
|
+
*/
|
|
316
|
+
nextPageToken = "";
|
|
317
|
+
|
|
318
|
+
/**
|
|
319
|
+
* @generated from field: string prev_page_token = 3;
|
|
320
|
+
*/
|
|
321
|
+
prevPageToken = "";
|
|
322
|
+
|
|
323
|
+
/**
|
|
324
|
+
* @generated from field: uint32 total_size = 4;
|
|
325
|
+
*/
|
|
326
|
+
totalSize = 0;
|
|
327
|
+
|
|
328
|
+
constructor(data?: PartialMessage<UserSessionDetails>) {
|
|
329
|
+
super();
|
|
330
|
+
proto3.util.initPartial(data, this);
|
|
331
|
+
}
|
|
332
|
+
|
|
333
|
+
static readonly runtime: typeof proto3 = proto3;
|
|
334
|
+
static readonly typeName = "scalekit.v1.sessions.UserSessionDetails";
|
|
335
|
+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
|
|
336
|
+
{ no: 1, name: "sessions", kind: "message", T: SessionDetails, repeated: true },
|
|
337
|
+
{ no: 2, name: "next_page_token", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
338
|
+
{ no: 3, name: "prev_page_token", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
339
|
+
{ no: 4, name: "total_size", kind: "scalar", T: 13 /* ScalarType.UINT32 */ },
|
|
340
|
+
]);
|
|
341
|
+
|
|
342
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UserSessionDetails {
|
|
343
|
+
return new UserSessionDetails().fromBinary(bytes, options);
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UserSessionDetails {
|
|
347
|
+
return new UserSessionDetails().fromJson(jsonValue, options);
|
|
348
|
+
}
|
|
349
|
+
|
|
350
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UserSessionDetails {
|
|
351
|
+
return new UserSessionDetails().fromJsonString(jsonString, options);
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
static equals(a: UserSessionDetails | PlainMessage<UserSessionDetails> | undefined, b: UserSessionDetails | PlainMessage<UserSessionDetails> | undefined): boolean {
|
|
355
|
+
return proto3.util.equals(UserSessionDetails, a, b);
|
|
356
|
+
}
|
|
357
|
+
}
|
|
358
|
+
|
|
359
|
+
/**
|
|
360
|
+
* @generated from message scalekit.v1.sessions.SessionDetails
|
|
361
|
+
*/
|
|
362
|
+
export class SessionDetails extends Message<SessionDetails> {
|
|
363
|
+
/**
|
|
364
|
+
* @generated from field: string session_id = 1;
|
|
365
|
+
*/
|
|
366
|
+
sessionId = "";
|
|
367
|
+
|
|
368
|
+
/**
|
|
369
|
+
* @generated from field: string user_id = 2;
|
|
370
|
+
*/
|
|
371
|
+
userId = "";
|
|
372
|
+
|
|
373
|
+
/**
|
|
374
|
+
* @generated from field: repeated string authenticated_organizations = 3;
|
|
375
|
+
*/
|
|
376
|
+
authenticatedOrganizations: string[] = [];
|
|
377
|
+
|
|
378
|
+
/**
|
|
379
|
+
* @generated from field: string organization_id = 4;
|
|
380
|
+
*/
|
|
381
|
+
organizationId = "";
|
|
382
|
+
|
|
383
|
+
/**
|
|
384
|
+
* @generated from field: google.protobuf.Timestamp created_at = 5;
|
|
385
|
+
*/
|
|
386
|
+
createdAt?: Timestamp;
|
|
387
|
+
|
|
388
|
+
/**
|
|
389
|
+
* @generated from field: google.protobuf.Timestamp updated_at = 6;
|
|
390
|
+
*/
|
|
391
|
+
updatedAt?: Timestamp;
|
|
392
|
+
|
|
393
|
+
/**
|
|
394
|
+
* @generated from field: google.protobuf.Timestamp idle_expires_at = 7;
|
|
395
|
+
*/
|
|
396
|
+
idleExpiresAt?: Timestamp;
|
|
397
|
+
|
|
398
|
+
/**
|
|
399
|
+
* @generated from field: google.protobuf.Timestamp absolute_expires_at = 8;
|
|
400
|
+
*/
|
|
401
|
+
absoluteExpiresAt?: Timestamp;
|
|
402
|
+
|
|
403
|
+
/**
|
|
404
|
+
* @generated from field: google.protobuf.Timestamp expired_at = 9;
|
|
405
|
+
*/
|
|
406
|
+
expiredAt?: Timestamp;
|
|
407
|
+
|
|
408
|
+
/**
|
|
409
|
+
* @generated from field: google.protobuf.Timestamp logout_at = 10;
|
|
410
|
+
*/
|
|
411
|
+
logoutAt?: Timestamp;
|
|
412
|
+
|
|
413
|
+
/**
|
|
414
|
+
* @generated from field: string status = 11;
|
|
415
|
+
*/
|
|
416
|
+
status = "";
|
|
417
|
+
|
|
418
|
+
/**
|
|
419
|
+
* @generated from field: string initial_user_agent = 12;
|
|
420
|
+
*/
|
|
421
|
+
initialUserAgent = "";
|
|
422
|
+
|
|
423
|
+
/**
|
|
424
|
+
* @generated from field: string initial_os = 13;
|
|
425
|
+
*/
|
|
426
|
+
initialOs = "";
|
|
427
|
+
|
|
428
|
+
/**
|
|
429
|
+
* @generated from field: string initial_os_version = 14;
|
|
430
|
+
*/
|
|
431
|
+
initialOsVersion = "";
|
|
432
|
+
|
|
433
|
+
/**
|
|
434
|
+
* @generated from field: string initial_browser = 15;
|
|
435
|
+
*/
|
|
436
|
+
initialBrowser = "";
|
|
437
|
+
|
|
438
|
+
/**
|
|
439
|
+
* @generated from field: string initial_browser_version = 16;
|
|
440
|
+
*/
|
|
441
|
+
initialBrowserVersion = "";
|
|
442
|
+
|
|
443
|
+
/**
|
|
444
|
+
* @generated from field: string initial_device_type = 17;
|
|
445
|
+
*/
|
|
446
|
+
initialDeviceType = "";
|
|
447
|
+
|
|
448
|
+
/**
|
|
449
|
+
* @generated from field: string initial_ip = 19;
|
|
450
|
+
*/
|
|
451
|
+
initialIp = "";
|
|
452
|
+
|
|
453
|
+
/**
|
|
454
|
+
* @generated from field: scalekit.v1.sessions.Location initial_location = 20;
|
|
455
|
+
*/
|
|
456
|
+
initialLocation?: Location;
|
|
457
|
+
|
|
458
|
+
/**
|
|
459
|
+
* @generated from field: string latest_user_agent = 21;
|
|
460
|
+
*/
|
|
461
|
+
latestUserAgent = "";
|
|
462
|
+
|
|
463
|
+
/**
|
|
464
|
+
* @generated from field: string latest_os = 22;
|
|
465
|
+
*/
|
|
466
|
+
latestOs = "";
|
|
467
|
+
|
|
468
|
+
/**
|
|
469
|
+
* @generated from field: string latest_os_version = 23;
|
|
470
|
+
*/
|
|
471
|
+
latestOsVersion = "";
|
|
472
|
+
|
|
473
|
+
/**
|
|
474
|
+
* @generated from field: string latest_browser = 24;
|
|
475
|
+
*/
|
|
476
|
+
latestBrowser = "";
|
|
477
|
+
|
|
478
|
+
/**
|
|
479
|
+
* @generated from field: string latest_browser_version = 25;
|
|
480
|
+
*/
|
|
481
|
+
latestBrowserVersion = "";
|
|
482
|
+
|
|
483
|
+
/**
|
|
484
|
+
* @generated from field: string latest_device_type = 26;
|
|
485
|
+
*/
|
|
486
|
+
latestDeviceType = "";
|
|
487
|
+
|
|
488
|
+
/**
|
|
489
|
+
* @generated from field: string latest_ip = 28;
|
|
490
|
+
*/
|
|
491
|
+
latestIp = "";
|
|
492
|
+
|
|
493
|
+
/**
|
|
494
|
+
* @generated from field: scalekit.v1.sessions.Location latest_location = 29;
|
|
495
|
+
*/
|
|
496
|
+
latestLocation?: Location;
|
|
497
|
+
|
|
498
|
+
constructor(data?: PartialMessage<SessionDetails>) {
|
|
499
|
+
super();
|
|
500
|
+
proto3.util.initPartial(data, this);
|
|
501
|
+
}
|
|
502
|
+
|
|
503
|
+
static readonly runtime: typeof proto3 = proto3;
|
|
504
|
+
static readonly typeName = "scalekit.v1.sessions.SessionDetails";
|
|
505
|
+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
|
|
506
|
+
{ no: 1, name: "session_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
507
|
+
{ no: 2, name: "user_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
508
|
+
{ no: 3, name: "authenticated_organizations", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true },
|
|
509
|
+
{ no: 4, name: "organization_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
510
|
+
{ no: 5, name: "created_at", kind: "message", T: Timestamp },
|
|
511
|
+
{ no: 6, name: "updated_at", kind: "message", T: Timestamp },
|
|
512
|
+
{ no: 7, name: "idle_expires_at", kind: "message", T: Timestamp },
|
|
513
|
+
{ no: 8, name: "absolute_expires_at", kind: "message", T: Timestamp },
|
|
514
|
+
{ no: 9, name: "expired_at", kind: "message", T: Timestamp },
|
|
515
|
+
{ no: 10, name: "logout_at", kind: "message", T: Timestamp },
|
|
516
|
+
{ no: 11, name: "status", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
517
|
+
{ no: 12, name: "initial_user_agent", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
518
|
+
{ no: 13, name: "initial_os", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
519
|
+
{ no: 14, name: "initial_os_version", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
520
|
+
{ no: 15, name: "initial_browser", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
521
|
+
{ no: 16, name: "initial_browser_version", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
522
|
+
{ no: 17, name: "initial_device_type", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
523
|
+
{ no: 19, name: "initial_ip", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
524
|
+
{ no: 20, name: "initial_location", kind: "message", T: Location },
|
|
525
|
+
{ no: 21, name: "latest_user_agent", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
526
|
+
{ no: 22, name: "latest_os", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
527
|
+
{ no: 23, name: "latest_os_version", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
528
|
+
{ no: 24, name: "latest_browser", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
529
|
+
{ no: 25, name: "latest_browser_version", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
530
|
+
{ no: 26, name: "latest_device_type", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
531
|
+
{ no: 28, name: "latest_ip", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
532
|
+
{ no: 29, name: "latest_location", kind: "message", T: Location },
|
|
533
|
+
]);
|
|
534
|
+
|
|
535
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): SessionDetails {
|
|
536
|
+
return new SessionDetails().fromBinary(bytes, options);
|
|
537
|
+
}
|
|
538
|
+
|
|
539
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): SessionDetails {
|
|
540
|
+
return new SessionDetails().fromJson(jsonValue, options);
|
|
541
|
+
}
|
|
542
|
+
|
|
543
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): SessionDetails {
|
|
544
|
+
return new SessionDetails().fromJsonString(jsonString, options);
|
|
545
|
+
}
|
|
546
|
+
|
|
547
|
+
static equals(a: SessionDetails | PlainMessage<SessionDetails> | undefined, b: SessionDetails | PlainMessage<SessionDetails> | undefined): boolean {
|
|
548
|
+
return proto3.util.equals(SessionDetails, a, b);
|
|
549
|
+
}
|
|
550
|
+
}
|
|
551
|
+
|
|
552
|
+
/**
|
|
553
|
+
* @generated from message scalekit.v1.sessions.RevokedSessionDetails
|
|
554
|
+
*/
|
|
555
|
+
export class RevokedSessionDetails extends Message<RevokedSessionDetails> {
|
|
556
|
+
/**
|
|
557
|
+
* @generated from field: string session_id = 1;
|
|
558
|
+
*/
|
|
559
|
+
sessionId = "";
|
|
560
|
+
|
|
561
|
+
/**
|
|
562
|
+
* @generated from field: string user_id = 2;
|
|
563
|
+
*/
|
|
564
|
+
userId = "";
|
|
565
|
+
|
|
566
|
+
/**
|
|
567
|
+
* @generated from field: google.protobuf.Timestamp created_at = 5;
|
|
568
|
+
*/
|
|
569
|
+
createdAt?: Timestamp;
|
|
570
|
+
|
|
571
|
+
/**
|
|
572
|
+
* @generated from field: google.protobuf.Timestamp updated_at = 6;
|
|
573
|
+
*/
|
|
574
|
+
updatedAt?: Timestamp;
|
|
575
|
+
|
|
576
|
+
/**
|
|
577
|
+
* @generated from field: google.protobuf.Timestamp idle_expires_at = 7;
|
|
578
|
+
*/
|
|
579
|
+
idleExpiresAt?: Timestamp;
|
|
580
|
+
|
|
581
|
+
/**
|
|
582
|
+
* @generated from field: google.protobuf.Timestamp absolute_expires_at = 8;
|
|
583
|
+
*/
|
|
584
|
+
absoluteExpiresAt?: Timestamp;
|
|
585
|
+
|
|
586
|
+
/**
|
|
587
|
+
* @generated from field: google.protobuf.Timestamp expired_at = 9;
|
|
588
|
+
*/
|
|
589
|
+
expiredAt?: Timestamp;
|
|
590
|
+
|
|
591
|
+
/**
|
|
592
|
+
* @generated from field: google.protobuf.Timestamp logout_at = 10;
|
|
593
|
+
*/
|
|
594
|
+
logoutAt?: Timestamp;
|
|
595
|
+
|
|
596
|
+
/**
|
|
597
|
+
* @generated from field: string status = 11;
|
|
598
|
+
*/
|
|
599
|
+
status = "";
|
|
600
|
+
|
|
601
|
+
constructor(data?: PartialMessage<RevokedSessionDetails>) {
|
|
602
|
+
super();
|
|
603
|
+
proto3.util.initPartial(data, this);
|
|
604
|
+
}
|
|
605
|
+
|
|
606
|
+
static readonly runtime: typeof proto3 = proto3;
|
|
607
|
+
static readonly typeName = "scalekit.v1.sessions.RevokedSessionDetails";
|
|
608
|
+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
|
|
609
|
+
{ no: 1, name: "session_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
610
|
+
{ no: 2, name: "user_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
611
|
+
{ no: 5, name: "created_at", kind: "message", T: Timestamp },
|
|
612
|
+
{ no: 6, name: "updated_at", kind: "message", T: Timestamp },
|
|
613
|
+
{ no: 7, name: "idle_expires_at", kind: "message", T: Timestamp },
|
|
614
|
+
{ no: 8, name: "absolute_expires_at", kind: "message", T: Timestamp },
|
|
615
|
+
{ no: 9, name: "expired_at", kind: "message", T: Timestamp },
|
|
616
|
+
{ no: 10, name: "logout_at", kind: "message", T: Timestamp },
|
|
617
|
+
{ no: 11, name: "status", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
618
|
+
]);
|
|
619
|
+
|
|
620
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): RevokedSessionDetails {
|
|
621
|
+
return new RevokedSessionDetails().fromBinary(bytes, options);
|
|
622
|
+
}
|
|
623
|
+
|
|
624
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): RevokedSessionDetails {
|
|
625
|
+
return new RevokedSessionDetails().fromJson(jsonValue, options);
|
|
626
|
+
}
|
|
627
|
+
|
|
628
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): RevokedSessionDetails {
|
|
629
|
+
return new RevokedSessionDetails().fromJsonString(jsonString, options);
|
|
630
|
+
}
|
|
631
|
+
|
|
632
|
+
static equals(a: RevokedSessionDetails | PlainMessage<RevokedSessionDetails> | undefined, b: RevokedSessionDetails | PlainMessage<RevokedSessionDetails> | undefined): boolean {
|
|
633
|
+
return proto3.util.equals(RevokedSessionDetails, a, b);
|
|
634
|
+
}
|
|
635
|
+
}
|
|
636
|
+
|
|
637
|
+
/**
|
|
638
|
+
* @generated from message scalekit.v1.sessions.Location
|
|
639
|
+
*/
|
|
640
|
+
export class Location extends Message<Location> {
|
|
641
|
+
/**
|
|
642
|
+
* @generated from field: string region = 1;
|
|
643
|
+
*/
|
|
644
|
+
region = "";
|
|
645
|
+
|
|
646
|
+
/**
|
|
647
|
+
* @generated from field: string region_subdivision = 2;
|
|
648
|
+
*/
|
|
649
|
+
regionSubdivision = "";
|
|
650
|
+
|
|
651
|
+
/**
|
|
652
|
+
* @generated from field: string city = 3;
|
|
653
|
+
*/
|
|
654
|
+
city = "";
|
|
655
|
+
|
|
656
|
+
/**
|
|
657
|
+
* @generated from field: string latitude = 4;
|
|
658
|
+
*/
|
|
659
|
+
latitude = "";
|
|
660
|
+
|
|
661
|
+
/**
|
|
662
|
+
* @generated from field: string longitude = 5;
|
|
663
|
+
*/
|
|
664
|
+
longitude = "";
|
|
665
|
+
|
|
666
|
+
constructor(data?: PartialMessage<Location>) {
|
|
667
|
+
super();
|
|
668
|
+
proto3.util.initPartial(data, this);
|
|
669
|
+
}
|
|
670
|
+
|
|
671
|
+
static readonly runtime: typeof proto3 = proto3;
|
|
672
|
+
static readonly typeName = "scalekit.v1.sessions.Location";
|
|
673
|
+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
|
|
674
|
+
{ no: 1, name: "region", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
675
|
+
{ no: 2, name: "region_subdivision", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
676
|
+
{ no: 3, name: "city", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
677
|
+
{ no: 4, name: "latitude", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
678
|
+
{ no: 5, name: "longitude", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
|
679
|
+
]);
|
|
680
|
+
|
|
681
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Location {
|
|
682
|
+
return new Location().fromBinary(bytes, options);
|
|
683
|
+
}
|
|
684
|
+
|
|
685
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Location {
|
|
686
|
+
return new Location().fromJson(jsonValue, options);
|
|
687
|
+
}
|
|
688
|
+
|
|
689
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Location {
|
|
690
|
+
return new Location().fromJsonString(jsonString, options);
|
|
691
|
+
}
|
|
692
|
+
|
|
693
|
+
static equals(a: Location | PlainMessage<Location> | undefined, b: Location | PlainMessage<Location> | undefined): boolean {
|
|
694
|
+
return proto3.util.equals(Location, a, b);
|
|
695
|
+
}
|
|
696
|
+
}
|
|
697
|
+
|