@remnawave/backend-contract 2.2.17 → 2.2.19

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 (31) hide show
  1. package/build/backend/commands/remnawave-settings/get-remnawave-settings.command.d.ts +229 -0
  2. package/build/backend/commands/remnawave-settings/get-remnawave-settings.command.d.ts.map +1 -1
  3. package/build/backend/commands/remnawave-settings/update-remnawave-settings.command.d.ts +400 -0
  4. package/build/backend/commands/remnawave-settings/update-remnawave-settings.command.d.ts.map +1 -1
  5. package/build/backend/commands/remnawave-settings/update-remnawave-settings.command.js +3 -0
  6. package/build/backend/models/remnawave-settings/index.d.ts +3 -0
  7. package/build/backend/models/remnawave-settings/index.d.ts.map +1 -1
  8. package/build/backend/models/remnawave-settings/index.js +3 -0
  9. package/build/backend/models/remnawave-settings/oauth2-settings.schema.d.ts +96 -0
  10. package/build/backend/models/remnawave-settings/oauth2-settings.schema.d.ts.map +1 -0
  11. package/build/backend/models/remnawave-settings/oauth2-settings.schema.js +32 -0
  12. package/build/backend/models/remnawave-settings/passkey-settings.schema.d.ts +1 -0
  13. package/build/backend/models/remnawave-settings/passkey-settings.schema.d.ts.map +1 -1
  14. package/build/backend/models/remnawave-settings/passkey-settings.schema.js +13 -11
  15. package/build/backend/models/remnawave-settings/password-auth-settings.schema.d.ts +10 -0
  16. package/build/backend/models/remnawave-settings/password-auth-settings.schema.d.ts.map +1 -0
  17. package/build/backend/models/remnawave-settings/password-auth-settings.schema.js +10 -0
  18. package/build/backend/models/remnawave-settings/remnawave-settings.schema.d.ts +171 -2
  19. package/build/backend/models/remnawave-settings/remnawave-settings.schema.d.ts.map +1 -1
  20. package/build/backend/models/remnawave-settings/remnawave-settings.schema.js +6 -0
  21. package/build/backend/models/remnawave-settings/tg-auth-settings.schema.d.ts +16 -0
  22. package/build/backend/models/remnawave-settings/tg-auth-settings.schema.d.ts.map +1 -0
  23. package/build/backend/models/remnawave-settings/tg-auth-settings.schema.js +12 -0
  24. package/build/frontend/commands/remnawave-settings/update-remnawave-settings.command.js +3 -0
  25. package/build/frontend/models/remnawave-settings/index.js +3 -0
  26. package/build/frontend/models/remnawave-settings/oauth2-settings.schema.js +32 -0
  27. package/build/frontend/models/remnawave-settings/passkey-settings.schema.js +13 -11
  28. package/build/frontend/models/remnawave-settings/password-auth-settings.schema.js +10 -0
  29. package/build/frontend/models/remnawave-settings/remnawave-settings.schema.js +6 -0
  30. package/build/frontend/models/remnawave-settings/tg-auth-settings.schema.js +12 -0
  31. package/package.json +4 -1
@@ -17,18 +17,189 @@ export declare namespace UpdateRemnawaveSettingsCommand {
17
17
  rpId: string | null;
18
18
  origin: string | null;
19
19
  }>>;
20
+ oauth2Settings: z.ZodOptional<z.ZodObject<{
21
+ github: z.ZodObject<{
22
+ enabled: z.ZodBoolean;
23
+ clientId: z.ZodNullable<z.ZodString>;
24
+ clientSecret: z.ZodNullable<z.ZodString>;
25
+ allowedEmails: z.ZodArray<z.ZodString, "many">;
26
+ }, "strip", z.ZodTypeAny, {
27
+ enabled: boolean;
28
+ clientId: string | null;
29
+ clientSecret: string | null;
30
+ allowedEmails: string[];
31
+ }, {
32
+ enabled: boolean;
33
+ clientId: string | null;
34
+ clientSecret: string | null;
35
+ allowedEmails: string[];
36
+ }>;
37
+ pocketid: z.ZodObject<{
38
+ enabled: z.ZodBoolean;
39
+ clientId: z.ZodNullable<z.ZodString>;
40
+ clientSecret: z.ZodNullable<z.ZodString>;
41
+ plainDomain: z.ZodNullable<z.ZodEffects<z.ZodString, string, string>>;
42
+ allowedEmails: z.ZodArray<z.ZodString, "many">;
43
+ }, "strip", z.ZodTypeAny, {
44
+ enabled: boolean;
45
+ clientId: string | null;
46
+ clientSecret: string | null;
47
+ allowedEmails: string[];
48
+ plainDomain: string | null;
49
+ }, {
50
+ enabled: boolean;
51
+ clientId: string | null;
52
+ clientSecret: string | null;
53
+ allowedEmails: string[];
54
+ plainDomain: string | null;
55
+ }>;
56
+ yandex: z.ZodObject<{
57
+ enabled: z.ZodBoolean;
58
+ clientId: z.ZodNullable<z.ZodString>;
59
+ clientSecret: z.ZodNullable<z.ZodString>;
60
+ allowedEmails: z.ZodArray<z.ZodString, "many">;
61
+ }, "strip", z.ZodTypeAny, {
62
+ enabled: boolean;
63
+ clientId: string | null;
64
+ clientSecret: string | null;
65
+ allowedEmails: string[];
66
+ }, {
67
+ enabled: boolean;
68
+ clientId: string | null;
69
+ clientSecret: string | null;
70
+ allowedEmails: string[];
71
+ }>;
72
+ }, "strip", z.ZodTypeAny, {
73
+ github: {
74
+ enabled: boolean;
75
+ clientId: string | null;
76
+ clientSecret: string | null;
77
+ allowedEmails: string[];
78
+ };
79
+ pocketid: {
80
+ enabled: boolean;
81
+ clientId: string | null;
82
+ clientSecret: string | null;
83
+ allowedEmails: string[];
84
+ plainDomain: string | null;
85
+ };
86
+ yandex: {
87
+ enabled: boolean;
88
+ clientId: string | null;
89
+ clientSecret: string | null;
90
+ allowedEmails: string[];
91
+ };
92
+ }, {
93
+ github: {
94
+ enabled: boolean;
95
+ clientId: string | null;
96
+ clientSecret: string | null;
97
+ allowedEmails: string[];
98
+ };
99
+ pocketid: {
100
+ enabled: boolean;
101
+ clientId: string | null;
102
+ clientSecret: string | null;
103
+ allowedEmails: string[];
104
+ plainDomain: string | null;
105
+ };
106
+ yandex: {
107
+ enabled: boolean;
108
+ clientId: string | null;
109
+ clientSecret: string | null;
110
+ allowedEmails: string[];
111
+ };
112
+ }>>;
113
+ tgAuthSettings: z.ZodOptional<z.ZodObject<{
114
+ enabled: z.ZodBoolean;
115
+ botToken: z.ZodNullable<z.ZodString>;
116
+ adminIds: z.ZodArray<z.ZodNumber, "many">;
117
+ }, "strip", z.ZodTypeAny, {
118
+ enabled: boolean;
119
+ botToken: string | null;
120
+ adminIds: number[];
121
+ }, {
122
+ enabled: boolean;
123
+ botToken: string | null;
124
+ adminIds: number[];
125
+ }>>;
126
+ passwordSettings: z.ZodOptional<z.ZodObject<{
127
+ enabled: z.ZodBoolean;
128
+ }, "strip", z.ZodTypeAny, {
129
+ enabled: boolean;
130
+ }, {
131
+ enabled: boolean;
132
+ }>>;
20
133
  }, "strip", z.ZodTypeAny, {
21
134
  passkeySettings?: {
22
135
  enabled: boolean;
23
136
  rpId: string | null;
24
137
  origin: string | null;
25
138
  } | undefined;
139
+ oauth2Settings?: {
140
+ github: {
141
+ enabled: boolean;
142
+ clientId: string | null;
143
+ clientSecret: string | null;
144
+ allowedEmails: string[];
145
+ };
146
+ pocketid: {
147
+ enabled: boolean;
148
+ clientId: string | null;
149
+ clientSecret: string | null;
150
+ allowedEmails: string[];
151
+ plainDomain: string | null;
152
+ };
153
+ yandex: {
154
+ enabled: boolean;
155
+ clientId: string | null;
156
+ clientSecret: string | null;
157
+ allowedEmails: string[];
158
+ };
159
+ } | undefined;
160
+ tgAuthSettings?: {
161
+ enabled: boolean;
162
+ botToken: string | null;
163
+ adminIds: number[];
164
+ } | undefined;
165
+ passwordSettings?: {
166
+ enabled: boolean;
167
+ } | undefined;
26
168
  }, {
27
169
  passkeySettings?: {
28
170
  enabled: boolean;
29
171
  rpId: string | null;
30
172
  origin: string | null;
31
173
  } | undefined;
174
+ oauth2Settings?: {
175
+ github: {
176
+ enabled: boolean;
177
+ clientId: string | null;
178
+ clientSecret: string | null;
179
+ allowedEmails: string[];
180
+ };
181
+ pocketid: {
182
+ enabled: boolean;
183
+ clientId: string | null;
184
+ clientSecret: string | null;
185
+ allowedEmails: string[];
186
+ plainDomain: string | null;
187
+ };
188
+ yandex: {
189
+ enabled: boolean;
190
+ clientId: string | null;
191
+ clientSecret: string | null;
192
+ allowedEmails: string[];
193
+ };
194
+ } | undefined;
195
+ tgAuthSettings?: {
196
+ enabled: boolean;
197
+ botToken: string | null;
198
+ adminIds: number[];
199
+ } | undefined;
200
+ passwordSettings?: {
201
+ enabled: boolean;
202
+ } | undefined;
32
203
  }>;
33
204
  type Request = z.infer<typeof RequestSchema>;
34
205
  const ResponseSchema: z.ZodObject<{
@@ -46,18 +217,189 @@ export declare namespace UpdateRemnawaveSettingsCommand {
46
217
  rpId: string | null;
47
218
  origin: string | null;
48
219
  }>>;
220
+ oauth2Settings: z.ZodNullable<z.ZodObject<{
221
+ github: z.ZodObject<{
222
+ enabled: z.ZodBoolean;
223
+ clientId: z.ZodNullable<z.ZodString>;
224
+ clientSecret: z.ZodNullable<z.ZodString>;
225
+ allowedEmails: z.ZodArray<z.ZodString, "many">;
226
+ }, "strip", z.ZodTypeAny, {
227
+ enabled: boolean;
228
+ clientId: string | null;
229
+ clientSecret: string | null;
230
+ allowedEmails: string[];
231
+ }, {
232
+ enabled: boolean;
233
+ clientId: string | null;
234
+ clientSecret: string | null;
235
+ allowedEmails: string[];
236
+ }>;
237
+ pocketid: z.ZodObject<{
238
+ enabled: z.ZodBoolean;
239
+ clientId: z.ZodNullable<z.ZodString>;
240
+ clientSecret: z.ZodNullable<z.ZodString>;
241
+ plainDomain: z.ZodNullable<z.ZodEffects<z.ZodString, string, string>>;
242
+ allowedEmails: z.ZodArray<z.ZodString, "many">;
243
+ }, "strip", z.ZodTypeAny, {
244
+ enabled: boolean;
245
+ clientId: string | null;
246
+ clientSecret: string | null;
247
+ allowedEmails: string[];
248
+ plainDomain: string | null;
249
+ }, {
250
+ enabled: boolean;
251
+ clientId: string | null;
252
+ clientSecret: string | null;
253
+ allowedEmails: string[];
254
+ plainDomain: string | null;
255
+ }>;
256
+ yandex: z.ZodObject<{
257
+ enabled: z.ZodBoolean;
258
+ clientId: z.ZodNullable<z.ZodString>;
259
+ clientSecret: z.ZodNullable<z.ZodString>;
260
+ allowedEmails: z.ZodArray<z.ZodString, "many">;
261
+ }, "strip", z.ZodTypeAny, {
262
+ enabled: boolean;
263
+ clientId: string | null;
264
+ clientSecret: string | null;
265
+ allowedEmails: string[];
266
+ }, {
267
+ enabled: boolean;
268
+ clientId: string | null;
269
+ clientSecret: string | null;
270
+ allowedEmails: string[];
271
+ }>;
272
+ }, "strip", z.ZodTypeAny, {
273
+ github: {
274
+ enabled: boolean;
275
+ clientId: string | null;
276
+ clientSecret: string | null;
277
+ allowedEmails: string[];
278
+ };
279
+ pocketid: {
280
+ enabled: boolean;
281
+ clientId: string | null;
282
+ clientSecret: string | null;
283
+ allowedEmails: string[];
284
+ plainDomain: string | null;
285
+ };
286
+ yandex: {
287
+ enabled: boolean;
288
+ clientId: string | null;
289
+ clientSecret: string | null;
290
+ allowedEmails: string[];
291
+ };
292
+ }, {
293
+ github: {
294
+ enabled: boolean;
295
+ clientId: string | null;
296
+ clientSecret: string | null;
297
+ allowedEmails: string[];
298
+ };
299
+ pocketid: {
300
+ enabled: boolean;
301
+ clientId: string | null;
302
+ clientSecret: string | null;
303
+ allowedEmails: string[];
304
+ plainDomain: string | null;
305
+ };
306
+ yandex: {
307
+ enabled: boolean;
308
+ clientId: string | null;
309
+ clientSecret: string | null;
310
+ allowedEmails: string[];
311
+ };
312
+ }>>;
313
+ tgAuthSettings: z.ZodNullable<z.ZodObject<{
314
+ enabled: z.ZodBoolean;
315
+ botToken: z.ZodNullable<z.ZodString>;
316
+ adminIds: z.ZodArray<z.ZodNumber, "many">;
317
+ }, "strip", z.ZodTypeAny, {
318
+ enabled: boolean;
319
+ botToken: string | null;
320
+ adminIds: number[];
321
+ }, {
322
+ enabled: boolean;
323
+ botToken: string | null;
324
+ adminIds: number[];
325
+ }>>;
326
+ passwordSettings: z.ZodNullable<z.ZodObject<{
327
+ enabled: z.ZodBoolean;
328
+ }, "strip", z.ZodTypeAny, {
329
+ enabled: boolean;
330
+ }, {
331
+ enabled: boolean;
332
+ }>>;
49
333
  }, "strip", z.ZodTypeAny, {
50
334
  passkeySettings: {
51
335
  enabled: boolean;
52
336
  rpId: string | null;
53
337
  origin: string | null;
54
338
  } | null;
339
+ oauth2Settings: {
340
+ github: {
341
+ enabled: boolean;
342
+ clientId: string | null;
343
+ clientSecret: string | null;
344
+ allowedEmails: string[];
345
+ };
346
+ pocketid: {
347
+ enabled: boolean;
348
+ clientId: string | null;
349
+ clientSecret: string | null;
350
+ allowedEmails: string[];
351
+ plainDomain: string | null;
352
+ };
353
+ yandex: {
354
+ enabled: boolean;
355
+ clientId: string | null;
356
+ clientSecret: string | null;
357
+ allowedEmails: string[];
358
+ };
359
+ } | null;
360
+ tgAuthSettings: {
361
+ enabled: boolean;
362
+ botToken: string | null;
363
+ adminIds: number[];
364
+ } | null;
365
+ passwordSettings: {
366
+ enabled: boolean;
367
+ } | null;
55
368
  }, {
56
369
  passkeySettings: {
57
370
  enabled: boolean;
58
371
  rpId: string | null;
59
372
  origin: string | null;
60
373
  } | null;
374
+ oauth2Settings: {
375
+ github: {
376
+ enabled: boolean;
377
+ clientId: string | null;
378
+ clientSecret: string | null;
379
+ allowedEmails: string[];
380
+ };
381
+ pocketid: {
382
+ enabled: boolean;
383
+ clientId: string | null;
384
+ clientSecret: string | null;
385
+ allowedEmails: string[];
386
+ plainDomain: string | null;
387
+ };
388
+ yandex: {
389
+ enabled: boolean;
390
+ clientId: string | null;
391
+ clientSecret: string | null;
392
+ allowedEmails: string[];
393
+ };
394
+ } | null;
395
+ tgAuthSettings: {
396
+ enabled: boolean;
397
+ botToken: string | null;
398
+ adminIds: number[];
399
+ } | null;
400
+ passwordSettings: {
401
+ enabled: boolean;
402
+ } | null;
61
403
  }>;
62
404
  }, "strip", z.ZodTypeAny, {
63
405
  response: {
@@ -66,6 +408,35 @@ export declare namespace UpdateRemnawaveSettingsCommand {
66
408
  rpId: string | null;
67
409
  origin: string | null;
68
410
  } | null;
411
+ oauth2Settings: {
412
+ github: {
413
+ enabled: boolean;
414
+ clientId: string | null;
415
+ clientSecret: string | null;
416
+ allowedEmails: string[];
417
+ };
418
+ pocketid: {
419
+ enabled: boolean;
420
+ clientId: string | null;
421
+ clientSecret: string | null;
422
+ allowedEmails: string[];
423
+ plainDomain: string | null;
424
+ };
425
+ yandex: {
426
+ enabled: boolean;
427
+ clientId: string | null;
428
+ clientSecret: string | null;
429
+ allowedEmails: string[];
430
+ };
431
+ } | null;
432
+ tgAuthSettings: {
433
+ enabled: boolean;
434
+ botToken: string | null;
435
+ adminIds: number[];
436
+ } | null;
437
+ passwordSettings: {
438
+ enabled: boolean;
439
+ } | null;
69
440
  };
70
441
  }, {
71
442
  response: {
@@ -74,6 +445,35 @@ export declare namespace UpdateRemnawaveSettingsCommand {
74
445
  rpId: string | null;
75
446
  origin: string | null;
76
447
  } | null;
448
+ oauth2Settings: {
449
+ github: {
450
+ enabled: boolean;
451
+ clientId: string | null;
452
+ clientSecret: string | null;
453
+ allowedEmails: string[];
454
+ };
455
+ pocketid: {
456
+ enabled: boolean;
457
+ clientId: string | null;
458
+ clientSecret: string | null;
459
+ allowedEmails: string[];
460
+ plainDomain: string | null;
461
+ };
462
+ yandex: {
463
+ enabled: boolean;
464
+ clientId: string | null;
465
+ clientSecret: string | null;
466
+ allowedEmails: string[];
467
+ };
468
+ } | null;
469
+ tgAuthSettings: {
470
+ enabled: boolean;
471
+ botToken: string | null;
472
+ adminIds: number[];
473
+ } | null;
474
+ passwordSettings: {
475
+ enabled: boolean;
476
+ } | null;
77
477
  };
78
478
  }>;
79
479
  type Response = z.infer<typeof ResponseSchema>;
@@ -1 +1 @@
1
- {"version":3,"file":"update-remnawave-settings.command.d.ts","sourceRoot":"","sources":["../../../../commands/remnawave-settings/update-remnawave-settings.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,yBAAiB,8BAA8B,CAAC;IACrC,MAAM,GAAG,4BAAsC,CAAC;IAChD,MAAM,OAAO,4BAAM,CAAC;IAEpB,MAAM,eAAe,2CAI3B,CAAC;IAEK,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;MAExB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;IAE7C,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAEzB,CAAC;IAEH,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACzD"}
1
+ {"version":3,"file":"update-remnawave-settings.command.d.ts","sourceRoot":"","sources":["../../../../commands/remnawave-settings/update-remnawave-settings.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAYxB,yBAAiB,8BAA8B,CAAC;IACrC,MAAM,GAAG,4BAAsC,CAAC;IAChD,MAAM,OAAO,4BAAM,CAAC;IAEpB,MAAM,eAAe,2CAI3B,CAAC;IAEK,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAKxB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;IAE7C,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAEzB,CAAC;IAEH,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACzD"}
@@ -12,6 +12,9 @@ var UpdateRemnawaveSettingsCommand;
12
12
  UpdateRemnawaveSettingsCommand.endpointDetails = (0, constants_1.getEndpointDetails)(api_1.REMNAAWAVE_SETTINGS_ROUTES.UPDATE, 'patch', 'Update Remnawave settings');
13
13
  UpdateRemnawaveSettingsCommand.RequestSchema = zod_1.z.object({
14
14
  passkeySettings: models_1.PasskeySettingsSchema.optional(),
15
+ oauth2Settings: models_1.Oauth2SettingsSchema.optional(),
16
+ tgAuthSettings: models_1.TgAuthSettingsSchema.optional(),
17
+ passwordSettings: models_1.PasswordAuthSettingsSchema.optional(),
15
18
  });
16
19
  UpdateRemnawaveSettingsCommand.ResponseSchema = zod_1.z.object({
17
20
  response: models_1.RemnawaveSettingsSchema,
@@ -1,3 +1,6 @@
1
+ export * from './oauth2-settings.schema';
1
2
  export * from './passkey-settings.schema';
3
+ export * from './password-auth-settings.schema';
2
4
  export * from './remnawave-settings.schema';
5
+ export * from './tg-auth-settings.schema';
3
6
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../models/remnawave-settings/index.ts"],"names":[],"mappings":"AAAA,cAAc,2BAA2B,CAAC;AAC1C,cAAc,6BAA6B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../models/remnawave-settings/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC;AACzC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,iCAAiC,CAAC;AAChD,cAAc,6BAA6B,CAAC;AAC5C,cAAc,2BAA2B,CAAC"}
@@ -14,5 +14,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./oauth2-settings.schema"), exports);
17
18
  __exportStar(require("./passkey-settings.schema"), exports);
19
+ __exportStar(require("./password-auth-settings.schema"), exports);
18
20
  __exportStar(require("./remnawave-settings.schema"), exports);
21
+ __exportStar(require("./tg-auth-settings.schema"), exports);
@@ -0,0 +1,96 @@
1
+ import z from 'zod';
2
+ export declare const Oauth2SettingsSchema: z.ZodObject<{
3
+ github: z.ZodObject<{
4
+ enabled: z.ZodBoolean;
5
+ clientId: z.ZodNullable<z.ZodString>;
6
+ clientSecret: z.ZodNullable<z.ZodString>;
7
+ allowedEmails: z.ZodArray<z.ZodString, "many">;
8
+ }, "strip", z.ZodTypeAny, {
9
+ enabled: boolean;
10
+ clientId: string | null;
11
+ clientSecret: string | null;
12
+ allowedEmails: string[];
13
+ }, {
14
+ enabled: boolean;
15
+ clientId: string | null;
16
+ clientSecret: string | null;
17
+ allowedEmails: string[];
18
+ }>;
19
+ pocketid: z.ZodObject<{
20
+ enabled: z.ZodBoolean;
21
+ clientId: z.ZodNullable<z.ZodString>;
22
+ clientSecret: z.ZodNullable<z.ZodString>;
23
+ plainDomain: z.ZodNullable<z.ZodEffects<z.ZodString, string, string>>;
24
+ allowedEmails: z.ZodArray<z.ZodString, "many">;
25
+ }, "strip", z.ZodTypeAny, {
26
+ enabled: boolean;
27
+ clientId: string | null;
28
+ clientSecret: string | null;
29
+ allowedEmails: string[];
30
+ plainDomain: string | null;
31
+ }, {
32
+ enabled: boolean;
33
+ clientId: string | null;
34
+ clientSecret: string | null;
35
+ allowedEmails: string[];
36
+ plainDomain: string | null;
37
+ }>;
38
+ yandex: z.ZodObject<{
39
+ enabled: z.ZodBoolean;
40
+ clientId: z.ZodNullable<z.ZodString>;
41
+ clientSecret: z.ZodNullable<z.ZodString>;
42
+ allowedEmails: z.ZodArray<z.ZodString, "many">;
43
+ }, "strip", z.ZodTypeAny, {
44
+ enabled: boolean;
45
+ clientId: string | null;
46
+ clientSecret: string | null;
47
+ allowedEmails: string[];
48
+ }, {
49
+ enabled: boolean;
50
+ clientId: string | null;
51
+ clientSecret: string | null;
52
+ allowedEmails: string[];
53
+ }>;
54
+ }, "strip", z.ZodTypeAny, {
55
+ github: {
56
+ enabled: boolean;
57
+ clientId: string | null;
58
+ clientSecret: string | null;
59
+ allowedEmails: string[];
60
+ };
61
+ pocketid: {
62
+ enabled: boolean;
63
+ clientId: string | null;
64
+ clientSecret: string | null;
65
+ allowedEmails: string[];
66
+ plainDomain: string | null;
67
+ };
68
+ yandex: {
69
+ enabled: boolean;
70
+ clientId: string | null;
71
+ clientSecret: string | null;
72
+ allowedEmails: string[];
73
+ };
74
+ }, {
75
+ github: {
76
+ enabled: boolean;
77
+ clientId: string | null;
78
+ clientSecret: string | null;
79
+ allowedEmails: string[];
80
+ };
81
+ pocketid: {
82
+ enabled: boolean;
83
+ clientId: string | null;
84
+ clientSecret: string | null;
85
+ allowedEmails: string[];
86
+ plainDomain: string | null;
87
+ };
88
+ yandex: {
89
+ enabled: boolean;
90
+ clientId: string | null;
91
+ clientSecret: string | null;
92
+ allowedEmails: string[];
93
+ };
94
+ }>;
95
+ export type TOauth2Settings = z.infer<typeof Oauth2SettingsSchema>;
96
+ //# sourceMappingURL=oauth2-settings.schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"oauth2-settings.schema.d.ts","sourceRoot":"","sources":["../../../../models/remnawave-settings/oauth2-settings.schema.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA6B/B,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC"}
@@ -0,0 +1,32 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.Oauth2SettingsSchema = void 0;
7
+ const isFQDN_1 = __importDefault(require("validator/lib/isFQDN"));
8
+ const zod_1 = __importDefault(require("zod"));
9
+ exports.Oauth2SettingsSchema = zod_1.default.object({
10
+ github: zod_1.default.object({
11
+ enabled: zod_1.default.boolean(),
12
+ clientId: zod_1.default.nullable(zod_1.default.string()),
13
+ clientSecret: zod_1.default.nullable(zod_1.default.string()),
14
+ allowedEmails: zod_1.default.array(zod_1.default.string()),
15
+ }),
16
+ pocketid: zod_1.default.object({
17
+ enabled: zod_1.default.boolean(),
18
+ clientId: zod_1.default.nullable(zod_1.default.string()),
19
+ clientSecret: zod_1.default.nullable(zod_1.default.string()),
20
+ plainDomain: zod_1.default.nullable(zod_1.default.string().refine((val) => val === 'localhost' ||
21
+ (0, isFQDN_1.default)(val, {
22
+ require_tld: true,
23
+ }), 'Must be a valid fully qualified domain name (FQDN), e.g. "remnawave.com" or "localhost"')),
24
+ allowedEmails: zod_1.default.array(zod_1.default.string()),
25
+ }),
26
+ yandex: zod_1.default.object({
27
+ enabled: zod_1.default.boolean(),
28
+ clientId: zod_1.default.nullable(zod_1.default.string()),
29
+ clientSecret: zod_1.default.nullable(zod_1.default.string()),
30
+ allowedEmails: zod_1.default.array(zod_1.default.string()),
31
+ }),
32
+ });
@@ -12,4 +12,5 @@ export declare const PasskeySettingsSchema: z.ZodObject<{
12
12
  rpId: string | null;
13
13
  origin: string | null;
14
14
  }>;
15
+ export type TRemnawavePasskeySettings = z.infer<typeof PasskeySettingsSchema>;
15
16
  //# sourceMappingURL=passkey-settings.schema.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"passkey-settings.schema.d.ts","sourceRoot":"","sources":["../../../../models/remnawave-settings/passkey-settings.schema.ts"],"names":[],"mappings":"AAEA,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB,eAAO,MAAM,qBAAqB;;;;;;;;;;;;EAyBhC,CAAC"}
1
+ {"version":3,"file":"passkey-settings.schema.d.ts","sourceRoot":"","sources":["../../../../models/remnawave-settings/passkey-settings.schema.ts"],"names":[],"mappings":"AAEA,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB,eAAO,MAAM,qBAAqB;;;;;;;;;;;;EA2BhC,CAAC;AAEH,MAAM,MAAM,yBAAyB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC"}
@@ -9,15 +9,17 @@ const isURL_1 = __importDefault(require("validator/lib/isURL"));
9
9
  const zod_1 = __importDefault(require("zod"));
10
10
  exports.PasskeySettingsSchema = zod_1.default.object({
11
11
  enabled: zod_1.default.boolean(),
12
- rpId: zod_1.default.nullable(zod_1.default.string().refine((val) => (0, isFQDN_1.default)(val, {
13
- require_tld: true,
14
- }), 'Must me a valid fully qualified domain name (FQDN), e.g. "remnawave.com"')),
15
- origin: zod_1.default.nullable(zod_1.default.string().refine((val) => (0, isURL_1.default)(val, {
16
- protocols: ['http', 'https'],
17
- require_protocol: true,
18
- require_valid_protocol: true,
19
- allow_fragments: false,
20
- allow_query_components: false,
21
- allow_trailing_dot: false,
22
- }), 'Must me a valid URL, e.g. "https://remnawave.com"')),
12
+ rpId: zod_1.default.nullable(zod_1.default.string().refine((val) => val === 'localhost' ||
13
+ (0, isFQDN_1.default)(val, {
14
+ require_tld: true,
15
+ }), 'Must be a valid fully qualified domain name (FQDN), e.g. "remnawave.com" or "localhost"')),
16
+ origin: zod_1.default.nullable(zod_1.default.string().refine((val) => /^http[s]?:\/\/localhost:\d+$/.test(val) ||
17
+ (0, isURL_1.default)(val, {
18
+ protocols: ['http', 'https'],
19
+ require_protocol: true,
20
+ require_valid_protocol: true,
21
+ allow_fragments: false,
22
+ allow_query_components: false,
23
+ allow_trailing_dot: false,
24
+ }), 'Must be a valid URL, e.g. "https://remnawave.com"')),
23
25
  });
@@ -0,0 +1,10 @@
1
+ import z from 'zod';
2
+ export declare const PasswordAuthSettingsSchema: z.ZodObject<{
3
+ enabled: z.ZodBoolean;
4
+ }, "strip", z.ZodTypeAny, {
5
+ enabled: boolean;
6
+ }, {
7
+ enabled: boolean;
8
+ }>;
9
+ export type TPasswordAuthSettings = z.infer<typeof PasswordAuthSettingsSchema>;
10
+ //# sourceMappingURL=password-auth-settings.schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"password-auth-settings.schema.d.ts","sourceRoot":"","sources":["../../../../models/remnawave-settings/password-auth-settings.schema.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB,eAAO,MAAM,0BAA0B;;;;;;EAErC,CAAC;AAEH,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC"}