@scalekit-sdk/node 2.1.6 → 2.1.8

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.
Files changed (92) hide show
  1. package/buf.gen.yaml +1 -0
  2. package/lib/auth.d.ts +41 -9
  3. package/lib/auth.js +44 -12
  4. package/lib/auth.js.map +1 -1
  5. package/lib/connection.d.ts +195 -21
  6. package/lib/connection.js +197 -23
  7. package/lib/connection.js.map +1 -1
  8. package/lib/core.d.ts +2 -2
  9. package/lib/core.js +13 -12
  10. package/lib/core.js.map +1 -1
  11. package/lib/directory.d.ts +293 -40
  12. package/lib/directory.js +308 -44
  13. package/lib/directory.js.map +1 -1
  14. package/lib/domain.d.ts +166 -18
  15. package/lib/domain.js +178 -29
  16. package/lib/domain.js.map +1 -1
  17. package/lib/organization.d.ts +407 -40
  18. package/lib/organization.js +433 -49
  19. package/lib/organization.js.map +1 -1
  20. package/lib/permission.d.ts +179 -35
  21. package/lib/permission.js +190 -38
  22. package/lib/permission.js.map +1 -1
  23. package/lib/pkg/grpc/scalekit/v1/auth/auth_connect.d.ts +3 -3
  24. package/lib/pkg/grpc/scalekit/v1/auth/auth_connect.js +2 -2
  25. package/lib/pkg/grpc/scalekit/v1/auth/auth_connect.js.map +1 -1
  26. package/lib/pkg/grpc/scalekit/v1/auth/auth_pb.d.ts +16 -16
  27. package/lib/pkg/grpc/scalekit/v1/auth/auth_pb.js +21 -21
  28. package/lib/pkg/grpc/scalekit/v1/auth/auth_pb.js.map +1 -1
  29. package/lib/pkg/grpc/scalekit/v1/auth/webauthn_connect.d.ts +82 -0
  30. package/lib/pkg/grpc/scalekit/v1/auth/webauthn_connect.js +90 -0
  31. package/lib/pkg/grpc/scalekit/v1/auth/webauthn_connect.js.map +1 -0
  32. package/lib/pkg/grpc/scalekit/v1/auth/webauthn_pb.d.ts +647 -0
  33. package/lib/pkg/grpc/scalekit/v1/auth/webauthn_pb.js +993 -0
  34. package/lib/pkg/grpc/scalekit/v1/auth/webauthn_pb.js.map +1 -0
  35. package/lib/pkg/grpc/scalekit/v1/commons/commons_pb.d.ts +142 -0
  36. package/lib/pkg/grpc/scalekit/v1/commons/commons_pb.js +165 -1
  37. package/lib/pkg/grpc/scalekit/v1/commons/commons_pb.js.map +1 -1
  38. package/lib/pkg/grpc/scalekit/v1/connections/connections_connect.d.ts +1 -10
  39. package/lib/pkg/grpc/scalekit/v1/connections/connections_connect.js +0 -9
  40. package/lib/pkg/grpc/scalekit/v1/connections/connections_connect.js.map +1 -1
  41. package/lib/pkg/grpc/scalekit/v1/connections/connections_pb.d.ts +28 -63
  42. package/lib/pkg/grpc/scalekit/v1/connections/connections_pb.js +9 -90
  43. package/lib/pkg/grpc/scalekit/v1/connections/connections_pb.js.map +1 -1
  44. package/lib/pkg/grpc/scalekit/v1/organizations/organizations_connect.d.ts +6 -6
  45. package/lib/pkg/grpc/scalekit/v1/organizations/organizations_connect.js +5 -5
  46. package/lib/pkg/grpc/scalekit/v1/organizations/organizations_pb.d.ts +19 -30
  47. package/lib/pkg/grpc/scalekit/v1/organizations/organizations_pb.js +22 -31
  48. package/lib/pkg/grpc/scalekit/v1/organizations/organizations_pb.js.map +1 -1
  49. package/lib/pkg/grpc/scalekit/v1/users/users_pb.d.ts +2 -2
  50. package/lib/pkg/grpc/scalekit/v1/users/users_pb.js +1 -1
  51. package/lib/pkg/grpc/scalekit/v1/users/users_pb.js.map +1 -1
  52. package/lib/role.d.ts +252 -56
  53. package/lib/role.js +262 -62
  54. package/lib/role.js.map +1 -1
  55. package/lib/scalekit.d.ts +323 -54
  56. package/lib/scalekit.js +354 -76
  57. package/lib/scalekit.js.map +1 -1
  58. package/lib/session.d.ts +235 -22
  59. package/lib/session.js +237 -24
  60. package/lib/session.js.map +1 -1
  61. package/lib/types/organization.d.ts +3 -0
  62. package/lib/user.d.ts +571 -53
  63. package/lib/user.js +598 -89
  64. package/lib/user.js.map +1 -1
  65. package/lib/webauthn.d.ts +33 -0
  66. package/lib/webauthn.js +80 -0
  67. package/lib/webauthn.js.map +1 -0
  68. package/package.json +2 -2
  69. package/src/auth.ts +53 -19
  70. package/src/connection.ts +237 -62
  71. package/src/core.ts +39 -33
  72. package/src/directory.ts +356 -98
  73. package/src/domain.ts +215 -68
  74. package/src/organization.ts +506 -105
  75. package/src/permission.ts +234 -88
  76. package/src/pkg/grpc/scalekit/v1/auth/auth_connect.ts +3 -3
  77. package/src/pkg/grpc/scalekit/v1/auth/auth_pb.ts +24 -24
  78. package/src/pkg/grpc/scalekit/v1/auth/webauthn_connect.ts +89 -0
  79. package/src/pkg/grpc/scalekit/v1/auth/webauthn_pb.ts +1263 -0
  80. package/src/pkg/grpc/scalekit/v1/commons/commons_pb.ts +217 -0
  81. package/src/pkg/grpc/scalekit/v1/connections/connections_connect.ts +1 -10
  82. package/src/pkg/grpc/scalekit/v1/connections/connections_pb.ts +42 -129
  83. package/src/pkg/grpc/scalekit/v1/organizations/organizations_connect.ts +6 -6
  84. package/src/pkg/grpc/scalekit/v1/organizations/organizations_pb.ts +28 -43
  85. package/src/pkg/grpc/scalekit/v1/users/users_pb.ts +3 -3
  86. package/src/role.ts +336 -136
  87. package/src/scalekit.ts +478 -149
  88. package/src/session.ts +266 -63
  89. package/src/types/organization.ts +4 -0
  90. package/src/user.ts +675 -168
  91. package/src/webauthn.ts +98 -0
  92. package/tests/organization.test.ts +16 -0
@@ -0,0 +1,1263 @@
1
+ // @generated by protoc-gen-es v1.10.0 with parameter "target=ts"
2
+ // @generated from file scalekit/v1/auth/webauthn.proto (package scalekit.v1.auth.webauthn, 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, protoInt64, Struct, Timestamp } from "@bufbuild/protobuf";
8
+
9
+ /**
10
+ * @generated from message scalekit.v1.auth.webauthn.BeginRegistrationRequest
11
+ */
12
+ export class BeginRegistrationRequest extends Message<BeginRegistrationRequest> {
13
+ constructor(data?: PartialMessage<BeginRegistrationRequest>) {
14
+ super();
15
+ proto3.util.initPartial(data, this);
16
+ }
17
+
18
+ static readonly runtime: typeof proto3 = proto3;
19
+ static readonly typeName = "scalekit.v1.auth.webauthn.BeginRegistrationRequest";
20
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
21
+ ]);
22
+
23
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): BeginRegistrationRequest {
24
+ return new BeginRegistrationRequest().fromBinary(bytes, options);
25
+ }
26
+
27
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): BeginRegistrationRequest {
28
+ return new BeginRegistrationRequest().fromJson(jsonValue, options);
29
+ }
30
+
31
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): BeginRegistrationRequest {
32
+ return new BeginRegistrationRequest().fromJsonString(jsonString, options);
33
+ }
34
+
35
+ static equals(a: BeginRegistrationRequest | PlainMessage<BeginRegistrationRequest> | undefined, b: BeginRegistrationRequest | PlainMessage<BeginRegistrationRequest> | undefined): boolean {
36
+ return proto3.util.equals(BeginRegistrationRequest, a, b);
37
+ }
38
+ }
39
+
40
+ /**
41
+ * @generated from message scalekit.v1.auth.webauthn.BeginRegistrationResponse
42
+ */
43
+ export class BeginRegistrationResponse extends Message<BeginRegistrationResponse> {
44
+ /**
45
+ * @generated from field: google.protobuf.Struct options = 1;
46
+ */
47
+ options?: Struct;
48
+
49
+ constructor(data?: PartialMessage<BeginRegistrationResponse>) {
50
+ super();
51
+ proto3.util.initPartial(data, this);
52
+ }
53
+
54
+ static readonly runtime: typeof proto3 = proto3;
55
+ static readonly typeName = "scalekit.v1.auth.webauthn.BeginRegistrationResponse";
56
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
57
+ { no: 1, name: "options", kind: "message", T: Struct },
58
+ ]);
59
+
60
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): BeginRegistrationResponse {
61
+ return new BeginRegistrationResponse().fromBinary(bytes, options);
62
+ }
63
+
64
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): BeginRegistrationResponse {
65
+ return new BeginRegistrationResponse().fromJson(jsonValue, options);
66
+ }
67
+
68
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): BeginRegistrationResponse {
69
+ return new BeginRegistrationResponse().fromJsonString(jsonString, options);
70
+ }
71
+
72
+ static equals(a: BeginRegistrationResponse | PlainMessage<BeginRegistrationResponse> | undefined, b: BeginRegistrationResponse | PlainMessage<BeginRegistrationResponse> | undefined): boolean {
73
+ return proto3.util.equals(BeginRegistrationResponse, a, b);
74
+ }
75
+ }
76
+
77
+ /**
78
+ * @generated from message scalekit.v1.auth.webauthn.FinishRegistrationRequest
79
+ */
80
+ export class FinishRegistrationRequest extends Message<FinishRegistrationRequest> {
81
+ /**
82
+ * @generated from field: bytes credential_id = 1;
83
+ */
84
+ credentialId = new Uint8Array(0);
85
+
86
+ /**
87
+ * @generated from field: bytes attestation_object = 2;
88
+ */
89
+ attestationObject = new Uint8Array(0);
90
+
91
+ /**
92
+ * @generated from field: bytes client_data_json = 3;
93
+ */
94
+ clientDataJson = new Uint8Array(0);
95
+
96
+ /**
97
+ * @generated from field: string type = 4;
98
+ */
99
+ type = "";
100
+
101
+ /**
102
+ * @generated from field: repeated string transports = 5;
103
+ */
104
+ transports: string[] = [];
105
+
106
+ /**
107
+ * @generated from field: string authenticator_attachment = 6;
108
+ */
109
+ authenticatorAttachment = "";
110
+
111
+ /**
112
+ * @generated from field: google.protobuf.Struct client_extension_results = 7;
113
+ */
114
+ clientExtensionResults?: Struct;
115
+
116
+ constructor(data?: PartialMessage<FinishRegistrationRequest>) {
117
+ super();
118
+ proto3.util.initPartial(data, this);
119
+ }
120
+
121
+ static readonly runtime: typeof proto3 = proto3;
122
+ static readonly typeName = "scalekit.v1.auth.webauthn.FinishRegistrationRequest";
123
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
124
+ { no: 1, name: "credential_id", kind: "scalar", T: 12 /* ScalarType.BYTES */ },
125
+ { no: 2, name: "attestation_object", kind: "scalar", T: 12 /* ScalarType.BYTES */ },
126
+ { no: 3, name: "client_data_json", kind: "scalar", T: 12 /* ScalarType.BYTES */ },
127
+ { no: 4, name: "type", kind: "scalar", T: 9 /* ScalarType.STRING */ },
128
+ { no: 5, name: "transports", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true },
129
+ { no: 6, name: "authenticator_attachment", kind: "scalar", T: 9 /* ScalarType.STRING */ },
130
+ { no: 7, name: "client_extension_results", kind: "message", T: Struct },
131
+ ]);
132
+
133
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): FinishRegistrationRequest {
134
+ return new FinishRegistrationRequest().fromBinary(bytes, options);
135
+ }
136
+
137
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): FinishRegistrationRequest {
138
+ return new FinishRegistrationRequest().fromJson(jsonValue, options);
139
+ }
140
+
141
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): FinishRegistrationRequest {
142
+ return new FinishRegistrationRequest().fromJsonString(jsonString, options);
143
+ }
144
+
145
+ static equals(a: FinishRegistrationRequest | PlainMessage<FinishRegistrationRequest> | undefined, b: FinishRegistrationRequest | PlainMessage<FinishRegistrationRequest> | undefined): boolean {
146
+ return proto3.util.equals(FinishRegistrationRequest, a, b);
147
+ }
148
+ }
149
+
150
+ /**
151
+ * @generated from message scalekit.v1.auth.webauthn.FinishRegistrationResponse
152
+ */
153
+ export class FinishRegistrationResponse extends Message<FinishRegistrationResponse> {
154
+ /**
155
+ * @generated from field: bool success = 1;
156
+ */
157
+ success = false;
158
+
159
+ constructor(data?: PartialMessage<FinishRegistrationResponse>) {
160
+ super();
161
+ proto3.util.initPartial(data, this);
162
+ }
163
+
164
+ static readonly runtime: typeof proto3 = proto3;
165
+ static readonly typeName = "scalekit.v1.auth.webauthn.FinishRegistrationResponse";
166
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
167
+ { no: 1, name: "success", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
168
+ ]);
169
+
170
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): FinishRegistrationResponse {
171
+ return new FinishRegistrationResponse().fromBinary(bytes, options);
172
+ }
173
+
174
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): FinishRegistrationResponse {
175
+ return new FinishRegistrationResponse().fromJson(jsonValue, options);
176
+ }
177
+
178
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): FinishRegistrationResponse {
179
+ return new FinishRegistrationResponse().fromJsonString(jsonString, options);
180
+ }
181
+
182
+ static equals(a: FinishRegistrationResponse | PlainMessage<FinishRegistrationResponse> | undefined, b: FinishRegistrationResponse | PlainMessage<FinishRegistrationResponse> | undefined): boolean {
183
+ return proto3.util.equals(FinishRegistrationResponse, a, b);
184
+ }
185
+ }
186
+
187
+ /**
188
+ * @generated from message scalekit.v1.auth.webauthn.BeginAuthenticationRequest
189
+ */
190
+ export class BeginAuthenticationRequest extends Message<BeginAuthenticationRequest> {
191
+ /**
192
+ * @generated from field: optional string email = 1;
193
+ */
194
+ email?: string;
195
+
196
+ constructor(data?: PartialMessage<BeginAuthenticationRequest>) {
197
+ super();
198
+ proto3.util.initPartial(data, this);
199
+ }
200
+
201
+ static readonly runtime: typeof proto3 = proto3;
202
+ static readonly typeName = "scalekit.v1.auth.webauthn.BeginAuthenticationRequest";
203
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
204
+ { no: 1, name: "email", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
205
+ ]);
206
+
207
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): BeginAuthenticationRequest {
208
+ return new BeginAuthenticationRequest().fromBinary(bytes, options);
209
+ }
210
+
211
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): BeginAuthenticationRequest {
212
+ return new BeginAuthenticationRequest().fromJson(jsonValue, options);
213
+ }
214
+
215
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): BeginAuthenticationRequest {
216
+ return new BeginAuthenticationRequest().fromJsonString(jsonString, options);
217
+ }
218
+
219
+ static equals(a: BeginAuthenticationRequest | PlainMessage<BeginAuthenticationRequest> | undefined, b: BeginAuthenticationRequest | PlainMessage<BeginAuthenticationRequest> | undefined): boolean {
220
+ return proto3.util.equals(BeginAuthenticationRequest, a, b);
221
+ }
222
+ }
223
+
224
+ /**
225
+ * @generated from message scalekit.v1.auth.webauthn.BeginAuthenticationResponse
226
+ */
227
+ export class BeginAuthenticationResponse extends Message<BeginAuthenticationResponse> {
228
+ /**
229
+ * @generated from field: string session_id = 1;
230
+ */
231
+ sessionId = "";
232
+
233
+ /**
234
+ * @generated from field: google.protobuf.Struct options = 2;
235
+ */
236
+ options?: Struct;
237
+
238
+ constructor(data?: PartialMessage<BeginAuthenticationResponse>) {
239
+ super();
240
+ proto3.util.initPartial(data, this);
241
+ }
242
+
243
+ static readonly runtime: typeof proto3 = proto3;
244
+ static readonly typeName = "scalekit.v1.auth.webauthn.BeginAuthenticationResponse";
245
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
246
+ { no: 1, name: "session_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
247
+ { no: 2, name: "options", kind: "message", T: Struct },
248
+ ]);
249
+
250
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): BeginAuthenticationResponse {
251
+ return new BeginAuthenticationResponse().fromBinary(bytes, options);
252
+ }
253
+
254
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): BeginAuthenticationResponse {
255
+ return new BeginAuthenticationResponse().fromJson(jsonValue, options);
256
+ }
257
+
258
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): BeginAuthenticationResponse {
259
+ return new BeginAuthenticationResponse().fromJsonString(jsonString, options);
260
+ }
261
+
262
+ static equals(a: BeginAuthenticationResponse | PlainMessage<BeginAuthenticationResponse> | undefined, b: BeginAuthenticationResponse | PlainMessage<BeginAuthenticationResponse> | undefined): boolean {
263
+ return proto3.util.equals(BeginAuthenticationResponse, a, b);
264
+ }
265
+ }
266
+
267
+ /**
268
+ * @generated from message scalekit.v1.auth.webauthn.FinishAuthenticationRequest
269
+ */
270
+ export class FinishAuthenticationRequest extends Message<FinishAuthenticationRequest> {
271
+ /**
272
+ * @generated from field: string session_id = 1;
273
+ */
274
+ sessionId = "";
275
+
276
+ /**
277
+ * @generated from field: bytes credential_id = 2;
278
+ */
279
+ credentialId = new Uint8Array(0);
280
+
281
+ /**
282
+ * @generated from field: google.protobuf.Struct client_extension_results = 3;
283
+ */
284
+ clientExtensionResults?: Struct;
285
+
286
+ /**
287
+ * @generated from field: string type = 4;
288
+ */
289
+ type = "";
290
+
291
+ /**
292
+ * @generated from field: scalekit.v1.auth.webauthn.AuthenticatorAssertionResponse response = 5;
293
+ */
294
+ response?: AuthenticatorAssertionResponse;
295
+
296
+ /**
297
+ * @generated from field: string authenticator_attachment = 6;
298
+ */
299
+ authenticatorAttachment = "";
300
+
301
+ constructor(data?: PartialMessage<FinishAuthenticationRequest>) {
302
+ super();
303
+ proto3.util.initPartial(data, this);
304
+ }
305
+
306
+ static readonly runtime: typeof proto3 = proto3;
307
+ static readonly typeName = "scalekit.v1.auth.webauthn.FinishAuthenticationRequest";
308
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
309
+ { no: 1, name: "session_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
310
+ { no: 2, name: "credential_id", kind: "scalar", T: 12 /* ScalarType.BYTES */ },
311
+ { no: 3, name: "client_extension_results", kind: "message", T: Struct },
312
+ { no: 4, name: "type", kind: "scalar", T: 9 /* ScalarType.STRING */ },
313
+ { no: 5, name: "response", kind: "message", T: AuthenticatorAssertionResponse },
314
+ { no: 6, name: "authenticator_attachment", kind: "scalar", T: 9 /* ScalarType.STRING */ },
315
+ ]);
316
+
317
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): FinishAuthenticationRequest {
318
+ return new FinishAuthenticationRequest().fromBinary(bytes, options);
319
+ }
320
+
321
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): FinishAuthenticationRequest {
322
+ return new FinishAuthenticationRequest().fromJson(jsonValue, options);
323
+ }
324
+
325
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): FinishAuthenticationRequest {
326
+ return new FinishAuthenticationRequest().fromJsonString(jsonString, options);
327
+ }
328
+
329
+ static equals(a: FinishAuthenticationRequest | PlainMessage<FinishAuthenticationRequest> | undefined, b: FinishAuthenticationRequest | PlainMessage<FinishAuthenticationRequest> | undefined): boolean {
330
+ return proto3.util.equals(FinishAuthenticationRequest, a, b);
331
+ }
332
+ }
333
+
334
+ /**
335
+ * @generated from message scalekit.v1.auth.webauthn.AuthenticatorAssertionResponse
336
+ */
337
+ export class AuthenticatorAssertionResponse extends Message<AuthenticatorAssertionResponse> {
338
+ /**
339
+ * @generated from field: bytes authenticator_data = 1;
340
+ */
341
+ authenticatorData = new Uint8Array(0);
342
+
343
+ /**
344
+ * @generated from field: bytes client_data_json = 2;
345
+ */
346
+ clientDataJson = new Uint8Array(0);
347
+
348
+ /**
349
+ * @generated from field: bytes signature = 3;
350
+ */
351
+ signature = new Uint8Array(0);
352
+
353
+ /**
354
+ * @generated from field: bytes user_handle = 4;
355
+ */
356
+ userHandle = new Uint8Array(0);
357
+
358
+ constructor(data?: PartialMessage<AuthenticatorAssertionResponse>) {
359
+ super();
360
+ proto3.util.initPartial(data, this);
361
+ }
362
+
363
+ static readonly runtime: typeof proto3 = proto3;
364
+ static readonly typeName = "scalekit.v1.auth.webauthn.AuthenticatorAssertionResponse";
365
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
366
+ { no: 1, name: "authenticator_data", kind: "scalar", T: 12 /* ScalarType.BYTES */ },
367
+ { no: 2, name: "client_data_json", kind: "scalar", T: 12 /* ScalarType.BYTES */ },
368
+ { no: 3, name: "signature", kind: "scalar", T: 12 /* ScalarType.BYTES */ },
369
+ { no: 4, name: "user_handle", kind: "scalar", T: 12 /* ScalarType.BYTES */ },
370
+ ]);
371
+
372
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AuthenticatorAssertionResponse {
373
+ return new AuthenticatorAssertionResponse().fromBinary(bytes, options);
374
+ }
375
+
376
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AuthenticatorAssertionResponse {
377
+ return new AuthenticatorAssertionResponse().fromJson(jsonValue, options);
378
+ }
379
+
380
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AuthenticatorAssertionResponse {
381
+ return new AuthenticatorAssertionResponse().fromJsonString(jsonString, options);
382
+ }
383
+
384
+ static equals(a: AuthenticatorAssertionResponse | PlainMessage<AuthenticatorAssertionResponse> | undefined, b: AuthenticatorAssertionResponse | PlainMessage<AuthenticatorAssertionResponse> | undefined): boolean {
385
+ return proto3.util.equals(AuthenticatorAssertionResponse, a, b);
386
+ }
387
+ }
388
+
389
+ /**
390
+ * @generated from message scalekit.v1.auth.webauthn.FinishAuthenticationResponse
391
+ */
392
+ export class FinishAuthenticationResponse extends Message<FinishAuthenticationResponse> {
393
+ /**
394
+ * @generated from field: bool success = 1;
395
+ */
396
+ success = false;
397
+
398
+ /**
399
+ * @generated from field: string user_id = 2;
400
+ */
401
+ userId = "";
402
+
403
+ /**
404
+ * @generated from field: string session_token = 3;
405
+ */
406
+ sessionToken = "";
407
+
408
+ constructor(data?: PartialMessage<FinishAuthenticationResponse>) {
409
+ super();
410
+ proto3.util.initPartial(data, this);
411
+ }
412
+
413
+ static readonly runtime: typeof proto3 = proto3;
414
+ static readonly typeName = "scalekit.v1.auth.webauthn.FinishAuthenticationResponse";
415
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
416
+ { no: 1, name: "success", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
417
+ { no: 2, name: "user_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
418
+ { no: 3, name: "session_token", kind: "scalar", T: 9 /* ScalarType.STRING */ },
419
+ ]);
420
+
421
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): FinishAuthenticationResponse {
422
+ return new FinishAuthenticationResponse().fromBinary(bytes, options);
423
+ }
424
+
425
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): FinishAuthenticationResponse {
426
+ return new FinishAuthenticationResponse().fromJson(jsonValue, options);
427
+ }
428
+
429
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): FinishAuthenticationResponse {
430
+ return new FinishAuthenticationResponse().fromJsonString(jsonString, options);
431
+ }
432
+
433
+ static equals(a: FinishAuthenticationResponse | PlainMessage<FinishAuthenticationResponse> | undefined, b: FinishAuthenticationResponse | PlainMessage<FinishAuthenticationResponse> | undefined): boolean {
434
+ return proto3.util.equals(FinishAuthenticationResponse, a, b);
435
+ }
436
+ }
437
+
438
+ /**
439
+ * @generated from message scalekit.v1.auth.webauthn.WebAuthnConfiguration
440
+ */
441
+ export class WebAuthnConfiguration extends Message<WebAuthnConfiguration> {
442
+ /**
443
+ * @generated from field: string rp_id = 1;
444
+ */
445
+ rpId = "";
446
+
447
+ /**
448
+ * @generated from field: string rp_origin = 2;
449
+ */
450
+ rpOrigin = "";
451
+
452
+ /**
453
+ * @generated from field: string user_verification = 3;
454
+ */
455
+ userVerification = "";
456
+
457
+ /**
458
+ * @generated from field: string authenticator_attachment = 4;
459
+ */
460
+ authenticatorAttachment = "";
461
+
462
+ /**
463
+ * @generated from field: string resident_key = 5;
464
+ */
465
+ residentKey = "";
466
+
467
+ /**
468
+ * @generated from field: int64 timeout = 6;
469
+ */
470
+ timeout = protoInt64.zero;
471
+
472
+ /**
473
+ * @generated from field: repeated string allowed_transports = 7;
474
+ */
475
+ allowedTransports: string[] = [];
476
+
477
+ constructor(data?: PartialMessage<WebAuthnConfiguration>) {
478
+ super();
479
+ proto3.util.initPartial(data, this);
480
+ }
481
+
482
+ static readonly runtime: typeof proto3 = proto3;
483
+ static readonly typeName = "scalekit.v1.auth.webauthn.WebAuthnConfiguration";
484
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
485
+ { no: 1, name: "rp_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
486
+ { no: 2, name: "rp_origin", kind: "scalar", T: 9 /* ScalarType.STRING */ },
487
+ { no: 3, name: "user_verification", kind: "scalar", T: 9 /* ScalarType.STRING */ },
488
+ { no: 4, name: "authenticator_attachment", kind: "scalar", T: 9 /* ScalarType.STRING */ },
489
+ { no: 5, name: "resident_key", kind: "scalar", T: 9 /* ScalarType.STRING */ },
490
+ { no: 6, name: "timeout", kind: "scalar", T: 3 /* ScalarType.INT64 */ },
491
+ { no: 7, name: "allowed_transports", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true },
492
+ ]);
493
+
494
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): WebAuthnConfiguration {
495
+ return new WebAuthnConfiguration().fromBinary(bytes, options);
496
+ }
497
+
498
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): WebAuthnConfiguration {
499
+ return new WebAuthnConfiguration().fromJson(jsonValue, options);
500
+ }
501
+
502
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): WebAuthnConfiguration {
503
+ return new WebAuthnConfiguration().fromJsonString(jsonString, options);
504
+ }
505
+
506
+ static equals(a: WebAuthnConfiguration | PlainMessage<WebAuthnConfiguration> | undefined, b: WebAuthnConfiguration | PlainMessage<WebAuthnConfiguration> | undefined): boolean {
507
+ return proto3.util.equals(WebAuthnConfiguration, a, b);
508
+ }
509
+ }
510
+
511
+ /**
512
+ * @generated from message scalekit.v1.auth.webauthn.ListCredentialsRequest
513
+ */
514
+ export class ListCredentialsRequest extends Message<ListCredentialsRequest> {
515
+ /**
516
+ * @generated from field: string user_id = 1;
517
+ */
518
+ userId = "";
519
+
520
+ constructor(data?: PartialMessage<ListCredentialsRequest>) {
521
+ super();
522
+ proto3.util.initPartial(data, this);
523
+ }
524
+
525
+ static readonly runtime: typeof proto3 = proto3;
526
+ static readonly typeName = "scalekit.v1.auth.webauthn.ListCredentialsRequest";
527
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
528
+ { no: 1, name: "user_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
529
+ ]);
530
+
531
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): ListCredentialsRequest {
532
+ return new ListCredentialsRequest().fromBinary(bytes, options);
533
+ }
534
+
535
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): ListCredentialsRequest {
536
+ return new ListCredentialsRequest().fromJson(jsonValue, options);
537
+ }
538
+
539
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): ListCredentialsRequest {
540
+ return new ListCredentialsRequest().fromJsonString(jsonString, options);
541
+ }
542
+
543
+ static equals(a: ListCredentialsRequest | PlainMessage<ListCredentialsRequest> | undefined, b: ListCredentialsRequest | PlainMessage<ListCredentialsRequest> | undefined): boolean {
544
+ return proto3.util.equals(ListCredentialsRequest, a, b);
545
+ }
546
+ }
547
+
548
+ /**
549
+ * @generated from message scalekit.v1.auth.webauthn.ListCredentialsResponse
550
+ */
551
+ export class ListCredentialsResponse extends Message<ListCredentialsResponse> {
552
+ /**
553
+ * @generated from field: repeated scalekit.v1.auth.webauthn.WebAuthnCredential credentials = 1;
554
+ */
555
+ credentials: WebAuthnCredential[] = [];
556
+
557
+ /**
558
+ * @generated from field: scalekit.v1.auth.webauthn.AllAcceptedCredentialsOptions all_accepted_credentials_options = 2;
559
+ */
560
+ allAcceptedCredentialsOptions?: AllAcceptedCredentialsOptions;
561
+
562
+ constructor(data?: PartialMessage<ListCredentialsResponse>) {
563
+ super();
564
+ proto3.util.initPartial(data, this);
565
+ }
566
+
567
+ static readonly runtime: typeof proto3 = proto3;
568
+ static readonly typeName = "scalekit.v1.auth.webauthn.ListCredentialsResponse";
569
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
570
+ { no: 1, name: "credentials", kind: "message", T: WebAuthnCredential, repeated: true },
571
+ { no: 2, name: "all_accepted_credentials_options", kind: "message", T: AllAcceptedCredentialsOptions },
572
+ ]);
573
+
574
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): ListCredentialsResponse {
575
+ return new ListCredentialsResponse().fromBinary(bytes, options);
576
+ }
577
+
578
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): ListCredentialsResponse {
579
+ return new ListCredentialsResponse().fromJson(jsonValue, options);
580
+ }
581
+
582
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): ListCredentialsResponse {
583
+ return new ListCredentialsResponse().fromJsonString(jsonString, options);
584
+ }
585
+
586
+ static equals(a: ListCredentialsResponse | PlainMessage<ListCredentialsResponse> | undefined, b: ListCredentialsResponse | PlainMessage<ListCredentialsResponse> | undefined): boolean {
587
+ return proto3.util.equals(ListCredentialsResponse, a, b);
588
+ }
589
+ }
590
+
591
+ /**
592
+ * @generated from message scalekit.v1.auth.webauthn.DeleteCredentialRequest
593
+ */
594
+ export class DeleteCredentialRequest extends Message<DeleteCredentialRequest> {
595
+ /**
596
+ * @generated from field: string credential_id = 1;
597
+ */
598
+ credentialId = "";
599
+
600
+ constructor(data?: PartialMessage<DeleteCredentialRequest>) {
601
+ super();
602
+ proto3.util.initPartial(data, this);
603
+ }
604
+
605
+ static readonly runtime: typeof proto3 = proto3;
606
+ static readonly typeName = "scalekit.v1.auth.webauthn.DeleteCredentialRequest";
607
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
608
+ { no: 1, name: "credential_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
609
+ ]);
610
+
611
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): DeleteCredentialRequest {
612
+ return new DeleteCredentialRequest().fromBinary(bytes, options);
613
+ }
614
+
615
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): DeleteCredentialRequest {
616
+ return new DeleteCredentialRequest().fromJson(jsonValue, options);
617
+ }
618
+
619
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): DeleteCredentialRequest {
620
+ return new DeleteCredentialRequest().fromJsonString(jsonString, options);
621
+ }
622
+
623
+ static equals(a: DeleteCredentialRequest | PlainMessage<DeleteCredentialRequest> | undefined, b: DeleteCredentialRequest | PlainMessage<DeleteCredentialRequest> | undefined): boolean {
624
+ return proto3.util.equals(DeleteCredentialRequest, a, b);
625
+ }
626
+ }
627
+
628
+ /**
629
+ * @generated from message scalekit.v1.auth.webauthn.DeleteCredentialResponse
630
+ */
631
+ export class DeleteCredentialResponse extends Message<DeleteCredentialResponse> {
632
+ /**
633
+ * @generated from field: bool success = 1;
634
+ */
635
+ success = false;
636
+
637
+ /**
638
+ * @generated from field: scalekit.v1.auth.webauthn.UnknownCredentialOptions unknown_credential_options = 2;
639
+ */
640
+ unknownCredentialOptions?: UnknownCredentialOptions;
641
+
642
+ constructor(data?: PartialMessage<DeleteCredentialResponse>) {
643
+ super();
644
+ proto3.util.initPartial(data, this);
645
+ }
646
+
647
+ static readonly runtime: typeof proto3 = proto3;
648
+ static readonly typeName = "scalekit.v1.auth.webauthn.DeleteCredentialResponse";
649
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
650
+ { no: 1, name: "success", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
651
+ { no: 2, name: "unknown_credential_options", kind: "message", T: UnknownCredentialOptions },
652
+ ]);
653
+
654
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): DeleteCredentialResponse {
655
+ return new DeleteCredentialResponse().fromBinary(bytes, options);
656
+ }
657
+
658
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): DeleteCredentialResponse {
659
+ return new DeleteCredentialResponse().fromJson(jsonValue, options);
660
+ }
661
+
662
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): DeleteCredentialResponse {
663
+ return new DeleteCredentialResponse().fromJsonString(jsonString, options);
664
+ }
665
+
666
+ static equals(a: DeleteCredentialResponse | PlainMessage<DeleteCredentialResponse> | undefined, b: DeleteCredentialResponse | PlainMessage<DeleteCredentialResponse> | undefined): boolean {
667
+ return proto3.util.equals(DeleteCredentialResponse, a, b);
668
+ }
669
+ }
670
+
671
+ /**
672
+ * @generated from message scalekit.v1.auth.webauthn.UnknownCredentialOptions
673
+ */
674
+ export class UnknownCredentialOptions extends Message<UnknownCredentialOptions> {
675
+ /**
676
+ * @generated from field: string rp_id = 1;
677
+ */
678
+ rpId = "";
679
+
680
+ /**
681
+ * @generated from field: string credential_id = 2;
682
+ */
683
+ credentialId = "";
684
+
685
+ constructor(data?: PartialMessage<UnknownCredentialOptions>) {
686
+ super();
687
+ proto3.util.initPartial(data, this);
688
+ }
689
+
690
+ static readonly runtime: typeof proto3 = proto3;
691
+ static readonly typeName = "scalekit.v1.auth.webauthn.UnknownCredentialOptions";
692
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
693
+ { no: 1, name: "rp_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
694
+ { no: 2, name: "credential_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
695
+ ]);
696
+
697
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UnknownCredentialOptions {
698
+ return new UnknownCredentialOptions().fromBinary(bytes, options);
699
+ }
700
+
701
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UnknownCredentialOptions {
702
+ return new UnknownCredentialOptions().fromJson(jsonValue, options);
703
+ }
704
+
705
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UnknownCredentialOptions {
706
+ return new UnknownCredentialOptions().fromJsonString(jsonString, options);
707
+ }
708
+
709
+ static equals(a: UnknownCredentialOptions | PlainMessage<UnknownCredentialOptions> | undefined, b: UnknownCredentialOptions | PlainMessage<UnknownCredentialOptions> | undefined): boolean {
710
+ return proto3.util.equals(UnknownCredentialOptions, a, b);
711
+ }
712
+ }
713
+
714
+ /**
715
+ * @generated from message scalekit.v1.auth.webauthn.AllAcceptedCredentialsOptions
716
+ */
717
+ export class AllAcceptedCredentialsOptions extends Message<AllAcceptedCredentialsOptions> {
718
+ /**
719
+ * @generated from field: string rp_id = 1;
720
+ */
721
+ rpId = "";
722
+
723
+ /**
724
+ * @generated from field: string user_id = 2;
725
+ */
726
+ userId = "";
727
+
728
+ /**
729
+ * @generated from field: repeated string all_accepted_credential_ids = 3;
730
+ */
731
+ allAcceptedCredentialIds: string[] = [];
732
+
733
+ constructor(data?: PartialMessage<AllAcceptedCredentialsOptions>) {
734
+ super();
735
+ proto3.util.initPartial(data, this);
736
+ }
737
+
738
+ static readonly runtime: typeof proto3 = proto3;
739
+ static readonly typeName = "scalekit.v1.auth.webauthn.AllAcceptedCredentialsOptions";
740
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
741
+ { no: 1, name: "rp_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
742
+ { no: 2, name: "user_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
743
+ { no: 3, name: "all_accepted_credential_ids", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true },
744
+ ]);
745
+
746
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AllAcceptedCredentialsOptions {
747
+ return new AllAcceptedCredentialsOptions().fromBinary(bytes, options);
748
+ }
749
+
750
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AllAcceptedCredentialsOptions {
751
+ return new AllAcceptedCredentialsOptions().fromJson(jsonValue, options);
752
+ }
753
+
754
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AllAcceptedCredentialsOptions {
755
+ return new AllAcceptedCredentialsOptions().fromJsonString(jsonString, options);
756
+ }
757
+
758
+ static equals(a: AllAcceptedCredentialsOptions | PlainMessage<AllAcceptedCredentialsOptions> | undefined, b: AllAcceptedCredentialsOptions | PlainMessage<AllAcceptedCredentialsOptions> | undefined): boolean {
759
+ return proto3.util.equals(AllAcceptedCredentialsOptions, a, b);
760
+ }
761
+ }
762
+
763
+ /**
764
+ * @generated from message scalekit.v1.auth.webauthn.UpdateCredentialRequest
765
+ */
766
+ export class UpdateCredentialRequest extends Message<UpdateCredentialRequest> {
767
+ /**
768
+ * @generated from field: string credential_id = 1;
769
+ */
770
+ credentialId = "";
771
+
772
+ /**
773
+ * @generated from field: string display_name = 2;
774
+ */
775
+ displayName = "";
776
+
777
+ constructor(data?: PartialMessage<UpdateCredentialRequest>) {
778
+ super();
779
+ proto3.util.initPartial(data, this);
780
+ }
781
+
782
+ static readonly runtime: typeof proto3 = proto3;
783
+ static readonly typeName = "scalekit.v1.auth.webauthn.UpdateCredentialRequest";
784
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
785
+ { no: 1, name: "credential_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
786
+ { no: 2, name: "display_name", kind: "scalar", T: 9 /* ScalarType.STRING */ },
787
+ ]);
788
+
789
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UpdateCredentialRequest {
790
+ return new UpdateCredentialRequest().fromBinary(bytes, options);
791
+ }
792
+
793
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UpdateCredentialRequest {
794
+ return new UpdateCredentialRequest().fromJson(jsonValue, options);
795
+ }
796
+
797
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UpdateCredentialRequest {
798
+ return new UpdateCredentialRequest().fromJsonString(jsonString, options);
799
+ }
800
+
801
+ static equals(a: UpdateCredentialRequest | PlainMessage<UpdateCredentialRequest> | undefined, b: UpdateCredentialRequest | PlainMessage<UpdateCredentialRequest> | undefined): boolean {
802
+ return proto3.util.equals(UpdateCredentialRequest, a, b);
803
+ }
804
+ }
805
+
806
+ /**
807
+ * @generated from message scalekit.v1.auth.webauthn.UpdateCredentialResponse
808
+ */
809
+ export class UpdateCredentialResponse extends Message<UpdateCredentialResponse> {
810
+ /**
811
+ * @generated from field: scalekit.v1.auth.webauthn.WebAuthnCredential credential = 1;
812
+ */
813
+ credential?: WebAuthnCredential;
814
+
815
+ constructor(data?: PartialMessage<UpdateCredentialResponse>) {
816
+ super();
817
+ proto3.util.initPartial(data, this);
818
+ }
819
+
820
+ static readonly runtime: typeof proto3 = proto3;
821
+ static readonly typeName = "scalekit.v1.auth.webauthn.UpdateCredentialResponse";
822
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
823
+ { no: 1, name: "credential", kind: "message", T: WebAuthnCredential },
824
+ ]);
825
+
826
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UpdateCredentialResponse {
827
+ return new UpdateCredentialResponse().fromBinary(bytes, options);
828
+ }
829
+
830
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UpdateCredentialResponse {
831
+ return new UpdateCredentialResponse().fromJson(jsonValue, options);
832
+ }
833
+
834
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UpdateCredentialResponse {
835
+ return new UpdateCredentialResponse().fromJsonString(jsonString, options);
836
+ }
837
+
838
+ static equals(a: UpdateCredentialResponse | PlainMessage<UpdateCredentialResponse> | undefined, b: UpdateCredentialResponse | PlainMessage<UpdateCredentialResponse> | undefined): boolean {
839
+ return proto3.util.equals(UpdateCredentialResponse, a, b);
840
+ }
841
+ }
842
+
843
+ /**
844
+ * @generated from message scalekit.v1.auth.webauthn.WebAuthnCredential
845
+ */
846
+ export class WebAuthnCredential extends Message<WebAuthnCredential> {
847
+ /**
848
+ * @generated from field: string id = 1;
849
+ */
850
+ id = "";
851
+
852
+ /**
853
+ * @generated from field: string user_id = 2;
854
+ */
855
+ userId = "";
856
+
857
+ /**
858
+ * @generated from field: bytes credential_id = 3;
859
+ */
860
+ credentialId = new Uint8Array(0);
861
+
862
+ /**
863
+ * @generated from field: string attestation_type = 4;
864
+ */
865
+ attestationType = "";
866
+
867
+ /**
868
+ * @generated from field: scalekit.v1.auth.webauthn.WebAuthnCredential.Authenticator authenticator = 5;
869
+ */
870
+ authenticator?: WebAuthnCredential_Authenticator;
871
+
872
+ /**
873
+ * @generated from field: repeated string transports = 6;
874
+ */
875
+ transports: string[] = [];
876
+
877
+ /**
878
+ * @generated from field: scalekit.v1.auth.webauthn.WebAuthnCredential.AuthenticatorFlags authenticator_flags = 7;
879
+ */
880
+ authenticatorFlags?: WebAuthnCredential_AuthenticatorFlags;
881
+
882
+ /**
883
+ * @generated from field: google.protobuf.Timestamp created_at = 8;
884
+ */
885
+ createdAt?: Timestamp;
886
+
887
+ /**
888
+ * @generated from field: google.protobuf.Timestamp updated_at = 9;
889
+ */
890
+ updatedAt?: Timestamp;
891
+
892
+ /**
893
+ * @generated from field: scalekit.v1.auth.webauthn.WebAuthnCredential.UserAgent user_agent = 10;
894
+ */
895
+ userAgent?: WebAuthnCredential_UserAgent;
896
+
897
+ /**
898
+ * @generated from field: scalekit.v1.auth.webauthn.WebAuthnCredential.ClientInfo client_info = 11;
899
+ */
900
+ clientInfo?: WebAuthnCredential_ClientInfo;
901
+
902
+ /**
903
+ * @generated from field: optional string display_name = 12;
904
+ */
905
+ displayName?: string;
906
+
907
+ constructor(data?: PartialMessage<WebAuthnCredential>) {
908
+ super();
909
+ proto3.util.initPartial(data, this);
910
+ }
911
+
912
+ static readonly runtime: typeof proto3 = proto3;
913
+ static readonly typeName = "scalekit.v1.auth.webauthn.WebAuthnCredential";
914
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
915
+ { no: 1, name: "id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
916
+ { no: 2, name: "user_id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
917
+ { no: 3, name: "credential_id", kind: "scalar", T: 12 /* ScalarType.BYTES */ },
918
+ { no: 4, name: "attestation_type", kind: "scalar", T: 9 /* ScalarType.STRING */ },
919
+ { no: 5, name: "authenticator", kind: "message", T: WebAuthnCredential_Authenticator },
920
+ { no: 6, name: "transports", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true },
921
+ { no: 7, name: "authenticator_flags", kind: "message", T: WebAuthnCredential_AuthenticatorFlags },
922
+ { no: 8, name: "created_at", kind: "message", T: Timestamp },
923
+ { no: 9, name: "updated_at", kind: "message", T: Timestamp },
924
+ { no: 10, name: "user_agent", kind: "message", T: WebAuthnCredential_UserAgent },
925
+ { no: 11, name: "client_info", kind: "message", T: WebAuthnCredential_ClientInfo },
926
+ { no: 12, name: "display_name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
927
+ ]);
928
+
929
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): WebAuthnCredential {
930
+ return new WebAuthnCredential().fromBinary(bytes, options);
931
+ }
932
+
933
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): WebAuthnCredential {
934
+ return new WebAuthnCredential().fromJson(jsonValue, options);
935
+ }
936
+
937
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): WebAuthnCredential {
938
+ return new WebAuthnCredential().fromJsonString(jsonString, options);
939
+ }
940
+
941
+ static equals(a: WebAuthnCredential | PlainMessage<WebAuthnCredential> | undefined, b: WebAuthnCredential | PlainMessage<WebAuthnCredential> | undefined): boolean {
942
+ return proto3.util.equals(WebAuthnCredential, a, b);
943
+ }
944
+ }
945
+
946
+ /**
947
+ * @generated from message scalekit.v1.auth.webauthn.WebAuthnCredential.AuthenticatorFlags
948
+ */
949
+ export class WebAuthnCredential_AuthenticatorFlags extends Message<WebAuthnCredential_AuthenticatorFlags> {
950
+ /**
951
+ * @generated from field: bool user_present = 1;
952
+ */
953
+ userPresent = false;
954
+
955
+ /**
956
+ * @generated from field: bool user_verified = 2;
957
+ */
958
+ userVerified = false;
959
+
960
+ /**
961
+ * @generated from field: bool backup_eligible = 3;
962
+ */
963
+ backupEligible = false;
964
+
965
+ /**
966
+ * @generated from field: bool backup_state = 4;
967
+ */
968
+ backupState = false;
969
+
970
+ constructor(data?: PartialMessage<WebAuthnCredential_AuthenticatorFlags>) {
971
+ super();
972
+ proto3.util.initPartial(data, this);
973
+ }
974
+
975
+ static readonly runtime: typeof proto3 = proto3;
976
+ static readonly typeName = "scalekit.v1.auth.webauthn.WebAuthnCredential.AuthenticatorFlags";
977
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
978
+ { no: 1, name: "user_present", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
979
+ { no: 2, name: "user_verified", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
980
+ { no: 3, name: "backup_eligible", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
981
+ { no: 4, name: "backup_state", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
982
+ ]);
983
+
984
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): WebAuthnCredential_AuthenticatorFlags {
985
+ return new WebAuthnCredential_AuthenticatorFlags().fromBinary(bytes, options);
986
+ }
987
+
988
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): WebAuthnCredential_AuthenticatorFlags {
989
+ return new WebAuthnCredential_AuthenticatorFlags().fromJson(jsonValue, options);
990
+ }
991
+
992
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): WebAuthnCredential_AuthenticatorFlags {
993
+ return new WebAuthnCredential_AuthenticatorFlags().fromJsonString(jsonString, options);
994
+ }
995
+
996
+ static equals(a: WebAuthnCredential_AuthenticatorFlags | PlainMessage<WebAuthnCredential_AuthenticatorFlags> | undefined, b: WebAuthnCredential_AuthenticatorFlags | PlainMessage<WebAuthnCredential_AuthenticatorFlags> | undefined): boolean {
997
+ return proto3.util.equals(WebAuthnCredential_AuthenticatorFlags, a, b);
998
+ }
999
+ }
1000
+
1001
+ /**
1002
+ * @generated from message scalekit.v1.auth.webauthn.WebAuthnCredential.Authenticator
1003
+ */
1004
+ export class WebAuthnCredential_Authenticator extends Message<WebAuthnCredential_Authenticator> {
1005
+ /**
1006
+ * @generated from field: string aaguid = 1;
1007
+ */
1008
+ aaguid = "";
1009
+
1010
+ /**
1011
+ * @generated from field: string name = 2;
1012
+ */
1013
+ name = "";
1014
+
1015
+ /**
1016
+ * @generated from field: string attachment = 3;
1017
+ */
1018
+ attachment = "";
1019
+
1020
+ /**
1021
+ * @generated from field: string icon_dark = 4;
1022
+ */
1023
+ iconDark = "";
1024
+
1025
+ /**
1026
+ * @generated from field: string icon_light = 5;
1027
+ */
1028
+ iconLight = "";
1029
+
1030
+ constructor(data?: PartialMessage<WebAuthnCredential_Authenticator>) {
1031
+ super();
1032
+ proto3.util.initPartial(data, this);
1033
+ }
1034
+
1035
+ static readonly runtime: typeof proto3 = proto3;
1036
+ static readonly typeName = "scalekit.v1.auth.webauthn.WebAuthnCredential.Authenticator";
1037
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
1038
+ { no: 1, name: "aaguid", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1039
+ { no: 2, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1040
+ { no: 3, name: "attachment", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1041
+ { no: 4, name: "icon_dark", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1042
+ { no: 5, name: "icon_light", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1043
+ ]);
1044
+
1045
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): WebAuthnCredential_Authenticator {
1046
+ return new WebAuthnCredential_Authenticator().fromBinary(bytes, options);
1047
+ }
1048
+
1049
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): WebAuthnCredential_Authenticator {
1050
+ return new WebAuthnCredential_Authenticator().fromJson(jsonValue, options);
1051
+ }
1052
+
1053
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): WebAuthnCredential_Authenticator {
1054
+ return new WebAuthnCredential_Authenticator().fromJsonString(jsonString, options);
1055
+ }
1056
+
1057
+ static equals(a: WebAuthnCredential_Authenticator | PlainMessage<WebAuthnCredential_Authenticator> | undefined, b: WebAuthnCredential_Authenticator | PlainMessage<WebAuthnCredential_Authenticator> | undefined): boolean {
1058
+ return proto3.util.equals(WebAuthnCredential_Authenticator, a, b);
1059
+ }
1060
+ }
1061
+
1062
+ /**
1063
+ * @generated from message scalekit.v1.auth.webauthn.WebAuthnCredential.UserAgent
1064
+ */
1065
+ export class WebAuthnCredential_UserAgent extends Message<WebAuthnCredential_UserAgent> {
1066
+ /**
1067
+ * @generated from field: string raw = 1;
1068
+ */
1069
+ raw = "";
1070
+
1071
+ /**
1072
+ * @generated from field: string url = 2;
1073
+ */
1074
+ url = "";
1075
+
1076
+ /**
1077
+ * @generated from field: string browser = 3;
1078
+ */
1079
+ browser = "";
1080
+
1081
+ /**
1082
+ * @generated from field: string browser_version = 4;
1083
+ */
1084
+ browserVersion = "";
1085
+
1086
+ /**
1087
+ * @generated from field: string os = 5;
1088
+ */
1089
+ os = "";
1090
+
1091
+ /**
1092
+ * @generated from field: string os_version = 6;
1093
+ */
1094
+ osVersion = "";
1095
+
1096
+ /**
1097
+ * @generated from field: string device_type = 7;
1098
+ */
1099
+ deviceType = "";
1100
+
1101
+ /**
1102
+ * @generated from field: string device_model = 8;
1103
+ */
1104
+ deviceModel = "";
1105
+
1106
+ constructor(data?: PartialMessage<WebAuthnCredential_UserAgent>) {
1107
+ super();
1108
+ proto3.util.initPartial(data, this);
1109
+ }
1110
+
1111
+ static readonly runtime: typeof proto3 = proto3;
1112
+ static readonly typeName = "scalekit.v1.auth.webauthn.WebAuthnCredential.UserAgent";
1113
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
1114
+ { no: 1, name: "raw", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1115
+ { no: 2, name: "url", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1116
+ { no: 3, name: "browser", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1117
+ { no: 4, name: "browser_version", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1118
+ { no: 5, name: "os", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1119
+ { no: 6, name: "os_version", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1120
+ { no: 7, name: "device_type", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1121
+ { no: 8, name: "device_model", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1122
+ ]);
1123
+
1124
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): WebAuthnCredential_UserAgent {
1125
+ return new WebAuthnCredential_UserAgent().fromBinary(bytes, options);
1126
+ }
1127
+
1128
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): WebAuthnCredential_UserAgent {
1129
+ return new WebAuthnCredential_UserAgent().fromJson(jsonValue, options);
1130
+ }
1131
+
1132
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): WebAuthnCredential_UserAgent {
1133
+ return new WebAuthnCredential_UserAgent().fromJsonString(jsonString, options);
1134
+ }
1135
+
1136
+ static equals(a: WebAuthnCredential_UserAgent | PlainMessage<WebAuthnCredential_UserAgent> | undefined, b: WebAuthnCredential_UserAgent | PlainMessage<WebAuthnCredential_UserAgent> | undefined): boolean {
1137
+ return proto3.util.equals(WebAuthnCredential_UserAgent, a, b);
1138
+ }
1139
+ }
1140
+
1141
+ /**
1142
+ * @generated from message scalekit.v1.auth.webauthn.WebAuthnCredential.ClientInfo
1143
+ */
1144
+ export class WebAuthnCredential_ClientInfo extends Message<WebAuthnCredential_ClientInfo> {
1145
+ /**
1146
+ * @generated from field: string ip = 1;
1147
+ */
1148
+ ip = "";
1149
+
1150
+ /**
1151
+ * @generated from field: string region = 2;
1152
+ */
1153
+ region = "";
1154
+
1155
+ /**
1156
+ * @generated from field: string region_subdivision = 3;
1157
+ */
1158
+ regionSubdivision = "";
1159
+
1160
+ /**
1161
+ * @generated from field: string city = 4;
1162
+ */
1163
+ city = "";
1164
+
1165
+ constructor(data?: PartialMessage<WebAuthnCredential_ClientInfo>) {
1166
+ super();
1167
+ proto3.util.initPartial(data, this);
1168
+ }
1169
+
1170
+ static readonly runtime: typeof proto3 = proto3;
1171
+ static readonly typeName = "scalekit.v1.auth.webauthn.WebAuthnCredential.ClientInfo";
1172
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
1173
+ { no: 1, name: "ip", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1174
+ { no: 2, name: "region", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1175
+ { no: 3, name: "region_subdivision", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1176
+ { no: 4, name: "city", kind: "scalar", T: 9 /* ScalarType.STRING */ },
1177
+ ]);
1178
+
1179
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): WebAuthnCredential_ClientInfo {
1180
+ return new WebAuthnCredential_ClientInfo().fromBinary(bytes, options);
1181
+ }
1182
+
1183
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): WebAuthnCredential_ClientInfo {
1184
+ return new WebAuthnCredential_ClientInfo().fromJson(jsonValue, options);
1185
+ }
1186
+
1187
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): WebAuthnCredential_ClientInfo {
1188
+ return new WebAuthnCredential_ClientInfo().fromJsonString(jsonString, options);
1189
+ }
1190
+
1191
+ static equals(a: WebAuthnCredential_ClientInfo | PlainMessage<WebAuthnCredential_ClientInfo> | undefined, b: WebAuthnCredential_ClientInfo | PlainMessage<WebAuthnCredential_ClientInfo> | undefined): boolean {
1192
+ return proto3.util.equals(WebAuthnCredential_ClientInfo, a, b);
1193
+ }
1194
+ }
1195
+
1196
+ /**
1197
+ * @generated from message scalekit.v1.auth.webauthn.GetRelatedOriginsRequest
1198
+ */
1199
+ export class GetRelatedOriginsRequest extends Message<GetRelatedOriginsRequest> {
1200
+ constructor(data?: PartialMessage<GetRelatedOriginsRequest>) {
1201
+ super();
1202
+ proto3.util.initPartial(data, this);
1203
+ }
1204
+
1205
+ static readonly runtime: typeof proto3 = proto3;
1206
+ static readonly typeName = "scalekit.v1.auth.webauthn.GetRelatedOriginsRequest";
1207
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
1208
+ ]);
1209
+
1210
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GetRelatedOriginsRequest {
1211
+ return new GetRelatedOriginsRequest().fromBinary(bytes, options);
1212
+ }
1213
+
1214
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GetRelatedOriginsRequest {
1215
+ return new GetRelatedOriginsRequest().fromJson(jsonValue, options);
1216
+ }
1217
+
1218
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GetRelatedOriginsRequest {
1219
+ return new GetRelatedOriginsRequest().fromJsonString(jsonString, options);
1220
+ }
1221
+
1222
+ static equals(a: GetRelatedOriginsRequest | PlainMessage<GetRelatedOriginsRequest> | undefined, b: GetRelatedOriginsRequest | PlainMessage<GetRelatedOriginsRequest> | undefined): boolean {
1223
+ return proto3.util.equals(GetRelatedOriginsRequest, a, b);
1224
+ }
1225
+ }
1226
+
1227
+ /**
1228
+ * @generated from message scalekit.v1.auth.webauthn.GetRelatedOriginsResponse
1229
+ */
1230
+ export class GetRelatedOriginsResponse extends Message<GetRelatedOriginsResponse> {
1231
+ /**
1232
+ * @generated from field: repeated string origins = 1;
1233
+ */
1234
+ origins: string[] = [];
1235
+
1236
+ constructor(data?: PartialMessage<GetRelatedOriginsResponse>) {
1237
+ super();
1238
+ proto3.util.initPartial(data, this);
1239
+ }
1240
+
1241
+ static readonly runtime: typeof proto3 = proto3;
1242
+ static readonly typeName = "scalekit.v1.auth.webauthn.GetRelatedOriginsResponse";
1243
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
1244
+ { no: 1, name: "origins", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true },
1245
+ ]);
1246
+
1247
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GetRelatedOriginsResponse {
1248
+ return new GetRelatedOriginsResponse().fromBinary(bytes, options);
1249
+ }
1250
+
1251
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GetRelatedOriginsResponse {
1252
+ return new GetRelatedOriginsResponse().fromJson(jsonValue, options);
1253
+ }
1254
+
1255
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GetRelatedOriginsResponse {
1256
+ return new GetRelatedOriginsResponse().fromJsonString(jsonString, options);
1257
+ }
1258
+
1259
+ static equals(a: GetRelatedOriginsResponse | PlainMessage<GetRelatedOriginsResponse> | undefined, b: GetRelatedOriginsResponse | PlainMessage<GetRelatedOriginsResponse> | undefined): boolean {
1260
+ return proto3.util.equals(GetRelatedOriginsResponse, a, b);
1261
+ }
1262
+ }
1263
+