@alepha/ui 0.13.7 → 0.13.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.
- package/dist/admin/index.d.ts +1921 -1399
- package/dist/auth/index.d.ts +562 -534
- package/dist/core/index.d.ts +51 -51
- package/package.json +15 -16
package/dist/admin/index.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { AdminShellProps } from "@alepha/ui";
|
|
2
2
|
import { AuthRouter } from "@alepha/ui/auth";
|
|
3
|
-
import * as
|
|
3
|
+
import * as alepha2502 from "alepha";
|
|
4
4
|
import { Alepha, AlephaError, Async, FileLike, InstantiableClass, LogLevel, LoggerInterface, Page, Page as Page$1, PageQuery, Primitive, Service, Static, StaticEncode, StreamLike, TArray, TFile, TNull, TObject, TOptional, TRecord, TSchema, TStream, TString, TUnion, TVoid } from "alepha";
|
|
5
5
|
import * as react_jsx_runtime0 from "react/jsx-runtime";
|
|
6
|
-
import * as
|
|
6
|
+
import * as react3 from "react";
|
|
7
7
|
import { FC, ReactNode } from "react";
|
|
8
8
|
import { IncomingMessage, Server, ServerResponse } from "node:http";
|
|
9
9
|
import { Readable } from "node:stream";
|
|
@@ -17,7 +17,6 @@ import "dayjs/locale/ar.js";
|
|
|
17
17
|
import "dayjs/locale/fr.js";
|
|
18
18
|
import DayjsApi, { Dayjs, ManipulateType, PluginFunc } from "dayjs";
|
|
19
19
|
import { JSONWebKeySet } from "jose";
|
|
20
|
-
import { AuditController } from "alepha/api/audits";
|
|
21
20
|
import * as drizzle_orm0 from "drizzle-orm";
|
|
22
21
|
import { BuildExtraConfigColumns, SQL, SQLWrapper } from "drizzle-orm";
|
|
23
22
|
import * as drizzle_orm_pg_core0 from "drizzle-orm/pg-core";
|
|
@@ -26,33 +25,33 @@ import { PgTransactionConfig } from "drizzle-orm/pg-core/session";
|
|
|
26
25
|
import * as DrizzleKit from "drizzle-kit/api";
|
|
27
26
|
|
|
28
27
|
//#region ../../../alepha/src/security/schemas/userAccountInfoSchema.d.ts
|
|
29
|
-
declare const userAccountInfoSchema:
|
|
30
|
-
id:
|
|
31
|
-
name:
|
|
32
|
-
email:
|
|
33
|
-
username:
|
|
34
|
-
picture:
|
|
35
|
-
sessionId:
|
|
36
|
-
organizations:
|
|
37
|
-
roles:
|
|
28
|
+
declare const userAccountInfoSchema: alepha2502.TObject<{
|
|
29
|
+
id: alepha2502.TString;
|
|
30
|
+
name: alepha2502.TOptional<alepha2502.TString>;
|
|
31
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
32
|
+
username: alepha2502.TOptional<alepha2502.TString>;
|
|
33
|
+
picture: alepha2502.TOptional<alepha2502.TString>;
|
|
34
|
+
sessionId: alepha2502.TOptional<alepha2502.TString>;
|
|
35
|
+
organizations: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
36
|
+
roles: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
38
37
|
}>;
|
|
39
38
|
type UserAccount = Static<typeof userAccountInfoSchema>;
|
|
40
39
|
//#endregion
|
|
41
|
-
//#region ../../../alepha/src/server/schemas/errorSchema.d.ts
|
|
42
|
-
declare const errorSchema:
|
|
43
|
-
error:
|
|
44
|
-
status:
|
|
45
|
-
message:
|
|
46
|
-
details:
|
|
47
|
-
requestId:
|
|
48
|
-
cause:
|
|
49
|
-
name:
|
|
50
|
-
message:
|
|
40
|
+
//#region ../../../alepha/src/server/core/schemas/errorSchema.d.ts
|
|
41
|
+
declare const errorSchema: alepha2502.TObject<{
|
|
42
|
+
error: alepha2502.TString;
|
|
43
|
+
status: alepha2502.TInteger;
|
|
44
|
+
message: alepha2502.TString;
|
|
45
|
+
details: alepha2502.TOptional<alepha2502.TString>;
|
|
46
|
+
requestId: alepha2502.TOptional<alepha2502.TString>;
|
|
47
|
+
cause: alepha2502.TOptional<alepha2502.TObject<{
|
|
48
|
+
name: alepha2502.TString;
|
|
49
|
+
message: alepha2502.TString;
|
|
51
50
|
}>>;
|
|
52
51
|
}>;
|
|
53
52
|
type ErrorSchema = Static<typeof errorSchema>;
|
|
54
53
|
//#endregion
|
|
55
|
-
//#region ../../../alepha/src/server/errors/HttpError.d.ts
|
|
54
|
+
//#region ../../../alepha/src/server/core/errors/HttpError.d.ts
|
|
56
55
|
declare class HttpError extends AlephaError {
|
|
57
56
|
name: string;
|
|
58
57
|
static is: (error: unknown, status?: number) => error is HttpErrorLike;
|
|
@@ -115,11 +114,11 @@ interface Tree<T$1 extends Route> {
|
|
|
115
114
|
};
|
|
116
115
|
}
|
|
117
116
|
//#endregion
|
|
118
|
-
//#region ../../../alepha/src/server/constants/routeMethods.d.ts
|
|
117
|
+
//#region ../../../alepha/src/server/core/constants/routeMethods.d.ts
|
|
119
118
|
declare const routeMethods: readonly ["GET", "POST", "PUT", "PATCH", "DELETE", "HEAD", "OPTIONS", "CONNECT", "TRACE"];
|
|
120
119
|
type RouteMethod = (typeof routeMethods)[number];
|
|
121
120
|
//#endregion
|
|
122
|
-
//#region ../../../alepha/src/server/helpers/ServerReply.d.ts
|
|
121
|
+
//#region ../../../alepha/src/server/core/helpers/ServerReply.d.ts
|
|
123
122
|
/**
|
|
124
123
|
* Helper for building server replies.
|
|
125
124
|
*/
|
|
@@ -147,7 +146,7 @@ declare class ServerReply {
|
|
|
147
146
|
setBody(body: any): this;
|
|
148
147
|
}
|
|
149
148
|
//#endregion
|
|
150
|
-
//#region ../../../alepha/src/server/services/UserAgentParser.d.ts
|
|
149
|
+
//#region ../../../alepha/src/server/core/services/UserAgentParser.d.ts
|
|
151
150
|
interface UserAgentInfo {
|
|
152
151
|
os: "Windows" | "Android" | "Ubuntu" | "MacOS" | "iOS" | "Linux" | "FreeBSD" | "OpenBSD" | "ChromeOS" | "BlackBerry" | "Symbian" | "Windows Phone";
|
|
153
152
|
browser: "Chrome" | "Firefox" | "Safari" | "Edge" | "Opera" | "Internet Explorer" | "Brave" | "Vivaldi" | "Samsung Browser" | "UC Browser" | "Yandex";
|
|
@@ -163,7 +162,7 @@ declare class UserAgentParser {
|
|
|
163
162
|
parse(userAgent?: string): UserAgentInfo;
|
|
164
163
|
}
|
|
165
164
|
//#endregion
|
|
166
|
-
//#region ../../../alepha/src/server/interfaces/ServerRequest.d.ts
|
|
165
|
+
//#region ../../../alepha/src/server/core/interfaces/ServerRequest.d.ts
|
|
167
166
|
type TRequestBody = TObject | TString | TArray | TRecord | TStream;
|
|
168
167
|
type TResponseBody = TObject | TString | TRecord | TFile | TArray | TStream | TVoid;
|
|
169
168
|
interface RequestConfigSchema {
|
|
@@ -286,15 +285,15 @@ interface WebRequestEvent {
|
|
|
286
285
|
}
|
|
287
286
|
//#endregion
|
|
288
287
|
//#region ../../../alepha/src/logger/schemas/logEntrySchema.d.ts
|
|
289
|
-
declare const logEntrySchema:
|
|
290
|
-
level:
|
|
291
|
-
message:
|
|
292
|
-
service:
|
|
293
|
-
module:
|
|
294
|
-
context:
|
|
295
|
-
app:
|
|
296
|
-
data:
|
|
297
|
-
timestamp:
|
|
288
|
+
declare const logEntrySchema: alepha2502.TObject<{
|
|
289
|
+
level: alepha2502.TUnsafe<"TRACE" | "SILENT" | "DEBUG" | "INFO" | "WARN" | "ERROR">;
|
|
290
|
+
message: alepha2502.TString;
|
|
291
|
+
service: alepha2502.TString;
|
|
292
|
+
module: alepha2502.TString;
|
|
293
|
+
context: alepha2502.TOptional<alepha2502.TString>;
|
|
294
|
+
app: alepha2502.TOptional<alepha2502.TString>;
|
|
295
|
+
data: alepha2502.TOptional<alepha2502.TAny>;
|
|
296
|
+
timestamp: alepha2502.TNumber;
|
|
298
297
|
}>;
|
|
299
298
|
type LogEntry = Static<typeof logEntrySchema>;
|
|
300
299
|
//#endregion
|
|
@@ -309,8 +308,8 @@ declare class DateTimeProvider {
|
|
|
309
308
|
protected readonly timeouts: Timeout[];
|
|
310
309
|
protected readonly intervals: Interval[];
|
|
311
310
|
constructor();
|
|
312
|
-
protected readonly onStart:
|
|
313
|
-
protected readonly onStop:
|
|
311
|
+
protected readonly onStart: alepha2502.HookPrimitive<"start">;
|
|
312
|
+
protected readonly onStop: alepha2502.HookPrimitive<"stop">;
|
|
314
313
|
setLocale(locale: string): void;
|
|
315
314
|
isDateTime(value: unknown): value is DateTime;
|
|
316
315
|
/**
|
|
@@ -442,7 +441,7 @@ declare class Logger implements LoggerInterface {
|
|
|
442
441
|
}
|
|
443
442
|
//#endregion
|
|
444
443
|
//#region ../../../alepha/src/logger/index.d.ts
|
|
445
|
-
declare const envSchema$10:
|
|
444
|
+
declare const envSchema$10: alepha2502.TObject<{
|
|
446
445
|
/**
|
|
447
446
|
* Default log level for the application.
|
|
448
447
|
*
|
|
@@ -459,14 +458,14 @@ declare const envSchema$10: alepha1962.TObject<{
|
|
|
459
458
|
* LOG_LEVEL=my.module.name:debug,info # Set debug level for my.module.name and info for all other modules
|
|
460
459
|
* LOG_LEVEL=alepha:trace, info # Set trace level for all alepha modules and info for all other modules
|
|
461
460
|
*/
|
|
462
|
-
LOG_LEVEL:
|
|
461
|
+
LOG_LEVEL: alepha2502.TOptional<alepha2502.TString>;
|
|
463
462
|
/**
|
|
464
463
|
* Built-in log formats.
|
|
465
464
|
* - "json" - JSON format, useful for structured logging and log aggregation. {@link JsonFormatterProvider}
|
|
466
465
|
* - "pretty" - Simple text format, human-readable, with colors. {@link PrettyFormatterProvider}
|
|
467
466
|
* - "raw" - Raw format, no formatting, just the message. {@link RawFormatterProvider}
|
|
468
467
|
*/
|
|
469
|
-
LOG_FORMAT:
|
|
468
|
+
LOG_FORMAT: alepha2502.TOptional<alepha2502.TUnsafe<"json" | "pretty" | "raw">>;
|
|
470
469
|
}>;
|
|
471
470
|
declare module "alepha" {
|
|
472
471
|
interface Env extends Partial<Static<typeof envSchema$10>> {}
|
|
@@ -484,7 +483,7 @@ declare module "alepha" {
|
|
|
484
483
|
}
|
|
485
484
|
}
|
|
486
485
|
//#endregion
|
|
487
|
-
//#region ../../../alepha/src/server/services/ServerRequestParser.d.ts
|
|
486
|
+
//#region ../../../alepha/src/server/core/services/ServerRequestParser.d.ts
|
|
488
487
|
declare class ServerRequestParser {
|
|
489
488
|
protected readonly alepha: Alepha;
|
|
490
489
|
protected readonly userAgentParser: UserAgentParser;
|
|
@@ -494,7 +493,7 @@ declare class ServerRequestParser {
|
|
|
494
493
|
getRequestIp(request: ServerRequestData): string | undefined;
|
|
495
494
|
}
|
|
496
495
|
//#endregion
|
|
497
|
-
//#region ../../../alepha/src/server/providers/ServerTimingProvider.d.ts
|
|
496
|
+
//#region ../../../alepha/src/server/core/providers/ServerTimingProvider.d.ts
|
|
498
497
|
type TimingMap = Record<string, [number, number]>;
|
|
499
498
|
declare class ServerTimingProvider {
|
|
500
499
|
protected readonly log: Logger;
|
|
@@ -503,15 +502,15 @@ declare class ServerTimingProvider {
|
|
|
503
502
|
prefix: string;
|
|
504
503
|
disabled: boolean;
|
|
505
504
|
};
|
|
506
|
-
readonly onRequest:
|
|
507
|
-
readonly onResponse:
|
|
505
|
+
readonly onRequest: alepha2502.HookPrimitive<"server:onRequest">;
|
|
506
|
+
readonly onResponse: alepha2502.HookPrimitive<"server:onResponse">;
|
|
508
507
|
protected get handlerName(): string;
|
|
509
508
|
beginTiming(name: string): void;
|
|
510
509
|
endTiming(name: string): void;
|
|
511
510
|
protected setDuration(name: string, timing: TimingMap): void;
|
|
512
511
|
}
|
|
513
512
|
//#endregion
|
|
514
|
-
//#region ../../../alepha/src/server/providers/ServerRouterProvider.d.ts
|
|
513
|
+
//#region ../../../alepha/src/server/core/providers/ServerRouterProvider.d.ts
|
|
515
514
|
/**
|
|
516
515
|
* Main router for all routes on the server side.
|
|
517
516
|
*
|
|
@@ -550,7 +549,7 @@ declare class ServerRouterProvider extends RouterProvider<ServerRouteMatcher> {
|
|
|
550
549
|
}, request: ServerRequestConfig): void;
|
|
551
550
|
}
|
|
552
551
|
//#endregion
|
|
553
|
-
//#region ../../../alepha/src/server/providers/ServerProvider.d.ts
|
|
552
|
+
//#region ../../../alepha/src/server/core/providers/ServerProvider.d.ts
|
|
554
553
|
/**
|
|
555
554
|
* Base server provider to handle incoming requests and route them.
|
|
556
555
|
*
|
|
@@ -568,11 +567,11 @@ declare class ServerProvider {
|
|
|
568
567
|
/**
|
|
569
568
|
* When a Node.js HTTP request is received from outside. (Vercel, AWS Lambda, etc.)
|
|
570
569
|
*/
|
|
571
|
-
protected readonly onNodeRequest:
|
|
570
|
+
protected readonly onNodeRequest: alepha2502.HookPrimitive<"node:request">;
|
|
572
571
|
/**
|
|
573
572
|
* When a Web (Fetch API) request is received from outside. (Netlify, Cloudflare Workers, etc.)
|
|
574
573
|
*/
|
|
575
|
-
protected readonly onWebRequest:
|
|
574
|
+
protected readonly onWebRequest: alepha2502.HookPrimitive<"web:request">;
|
|
576
575
|
/**
|
|
577
576
|
* Handle Node.js HTTP request event.
|
|
578
577
|
*
|
|
@@ -589,7 +588,7 @@ declare class ServerProvider {
|
|
|
589
588
|
protected isViteNotFound(url?: string, route?: Route, params?: Record<string, string>): boolean;
|
|
590
589
|
}
|
|
591
590
|
//#endregion
|
|
592
|
-
//#region ../../../alepha/src/cache/providers/CacheProvider.d.ts
|
|
591
|
+
//#region ../../../alepha/src/cache/core/providers/CacheProvider.d.ts
|
|
593
592
|
/**
|
|
594
593
|
* Cache provider interface.
|
|
595
594
|
*
|
|
@@ -632,7 +631,7 @@ declare abstract class CacheProvider {
|
|
|
632
631
|
abstract clear(): Promise<void>;
|
|
633
632
|
}
|
|
634
633
|
//#endregion
|
|
635
|
-
//#region ../../../alepha/src/cache/primitives/$cache.d.ts
|
|
634
|
+
//#region ../../../alepha/src/cache/core/primitives/$cache.d.ts
|
|
636
635
|
interface CachePrimitiveOptions<TReturn = any, TParameter extends any[] = any[]> {
|
|
637
636
|
/**
|
|
638
637
|
* The cache name. This is useful for invalidating multiple caches at once.
|
|
@@ -699,7 +698,7 @@ interface CachePrimitiveFn<TReturn = any, TParameter extends any[] = any[]> exte
|
|
|
699
698
|
(...args: TParameter): Promise<TReturn>;
|
|
700
699
|
}
|
|
701
700
|
//#endregion
|
|
702
|
-
//#region ../../../alepha/src/server/services/HttpClient.d.ts
|
|
701
|
+
//#region ../../../alepha/src/server/core/services/HttpClient.d.ts
|
|
703
702
|
declare class HttpClient {
|
|
704
703
|
protected readonly log: Logger;
|
|
705
704
|
protected readonly alepha: Alepha;
|
|
@@ -771,7 +770,7 @@ interface HttpAction {
|
|
|
771
770
|
};
|
|
772
771
|
}
|
|
773
772
|
//#endregion
|
|
774
|
-
//#region ../../../alepha/src/server/primitives/$action.d.ts
|
|
773
|
+
//#region ../../../alepha/src/server/core/primitives/$action.d.ts
|
|
775
774
|
interface ActionPrimitiveOptions<TConfig extends RequestConfigSchema> extends Omit<ServerRoute, "handler" | "path" | "schema" | "mapParams"> {
|
|
776
775
|
/**
|
|
777
776
|
* Name of the action.
|
|
@@ -909,33 +908,33 @@ type ServerActionHandler<TConfig extends RequestConfigSchema = RequestConfigSche
|
|
|
909
908
|
*/
|
|
910
909
|
interface ServerActionRequest<TConfig extends RequestConfigSchema> extends ServerRequest<TConfig> {}
|
|
911
910
|
//#endregion
|
|
912
|
-
//#region ../../../alepha/src/server/schemas/okSchema.d.ts
|
|
913
|
-
declare const okSchema:
|
|
914
|
-
ok:
|
|
915
|
-
id:
|
|
916
|
-
count:
|
|
911
|
+
//#region ../../../alepha/src/server/core/schemas/okSchema.d.ts
|
|
912
|
+
declare const okSchema: alepha2502.TObject<{
|
|
913
|
+
ok: alepha2502.TBoolean;
|
|
914
|
+
id: alepha2502.TOptional<alepha2502.TUnion<[alepha2502.TString, alepha2502.TInteger]>>;
|
|
915
|
+
count: alepha2502.TOptional<alepha2502.TNumber>;
|
|
917
916
|
}>;
|
|
918
917
|
type Ok = Static<typeof okSchema>;
|
|
919
918
|
//#endregion
|
|
920
|
-
//#region ../../../alepha/src/server/providers/BunHttpServerProvider.d.ts
|
|
921
|
-
declare const envSchema$9:
|
|
922
|
-
SERVER_PORT:
|
|
923
|
-
SERVER_HOST:
|
|
919
|
+
//#region ../../../alepha/src/server/core/providers/BunHttpServerProvider.d.ts
|
|
920
|
+
declare const envSchema$9: alepha2502.TObject<{
|
|
921
|
+
SERVER_PORT: alepha2502.TInteger;
|
|
922
|
+
SERVER_HOST: alepha2502.TString;
|
|
924
923
|
}>;
|
|
925
924
|
declare module "alepha" {
|
|
926
925
|
interface Env extends Partial<Static<typeof envSchema$9>> {}
|
|
927
926
|
}
|
|
928
927
|
//#endregion
|
|
929
|
-
//#region ../../../alepha/src/server/providers/NodeHttpServerProvider.d.ts
|
|
930
|
-
declare const envSchema$8:
|
|
931
|
-
SERVER_PORT:
|
|
932
|
-
SERVER_HOST:
|
|
928
|
+
//#region ../../../alepha/src/server/core/providers/NodeHttpServerProvider.d.ts
|
|
929
|
+
declare const envSchema$8: alepha2502.TObject<{
|
|
930
|
+
SERVER_PORT: alepha2502.TInteger;
|
|
931
|
+
SERVER_HOST: alepha2502.TString;
|
|
933
932
|
}>;
|
|
934
933
|
declare module "alepha" {
|
|
935
934
|
interface Env extends Partial<Static<typeof envSchema$8>> {}
|
|
936
935
|
}
|
|
937
936
|
//#endregion
|
|
938
|
-
//#region ../../../alepha/src/server/index.d.ts
|
|
937
|
+
//#region ../../../alepha/src/server/core/index.d.ts
|
|
939
938
|
declare module "alepha" {
|
|
940
939
|
interface State {
|
|
941
940
|
"alepha.node.server"?: Server;
|
|
@@ -1013,21 +1012,21 @@ interface UserAccountToken extends UserAccount {
|
|
|
1013
1012
|
}
|
|
1014
1013
|
//#endregion
|
|
1015
1014
|
//#region ../../../alepha/src/security/schemas/roleSchema.d.ts
|
|
1016
|
-
declare const roleSchema:
|
|
1017
|
-
name:
|
|
1018
|
-
description:
|
|
1019
|
-
default:
|
|
1020
|
-
permissions:
|
|
1021
|
-
name:
|
|
1022
|
-
ownership:
|
|
1023
|
-
exclude:
|
|
1015
|
+
declare const roleSchema: alepha2502.TObject<{
|
|
1016
|
+
name: alepha2502.TString;
|
|
1017
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
1018
|
+
default: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
1019
|
+
permissions: alepha2502.TArray<alepha2502.TObject<{
|
|
1020
|
+
name: alepha2502.TString;
|
|
1021
|
+
ownership: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
1022
|
+
exclude: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
1024
1023
|
}>>;
|
|
1025
1024
|
}>;
|
|
1026
1025
|
type Role = Static<typeof roleSchema>;
|
|
1027
1026
|
//#endregion
|
|
1028
1027
|
//#region ../../../alepha/src/security/providers/SecurityProvider.d.ts
|
|
1029
|
-
declare const envSchema$7:
|
|
1030
|
-
APP_SECRET:
|
|
1028
|
+
declare const envSchema$7: alepha2502.TObject<{
|
|
1029
|
+
APP_SECRET: alepha2502.TString;
|
|
1031
1030
|
}>;
|
|
1032
1031
|
declare module "alepha" {
|
|
1033
1032
|
interface Env extends Partial<Static<typeof envSchema$7>> {}
|
|
@@ -1127,19 +1126,19 @@ declare module "alepha" {
|
|
|
1127
1126
|
* @module alepha.security
|
|
1128
1127
|
*/
|
|
1129
1128
|
//#endregion
|
|
1130
|
-
//#region ../../../alepha/src/server
|
|
1129
|
+
//#region ../../../alepha/src/server/security/providers/ServerBasicAuthProvider.d.ts
|
|
1131
1130
|
interface BasicAuthOptions {
|
|
1132
1131
|
username: string;
|
|
1133
1132
|
password: string;
|
|
1134
1133
|
}
|
|
1135
1134
|
//#endregion
|
|
1136
|
-
//#region ../../../alepha/src/server
|
|
1135
|
+
//#region ../../../alepha/src/server/security/providers/ServerSecurityProvider.d.ts
|
|
1137
1136
|
type ServerRouteSecure = {
|
|
1138
1137
|
realm?: string;
|
|
1139
1138
|
basic?: BasicAuthOptions;
|
|
1140
1139
|
};
|
|
1141
1140
|
//#endregion
|
|
1142
|
-
//#region ../../../alepha/src/server
|
|
1141
|
+
//#region ../../../alepha/src/server/security/index.d.ts
|
|
1143
1142
|
declare module "alepha" {
|
|
1144
1143
|
interface State {
|
|
1145
1144
|
/**
|
|
@@ -1191,30 +1190,30 @@ declare module "alepha/server" {
|
|
|
1191
1190
|
* @module alepha.server.security
|
|
1192
1191
|
*/
|
|
1193
1192
|
//#endregion
|
|
1194
|
-
//#region ../../../alepha/src/server
|
|
1195
|
-
declare const apiLinkSchema:
|
|
1196
|
-
name:
|
|
1197
|
-
group:
|
|
1198
|
-
path:
|
|
1199
|
-
method:
|
|
1200
|
-
requestBodyType:
|
|
1201
|
-
service:
|
|
1193
|
+
//#region ../../../alepha/src/server/links/schemas/apiLinksResponseSchema.d.ts
|
|
1194
|
+
declare const apiLinkSchema: alepha2502.TObject<{
|
|
1195
|
+
name: alepha2502.TString;
|
|
1196
|
+
group: alepha2502.TOptional<alepha2502.TString>;
|
|
1197
|
+
path: alepha2502.TString;
|
|
1198
|
+
method: alepha2502.TOptional<alepha2502.TString>;
|
|
1199
|
+
requestBodyType: alepha2502.TOptional<alepha2502.TString>;
|
|
1200
|
+
service: alepha2502.TOptional<alepha2502.TString>;
|
|
1202
1201
|
}>;
|
|
1203
|
-
declare const apiLinksResponseSchema:
|
|
1204
|
-
prefix:
|
|
1205
|
-
links:
|
|
1206
|
-
name:
|
|
1207
|
-
group:
|
|
1208
|
-
path:
|
|
1209
|
-
method:
|
|
1210
|
-
requestBodyType:
|
|
1211
|
-
service:
|
|
1202
|
+
declare const apiLinksResponseSchema: alepha2502.TObject<{
|
|
1203
|
+
prefix: alepha2502.TOptional<alepha2502.TString>;
|
|
1204
|
+
links: alepha2502.TArray<alepha2502.TObject<{
|
|
1205
|
+
name: alepha2502.TString;
|
|
1206
|
+
group: alepha2502.TOptional<alepha2502.TString>;
|
|
1207
|
+
path: alepha2502.TString;
|
|
1208
|
+
method: alepha2502.TOptional<alepha2502.TString>;
|
|
1209
|
+
requestBodyType: alepha2502.TOptional<alepha2502.TString>;
|
|
1210
|
+
service: alepha2502.TOptional<alepha2502.TString>;
|
|
1212
1211
|
}>>;
|
|
1213
1212
|
}>;
|
|
1214
1213
|
type ApiLinksResponse = Static<typeof apiLinksResponseSchema>;
|
|
1215
1214
|
type ApiLink = Static<typeof apiLinkSchema>;
|
|
1216
1215
|
//#endregion
|
|
1217
|
-
//#region ../../../alepha/src/server
|
|
1216
|
+
//#region ../../../alepha/src/server/links/providers/LinkProvider.d.ts
|
|
1218
1217
|
/**
|
|
1219
1218
|
* Browser, SSR friendly, service to handle links.
|
|
1220
1219
|
*/
|
|
@@ -1410,7 +1409,7 @@ interface RetryPrimitiveOptions<T$1 extends (...args: any[]) => any> {
|
|
|
1410
1409
|
signal?: AbortSignal;
|
|
1411
1410
|
}
|
|
1412
1411
|
//#endregion
|
|
1413
|
-
//#region ../../../alepha/src/server
|
|
1412
|
+
//#region ../../../alepha/src/server/links/index.d.ts
|
|
1414
1413
|
declare module "alepha" {
|
|
1415
1414
|
interface State {
|
|
1416
1415
|
/**
|
|
@@ -1434,7 +1433,7 @@ declare module "alepha" {
|
|
|
1434
1433
|
* @module alepha.server.links
|
|
1435
1434
|
*/
|
|
1436
1435
|
//#endregion
|
|
1437
|
-
//#region ../../../alepha/src/server
|
|
1436
|
+
//#region ../../../alepha/src/server/cache/providers/ServerCacheProvider.d.ts
|
|
1438
1437
|
declare module "alepha/server" {
|
|
1439
1438
|
interface ServerRoute {
|
|
1440
1439
|
/**
|
|
@@ -1549,8 +1548,8 @@ declare class Redirection extends Error {
|
|
|
1549
1548
|
}
|
|
1550
1549
|
//#endregion
|
|
1551
1550
|
//#region ../../../react/src/core/providers/ReactPageProvider.d.ts
|
|
1552
|
-
declare const envSchema$6:
|
|
1553
|
-
REACT_STRICT_MODE:
|
|
1551
|
+
declare const envSchema$6: alepha2502.TObject<{
|
|
1552
|
+
REACT_STRICT_MODE: alepha2502.TBoolean;
|
|
1554
1553
|
}>;
|
|
1555
1554
|
declare module "alepha" {
|
|
1556
1555
|
interface Env extends Partial<Static<typeof envSchema$6>> {}
|
|
@@ -1592,7 +1591,7 @@ declare class ReactPageProvider {
|
|
|
1592
1591
|
}, params?: Record<string, any>): string;
|
|
1593
1592
|
compile(path: string, params?: Record<string, string>): string;
|
|
1594
1593
|
protected renderView(index: number, path: string, view: ReactNode | undefined, page: PageRoute): ReactNode;
|
|
1595
|
-
protected readonly configure:
|
|
1594
|
+
protected readonly configure: alepha2502.HookPrimitive<"configure">;
|
|
1596
1595
|
protected map(pages: Array<PagePrimitive>, target: PagePrimitive): PageRouteEntry;
|
|
1597
1596
|
add(entry: PageRouteEntry): void;
|
|
1598
1597
|
protected createMatch(page: PageRoute): string;
|
|
@@ -1931,14 +1930,14 @@ declare class ReactBrowserRouterProvider extends RouterProvider<BrowserRoute> {
|
|
|
1931
1930
|
protected readonly alepha: Alepha;
|
|
1932
1931
|
protected readonly pageApi: ReactPageProvider;
|
|
1933
1932
|
add(entry: PageRouteEntry): void;
|
|
1934
|
-
protected readonly configure:
|
|
1933
|
+
protected readonly configure: alepha2502.HookPrimitive<"configure">;
|
|
1935
1934
|
transition(url: URL, previous?: PreviousLayerData[], meta?: {}): Promise<string | void>;
|
|
1936
1935
|
root(state: ReactRouterState): ReactNode;
|
|
1937
1936
|
}
|
|
1938
1937
|
//#endregion
|
|
1939
1938
|
//#region ../../../react/src/core/providers/ReactBrowserProvider.d.ts
|
|
1940
|
-
declare const envSchema$5:
|
|
1941
|
-
REACT_ROOT_ID:
|
|
1939
|
+
declare const envSchema$5: alepha2502.TObject<{
|
|
1940
|
+
REACT_ROOT_ID: alepha2502.TString;
|
|
1942
1941
|
}>;
|
|
1943
1942
|
declare module "alepha" {
|
|
1944
1943
|
interface Env extends Partial<Static<typeof envSchema$5>> {}
|
|
@@ -1946,8 +1945,8 @@ declare module "alepha" {
|
|
|
1946
1945
|
/**
|
|
1947
1946
|
* React browser renderer configuration atom
|
|
1948
1947
|
*/
|
|
1949
|
-
declare const reactBrowserOptions:
|
|
1950
|
-
scrollRestoration:
|
|
1948
|
+
declare const reactBrowserOptions: alepha2502.Atom<alepha2502.TObject<{
|
|
1949
|
+
scrollRestoration: alepha2502.TUnsafe<"top" | "manual">;
|
|
1951
1950
|
}>, "alepha.react.browser.options">;
|
|
1952
1951
|
type ReactBrowserRendererOptions = Static<typeof reactBrowserOptions.schema>;
|
|
1953
1952
|
declare module "alepha" {
|
|
@@ -1995,8 +1994,8 @@ declare class ReactBrowserProvider {
|
|
|
1995
1994
|
* Get embedded layers from the server.
|
|
1996
1995
|
*/
|
|
1997
1996
|
protected getHydrationState(): ReactHydrationState | undefined;
|
|
1998
|
-
protected readonly onTransitionEnd:
|
|
1999
|
-
readonly ready:
|
|
1997
|
+
protected readonly onTransitionEnd: alepha2502.HookPrimitive<"react:transition:end">;
|
|
1998
|
+
readonly ready: alepha2502.HookPrimitive<"ready">;
|
|
2000
1999
|
}
|
|
2001
2000
|
interface RouterGoOptions {
|
|
2002
2001
|
replace?: boolean;
|
|
@@ -2108,9 +2107,9 @@ declare class ReactRouter<T$1 extends object> {
|
|
|
2108
2107
|
schema?: PageConfigSchema | undefined;
|
|
2109
2108
|
resolve?: ((context: PageResolve<PageConfigSchema, TPropsParentDefault>) => any) | undefined;
|
|
2110
2109
|
props?: (() => Partial<any>) | undefined;
|
|
2111
|
-
component?:
|
|
2110
|
+
component?: react3.FC<any> | undefined;
|
|
2112
2111
|
lazy?: (() => Promise<{
|
|
2113
|
-
default:
|
|
2112
|
+
default: react3.FC<any>;
|
|
2114
2113
|
}>) | undefined;
|
|
2115
2114
|
can?: (() => boolean) | undefined;
|
|
2116
2115
|
errorHandler?: ErrorHandler | undefined;
|
|
@@ -2123,7 +2122,7 @@ declare class ReactRouter<T$1 extends object> {
|
|
|
2123
2122
|
onLeave?: (() => void) | undefined;
|
|
2124
2123
|
animation?: PageAnimation | undefined;
|
|
2125
2124
|
head?: Head | ((props: any, previous?: Head) => Head) | undefined;
|
|
2126
|
-
icon?:
|
|
2125
|
+
icon?: react3.ReactNode | react3.ComponentType;
|
|
2127
2126
|
};
|
|
2128
2127
|
path(name: keyof VirtualRouter<T$1> | string, config?: {
|
|
2129
2128
|
params?: Record<string, any>;
|
|
@@ -2559,9 +2558,9 @@ declare class FileDetector {
|
|
|
2559
2558
|
}
|
|
2560
2559
|
//#endregion
|
|
2561
2560
|
//#region ../../../react/src/core/providers/ReactServerProvider.d.ts
|
|
2562
|
-
declare const envSchema$4:
|
|
2563
|
-
REACT_SSR_ENABLED:
|
|
2564
|
-
REACT_ROOT_ID:
|
|
2561
|
+
declare const envSchema$4: alepha2502.TObject<{
|
|
2562
|
+
REACT_SSR_ENABLED: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
2563
|
+
REACT_ROOT_ID: alepha2502.TString;
|
|
2565
2564
|
}>;
|
|
2566
2565
|
declare module "alepha" {
|
|
2567
2566
|
interface Env extends Partial<Static<typeof envSchema$4>> {}
|
|
@@ -2573,11 +2572,11 @@ declare module "alepha" {
|
|
|
2573
2572
|
/**
|
|
2574
2573
|
* React server provider configuration atom
|
|
2575
2574
|
*/
|
|
2576
|
-
declare const reactServerOptions:
|
|
2577
|
-
publicDir:
|
|
2578
|
-
staticServer:
|
|
2579
|
-
disabled:
|
|
2580
|
-
path:
|
|
2575
|
+
declare const reactServerOptions: alepha2502.Atom<alepha2502.TObject<{
|
|
2576
|
+
publicDir: alepha2502.TString;
|
|
2577
|
+
staticServer: alepha2502.TObject<{
|
|
2578
|
+
disabled: alepha2502.TBoolean;
|
|
2579
|
+
path: alepha2502.TString;
|
|
2581
2580
|
}>;
|
|
2582
2581
|
}>, "alepha.react.server.options">;
|
|
2583
2582
|
type ReactServerProviderOptions = Static<typeof reactServerOptions.schema>;
|
|
@@ -2690,21 +2689,21 @@ declare module "alepha" {
|
|
|
2690
2689
|
* @module alepha.react
|
|
2691
2690
|
*/
|
|
2692
2691
|
//#endregion
|
|
2693
|
-
//#region ../../../alepha/src/server
|
|
2694
|
-
declare const tokensSchema:
|
|
2695
|
-
provider:
|
|
2696
|
-
access_token:
|
|
2697
|
-
issued_at:
|
|
2698
|
-
expires_in:
|
|
2699
|
-
refresh_token:
|
|
2700
|
-
refresh_token_expires_in:
|
|
2701
|
-
refresh_expires_in:
|
|
2702
|
-
id_token:
|
|
2703
|
-
scope:
|
|
2692
|
+
//#region ../../../alepha/src/server/auth/schemas/tokensSchema.d.ts
|
|
2693
|
+
declare const tokensSchema: alepha2502.TObject<{
|
|
2694
|
+
provider: alepha2502.TString;
|
|
2695
|
+
access_token: alepha2502.TString;
|
|
2696
|
+
issued_at: alepha2502.TNumber;
|
|
2697
|
+
expires_in: alepha2502.TOptional<alepha2502.TNumber>;
|
|
2698
|
+
refresh_token: alepha2502.TOptional<alepha2502.TString>;
|
|
2699
|
+
refresh_token_expires_in: alepha2502.TOptional<alepha2502.TNumber>;
|
|
2700
|
+
refresh_expires_in: alepha2502.TOptional<alepha2502.TNumber>;
|
|
2701
|
+
id_token: alepha2502.TOptional<alepha2502.TString>;
|
|
2702
|
+
scope: alepha2502.TOptional<alepha2502.TString>;
|
|
2704
2703
|
}>;
|
|
2705
2704
|
type Tokens = Static<typeof tokensSchema>;
|
|
2706
2705
|
//#endregion
|
|
2707
|
-
//#region ../../../alepha/src/server
|
|
2706
|
+
//#region ../../../alepha/src/server/cookies/primitives/$cookie.d.ts
|
|
2708
2707
|
interface Cookies {
|
|
2709
2708
|
req: Record<string, string>;
|
|
2710
2709
|
res: Record<string, Cookie | null>;
|
|
@@ -2719,7 +2718,7 @@ interface Cookie {
|
|
|
2719
2718
|
domain?: string;
|
|
2720
2719
|
}
|
|
2721
2720
|
//#endregion
|
|
2722
|
-
//#region ../../../alepha/src/server
|
|
2721
|
+
//#region ../../../alepha/src/server/cookies/index.d.ts
|
|
2723
2722
|
declare module "alepha/server" {
|
|
2724
2723
|
interface ServerRequest {
|
|
2725
2724
|
cookies: Cookies;
|
|
@@ -2736,7 +2735,7 @@ declare module "alepha/server" {
|
|
|
2736
2735
|
* @module alepha.server.cookies
|
|
2737
2736
|
*/
|
|
2738
2737
|
//#endregion
|
|
2739
|
-
//#region ../../../alepha/src/server
|
|
2738
|
+
//#region ../../../alepha/src/server/auth/index.d.ts
|
|
2740
2739
|
declare module "alepha" {
|
|
2741
2740
|
interface State {
|
|
2742
2741
|
/**
|
|
@@ -2770,8 +2769,8 @@ declare class ReactAuth {
|
|
|
2770
2769
|
protected readonly alepha: Alepha;
|
|
2771
2770
|
protected readonly httpClient: HttpClient;
|
|
2772
2771
|
protected readonly linkProvider: LinkProvider;
|
|
2773
|
-
protected readonly onBeginTransition:
|
|
2774
|
-
protected readonly onFetchRequest:
|
|
2772
|
+
protected readonly onBeginTransition: alepha2502.HookPrimitive<"react:transition:begin">;
|
|
2773
|
+
protected readonly onFetchRequest: alepha2502.HookPrimitive<"client:onRequest">;
|
|
2775
2774
|
/**
|
|
2776
2775
|
* Get the current authenticated user.
|
|
2777
2776
|
*
|
|
@@ -3704,11 +3703,11 @@ declare class DrizzleKitProvider {
|
|
|
3704
3703
|
*/
|
|
3705
3704
|
importDrizzleKit(): typeof DrizzleKit;
|
|
3706
3705
|
}
|
|
3707
|
-
declare const devMigrationsSchema:
|
|
3708
|
-
id:
|
|
3709
|
-
name:
|
|
3710
|
-
snapshot:
|
|
3711
|
-
created_at:
|
|
3706
|
+
declare const devMigrationsSchema: alepha2502.TObject<{
|
|
3707
|
+
id: alepha2502.TNumber;
|
|
3708
|
+
name: alepha2502.TString;
|
|
3709
|
+
snapshot: alepha2502.TString;
|
|
3710
|
+
created_at: alepha2502.TString;
|
|
3712
3711
|
}>;
|
|
3713
3712
|
type DevMigrations = Static<typeof devMigrationsSchema>;
|
|
3714
3713
|
//#endregion
|
|
@@ -3905,7 +3904,7 @@ declare class QueryManager {
|
|
|
3905
3904
|
createPagination<T$1>(entities: T$1[], limit?: number, offset?: number, sort?: Array<{
|
|
3906
3905
|
column: string;
|
|
3907
3906
|
direction: "asc" | "desc";
|
|
3908
|
-
}>):
|
|
3907
|
+
}>): alepha2502.Page<T$1>;
|
|
3909
3908
|
}
|
|
3910
3909
|
interface PgJoin {
|
|
3911
3910
|
table: string;
|
|
@@ -4213,7 +4212,7 @@ interface StatementOptions {
|
|
|
4213
4212
|
now?: DateTime | string;
|
|
4214
4213
|
}
|
|
4215
4214
|
//#endregion
|
|
4216
|
-
//#region ../../../alepha/src/topic/providers/TopicProvider.d.ts
|
|
4215
|
+
//#region ../../../alepha/src/topic/core/providers/TopicProvider.d.ts
|
|
4217
4216
|
/**
|
|
4218
4217
|
* Base class for topic providers.
|
|
4219
4218
|
*/
|
|
@@ -4247,7 +4246,7 @@ declare abstract class TopicProvider {
|
|
|
4247
4246
|
type SubscribeCallback = (message: string) => Promise<void> | void;
|
|
4248
4247
|
type UnSubscribeFn = () => Promise<void>;
|
|
4249
4248
|
//#endregion
|
|
4250
|
-
//#region ../../../alepha/src/topic/primitives/$topic.d.ts
|
|
4249
|
+
//#region ../../../alepha/src/topic/core/primitives/$topic.d.ts
|
|
4251
4250
|
interface TopicPrimitiveOptions<T$1 extends TopicMessageSchema> {
|
|
4252
4251
|
/**
|
|
4253
4252
|
* Unique name identifier for the topic.
|
|
@@ -4448,9 +4447,9 @@ interface TopicMessageSchema {
|
|
|
4448
4447
|
}
|
|
4449
4448
|
type TopicHandler<T$1 extends TopicMessageSchema = TopicMessageSchema> = (message: TopicMessage<T$1>) => unknown;
|
|
4450
4449
|
//#endregion
|
|
4451
|
-
//#region ../../../alepha/src/lock/primitives/$lock.d.ts
|
|
4452
|
-
declare const envSchema$3:
|
|
4453
|
-
LOCK_PREFIX_KEY:
|
|
4450
|
+
//#region ../../../alepha/src/lock/core/primitives/$lock.d.ts
|
|
4451
|
+
declare const envSchema$3: alepha2502.TObject<{
|
|
4452
|
+
LOCK_PREFIX_KEY: alepha2502.TString;
|
|
4454
4453
|
}>;
|
|
4455
4454
|
declare module "alepha" {
|
|
4456
4455
|
interface Env extends Partial<Static<typeof envSchema$3>> {}
|
|
@@ -4460,7 +4459,7 @@ declare module "alepha" {
|
|
|
4460
4459
|
declare module "alepha" {
|
|
4461
4460
|
interface Env extends Partial<Static<typeof envSchema$2>> {}
|
|
4462
4461
|
}
|
|
4463
|
-
declare const envSchema$2:
|
|
4462
|
+
declare const envSchema$2: alepha2502.TObject<{
|
|
4464
4463
|
/**
|
|
4465
4464
|
* Main configuration for database connection.
|
|
4466
4465
|
* Accept a string in the format of a Postgres connection URL.
|
|
@@ -4468,21 +4467,21 @@ declare const envSchema$2: alepha1962.TObject<{
|
|
|
4468
4467
|
* or
|
|
4469
4468
|
* Example: postgres://user:password@localhost:5432/database?sslmode=require
|
|
4470
4469
|
*/
|
|
4471
|
-
DATABASE_URL:
|
|
4470
|
+
DATABASE_URL: alepha2502.TOptional<alepha2502.TString>;
|
|
4472
4471
|
/**
|
|
4473
4472
|
* In addition to the DATABASE_URL, you can specify the postgres schema name.
|
|
4474
4473
|
*
|
|
4475
4474
|
* It will monkey patch drizzle tables.
|
|
4476
4475
|
*/
|
|
4477
|
-
POSTGRES_SCHEMA:
|
|
4476
|
+
POSTGRES_SCHEMA: alepha2502.TOptional<alepha2502.TString>;
|
|
4478
4477
|
}>;
|
|
4479
4478
|
//#endregion
|
|
4480
4479
|
//#region ../../../alepha/src/orm/providers/drivers/NodeSqliteProvider.d.ts
|
|
4481
4480
|
/**
|
|
4482
4481
|
* Configuration options for the Node.js SQLite database provider.
|
|
4483
4482
|
*/
|
|
4484
|
-
declare const nodeSqliteOptions:
|
|
4485
|
-
path:
|
|
4483
|
+
declare const nodeSqliteOptions: alepha2502.Atom<alepha2502.TObject<{
|
|
4484
|
+
path: alepha2502.TOptional<alepha2502.TString>;
|
|
4486
4485
|
}>, "alepha.postgres.node-sqlite.options">;
|
|
4487
4486
|
type NodeSqliteProviderOptions = Static<typeof nodeSqliteOptions.schema>;
|
|
4488
4487
|
declare module "alepha" {
|
|
@@ -4565,6 +4564,539 @@ declare module "alepha" {
|
|
|
4565
4564
|
}
|
|
4566
4565
|
}
|
|
4567
4566
|
//#endregion
|
|
4567
|
+
//#region ../../../alepha/src/api/audits/entities/audits.d.ts
|
|
4568
|
+
/**
|
|
4569
|
+
* Audit severity levels for categorizing events.
|
|
4570
|
+
*/
|
|
4571
|
+
declare const auditSeveritySchema: alepha2502.TUnsafe<"info" | "warning" | "critical">;
|
|
4572
|
+
type AuditSeverity = Static<typeof auditSeveritySchema>;
|
|
4573
|
+
/**
|
|
4574
|
+
* Audit log entity for tracking important system events.
|
|
4575
|
+
*
|
|
4576
|
+
* Stores comprehensive audit information including:
|
|
4577
|
+
* - Who performed the action (userId, userRealm)
|
|
4578
|
+
* - What happened (type, action, resource)
|
|
4579
|
+
* - When it happened (createdAt)
|
|
4580
|
+
* - Context and details (metadata, ipAddress, userAgent)
|
|
4581
|
+
*/
|
|
4582
|
+
declare const audits: EntityPrimitive<alepha2502.TObject<{
|
|
4583
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
4584
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
4585
|
+
/**
|
|
4586
|
+
* Audit event type (e.g., "auth", "user", "payment", "system").
|
|
4587
|
+
* Used for categorizing and filtering audit events.
|
|
4588
|
+
*/
|
|
4589
|
+
type: alepha2502.TString;
|
|
4590
|
+
/**
|
|
4591
|
+
* Specific action performed (e.g., "login", "logout", "create", "update", "delete").
|
|
4592
|
+
*/
|
|
4593
|
+
action: alepha2502.TString;
|
|
4594
|
+
/**
|
|
4595
|
+
* Severity level of the event.
|
|
4596
|
+
*/
|
|
4597
|
+
severity: PgAttr<alepha2502.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
|
|
4598
|
+
/**
|
|
4599
|
+
* User ID who performed the action (null for system events).
|
|
4600
|
+
*/
|
|
4601
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
4602
|
+
/**
|
|
4603
|
+
* User realm for multi-tenant support.
|
|
4604
|
+
*/
|
|
4605
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
4606
|
+
/**
|
|
4607
|
+
* User email at the time of the event (denormalized for history).
|
|
4608
|
+
*/
|
|
4609
|
+
userEmail: alepha2502.TOptional<alepha2502.TString>;
|
|
4610
|
+
/**
|
|
4611
|
+
* Resource type affected (e.g., "user", "order", "file").
|
|
4612
|
+
*/
|
|
4613
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
4614
|
+
/**
|
|
4615
|
+
* Resource ID affected.
|
|
4616
|
+
*/
|
|
4617
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
4618
|
+
/**
|
|
4619
|
+
* Human-readable description of the event.
|
|
4620
|
+
*/
|
|
4621
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
4622
|
+
/**
|
|
4623
|
+
* Additional metadata/context as JSON.
|
|
4624
|
+
*/
|
|
4625
|
+
metadata: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
4626
|
+
/**
|
|
4627
|
+
* Client IP address.
|
|
4628
|
+
*/
|
|
4629
|
+
ipAddress: alepha2502.TOptional<alepha2502.TString>;
|
|
4630
|
+
/**
|
|
4631
|
+
* Client user agent.
|
|
4632
|
+
*/
|
|
4633
|
+
userAgent: alepha2502.TOptional<alepha2502.TString>;
|
|
4634
|
+
/**
|
|
4635
|
+
* Session ID if applicable.
|
|
4636
|
+
*/
|
|
4637
|
+
sessionId: alepha2502.TOptional<alepha2502.TString>;
|
|
4638
|
+
/**
|
|
4639
|
+
* Request ID for correlation.
|
|
4640
|
+
*/
|
|
4641
|
+
requestId: alepha2502.TOptional<alepha2502.TString>;
|
|
4642
|
+
/**
|
|
4643
|
+
* Whether the action was successful.
|
|
4644
|
+
*/
|
|
4645
|
+
success: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
4646
|
+
/**
|
|
4647
|
+
* Error message if the action failed.
|
|
4648
|
+
*/
|
|
4649
|
+
errorMessage: alepha2502.TOptional<alepha2502.TString>;
|
|
4650
|
+
}>>;
|
|
4651
|
+
type AuditEntity = Static<typeof audits.schema>;
|
|
4652
|
+
//#endregion
|
|
4653
|
+
//#region ../../../alepha/src/api/audits/schemas/auditQuerySchema.d.ts
|
|
4654
|
+
/**
|
|
4655
|
+
* Query schema for searching and filtering audit logs.
|
|
4656
|
+
*/
|
|
4657
|
+
declare const auditQuerySchema: alepha2502.TObject<{
|
|
4658
|
+
page: alepha2502.TOptional<alepha2502.TInteger>;
|
|
4659
|
+
size: alepha2502.TOptional<alepha2502.TInteger>;
|
|
4660
|
+
sort: alepha2502.TOptional<alepha2502.TString>;
|
|
4661
|
+
type: alepha2502.TOptional<alepha2502.TString>;
|
|
4662
|
+
action: alepha2502.TOptional<alepha2502.TString>;
|
|
4663
|
+
severity: alepha2502.TOptional<alepha2502.TUnsafe<"info" | "warning" | "critical">>;
|
|
4664
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
4665
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
4666
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
4667
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
4668
|
+
success: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
4669
|
+
from: alepha2502.TOptional<alepha2502.TString>;
|
|
4670
|
+
to: alepha2502.TOptional<alepha2502.TString>;
|
|
4671
|
+
search: alepha2502.TOptional<alepha2502.TString>;
|
|
4672
|
+
}>;
|
|
4673
|
+
type AuditQuery = Static<typeof auditQuerySchema>;
|
|
4674
|
+
//#endregion
|
|
4675
|
+
//#region ../../../alepha/src/api/audits/schemas/createAuditSchema.d.ts
|
|
4676
|
+
/**
|
|
4677
|
+
* Schema for creating a new audit log entry.
|
|
4678
|
+
*/
|
|
4679
|
+
declare const createAuditSchema: alepha2502.TObject<{
|
|
4680
|
+
type: alepha2502.TString;
|
|
4681
|
+
action: alepha2502.TString;
|
|
4682
|
+
severity: alepha2502.TOptional<alepha2502.TUnsafe<"info" | "warning" | "critical">>;
|
|
4683
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
4684
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
4685
|
+
userEmail: alepha2502.TOptional<alepha2502.TString>;
|
|
4686
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
4687
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
4688
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
4689
|
+
metadata: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
4690
|
+
ipAddress: alepha2502.TOptional<alepha2502.TString>;
|
|
4691
|
+
userAgent: alepha2502.TOptional<alepha2502.TString>;
|
|
4692
|
+
sessionId: alepha2502.TOptional<alepha2502.TString>;
|
|
4693
|
+
requestId: alepha2502.TOptional<alepha2502.TString>;
|
|
4694
|
+
success: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
4695
|
+
errorMessage: alepha2502.TOptional<alepha2502.TString>;
|
|
4696
|
+
}>;
|
|
4697
|
+
type CreateAudit = Static<typeof createAuditSchema>;
|
|
4698
|
+
//#endregion
|
|
4699
|
+
//#region ../../../alepha/src/api/audits/services/AuditService.d.ts
|
|
4700
|
+
/**
|
|
4701
|
+
* Registered audit type definition.
|
|
4702
|
+
*/
|
|
4703
|
+
interface AuditTypeDefinition {
|
|
4704
|
+
type: string;
|
|
4705
|
+
description?: string;
|
|
4706
|
+
actions: string[];
|
|
4707
|
+
}
|
|
4708
|
+
/**
|
|
4709
|
+
* Service for managing audit logs.
|
|
4710
|
+
*
|
|
4711
|
+
* Provides methods for:
|
|
4712
|
+
* - Creating audit entries
|
|
4713
|
+
* - Querying audit history
|
|
4714
|
+
* - Aggregating audit statistics
|
|
4715
|
+
* - Managing registered audit types
|
|
4716
|
+
*/
|
|
4717
|
+
declare class AuditService {
|
|
4718
|
+
protected readonly alepha: Alepha;
|
|
4719
|
+
protected readonly log: Logger;
|
|
4720
|
+
protected readonly repo: Repository<alepha2502.TObject<{
|
|
4721
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
4722
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
4723
|
+
type: alepha2502.TString;
|
|
4724
|
+
action: alepha2502.TString;
|
|
4725
|
+
severity: PgAttr<alepha2502.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
|
|
4726
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
4727
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
4728
|
+
userEmail: alepha2502.TOptional<alepha2502.TString>;
|
|
4729
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
4730
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
4731
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
4732
|
+
metadata: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
4733
|
+
ipAddress: alepha2502.TOptional<alepha2502.TString>;
|
|
4734
|
+
userAgent: alepha2502.TOptional<alepha2502.TString>;
|
|
4735
|
+
sessionId: alepha2502.TOptional<alepha2502.TString>;
|
|
4736
|
+
requestId: alepha2502.TOptional<alepha2502.TString>;
|
|
4737
|
+
success: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
4738
|
+
errorMessage: alepha2502.TOptional<alepha2502.TString>;
|
|
4739
|
+
}>>;
|
|
4740
|
+
/**
|
|
4741
|
+
* Registry of audit types and their allowed actions.
|
|
4742
|
+
*/
|
|
4743
|
+
protected readonly auditTypes: Map<string, AuditTypeDefinition>;
|
|
4744
|
+
/**
|
|
4745
|
+
* Register an audit type with its allowed actions.
|
|
4746
|
+
*/
|
|
4747
|
+
registerType(definition: AuditTypeDefinition): void;
|
|
4748
|
+
/**
|
|
4749
|
+
* Get all registered audit types.
|
|
4750
|
+
*/
|
|
4751
|
+
getRegisteredTypes(): AuditTypeDefinition[];
|
|
4752
|
+
/**
|
|
4753
|
+
* Get current request context if available.
|
|
4754
|
+
*/
|
|
4755
|
+
protected getRequestContext(): ServerRequest | undefined;
|
|
4756
|
+
/**
|
|
4757
|
+
* Create a new audit log entry.
|
|
4758
|
+
* Automatically populates ipAddress, userAgent, and requestId from the current request context.
|
|
4759
|
+
*/
|
|
4760
|
+
create(data: CreateAudit): Promise<AuditEntity>;
|
|
4761
|
+
/**
|
|
4762
|
+
* Record an audit event (convenience method).
|
|
4763
|
+
*/
|
|
4764
|
+
record(type: string, action: string, options?: Omit<CreateAudit, "type" | "action">): Promise<AuditEntity>;
|
|
4765
|
+
/**
|
|
4766
|
+
* Record an authentication event.
|
|
4767
|
+
*/
|
|
4768
|
+
recordAuth(action: "login" | "logout" | "login_failed" | "token_refresh" | "mfa_setup" | "mfa_verify", options?: Omit<CreateAudit, "type" | "action">): Promise<AuditEntity>;
|
|
4769
|
+
/**
|
|
4770
|
+
* Record a user management event.
|
|
4771
|
+
*/
|
|
4772
|
+
recordUser(action: "create" | "update" | "delete" | "enable" | "disable" | "role_change", options?: Omit<CreateAudit, "type" | "action">): Promise<AuditEntity>;
|
|
4773
|
+
/**
|
|
4774
|
+
* Record a data access event.
|
|
4775
|
+
*/
|
|
4776
|
+
recordAccess(action: "view" | "export" | "download", options?: Omit<CreateAudit, "type" | "action">): Promise<AuditEntity>;
|
|
4777
|
+
/**
|
|
4778
|
+
* Record a security event.
|
|
4779
|
+
*/
|
|
4780
|
+
recordSecurity(action: "permission_denied" | "suspicious_activity" | "rate_limited" | "blocked", options?: Omit<CreateAudit, "type" | "action">): Promise<AuditEntity>;
|
|
4781
|
+
/**
|
|
4782
|
+
* Record a system event.
|
|
4783
|
+
*/
|
|
4784
|
+
recordSystem(action: "startup" | "shutdown" | "config_change" | "maintenance" | "error", options?: Omit<CreateAudit, "type" | "action">): Promise<AuditEntity>;
|
|
4785
|
+
/**
|
|
4786
|
+
* Find audit entries with filtering and pagination.
|
|
4787
|
+
*/
|
|
4788
|
+
find(query?: AuditQuery): Promise<Page$1<AuditEntity>>;
|
|
4789
|
+
/**
|
|
4790
|
+
* Get audit entry by ID.
|
|
4791
|
+
*/
|
|
4792
|
+
getById(id: string): Promise<AuditEntity>;
|
|
4793
|
+
/**
|
|
4794
|
+
* Get audit entries for a specific user.
|
|
4795
|
+
*/
|
|
4796
|
+
findByUser(userId: string, query?: Omit<AuditQuery, "userId">): Promise<Page$1<AuditEntity>>;
|
|
4797
|
+
/**
|
|
4798
|
+
* Get audit entries for a specific resource.
|
|
4799
|
+
*/
|
|
4800
|
+
findByResource(resourceType: string, resourceId: string, query?: Omit<AuditQuery, "resourceType" | "resourceId">): Promise<Page$1<AuditEntity>>;
|
|
4801
|
+
/**
|
|
4802
|
+
* Get audit statistics for a time period.
|
|
4803
|
+
*/
|
|
4804
|
+
getStats(options?: {
|
|
4805
|
+
from?: Date;
|
|
4806
|
+
to?: Date;
|
|
4807
|
+
userRealm?: string;
|
|
4808
|
+
}): Promise<AuditStats>;
|
|
4809
|
+
/**
|
|
4810
|
+
* Delete old audit entries (for retention policy).
|
|
4811
|
+
*/
|
|
4812
|
+
deleteOlderThan(date: Date): Promise<number>;
|
|
4813
|
+
}
|
|
4814
|
+
/**
|
|
4815
|
+
* Audit statistics summary.
|
|
4816
|
+
*/
|
|
4817
|
+
interface AuditStats {
|
|
4818
|
+
total: number;
|
|
4819
|
+
byType: Record<string, number>;
|
|
4820
|
+
bySeverity: Record<AuditSeverity, number>;
|
|
4821
|
+
successRate: number;
|
|
4822
|
+
recentFailures: AuditEntity[];
|
|
4823
|
+
}
|
|
4824
|
+
//#endregion
|
|
4825
|
+
//#region ../../../alepha/src/api/audits/controllers/AuditController.d.ts
|
|
4826
|
+
/**
|
|
4827
|
+
* REST API controller for audit log management.
|
|
4828
|
+
*
|
|
4829
|
+
* Provides endpoints for:
|
|
4830
|
+
* - Querying audit logs with filtering
|
|
4831
|
+
* - Creating audit entries
|
|
4832
|
+
* - Getting audit statistics
|
|
4833
|
+
* - Viewing registered audit types
|
|
4834
|
+
*/
|
|
4835
|
+
declare class AuditController {
|
|
4836
|
+
protected readonly url = "/audits";
|
|
4837
|
+
protected readonly group = "audits";
|
|
4838
|
+
protected readonly auditService: AuditService;
|
|
4839
|
+
/**
|
|
4840
|
+
* Find audit entries with filtering and pagination.
|
|
4841
|
+
*/
|
|
4842
|
+
readonly findAudits: ActionPrimitiveFn<{
|
|
4843
|
+
query: alepha2502.TObject<{
|
|
4844
|
+
page: alepha2502.TOptional<alepha2502.TInteger>;
|
|
4845
|
+
size: alepha2502.TOptional<alepha2502.TInteger>;
|
|
4846
|
+
sort: alepha2502.TOptional<alepha2502.TString>;
|
|
4847
|
+
type: alepha2502.TOptional<alepha2502.TString>;
|
|
4848
|
+
action: alepha2502.TOptional<alepha2502.TString>;
|
|
4849
|
+
severity: alepha2502.TOptional<alepha2502.TUnsafe<"info" | "warning" | "critical">>;
|
|
4850
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
4851
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
4852
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
4853
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
4854
|
+
success: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
4855
|
+
from: alepha2502.TOptional<alepha2502.TString>;
|
|
4856
|
+
to: alepha2502.TOptional<alepha2502.TString>;
|
|
4857
|
+
search: alepha2502.TOptional<alepha2502.TString>;
|
|
4858
|
+
}>;
|
|
4859
|
+
response: alepha2502.TPage<alepha2502.TObject<{
|
|
4860
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
4861
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
4862
|
+
type: alepha2502.TString;
|
|
4863
|
+
action: alepha2502.TString;
|
|
4864
|
+
severity: PgAttr<alepha2502.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
|
|
4865
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
4866
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
4867
|
+
userEmail: alepha2502.TOptional<alepha2502.TString>;
|
|
4868
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
4869
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
4870
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
4871
|
+
metadata: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
4872
|
+
ipAddress: alepha2502.TOptional<alepha2502.TString>;
|
|
4873
|
+
userAgent: alepha2502.TOptional<alepha2502.TString>;
|
|
4874
|
+
sessionId: alepha2502.TOptional<alepha2502.TString>;
|
|
4875
|
+
requestId: alepha2502.TOptional<alepha2502.TString>;
|
|
4876
|
+
success: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
4877
|
+
errorMessage: alepha2502.TOptional<alepha2502.TString>;
|
|
4878
|
+
}>>;
|
|
4879
|
+
}>;
|
|
4880
|
+
/**
|
|
4881
|
+
* Get a single audit entry by ID.
|
|
4882
|
+
*/
|
|
4883
|
+
readonly getAudit: ActionPrimitiveFn<{
|
|
4884
|
+
params: alepha2502.TObject<{
|
|
4885
|
+
id: alepha2502.TString;
|
|
4886
|
+
}>;
|
|
4887
|
+
response: alepha2502.TObject<{
|
|
4888
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
4889
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
4890
|
+
type: alepha2502.TString;
|
|
4891
|
+
action: alepha2502.TString;
|
|
4892
|
+
severity: PgAttr<alepha2502.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
|
|
4893
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
4894
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
4895
|
+
userEmail: alepha2502.TOptional<alepha2502.TString>;
|
|
4896
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
4897
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
4898
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
4899
|
+
metadata: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
4900
|
+
ipAddress: alepha2502.TOptional<alepha2502.TString>;
|
|
4901
|
+
userAgent: alepha2502.TOptional<alepha2502.TString>;
|
|
4902
|
+
sessionId: alepha2502.TOptional<alepha2502.TString>;
|
|
4903
|
+
requestId: alepha2502.TOptional<alepha2502.TString>;
|
|
4904
|
+
success: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
4905
|
+
errorMessage: alepha2502.TOptional<alepha2502.TString>;
|
|
4906
|
+
}>;
|
|
4907
|
+
}>;
|
|
4908
|
+
/**
|
|
4909
|
+
* Create a new audit entry.
|
|
4910
|
+
*/
|
|
4911
|
+
readonly createAudit: ActionPrimitiveFn<{
|
|
4912
|
+
body: alepha2502.TObject<{
|
|
4913
|
+
type: alepha2502.TString;
|
|
4914
|
+
action: alepha2502.TString;
|
|
4915
|
+
severity: alepha2502.TOptional<alepha2502.TUnsafe<"info" | "warning" | "critical">>;
|
|
4916
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
4917
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
4918
|
+
userEmail: alepha2502.TOptional<alepha2502.TString>;
|
|
4919
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
4920
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
4921
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
4922
|
+
metadata: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
4923
|
+
ipAddress: alepha2502.TOptional<alepha2502.TString>;
|
|
4924
|
+
userAgent: alepha2502.TOptional<alepha2502.TString>;
|
|
4925
|
+
sessionId: alepha2502.TOptional<alepha2502.TString>;
|
|
4926
|
+
requestId: alepha2502.TOptional<alepha2502.TString>;
|
|
4927
|
+
success: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
4928
|
+
errorMessage: alepha2502.TOptional<alepha2502.TString>;
|
|
4929
|
+
}>;
|
|
4930
|
+
response: alepha2502.TObject<{
|
|
4931
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
4932
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
4933
|
+
type: alepha2502.TString;
|
|
4934
|
+
action: alepha2502.TString;
|
|
4935
|
+
severity: PgAttr<alepha2502.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
|
|
4936
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
4937
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
4938
|
+
userEmail: alepha2502.TOptional<alepha2502.TString>;
|
|
4939
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
4940
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
4941
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
4942
|
+
metadata: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
4943
|
+
ipAddress: alepha2502.TOptional<alepha2502.TString>;
|
|
4944
|
+
userAgent: alepha2502.TOptional<alepha2502.TString>;
|
|
4945
|
+
sessionId: alepha2502.TOptional<alepha2502.TString>;
|
|
4946
|
+
requestId: alepha2502.TOptional<alepha2502.TString>;
|
|
4947
|
+
success: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
4948
|
+
errorMessage: alepha2502.TOptional<alepha2502.TString>;
|
|
4949
|
+
}>;
|
|
4950
|
+
}>;
|
|
4951
|
+
/**
|
|
4952
|
+
* Get audit entries for a specific user.
|
|
4953
|
+
*/
|
|
4954
|
+
readonly findByUser: ActionPrimitiveFn<{
|
|
4955
|
+
params: alepha2502.TObject<{
|
|
4956
|
+
userId: alepha2502.TString;
|
|
4957
|
+
}>;
|
|
4958
|
+
query: alepha2502.TObject<{
|
|
4959
|
+
type: alepha2502.TOptional<alepha2502.TString>;
|
|
4960
|
+
sort: alepha2502.TOptional<alepha2502.TString>;
|
|
4961
|
+
search: alepha2502.TOptional<alepha2502.TString>;
|
|
4962
|
+
page: alepha2502.TOptional<alepha2502.TInteger>;
|
|
4963
|
+
from: alepha2502.TOptional<alepha2502.TString>;
|
|
4964
|
+
to: alepha2502.TOptional<alepha2502.TString>;
|
|
4965
|
+
size: alepha2502.TOptional<alepha2502.TInteger>;
|
|
4966
|
+
success: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
4967
|
+
action: alepha2502.TOptional<alepha2502.TString>;
|
|
4968
|
+
severity: alepha2502.TOptional<alepha2502.TUnsafe<"info" | "warning" | "critical">>;
|
|
4969
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
4970
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
4971
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
4972
|
+
}>;
|
|
4973
|
+
response: alepha2502.TPage<alepha2502.TObject<{
|
|
4974
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
4975
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
4976
|
+
type: alepha2502.TString;
|
|
4977
|
+
action: alepha2502.TString;
|
|
4978
|
+
severity: PgAttr<alepha2502.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
|
|
4979
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
4980
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
4981
|
+
userEmail: alepha2502.TOptional<alepha2502.TString>;
|
|
4982
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
4983
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
4984
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
4985
|
+
metadata: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
4986
|
+
ipAddress: alepha2502.TOptional<alepha2502.TString>;
|
|
4987
|
+
userAgent: alepha2502.TOptional<alepha2502.TString>;
|
|
4988
|
+
sessionId: alepha2502.TOptional<alepha2502.TString>;
|
|
4989
|
+
requestId: alepha2502.TOptional<alepha2502.TString>;
|
|
4990
|
+
success: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
4991
|
+
errorMessage: alepha2502.TOptional<alepha2502.TString>;
|
|
4992
|
+
}>>;
|
|
4993
|
+
}>;
|
|
4994
|
+
/**
|
|
4995
|
+
* Get audit entries for a specific resource.
|
|
4996
|
+
*/
|
|
4997
|
+
readonly findByResource: ActionPrimitiveFn<{
|
|
4998
|
+
params: alepha2502.TObject<{
|
|
4999
|
+
resourceType: alepha2502.TString;
|
|
5000
|
+
resourceId: alepha2502.TString;
|
|
5001
|
+
}>;
|
|
5002
|
+
query: alepha2502.TObject<{
|
|
5003
|
+
type: alepha2502.TOptional<alepha2502.TString>;
|
|
5004
|
+
sort: alepha2502.TOptional<alepha2502.TString>;
|
|
5005
|
+
search: alepha2502.TOptional<alepha2502.TString>;
|
|
5006
|
+
page: alepha2502.TOptional<alepha2502.TInteger>;
|
|
5007
|
+
from: alepha2502.TOptional<alepha2502.TString>;
|
|
5008
|
+
to: alepha2502.TOptional<alepha2502.TString>;
|
|
5009
|
+
size: alepha2502.TOptional<alepha2502.TInteger>;
|
|
5010
|
+
success: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
5011
|
+
action: alepha2502.TOptional<alepha2502.TString>;
|
|
5012
|
+
severity: alepha2502.TOptional<alepha2502.TUnsafe<"info" | "warning" | "critical">>;
|
|
5013
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
5014
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
5015
|
+
}>;
|
|
5016
|
+
response: alepha2502.TPage<alepha2502.TObject<{
|
|
5017
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
5018
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
5019
|
+
type: alepha2502.TString;
|
|
5020
|
+
action: alepha2502.TString;
|
|
5021
|
+
severity: PgAttr<alepha2502.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
|
|
5022
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
5023
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
5024
|
+
userEmail: alepha2502.TOptional<alepha2502.TString>;
|
|
5025
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
5026
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
5027
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
5028
|
+
metadata: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
5029
|
+
ipAddress: alepha2502.TOptional<alepha2502.TString>;
|
|
5030
|
+
userAgent: alepha2502.TOptional<alepha2502.TString>;
|
|
5031
|
+
sessionId: alepha2502.TOptional<alepha2502.TString>;
|
|
5032
|
+
requestId: alepha2502.TOptional<alepha2502.TString>;
|
|
5033
|
+
success: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
5034
|
+
errorMessage: alepha2502.TOptional<alepha2502.TString>;
|
|
5035
|
+
}>>;
|
|
5036
|
+
}>;
|
|
5037
|
+
/**
|
|
5038
|
+
* Get audit statistics.
|
|
5039
|
+
*/
|
|
5040
|
+
readonly getStats: ActionPrimitiveFn<{
|
|
5041
|
+
query: alepha2502.TObject<{
|
|
5042
|
+
from: alepha2502.TOptional<alepha2502.TString>;
|
|
5043
|
+
to: alepha2502.TOptional<alepha2502.TString>;
|
|
5044
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
5045
|
+
}>;
|
|
5046
|
+
response: alepha2502.TObject<{
|
|
5047
|
+
total: alepha2502.TInteger;
|
|
5048
|
+
byType: alepha2502.TRecord<"^.*$", alepha2502.TInteger>;
|
|
5049
|
+
bySeverity: alepha2502.TObject<{
|
|
5050
|
+
info: alepha2502.TInteger;
|
|
5051
|
+
warning: alepha2502.TInteger;
|
|
5052
|
+
critical: alepha2502.TInteger;
|
|
5053
|
+
}>;
|
|
5054
|
+
successRate: alepha2502.TNumber;
|
|
5055
|
+
recentFailures: alepha2502.TArray<alepha2502.TObject<{
|
|
5056
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
5057
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
5058
|
+
type: alepha2502.TString;
|
|
5059
|
+
action: alepha2502.TString;
|
|
5060
|
+
severity: PgAttr<alepha2502.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
|
|
5061
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
5062
|
+
userRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
5063
|
+
userEmail: alepha2502.TOptional<alepha2502.TString>;
|
|
5064
|
+
resourceType: alepha2502.TOptional<alepha2502.TString>;
|
|
5065
|
+
resourceId: alepha2502.TOptional<alepha2502.TString>;
|
|
5066
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
5067
|
+
metadata: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
5068
|
+
ipAddress: alepha2502.TOptional<alepha2502.TString>;
|
|
5069
|
+
userAgent: alepha2502.TOptional<alepha2502.TString>;
|
|
5070
|
+
sessionId: alepha2502.TOptional<alepha2502.TString>;
|
|
5071
|
+
requestId: alepha2502.TOptional<alepha2502.TString>;
|
|
5072
|
+
success: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
5073
|
+
errorMessage: alepha2502.TOptional<alepha2502.TString>;
|
|
5074
|
+
}>>;
|
|
5075
|
+
}>;
|
|
5076
|
+
}>;
|
|
5077
|
+
/**
|
|
5078
|
+
* Get registered audit types.
|
|
5079
|
+
*/
|
|
5080
|
+
readonly getTypes: ActionPrimitiveFn<{
|
|
5081
|
+
response: alepha2502.TArray<alepha2502.TObject<{
|
|
5082
|
+
type: alepha2502.TString;
|
|
5083
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
5084
|
+
actions: alepha2502.TArray<alepha2502.TString>;
|
|
5085
|
+
}>>;
|
|
5086
|
+
}>;
|
|
5087
|
+
/**
|
|
5088
|
+
* Get distinct values for filters.
|
|
5089
|
+
*/
|
|
5090
|
+
readonly getFilterOptions: ActionPrimitiveFn<{
|
|
5091
|
+
response: alepha2502.TObject<{
|
|
5092
|
+
types: alepha2502.TArray<alepha2502.TString>;
|
|
5093
|
+
actions: alepha2502.TArray<alepha2502.TString>;
|
|
5094
|
+
resourceTypes: alepha2502.TArray<alepha2502.TString>;
|
|
5095
|
+
userRealms: alepha2502.TArray<alepha2502.TString>;
|
|
5096
|
+
}>;
|
|
5097
|
+
}>;
|
|
5098
|
+
}
|
|
5099
|
+
//#endregion
|
|
4568
5100
|
//#region ../../../alepha/src/bucket/providers/FileStorageProvider.d.ts
|
|
4569
5101
|
declare abstract class FileStorageProvider {
|
|
4570
5102
|
/**
|
|
@@ -4789,8 +5321,8 @@ interface BucketFileOptions {
|
|
|
4789
5321
|
/**
|
|
4790
5322
|
* Local file storage configuration atom
|
|
4791
5323
|
*/
|
|
4792
|
-
declare const localFileStorageOptions:
|
|
4793
|
-
storagePath:
|
|
5324
|
+
declare const localFileStorageOptions: alepha2502.Atom<alepha2502.TObject<{
|
|
5325
|
+
storagePath: alepha2502.TString;
|
|
4794
5326
|
}>, "alepha.bucket.local.options">;
|
|
4795
5327
|
type LocalFileStorageProviderOptions = Static<typeof localFileStorageOptions.schema>;
|
|
4796
5328
|
declare module "alepha" {
|
|
@@ -4833,102 +5365,102 @@ declare module "alepha" {
|
|
|
4833
5365
|
* @module alepha.bucket
|
|
4834
5366
|
*/
|
|
4835
5367
|
//#endregion
|
|
4836
|
-
//#region ../../../alepha/src/api
|
|
4837
|
-
declare const files: EntityPrimitive<
|
|
4838
|
-
id: PgAttr<PgAttr<
|
|
4839
|
-
version: PgAttr<PgAttr<
|
|
4840
|
-
createdAt: PgAttr<PgAttr<
|
|
4841
|
-
updatedAt: PgAttr<PgAttr<
|
|
4842
|
-
blobId:
|
|
4843
|
-
creator:
|
|
4844
|
-
creatorRealm:
|
|
4845
|
-
creatorName:
|
|
4846
|
-
bucket:
|
|
4847
|
-
expirationDate:
|
|
4848
|
-
name:
|
|
4849
|
-
size:
|
|
4850
|
-
mimeType:
|
|
4851
|
-
tags:
|
|
4852
|
-
checksum:
|
|
5368
|
+
//#region ../../../alepha/src/api/files/entities/files.d.ts
|
|
5369
|
+
declare const files: EntityPrimitive<alepha2502.TObject<{
|
|
5370
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
5371
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
5372
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
5373
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
5374
|
+
blobId: alepha2502.TString;
|
|
5375
|
+
creator: alepha2502.TOptional<alepha2502.TString>;
|
|
5376
|
+
creatorRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
5377
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
5378
|
+
bucket: alepha2502.TString;
|
|
5379
|
+
expirationDate: alepha2502.TOptional<alepha2502.TString>;
|
|
5380
|
+
name: alepha2502.TString;
|
|
5381
|
+
size: alepha2502.TNumber;
|
|
5382
|
+
mimeType: alepha2502.TString;
|
|
5383
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
5384
|
+
checksum: alepha2502.TOptional<alepha2502.TString>;
|
|
4853
5385
|
}>>;
|
|
4854
5386
|
type FileEntity = Static<typeof files.schema>;
|
|
4855
5387
|
//#endregion
|
|
4856
|
-
//#region ../../../alepha/src/api
|
|
4857
|
-
declare const fileQuerySchema:
|
|
4858
|
-
page:
|
|
4859
|
-
size:
|
|
4860
|
-
sort:
|
|
4861
|
-
bucket:
|
|
4862
|
-
tags:
|
|
4863
|
-
name:
|
|
4864
|
-
mimeType:
|
|
4865
|
-
creator:
|
|
4866
|
-
createdAfter:
|
|
4867
|
-
createdBefore:
|
|
5388
|
+
//#region ../../../alepha/src/api/files/schemas/fileQuerySchema.d.ts
|
|
5389
|
+
declare const fileQuerySchema: alepha2502.TObject<{
|
|
5390
|
+
page: alepha2502.TOptional<alepha2502.TInteger>;
|
|
5391
|
+
size: alepha2502.TOptional<alepha2502.TInteger>;
|
|
5392
|
+
sort: alepha2502.TOptional<alepha2502.TString>;
|
|
5393
|
+
bucket: alepha2502.TOptional<alepha2502.TString>;
|
|
5394
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
5395
|
+
name: alepha2502.TOptional<alepha2502.TString>;
|
|
5396
|
+
mimeType: alepha2502.TOptional<alepha2502.TString>;
|
|
5397
|
+
creator: alepha2502.TOptional<alepha2502.TString>;
|
|
5398
|
+
createdAfter: alepha2502.TOptional<alepha2502.TString>;
|
|
5399
|
+
createdBefore: alepha2502.TOptional<alepha2502.TString>;
|
|
4868
5400
|
}>;
|
|
4869
5401
|
type FileQuery = Static<typeof fileQuerySchema>;
|
|
4870
5402
|
//#endregion
|
|
4871
|
-
//#region ../../../alepha/src/api
|
|
4872
|
-
declare const fileResourceSchema:
|
|
4873
|
-
id: PgAttr<PgAttr<
|
|
4874
|
-
version: PgAttr<PgAttr<
|
|
4875
|
-
createdAt: PgAttr<PgAttr<
|
|
4876
|
-
updatedAt: PgAttr<PgAttr<
|
|
4877
|
-
blobId:
|
|
4878
|
-
creator:
|
|
4879
|
-
creatorRealm:
|
|
4880
|
-
creatorName:
|
|
4881
|
-
bucket:
|
|
4882
|
-
expirationDate:
|
|
4883
|
-
name:
|
|
4884
|
-
size:
|
|
4885
|
-
mimeType:
|
|
4886
|
-
tags:
|
|
4887
|
-
checksum:
|
|
5403
|
+
//#region ../../../alepha/src/api/files/schemas/fileResourceSchema.d.ts
|
|
5404
|
+
declare const fileResourceSchema: alepha2502.TObject<{
|
|
5405
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
5406
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
5407
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
5408
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
5409
|
+
blobId: alepha2502.TString;
|
|
5410
|
+
creator: alepha2502.TOptional<alepha2502.TString>;
|
|
5411
|
+
creatorRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
5412
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
5413
|
+
bucket: alepha2502.TString;
|
|
5414
|
+
expirationDate: alepha2502.TOptional<alepha2502.TString>;
|
|
5415
|
+
name: alepha2502.TString;
|
|
5416
|
+
size: alepha2502.TNumber;
|
|
5417
|
+
mimeType: alepha2502.TString;
|
|
5418
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
5419
|
+
checksum: alepha2502.TOptional<alepha2502.TString>;
|
|
4888
5420
|
}>;
|
|
4889
5421
|
type FileResource = Static<typeof fileResourceSchema>;
|
|
4890
5422
|
//#endregion
|
|
4891
|
-
//#region ../../../alepha/src/api
|
|
4892
|
-
declare const storageStatsSchema:
|
|
4893
|
-
totalSize:
|
|
4894
|
-
totalFiles:
|
|
4895
|
-
byBucket:
|
|
4896
|
-
bucket:
|
|
4897
|
-
totalSize:
|
|
4898
|
-
fileCount:
|
|
5423
|
+
//#region ../../../alepha/src/api/files/schemas/storageStatsSchema.d.ts
|
|
5424
|
+
declare const storageStatsSchema: alepha2502.TObject<{
|
|
5425
|
+
totalSize: alepha2502.TNumber;
|
|
5426
|
+
totalFiles: alepha2502.TNumber;
|
|
5427
|
+
byBucket: alepha2502.TArray<alepha2502.TObject<{
|
|
5428
|
+
bucket: alepha2502.TString;
|
|
5429
|
+
totalSize: alepha2502.TNumber;
|
|
5430
|
+
fileCount: alepha2502.TNumber;
|
|
4899
5431
|
}>>;
|
|
4900
|
-
byMimeType:
|
|
4901
|
-
mimeType:
|
|
4902
|
-
fileCount:
|
|
5432
|
+
byMimeType: alepha2502.TArray<alepha2502.TObject<{
|
|
5433
|
+
mimeType: alepha2502.TString;
|
|
5434
|
+
fileCount: alepha2502.TNumber;
|
|
4903
5435
|
}>>;
|
|
4904
5436
|
}>;
|
|
4905
5437
|
type StorageStats = Static<typeof storageStatsSchema>;
|
|
4906
5438
|
//#endregion
|
|
4907
|
-
//#region ../../../alepha/src/api
|
|
5439
|
+
//#region ../../../alepha/src/api/files/services/FileService.d.ts
|
|
4908
5440
|
declare class FileService {
|
|
4909
5441
|
protected readonly alepha: Alepha;
|
|
4910
5442
|
protected readonly log: Logger;
|
|
4911
|
-
protected readonly fileRepository: Repository<
|
|
4912
|
-
id: PgAttr<PgAttr<
|
|
4913
|
-
version: PgAttr<PgAttr<
|
|
4914
|
-
createdAt: PgAttr<PgAttr<
|
|
4915
|
-
updatedAt: PgAttr<PgAttr<
|
|
4916
|
-
blobId:
|
|
4917
|
-
creator:
|
|
4918
|
-
creatorRealm:
|
|
4919
|
-
creatorName:
|
|
4920
|
-
bucket:
|
|
4921
|
-
expirationDate:
|
|
4922
|
-
name:
|
|
4923
|
-
size:
|
|
4924
|
-
mimeType:
|
|
4925
|
-
tags:
|
|
4926
|
-
checksum:
|
|
5443
|
+
protected readonly fileRepository: Repository<alepha2502.TObject<{
|
|
5444
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
5445
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
5446
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
5447
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
5448
|
+
blobId: alepha2502.TString;
|
|
5449
|
+
creator: alepha2502.TOptional<alepha2502.TString>;
|
|
5450
|
+
creatorRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
5451
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
5452
|
+
bucket: alepha2502.TString;
|
|
5453
|
+
expirationDate: alepha2502.TOptional<alepha2502.TString>;
|
|
5454
|
+
name: alepha2502.TString;
|
|
5455
|
+
size: alepha2502.TNumber;
|
|
5456
|
+
mimeType: alepha2502.TString;
|
|
5457
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
5458
|
+
checksum: alepha2502.TOptional<alepha2502.TString>;
|
|
4927
5459
|
}>>;
|
|
4928
5460
|
protected readonly dateTimeProvider: DateTimeProvider;
|
|
4929
5461
|
protected readonly defaultBucket: BucketPrimitive;
|
|
4930
|
-
protected onUploadFile:
|
|
4931
|
-
protected onDeleteBucketFile:
|
|
5462
|
+
protected onUploadFile: alepha2502.HookPrimitive<"bucket:file:uploaded">;
|
|
5463
|
+
protected onDeleteBucketFile: alepha2502.HookPrimitive<"bucket:file:deleted">;
|
|
4932
5464
|
/**
|
|
4933
5465
|
* Calculates SHA-256 checksum of a file.
|
|
4934
5466
|
*
|
|
@@ -5048,7 +5580,7 @@ declare class FileService {
|
|
|
5048
5580
|
entityToResource(entity: FileEntity): FileResource;
|
|
5049
5581
|
}
|
|
5050
5582
|
//#endregion
|
|
5051
|
-
//#region ../../../alepha/src/api
|
|
5583
|
+
//#region ../../../alepha/src/api/files/controllers/FileController.d.ts
|
|
5052
5584
|
/**
|
|
5053
5585
|
* REST API controller for file management operations.
|
|
5054
5586
|
* Provides endpoints for uploading, downloading, listing, and deleting files.
|
|
@@ -5062,34 +5594,34 @@ declare class FileController {
|
|
|
5062
5594
|
* Supports filtering by bucket and tags.
|
|
5063
5595
|
*/
|
|
5064
5596
|
readonly findFiles: ActionPrimitiveFn<{
|
|
5065
|
-
query:
|
|
5066
|
-
page:
|
|
5067
|
-
size:
|
|
5068
|
-
sort:
|
|
5069
|
-
bucket:
|
|
5070
|
-
tags:
|
|
5071
|
-
name:
|
|
5072
|
-
mimeType:
|
|
5073
|
-
creator:
|
|
5074
|
-
createdAfter:
|
|
5075
|
-
createdBefore:
|
|
5597
|
+
query: alepha2502.TObject<{
|
|
5598
|
+
page: alepha2502.TOptional<alepha2502.TInteger>;
|
|
5599
|
+
size: alepha2502.TOptional<alepha2502.TInteger>;
|
|
5600
|
+
sort: alepha2502.TOptional<alepha2502.TString>;
|
|
5601
|
+
bucket: alepha2502.TOptional<alepha2502.TString>;
|
|
5602
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
5603
|
+
name: alepha2502.TOptional<alepha2502.TString>;
|
|
5604
|
+
mimeType: alepha2502.TOptional<alepha2502.TString>;
|
|
5605
|
+
creator: alepha2502.TOptional<alepha2502.TString>;
|
|
5606
|
+
createdAfter: alepha2502.TOptional<alepha2502.TString>;
|
|
5607
|
+
createdBefore: alepha2502.TOptional<alepha2502.TString>;
|
|
5076
5608
|
}>;
|
|
5077
|
-
response:
|
|
5078
|
-
id: PgAttr<PgAttr<
|
|
5079
|
-
version: PgAttr<PgAttr<
|
|
5080
|
-
createdAt: PgAttr<PgAttr<
|
|
5081
|
-
updatedAt: PgAttr<PgAttr<
|
|
5082
|
-
blobId:
|
|
5083
|
-
creator:
|
|
5084
|
-
creatorRealm:
|
|
5085
|
-
creatorName:
|
|
5086
|
-
bucket:
|
|
5087
|
-
expirationDate:
|
|
5088
|
-
name:
|
|
5089
|
-
size:
|
|
5090
|
-
mimeType:
|
|
5091
|
-
tags:
|
|
5092
|
-
checksum:
|
|
5609
|
+
response: alepha2502.TPage<alepha2502.TObject<{
|
|
5610
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
5611
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
5612
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
5613
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
5614
|
+
blobId: alepha2502.TString;
|
|
5615
|
+
creator: alepha2502.TOptional<alepha2502.TString>;
|
|
5616
|
+
creatorRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
5617
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
5618
|
+
bucket: alepha2502.TString;
|
|
5619
|
+
expirationDate: alepha2502.TOptional<alepha2502.TString>;
|
|
5620
|
+
name: alepha2502.TString;
|
|
5621
|
+
size: alepha2502.TNumber;
|
|
5622
|
+
mimeType: alepha2502.TString;
|
|
5623
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
5624
|
+
checksum: alepha2502.TOptional<alepha2502.TString>;
|
|
5093
5625
|
}>>;
|
|
5094
5626
|
}>;
|
|
5095
5627
|
/**
|
|
@@ -5097,13 +5629,13 @@ declare class FileController {
|
|
|
5097
5629
|
* Removes the file from the bucket and cleans up the database record.
|
|
5098
5630
|
*/
|
|
5099
5631
|
readonly deleteFile: ActionPrimitiveFn<{
|
|
5100
|
-
params:
|
|
5101
|
-
id:
|
|
5632
|
+
params: alepha2502.TObject<{
|
|
5633
|
+
id: alepha2502.TString;
|
|
5102
5634
|
}>;
|
|
5103
|
-
response:
|
|
5104
|
-
ok:
|
|
5105
|
-
id:
|
|
5106
|
-
count:
|
|
5635
|
+
response: alepha2502.TObject<{
|
|
5636
|
+
ok: alepha2502.TBoolean;
|
|
5637
|
+
id: alepha2502.TOptional<alepha2502.TUnion<[alepha2502.TString, alepha2502.TInteger]>>;
|
|
5638
|
+
count: alepha2502.TOptional<alepha2502.TNumber>;
|
|
5107
5639
|
}>;
|
|
5108
5640
|
}>;
|
|
5109
5641
|
/**
|
|
@@ -5112,29 +5644,29 @@ declare class FileController {
|
|
|
5112
5644
|
* Optionally specify bucket and expiration date.
|
|
5113
5645
|
*/
|
|
5114
5646
|
readonly uploadFile: ActionPrimitiveFn<{
|
|
5115
|
-
body:
|
|
5116
|
-
file:
|
|
5647
|
+
body: alepha2502.TObject<{
|
|
5648
|
+
file: alepha2502.TFile;
|
|
5117
5649
|
}>;
|
|
5118
|
-
query:
|
|
5119
|
-
expirationDate:
|
|
5120
|
-
bucket:
|
|
5650
|
+
query: alepha2502.TObject<{
|
|
5651
|
+
expirationDate: alepha2502.TOptional<alepha2502.TString>;
|
|
5652
|
+
bucket: alepha2502.TOptional<alepha2502.TString>;
|
|
5121
5653
|
}>;
|
|
5122
|
-
response:
|
|
5123
|
-
id: PgAttr<PgAttr<
|
|
5124
|
-
version: PgAttr<PgAttr<
|
|
5125
|
-
createdAt: PgAttr<PgAttr<
|
|
5126
|
-
updatedAt: PgAttr<PgAttr<
|
|
5127
|
-
blobId:
|
|
5128
|
-
creator:
|
|
5129
|
-
creatorRealm:
|
|
5130
|
-
creatorName:
|
|
5131
|
-
bucket:
|
|
5132
|
-
expirationDate:
|
|
5133
|
-
name:
|
|
5134
|
-
size:
|
|
5135
|
-
mimeType:
|
|
5136
|
-
tags:
|
|
5137
|
-
checksum:
|
|
5654
|
+
response: alepha2502.TObject<{
|
|
5655
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
5656
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
5657
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
5658
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
5659
|
+
blobId: alepha2502.TString;
|
|
5660
|
+
creator: alepha2502.TOptional<alepha2502.TString>;
|
|
5661
|
+
creatorRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
5662
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
5663
|
+
bucket: alepha2502.TString;
|
|
5664
|
+
expirationDate: alepha2502.TOptional<alepha2502.TString>;
|
|
5665
|
+
name: alepha2502.TString;
|
|
5666
|
+
size: alepha2502.TNumber;
|
|
5667
|
+
mimeType: alepha2502.TString;
|
|
5668
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
5669
|
+
checksum: alepha2502.TOptional<alepha2502.TString>;
|
|
5138
5670
|
}>;
|
|
5139
5671
|
}>;
|
|
5140
5672
|
/**
|
|
@@ -5142,30 +5674,30 @@ declare class FileController {
|
|
|
5142
5674
|
* Allows updating name, tags, and expiration date without modifying file content.
|
|
5143
5675
|
*/
|
|
5144
5676
|
readonly updateFile: ActionPrimitiveFn<{
|
|
5145
|
-
params:
|
|
5146
|
-
id:
|
|
5677
|
+
params: alepha2502.TObject<{
|
|
5678
|
+
id: alepha2502.TString;
|
|
5147
5679
|
}>;
|
|
5148
|
-
body:
|
|
5149
|
-
name:
|
|
5150
|
-
tags:
|
|
5151
|
-
expirationDate:
|
|
5680
|
+
body: alepha2502.TObject<{
|
|
5681
|
+
name: alepha2502.TOptional<alepha2502.TString>;
|
|
5682
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
5683
|
+
expirationDate: alepha2502.TOptional<alepha2502.TString>;
|
|
5152
5684
|
}>;
|
|
5153
|
-
response:
|
|
5154
|
-
id: PgAttr<PgAttr<
|
|
5155
|
-
version: PgAttr<PgAttr<
|
|
5156
|
-
createdAt: PgAttr<PgAttr<
|
|
5157
|
-
updatedAt: PgAttr<PgAttr<
|
|
5158
|
-
blobId:
|
|
5159
|
-
creator:
|
|
5160
|
-
creatorRealm:
|
|
5161
|
-
creatorName:
|
|
5162
|
-
bucket:
|
|
5163
|
-
expirationDate:
|
|
5164
|
-
name:
|
|
5165
|
-
size:
|
|
5166
|
-
mimeType:
|
|
5167
|
-
tags:
|
|
5168
|
-
checksum:
|
|
5685
|
+
response: alepha2502.TObject<{
|
|
5686
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
5687
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
5688
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
5689
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
5690
|
+
blobId: alepha2502.TString;
|
|
5691
|
+
creator: alepha2502.TOptional<alepha2502.TString>;
|
|
5692
|
+
creatorRealm: alepha2502.TOptional<alepha2502.TString>;
|
|
5693
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
5694
|
+
bucket: alepha2502.TString;
|
|
5695
|
+
expirationDate: alepha2502.TOptional<alepha2502.TString>;
|
|
5696
|
+
name: alepha2502.TString;
|
|
5697
|
+
size: alepha2502.TNumber;
|
|
5698
|
+
mimeType: alepha2502.TString;
|
|
5699
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
5700
|
+
checksum: alepha2502.TOptional<alepha2502.TString>;
|
|
5169
5701
|
}>;
|
|
5170
5702
|
}>;
|
|
5171
5703
|
/**
|
|
@@ -5174,14 +5706,52 @@ declare class FileController {
|
|
|
5174
5706
|
* Cached with ETag support for 1 year (immutable).
|
|
5175
5707
|
*/
|
|
5176
5708
|
readonly streamFile: ActionPrimitiveFn<{
|
|
5177
|
-
params:
|
|
5178
|
-
id:
|
|
5709
|
+
params: alepha2502.TObject<{
|
|
5710
|
+
id: alepha2502.TString;
|
|
5179
5711
|
}>;
|
|
5180
|
-
response:
|
|
5712
|
+
response: alepha2502.TFile;
|
|
5181
5713
|
}>;
|
|
5182
5714
|
}
|
|
5183
5715
|
//#endregion
|
|
5184
|
-
//#region ../../../alepha/src/
|
|
5716
|
+
//#region ../../../alepha/src/scheduler/primitives/$scheduler.d.ts
|
|
5717
|
+
declare const envSchema$1: alepha2502.TObject<{
|
|
5718
|
+
SCHEDULER_PREFIX: alepha2502.TOptional<alepha2502.TString>;
|
|
5719
|
+
}>;
|
|
5720
|
+
declare module "alepha" {
|
|
5721
|
+
interface Env extends Partial<Static<typeof envSchema$1>> {}
|
|
5722
|
+
}
|
|
5723
|
+
//#endregion
|
|
5724
|
+
//#region ../../../alepha/src/scheduler/index.d.ts
|
|
5725
|
+
declare module "alepha" {
|
|
5726
|
+
interface Hooks {
|
|
5727
|
+
"scheduler:begin": {
|
|
5728
|
+
name: string;
|
|
5729
|
+
now: DateTime;
|
|
5730
|
+
context: string;
|
|
5731
|
+
};
|
|
5732
|
+
"scheduler:success": {
|
|
5733
|
+
name: string;
|
|
5734
|
+
context: string;
|
|
5735
|
+
};
|
|
5736
|
+
"scheduler:error": {
|
|
5737
|
+
name: string;
|
|
5738
|
+
error: Error;
|
|
5739
|
+
context: string;
|
|
5740
|
+
};
|
|
5741
|
+
"scheduler:end": {
|
|
5742
|
+
name: string;
|
|
5743
|
+
context: string;
|
|
5744
|
+
};
|
|
5745
|
+
}
|
|
5746
|
+
}
|
|
5747
|
+
/**
|
|
5748
|
+
* Generic interface for scheduling tasks.
|
|
5749
|
+
*
|
|
5750
|
+
* @see {@link $scheduler}
|
|
5751
|
+
* @module alepha.scheduler
|
|
5752
|
+
*/
|
|
5753
|
+
//#endregion
|
|
5754
|
+
//#region ../../../alepha/src/api/files/index.d.ts
|
|
5185
5755
|
declare module "alepha/bucket" {
|
|
5186
5756
|
interface BucketFileOptions {
|
|
5187
5757
|
/**
|
|
@@ -5479,56 +6049,56 @@ declare class BatchPrimitive<TItem extends TSchema, TResponse = any> extends Pri
|
|
|
5479
6049
|
* @returns The number of items cleared
|
|
5480
6050
|
*/
|
|
5481
6051
|
clearCompleted(status?: "completed" | "failed"): number;
|
|
5482
|
-
protected readonly onReady:
|
|
5483
|
-
protected readonly dispose:
|
|
5484
|
-
}
|
|
5485
|
-
//#endregion
|
|
5486
|
-
//#region ../../../alepha/src/api
|
|
5487
|
-
declare const notifications: EntityPrimitive<
|
|
5488
|
-
id: PgAttr<PgAttr<
|
|
5489
|
-
version: PgAttr<PgAttr<
|
|
5490
|
-
createdAt: PgAttr<PgAttr<
|
|
5491
|
-
updatedAt: PgAttr<PgAttr<
|
|
5492
|
-
type:
|
|
5493
|
-
template:
|
|
5494
|
-
category:
|
|
5495
|
-
critical:
|
|
5496
|
-
sensitive:
|
|
5497
|
-
contact:
|
|
5498
|
-
variables:
|
|
5499
|
-
scheduledAt:
|
|
5500
|
-
sentAt:
|
|
5501
|
-
error:
|
|
5502
|
-
at:
|
|
5503
|
-
name:
|
|
5504
|
-
message:
|
|
6052
|
+
protected readonly onReady: alepha2502.HookPrimitive<"ready">;
|
|
6053
|
+
protected readonly dispose: alepha2502.HookPrimitive<"stop">;
|
|
6054
|
+
}
|
|
6055
|
+
//#endregion
|
|
6056
|
+
//#region ../../../alepha/src/api/notifications/entities/notifications.d.ts
|
|
6057
|
+
declare const notifications: EntityPrimitive<alepha2502.TObject<{
|
|
6058
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
6059
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
6060
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
6061
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
6062
|
+
type: alepha2502.TUnsafe<"email" | "sms">;
|
|
6063
|
+
template: alepha2502.TString;
|
|
6064
|
+
category: alepha2502.TOptional<alepha2502.TString>;
|
|
6065
|
+
critical: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6066
|
+
sensitive: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6067
|
+
contact: alepha2502.TString;
|
|
6068
|
+
variables: alepha2502.TOptional<alepha2502.TRecord<"^.*$", alepha2502.TAny>>;
|
|
6069
|
+
scheduledAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6070
|
+
sentAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6071
|
+
error: alepha2502.TOptional<alepha2502.TObject<{
|
|
6072
|
+
at: alepha2502.TString;
|
|
6073
|
+
name: alepha2502.TString;
|
|
6074
|
+
message: alepha2502.TString;
|
|
5505
6075
|
}>>;
|
|
5506
6076
|
}>>;
|
|
5507
6077
|
type NotificationEntity = Static<typeof notifications.schema>;
|
|
5508
6078
|
//#endregion
|
|
5509
|
-
//#region ../../../alepha/src/api
|
|
5510
|
-
declare const notificationCreateSchema:
|
|
5511
|
-
type:
|
|
5512
|
-
template:
|
|
5513
|
-
contact:
|
|
5514
|
-
variables:
|
|
6079
|
+
//#region ../../../alepha/src/api/notifications/schemas/notificationCreateSchema.d.ts
|
|
6080
|
+
declare const notificationCreateSchema: alepha2502.TObject<{
|
|
6081
|
+
type: alepha2502.TUnsafe<"email" | "sms">;
|
|
6082
|
+
template: alepha2502.TString;
|
|
6083
|
+
contact: alepha2502.TString;
|
|
6084
|
+
variables: alepha2502.TOptional<alepha2502.TRecord<"^.*$", alepha2502.TAny>>;
|
|
5515
6085
|
}>;
|
|
5516
6086
|
type NotificationCreate = Static<typeof notificationCreateSchema>;
|
|
5517
6087
|
//#endregion
|
|
5518
|
-
//#region ../../../alepha/src/api
|
|
5519
|
-
declare const notificationQuerySchema:
|
|
5520
|
-
page:
|
|
5521
|
-
size:
|
|
5522
|
-
sort:
|
|
5523
|
-
type:
|
|
5524
|
-
template:
|
|
5525
|
-
contact:
|
|
5526
|
-
category:
|
|
5527
|
-
status:
|
|
6088
|
+
//#region ../../../alepha/src/api/notifications/schemas/notificationQuerySchema.d.ts
|
|
6089
|
+
declare const notificationQuerySchema: alepha2502.TObject<{
|
|
6090
|
+
page: alepha2502.TOptional<alepha2502.TInteger>;
|
|
6091
|
+
size: alepha2502.TOptional<alepha2502.TInteger>;
|
|
6092
|
+
sort: alepha2502.TOptional<alepha2502.TString>;
|
|
6093
|
+
type: alepha2502.TOptional<alepha2502.TUnsafe<"email" | "sms">>;
|
|
6094
|
+
template: alepha2502.TOptional<alepha2502.TString>;
|
|
6095
|
+
contact: alepha2502.TOptional<alepha2502.TString>;
|
|
6096
|
+
category: alepha2502.TOptional<alepha2502.TString>;
|
|
6097
|
+
status: alepha2502.TOptional<alepha2502.TUnsafe<"pending" | "sent" | "failed">>;
|
|
5528
6098
|
}>;
|
|
5529
6099
|
type NotificationQuery = Static<typeof notificationQuerySchema>;
|
|
5530
6100
|
//#endregion
|
|
5531
|
-
//#region ../../../alepha/src/api
|
|
6101
|
+
//#region ../../../alepha/src/api/notifications/primitives/$notification.d.ts
|
|
5532
6102
|
interface NotificationPrimitiveOptions<T$1 extends TObject> extends NotificationMessage<T$1> {
|
|
5533
6103
|
name?: string;
|
|
5534
6104
|
description?: string;
|
|
@@ -5655,28 +6225,28 @@ declare module "alepha" {
|
|
|
5655
6225
|
* @module alepha.sms
|
|
5656
6226
|
*/
|
|
5657
6227
|
//#endregion
|
|
5658
|
-
//#region ../../../alepha/src/api
|
|
6228
|
+
//#region ../../../alepha/src/api/notifications/services/NotificationSenderService.d.ts
|
|
5659
6229
|
declare class NotificationSenderService {
|
|
5660
6230
|
protected readonly alepha: Alepha;
|
|
5661
6231
|
protected readonly log: Logger;
|
|
5662
|
-
protected readonly notificationRepository: Repository<
|
|
5663
|
-
id: PgAttr<PgAttr<
|
|
5664
|
-
version: PgAttr<PgAttr<
|
|
5665
|
-
createdAt: PgAttr<PgAttr<
|
|
5666
|
-
updatedAt: PgAttr<PgAttr<
|
|
5667
|
-
type:
|
|
5668
|
-
template:
|
|
5669
|
-
category:
|
|
5670
|
-
critical:
|
|
5671
|
-
sensitive:
|
|
5672
|
-
contact:
|
|
5673
|
-
variables:
|
|
5674
|
-
scheduledAt:
|
|
5675
|
-
sentAt:
|
|
5676
|
-
error:
|
|
5677
|
-
at:
|
|
5678
|
-
name:
|
|
5679
|
-
message:
|
|
6232
|
+
protected readonly notificationRepository: Repository<alepha2502.TObject<{
|
|
6233
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
6234
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
6235
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
6236
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
6237
|
+
type: alepha2502.TUnsafe<"email" | "sms">;
|
|
6238
|
+
template: alepha2502.TString;
|
|
6239
|
+
category: alepha2502.TOptional<alepha2502.TString>;
|
|
6240
|
+
critical: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6241
|
+
sensitive: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6242
|
+
contact: alepha2502.TString;
|
|
6243
|
+
variables: alepha2502.TOptional<alepha2502.TRecord<"^.*$", alepha2502.TAny>>;
|
|
6244
|
+
scheduledAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6245
|
+
sentAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6246
|
+
error: alepha2502.TOptional<alepha2502.TObject<{
|
|
6247
|
+
at: alepha2502.TString;
|
|
6248
|
+
name: alepha2502.TString;
|
|
6249
|
+
message: alepha2502.TString;
|
|
5680
6250
|
}>>;
|
|
5681
6251
|
}>>;
|
|
5682
6252
|
protected readonly dateTimeProvider: DateTimeProvider;
|
|
@@ -5693,15 +6263,15 @@ declare class NotificationSenderService {
|
|
|
5693
6263
|
body: string;
|
|
5694
6264
|
};
|
|
5695
6265
|
protected load(notification: NotificationEntity): {
|
|
5696
|
-
template: NotificationPrimitive<
|
|
6266
|
+
template: NotificationPrimitive<alepha2502.TObject<alepha2502.TProperties>>;
|
|
5697
6267
|
variables: Record<string, any>;
|
|
5698
6268
|
contact: string;
|
|
5699
6269
|
};
|
|
5700
6270
|
}
|
|
5701
6271
|
//#endregion
|
|
5702
|
-
//#region ../../../alepha/src/api
|
|
5703
|
-
declare const notificationServiceEnvSchema:
|
|
5704
|
-
NOTIFICATION_QUEUE:
|
|
6272
|
+
//#region ../../../alepha/src/api/notifications/services/NotificationService.d.ts
|
|
6273
|
+
declare const notificationServiceEnvSchema: alepha2502.TObject<{
|
|
6274
|
+
NOTIFICATION_QUEUE: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
5705
6275
|
}>;
|
|
5706
6276
|
declare module "alepha" {
|
|
5707
6277
|
interface Env extends Partial<Static<typeof notificationServiceEnvSchema>> {}
|
|
@@ -5712,71 +6282,71 @@ declare class NotificationService {
|
|
|
5712
6282
|
protected readonly env: {
|
|
5713
6283
|
NOTIFICATION_QUEUE?: boolean | undefined;
|
|
5714
6284
|
};
|
|
5715
|
-
protected readonly notificationRepository: Repository<
|
|
5716
|
-
id: PgAttr<PgAttr<
|
|
5717
|
-
version: PgAttr<PgAttr<
|
|
5718
|
-
createdAt: PgAttr<PgAttr<
|
|
5719
|
-
updatedAt: PgAttr<PgAttr<
|
|
5720
|
-
type:
|
|
5721
|
-
template:
|
|
5722
|
-
category:
|
|
5723
|
-
critical:
|
|
5724
|
-
sensitive:
|
|
5725
|
-
contact:
|
|
5726
|
-
variables:
|
|
5727
|
-
scheduledAt:
|
|
5728
|
-
sentAt:
|
|
5729
|
-
error:
|
|
5730
|
-
at:
|
|
5731
|
-
name:
|
|
5732
|
-
message:
|
|
6285
|
+
protected readonly notificationRepository: Repository<alepha2502.TObject<{
|
|
6286
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
6287
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
6288
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
6289
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
6290
|
+
type: alepha2502.TUnsafe<"email" | "sms">;
|
|
6291
|
+
template: alepha2502.TString;
|
|
6292
|
+
category: alepha2502.TOptional<alepha2502.TString>;
|
|
6293
|
+
critical: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6294
|
+
sensitive: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6295
|
+
contact: alepha2502.TString;
|
|
6296
|
+
variables: alepha2502.TOptional<alepha2502.TRecord<"^.*$", alepha2502.TAny>>;
|
|
6297
|
+
scheduledAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6298
|
+
sentAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6299
|
+
error: alepha2502.TOptional<alepha2502.TObject<{
|
|
6300
|
+
at: alepha2502.TString;
|
|
6301
|
+
name: alepha2502.TString;
|
|
6302
|
+
message: alepha2502.TString;
|
|
5733
6303
|
}>>;
|
|
5734
6304
|
}>>;
|
|
5735
6305
|
protected readonly dateTimeProvider: DateTimeProvider;
|
|
5736
6306
|
protected readonly notificationSenderService: NotificationSenderService;
|
|
5737
|
-
readonly notificationBatch: BatchPrimitive<
|
|
5738
|
-
type:
|
|
5739
|
-
template:
|
|
5740
|
-
contact:
|
|
5741
|
-
variables:
|
|
6307
|
+
readonly notificationBatch: BatchPrimitive<alepha2502.TObject<{
|
|
6308
|
+
type: alepha2502.TUnsafe<"email" | "sms">;
|
|
6309
|
+
template: alepha2502.TString;
|
|
6310
|
+
contact: alepha2502.TString;
|
|
6311
|
+
variables: alepha2502.TOptional<alepha2502.TRecord<"^.*$", alepha2502.TAny>>;
|
|
5742
6312
|
}>, Promise<void>>;
|
|
5743
|
-
findNotificationById(id: string): Promise<PgStatic<
|
|
5744
|
-
id: PgAttr<PgAttr<
|
|
5745
|
-
version: PgAttr<PgAttr<
|
|
5746
|
-
createdAt: PgAttr<PgAttr<
|
|
5747
|
-
updatedAt: PgAttr<PgAttr<
|
|
5748
|
-
type:
|
|
5749
|
-
template:
|
|
5750
|
-
category:
|
|
5751
|
-
critical:
|
|
5752
|
-
sensitive:
|
|
5753
|
-
contact:
|
|
5754
|
-
variables:
|
|
5755
|
-
scheduledAt:
|
|
5756
|
-
sentAt:
|
|
5757
|
-
error:
|
|
5758
|
-
at:
|
|
5759
|
-
name:
|
|
5760
|
-
message:
|
|
6313
|
+
findNotificationById(id: string): Promise<PgStatic<alepha2502.TObject<{
|
|
6314
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
6315
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
6316
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
6317
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
6318
|
+
type: alepha2502.TUnsafe<"email" | "sms">;
|
|
6319
|
+
template: alepha2502.TString;
|
|
6320
|
+
category: alepha2502.TOptional<alepha2502.TString>;
|
|
6321
|
+
critical: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6322
|
+
sensitive: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6323
|
+
contact: alepha2502.TString;
|
|
6324
|
+
variables: alepha2502.TOptional<alepha2502.TRecord<"^.*$", alepha2502.TAny>>;
|
|
6325
|
+
scheduledAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6326
|
+
sentAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6327
|
+
error: alepha2502.TOptional<alepha2502.TObject<{
|
|
6328
|
+
at: alepha2502.TString;
|
|
6329
|
+
name: alepha2502.TString;
|
|
6330
|
+
message: alepha2502.TString;
|
|
5761
6331
|
}>>;
|
|
5762
|
-
}>, PgRelationMap<
|
|
5763
|
-
id: PgAttr<PgAttr<
|
|
5764
|
-
version: PgAttr<PgAttr<
|
|
5765
|
-
createdAt: PgAttr<PgAttr<
|
|
5766
|
-
updatedAt: PgAttr<PgAttr<
|
|
5767
|
-
type:
|
|
5768
|
-
template:
|
|
5769
|
-
category:
|
|
5770
|
-
critical:
|
|
5771
|
-
sensitive:
|
|
5772
|
-
contact:
|
|
5773
|
-
variables:
|
|
5774
|
-
scheduledAt:
|
|
5775
|
-
sentAt:
|
|
5776
|
-
error:
|
|
5777
|
-
at:
|
|
5778
|
-
name:
|
|
5779
|
-
message:
|
|
6332
|
+
}>, PgRelationMap<alepha2502.TObject<{
|
|
6333
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
6334
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
6335
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
6336
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
6337
|
+
type: alepha2502.TUnsafe<"email" | "sms">;
|
|
6338
|
+
template: alepha2502.TString;
|
|
6339
|
+
category: alepha2502.TOptional<alepha2502.TString>;
|
|
6340
|
+
critical: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6341
|
+
sensitive: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6342
|
+
contact: alepha2502.TString;
|
|
6343
|
+
variables: alepha2502.TOptional<alepha2502.TRecord<"^.*$", alepha2502.TAny>>;
|
|
6344
|
+
scheduledAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6345
|
+
sentAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6346
|
+
error: alepha2502.TOptional<alepha2502.TObject<{
|
|
6347
|
+
at: alepha2502.TString;
|
|
6348
|
+
name: alepha2502.TString;
|
|
6349
|
+
message: alepha2502.TString;
|
|
5780
6350
|
}>>;
|
|
5781
6351
|
}>>>>;
|
|
5782
6352
|
findNotifications(q?: NotificationQuery): Promise<Page$1<NotificationEntity>>;
|
|
@@ -5786,7 +6356,7 @@ declare class NotificationService {
|
|
|
5786
6356
|
createNotification(entry: NotificationCreate): Promise<void>;
|
|
5787
6357
|
}
|
|
5788
6358
|
//#endregion
|
|
5789
|
-
//#region ../../../alepha/src/api
|
|
6359
|
+
//#region ../../../alepha/src/api/notifications/controllers/NotificationController.d.ts
|
|
5790
6360
|
declare class NotificationController {
|
|
5791
6361
|
protected readonly url = "/notifications";
|
|
5792
6362
|
protected readonly group = "notifications";
|
|
@@ -5795,70 +6365,60 @@ declare class NotificationController {
|
|
|
5795
6365
|
* Find notifications with pagination and filtering.
|
|
5796
6366
|
*/
|
|
5797
6367
|
readonly findNotifications: ActionPrimitiveFn<{
|
|
5798
|
-
query:
|
|
5799
|
-
page:
|
|
5800
|
-
size:
|
|
5801
|
-
sort:
|
|
5802
|
-
type:
|
|
5803
|
-
template:
|
|
5804
|
-
contact:
|
|
5805
|
-
category:
|
|
5806
|
-
status:
|
|
6368
|
+
query: alepha2502.TObject<{
|
|
6369
|
+
page: alepha2502.TOptional<alepha2502.TInteger>;
|
|
6370
|
+
size: alepha2502.TOptional<alepha2502.TInteger>;
|
|
6371
|
+
sort: alepha2502.TOptional<alepha2502.TString>;
|
|
6372
|
+
type: alepha2502.TOptional<alepha2502.TUnsafe<"email" | "sms">>;
|
|
6373
|
+
template: alepha2502.TOptional<alepha2502.TString>;
|
|
6374
|
+
contact: alepha2502.TOptional<alepha2502.TString>;
|
|
6375
|
+
category: alepha2502.TOptional<alepha2502.TString>;
|
|
6376
|
+
status: alepha2502.TOptional<alepha2502.TUnsafe<"pending" | "sent" | "failed">>;
|
|
5807
6377
|
}>;
|
|
5808
|
-
response:
|
|
5809
|
-
id: PgAttr<PgAttr<
|
|
5810
|
-
version: PgAttr<PgAttr<
|
|
5811
|
-
createdAt: PgAttr<PgAttr<
|
|
5812
|
-
updatedAt: PgAttr<PgAttr<
|
|
5813
|
-
type:
|
|
5814
|
-
template:
|
|
5815
|
-
category:
|
|
5816
|
-
critical:
|
|
5817
|
-
sensitive:
|
|
5818
|
-
contact:
|
|
5819
|
-
variables:
|
|
5820
|
-
scheduledAt:
|
|
5821
|
-
sentAt:
|
|
5822
|
-
error:
|
|
5823
|
-
at:
|
|
5824
|
-
name:
|
|
5825
|
-
message:
|
|
6378
|
+
response: alepha2502.TPage<alepha2502.TObject<{
|
|
6379
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
6380
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
6381
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
6382
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
6383
|
+
type: alepha2502.TUnsafe<"email" | "sms">;
|
|
6384
|
+
template: alepha2502.TString;
|
|
6385
|
+
category: alepha2502.TOptional<alepha2502.TString>;
|
|
6386
|
+
critical: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6387
|
+
sensitive: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6388
|
+
contact: alepha2502.TString;
|
|
6389
|
+
variables: alepha2502.TOptional<alepha2502.TRecord<"^.*$", alepha2502.TAny>>;
|
|
6390
|
+
scheduledAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6391
|
+
sentAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6392
|
+
error: alepha2502.TOptional<alepha2502.TObject<{
|
|
6393
|
+
at: alepha2502.TString;
|
|
6394
|
+
name: alepha2502.TString;
|
|
6395
|
+
message: alepha2502.TString;
|
|
5826
6396
|
}>>;
|
|
5827
6397
|
}>>;
|
|
5828
6398
|
}>;
|
|
5829
6399
|
}
|
|
5830
6400
|
//#endregion
|
|
5831
|
-
//#region ../../../alepha/src/queue/providers/WorkerProvider.d.ts
|
|
5832
|
-
declare const envSchema
|
|
5833
|
-
/**
|
|
5834
|
-
* The timeout in seconds for blocking job acquisition.
|
|
5835
|
-
* Workers will check for shutdown after each timeout period.
|
|
5836
|
-
*/
|
|
5837
|
-
QUEUE_WORKER_BLOCKING_TIMEOUT: alepha1962.TInteger;
|
|
5838
|
-
/**
|
|
5839
|
-
* The number of workers to run concurrently. Defaults to 1.
|
|
5840
|
-
* Useful only if you are doing a lot of I/O.
|
|
5841
|
-
*/
|
|
5842
|
-
QUEUE_WORKER_CONCURRENCY: alepha1962.TInteger;
|
|
6401
|
+
//#region ../../../alepha/src/queue/core/providers/WorkerProvider.d.ts
|
|
6402
|
+
declare const envSchema: alepha2502.TObject<{
|
|
5843
6403
|
/**
|
|
5844
|
-
*
|
|
5845
|
-
* Should be less than the job's lock duration.
|
|
6404
|
+
* The interval in milliseconds to wait before checking for new messages.
|
|
5846
6405
|
*/
|
|
5847
|
-
|
|
6406
|
+
QUEUE_WORKER_INTERVAL: alepha2502.TInteger;
|
|
5848
6407
|
/**
|
|
5849
|
-
*
|
|
6408
|
+
* The maximum interval in milliseconds to wait before checking for new messages.
|
|
5850
6409
|
*/
|
|
5851
|
-
|
|
6410
|
+
QUEUE_WORKER_MAX_INTERVAL: alepha2502.TInteger;
|
|
5852
6411
|
/**
|
|
5853
|
-
*
|
|
6412
|
+
* The number of workers to run concurrently. Defaults to 1.
|
|
6413
|
+
* Useful only if you are doing a lot of I/O.
|
|
5854
6414
|
*/
|
|
5855
|
-
|
|
6415
|
+
QUEUE_WORKER_CONCURRENCY: alepha2502.TInteger;
|
|
5856
6416
|
}>;
|
|
5857
6417
|
declare module "alepha" {
|
|
5858
|
-
interface Env extends Partial<Static<typeof envSchema
|
|
6418
|
+
interface Env extends Partial<Static<typeof envSchema>> {}
|
|
5859
6419
|
}
|
|
5860
6420
|
//#endregion
|
|
5861
|
-
//#region ../../../alepha/src/api
|
|
6421
|
+
//#region ../../../alepha/src/api/parameters/entities/parameters.d.ts
|
|
5862
6422
|
/**
|
|
5863
6423
|
* Parameter status values.
|
|
5864
6424
|
*
|
|
@@ -5877,71 +6437,71 @@ type ParameterStatus = "expired" | "current" | "next" | "future";
|
|
|
5877
6437
|
* - Activation scheduling
|
|
5878
6438
|
* - Audit trail (creator info)
|
|
5879
6439
|
*/
|
|
5880
|
-
declare const parameters: EntityPrimitive<
|
|
5881
|
-
id: PgAttr<PgAttr<
|
|
5882
|
-
createdAt: PgAttr<PgAttr<
|
|
5883
|
-
updatedAt: PgAttr<PgAttr<
|
|
6440
|
+
declare const parameters: EntityPrimitive<alepha2502.TObject<{
|
|
6441
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
6442
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
6443
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
5884
6444
|
/**
|
|
5885
6445
|
* Configuration name using dot notation for tree hierarchy.
|
|
5886
6446
|
* Examples: "app.features", "app.pricing.tiers", "system.limits"
|
|
5887
6447
|
*/
|
|
5888
|
-
name:
|
|
6448
|
+
name: alepha2502.TString;
|
|
5889
6449
|
/**
|
|
5890
6450
|
* The configuration content as JSON.
|
|
5891
6451
|
*/
|
|
5892
|
-
content:
|
|
6452
|
+
content: alepha2502.TRecord<string, alepha2502.TAny>;
|
|
5893
6453
|
/**
|
|
5894
6454
|
* Schema version hash for detecting schema changes.
|
|
5895
6455
|
* Used for auto-migration when schema evolves.
|
|
5896
6456
|
*/
|
|
5897
|
-
schemaHash:
|
|
6457
|
+
schemaHash: alepha2502.TString;
|
|
5898
6458
|
/**
|
|
5899
6459
|
* Current status of this parameter version.
|
|
5900
6460
|
*/
|
|
5901
|
-
status: PgAttr<
|
|
6461
|
+
status: PgAttr<alepha2502.TUnsafe<"expired" | "current" | "next" | "future">, typeof PG_DEFAULT>;
|
|
5902
6462
|
/**
|
|
5903
6463
|
* When this version should become active.
|
|
5904
6464
|
* Default is immediate (now).
|
|
5905
6465
|
*/
|
|
5906
|
-
activationDate:
|
|
6466
|
+
activationDate: alepha2502.TString;
|
|
5907
6467
|
/**
|
|
5908
6468
|
* When this version was deactivated (became expired).
|
|
5909
6469
|
* Null if still active or scheduled.
|
|
5910
6470
|
*/
|
|
5911
|
-
expiredAt:
|
|
6471
|
+
expiredAt: alepha2502.TOptional<alepha2502.TString>;
|
|
5912
6472
|
/**
|
|
5913
6473
|
* Version number for this configuration.
|
|
5914
6474
|
* Auto-incremented per config name.
|
|
5915
6475
|
*/
|
|
5916
|
-
version:
|
|
6476
|
+
version: alepha2502.TInteger;
|
|
5917
6477
|
/**
|
|
5918
6478
|
* Optional description of changes in this version.
|
|
5919
6479
|
*/
|
|
5920
|
-
changeDescription:
|
|
6480
|
+
changeDescription: alepha2502.TOptional<alepha2502.TString>;
|
|
5921
6481
|
/**
|
|
5922
6482
|
* Optional tags for filtering/categorization.
|
|
5923
6483
|
*/
|
|
5924
|
-
tags:
|
|
6484
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
5925
6485
|
/**
|
|
5926
6486
|
* Creator user ID (if available).
|
|
5927
6487
|
*/
|
|
5928
|
-
creatorId:
|
|
6488
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
5929
6489
|
/**
|
|
5930
6490
|
* Creator display name for audit trail.
|
|
5931
6491
|
*/
|
|
5932
|
-
creatorName:
|
|
6492
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
5933
6493
|
/**
|
|
5934
6494
|
* Previous content before this change (for rollback reference).
|
|
5935
6495
|
*/
|
|
5936
|
-
previousContent:
|
|
6496
|
+
previousContent: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
5937
6497
|
/**
|
|
5938
6498
|
* Migration log if schema changed.
|
|
5939
6499
|
*/
|
|
5940
|
-
migrationLog:
|
|
6500
|
+
migrationLog: alepha2502.TOptional<alepha2502.TString>;
|
|
5941
6501
|
}>>;
|
|
5942
6502
|
type Parameter = Static<typeof parameters.schema>;
|
|
5943
6503
|
//#endregion
|
|
5944
|
-
//#region ../../../alepha/src/api
|
|
6504
|
+
//#region ../../../alepha/src/api/parameters/primitives/$config.d.ts
|
|
5945
6505
|
/**
|
|
5946
6506
|
* Creates a versioned configuration primitive for managing application settings.
|
|
5947
6507
|
*
|
|
@@ -6081,7 +6641,7 @@ declare class ConfigPrimitive<T$1 extends TObject> extends Primitive<ConfigPrimi
|
|
|
6081
6641
|
/**
|
|
6082
6642
|
* Hook to load initial value from database on start.
|
|
6083
6643
|
*/
|
|
6084
|
-
protected readonly onStart:
|
|
6644
|
+
protected readonly onStart: alepha2502.HookPrimitive<"start">;
|
|
6085
6645
|
/**
|
|
6086
6646
|
* Called after primitive creation to initialize.
|
|
6087
6647
|
*/
|
|
@@ -6115,7 +6675,7 @@ interface SetConfigOptions {
|
|
|
6115
6675
|
tags?: string[];
|
|
6116
6676
|
}
|
|
6117
6677
|
//#endregion
|
|
6118
|
-
//#region ../../../alepha/src/api
|
|
6678
|
+
//#region ../../../alepha/src/api/parameters/services/ConfigStore.d.ts
|
|
6119
6679
|
/**
|
|
6120
6680
|
* Payload for config sync events across instances.
|
|
6121
6681
|
*/
|
|
@@ -6140,22 +6700,22 @@ declare class ConfigStore {
|
|
|
6140
6700
|
protected readonly log: Logger;
|
|
6141
6701
|
protected readonly dateTimeProvider: DateTimeProvider;
|
|
6142
6702
|
protected readonly repo: Repository<TObject<{
|
|
6143
|
-
id: PgAttr<PgAttr<
|
|
6144
|
-
createdAt: PgAttr<PgAttr<
|
|
6145
|
-
updatedAt: PgAttr<PgAttr<
|
|
6146
|
-
name:
|
|
6147
|
-
content:
|
|
6148
|
-
schemaHash:
|
|
6149
|
-
status: PgAttr<
|
|
6150
|
-
activationDate:
|
|
6151
|
-
expiredAt:
|
|
6152
|
-
version:
|
|
6153
|
-
changeDescription:
|
|
6154
|
-
tags:
|
|
6155
|
-
creatorId:
|
|
6156
|
-
creatorName:
|
|
6157
|
-
previousContent:
|
|
6158
|
-
migrationLog:
|
|
6703
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
6704
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
6705
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
6706
|
+
name: alepha2502.TString;
|
|
6707
|
+
content: alepha2502.TRecord<string, alepha2502.TAny>;
|
|
6708
|
+
schemaHash: alepha2502.TString;
|
|
6709
|
+
status: PgAttr<alepha2502.TUnsafe<"expired" | "current" | "next" | "future">, typeof PG_DEFAULT>;
|
|
6710
|
+
activationDate: alepha2502.TString;
|
|
6711
|
+
expiredAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6712
|
+
version: alepha2502.TInteger;
|
|
6713
|
+
changeDescription: alepha2502.TOptional<alepha2502.TString>;
|
|
6714
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
6715
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
6716
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
6717
|
+
previousContent: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
6718
|
+
migrationLog: alepha2502.TOptional<alepha2502.TString>;
|
|
6159
6719
|
}>>;
|
|
6160
6720
|
/** Unique identifier for this instance (to avoid self-updates) */
|
|
6161
6721
|
protected readonly instanceId: `${string}-${string}-${string}-${string}-${string}`;
|
|
@@ -6164,11 +6724,11 @@ declare class ConfigStore {
|
|
|
6164
6724
|
/** Topic for cross-instance synchronization */
|
|
6165
6725
|
readonly syncTopic: TopicPrimitive<{
|
|
6166
6726
|
payload: TObject<{
|
|
6167
|
-
name:
|
|
6168
|
-
version:
|
|
6169
|
-
content:
|
|
6170
|
-
status:
|
|
6171
|
-
instanceId:
|
|
6727
|
+
name: alepha2502.TString;
|
|
6728
|
+
version: alepha2502.TInteger;
|
|
6729
|
+
content: alepha2502.TRecord<string, alepha2502.TAny>;
|
|
6730
|
+
status: alepha2502.TUnsafe<"expired" | "current" | "next" | "future">;
|
|
6731
|
+
instanceId: alepha2502.TString;
|
|
6172
6732
|
}>;
|
|
6173
6733
|
}>;
|
|
6174
6734
|
/**
|
|
@@ -6272,7 +6832,7 @@ interface ConfigTreeNode {
|
|
|
6272
6832
|
children: ConfigTreeNode[];
|
|
6273
6833
|
}
|
|
6274
6834
|
//#endregion
|
|
6275
|
-
//#region ../../../alepha/src/api
|
|
6835
|
+
//#region ../../../alepha/src/api/parameters/controllers/ConfigController.d.ts
|
|
6276
6836
|
/**
|
|
6277
6837
|
* REST API controller for versioned configuration management.
|
|
6278
6838
|
*
|
|
@@ -6291,41 +6851,41 @@ declare class ConfigController {
|
|
|
6291
6851
|
* Useful for admin UI navigation.
|
|
6292
6852
|
*/
|
|
6293
6853
|
getConfigTree: ActionPrimitiveFn<{
|
|
6294
|
-
response:
|
|
6854
|
+
response: alepha2502.TArray<any>;
|
|
6295
6855
|
}>;
|
|
6296
6856
|
/**
|
|
6297
6857
|
* List all unique configuration names.
|
|
6298
6858
|
*/
|
|
6299
6859
|
listConfigNames: ActionPrimitiveFn<{
|
|
6300
|
-
response:
|
|
6301
|
-
names:
|
|
6860
|
+
response: alepha2502.TObject<{
|
|
6861
|
+
names: alepha2502.TArray<alepha2502.TString>;
|
|
6302
6862
|
}>;
|
|
6303
6863
|
}>;
|
|
6304
6864
|
/**
|
|
6305
6865
|
* Get configurations by status.
|
|
6306
6866
|
*/
|
|
6307
6867
|
getByStatus: ActionPrimitiveFn<{
|
|
6308
|
-
params:
|
|
6309
|
-
status:
|
|
6868
|
+
params: alepha2502.TObject<{
|
|
6869
|
+
status: alepha2502.TUnsafe<"expired" | "current" | "next" | "future">;
|
|
6310
6870
|
}>;
|
|
6311
|
-
response:
|
|
6312
|
-
configs:
|
|
6313
|
-
id:
|
|
6314
|
-
createdAt:
|
|
6315
|
-
updatedAt:
|
|
6316
|
-
name:
|
|
6317
|
-
content:
|
|
6318
|
-
schemaHash:
|
|
6319
|
-
status:
|
|
6320
|
-
activationDate:
|
|
6321
|
-
expiredAt:
|
|
6322
|
-
version:
|
|
6323
|
-
changeDescription:
|
|
6324
|
-
tags:
|
|
6325
|
-
creatorId:
|
|
6326
|
-
creatorName:
|
|
6327
|
-
previousContent:
|
|
6328
|
-
migrationLog:
|
|
6871
|
+
response: alepha2502.TObject<{
|
|
6872
|
+
configs: alepha2502.TArray<alepha2502.TObject<{
|
|
6873
|
+
id: alepha2502.TString;
|
|
6874
|
+
createdAt: alepha2502.TString;
|
|
6875
|
+
updatedAt: alepha2502.TString;
|
|
6876
|
+
name: alepha2502.TString;
|
|
6877
|
+
content: alepha2502.TRecord<string, alepha2502.TAny>;
|
|
6878
|
+
schemaHash: alepha2502.TString;
|
|
6879
|
+
status: alepha2502.TUnsafe<"expired" | "current" | "next" | "future">;
|
|
6880
|
+
activationDate: alepha2502.TString;
|
|
6881
|
+
expiredAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6882
|
+
version: alepha2502.TInteger;
|
|
6883
|
+
changeDescription: alepha2502.TOptional<alepha2502.TString>;
|
|
6884
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
6885
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
6886
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
6887
|
+
previousContent: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
6888
|
+
migrationLog: alepha2502.TOptional<alepha2502.TString>;
|
|
6329
6889
|
}>>;
|
|
6330
6890
|
}>;
|
|
6331
6891
|
}>;
|
|
@@ -6333,27 +6893,27 @@ declare class ConfigController {
|
|
|
6333
6893
|
* Get version history for a specific configuration.
|
|
6334
6894
|
*/
|
|
6335
6895
|
getHistory: ActionPrimitiveFn<{
|
|
6336
|
-
params:
|
|
6337
|
-
name:
|
|
6896
|
+
params: alepha2502.TObject<{
|
|
6897
|
+
name: alepha2502.TString;
|
|
6338
6898
|
}>;
|
|
6339
|
-
response:
|
|
6340
|
-
versions:
|
|
6341
|
-
id:
|
|
6342
|
-
createdAt:
|
|
6343
|
-
updatedAt:
|
|
6344
|
-
name:
|
|
6345
|
-
content:
|
|
6346
|
-
schemaHash:
|
|
6347
|
-
status:
|
|
6348
|
-
activationDate:
|
|
6349
|
-
expiredAt:
|
|
6350
|
-
version:
|
|
6351
|
-
changeDescription:
|
|
6352
|
-
tags:
|
|
6353
|
-
creatorId:
|
|
6354
|
-
creatorName:
|
|
6355
|
-
previousContent:
|
|
6356
|
-
migrationLog:
|
|
6899
|
+
response: alepha2502.TObject<{
|
|
6900
|
+
versions: alepha2502.TArray<alepha2502.TObject<{
|
|
6901
|
+
id: alepha2502.TString;
|
|
6902
|
+
createdAt: alepha2502.TString;
|
|
6903
|
+
updatedAt: alepha2502.TString;
|
|
6904
|
+
name: alepha2502.TString;
|
|
6905
|
+
content: alepha2502.TRecord<string, alepha2502.TAny>;
|
|
6906
|
+
schemaHash: alepha2502.TString;
|
|
6907
|
+
status: alepha2502.TUnsafe<"expired" | "current" | "next" | "future">;
|
|
6908
|
+
activationDate: alepha2502.TString;
|
|
6909
|
+
expiredAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6910
|
+
version: alepha2502.TInteger;
|
|
6911
|
+
changeDescription: alepha2502.TOptional<alepha2502.TString>;
|
|
6912
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
6913
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
6914
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
6915
|
+
previousContent: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
6916
|
+
migrationLog: alepha2502.TOptional<alepha2502.TString>;
|
|
6357
6917
|
}>>;
|
|
6358
6918
|
}>;
|
|
6359
6919
|
}>;
|
|
@@ -6363,77 +6923,77 @@ declare class ConfigController {
|
|
|
6363
6923
|
* even if no versions exist in the database yet.
|
|
6364
6924
|
*/
|
|
6365
6925
|
getCurrent: ActionPrimitiveFn<{
|
|
6366
|
-
params:
|
|
6367
|
-
name:
|
|
6926
|
+
params: alepha2502.TObject<{
|
|
6927
|
+
name: alepha2502.TString;
|
|
6368
6928
|
}>;
|
|
6369
|
-
response:
|
|
6370
|
-
current:
|
|
6371
|
-
id:
|
|
6372
|
-
createdAt:
|
|
6373
|
-
updatedAt:
|
|
6374
|
-
name:
|
|
6375
|
-
content:
|
|
6376
|
-
schemaHash:
|
|
6377
|
-
status:
|
|
6378
|
-
activationDate:
|
|
6379
|
-
expiredAt:
|
|
6380
|
-
version:
|
|
6381
|
-
changeDescription:
|
|
6382
|
-
tags:
|
|
6383
|
-
creatorId:
|
|
6384
|
-
creatorName:
|
|
6385
|
-
previousContent:
|
|
6386
|
-
migrationLog:
|
|
6929
|
+
response: alepha2502.TObject<{
|
|
6930
|
+
current: alepha2502.TOptional<alepha2502.TObject<{
|
|
6931
|
+
id: alepha2502.TString;
|
|
6932
|
+
createdAt: alepha2502.TString;
|
|
6933
|
+
updatedAt: alepha2502.TString;
|
|
6934
|
+
name: alepha2502.TString;
|
|
6935
|
+
content: alepha2502.TRecord<string, alepha2502.TAny>;
|
|
6936
|
+
schemaHash: alepha2502.TString;
|
|
6937
|
+
status: alepha2502.TUnsafe<"expired" | "current" | "next" | "future">;
|
|
6938
|
+
activationDate: alepha2502.TString;
|
|
6939
|
+
expiredAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6940
|
+
version: alepha2502.TInteger;
|
|
6941
|
+
changeDescription: alepha2502.TOptional<alepha2502.TString>;
|
|
6942
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
6943
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
6944
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
6945
|
+
previousContent: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
6946
|
+
migrationLog: alepha2502.TOptional<alepha2502.TString>;
|
|
6387
6947
|
}>>;
|
|
6388
|
-
next:
|
|
6389
|
-
id:
|
|
6390
|
-
createdAt:
|
|
6391
|
-
updatedAt:
|
|
6392
|
-
name:
|
|
6393
|
-
content:
|
|
6394
|
-
schemaHash:
|
|
6395
|
-
status:
|
|
6396
|
-
activationDate:
|
|
6397
|
-
expiredAt:
|
|
6398
|
-
version:
|
|
6399
|
-
changeDescription:
|
|
6400
|
-
tags:
|
|
6401
|
-
creatorId:
|
|
6402
|
-
creatorName:
|
|
6403
|
-
previousContent:
|
|
6404
|
-
migrationLog:
|
|
6948
|
+
next: alepha2502.TOptional<alepha2502.TObject<{
|
|
6949
|
+
id: alepha2502.TString;
|
|
6950
|
+
createdAt: alepha2502.TString;
|
|
6951
|
+
updatedAt: alepha2502.TString;
|
|
6952
|
+
name: alepha2502.TString;
|
|
6953
|
+
content: alepha2502.TRecord<string, alepha2502.TAny>;
|
|
6954
|
+
schemaHash: alepha2502.TString;
|
|
6955
|
+
status: alepha2502.TUnsafe<"expired" | "current" | "next" | "future">;
|
|
6956
|
+
activationDate: alepha2502.TString;
|
|
6957
|
+
expiredAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6958
|
+
version: alepha2502.TInteger;
|
|
6959
|
+
changeDescription: alepha2502.TOptional<alepha2502.TString>;
|
|
6960
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
6961
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
6962
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
6963
|
+
previousContent: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
6964
|
+
migrationLog: alepha2502.TOptional<alepha2502.TString>;
|
|
6405
6965
|
}>>;
|
|
6406
|
-
defaultValue:
|
|
6407
|
-
currentValue:
|
|
6408
|
-
schema:
|
|
6966
|
+
defaultValue: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
6967
|
+
currentValue: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
6968
|
+
schema: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
6409
6969
|
}>;
|
|
6410
6970
|
}>;
|
|
6411
6971
|
/**
|
|
6412
6972
|
* Get a specific version of a configuration.
|
|
6413
6973
|
*/
|
|
6414
6974
|
getVersion: ActionPrimitiveFn<{
|
|
6415
|
-
params:
|
|
6416
|
-
name:
|
|
6417
|
-
version:
|
|
6975
|
+
params: alepha2502.TObject<{
|
|
6976
|
+
name: alepha2502.TString;
|
|
6977
|
+
version: alepha2502.TInteger;
|
|
6418
6978
|
}>;
|
|
6419
|
-
response:
|
|
6420
|
-
config:
|
|
6421
|
-
id:
|
|
6422
|
-
createdAt:
|
|
6423
|
-
updatedAt:
|
|
6424
|
-
name:
|
|
6425
|
-
content:
|
|
6426
|
-
schemaHash:
|
|
6427
|
-
status:
|
|
6428
|
-
activationDate:
|
|
6429
|
-
expiredAt:
|
|
6430
|
-
version:
|
|
6431
|
-
changeDescription:
|
|
6432
|
-
tags:
|
|
6433
|
-
creatorId:
|
|
6434
|
-
creatorName:
|
|
6435
|
-
previousContent:
|
|
6436
|
-
migrationLog:
|
|
6979
|
+
response: alepha2502.TObject<{
|
|
6980
|
+
config: alepha2502.TOptional<alepha2502.TObject<{
|
|
6981
|
+
id: alepha2502.TString;
|
|
6982
|
+
createdAt: alepha2502.TString;
|
|
6983
|
+
updatedAt: alepha2502.TString;
|
|
6984
|
+
name: alepha2502.TString;
|
|
6985
|
+
content: alepha2502.TRecord<string, alepha2502.TAny>;
|
|
6986
|
+
schemaHash: alepha2502.TString;
|
|
6987
|
+
status: alepha2502.TUnsafe<"expired" | "current" | "next" | "future">;
|
|
6988
|
+
activationDate: alepha2502.TString;
|
|
6989
|
+
expiredAt: alepha2502.TOptional<alepha2502.TString>;
|
|
6990
|
+
version: alepha2502.TInteger;
|
|
6991
|
+
changeDescription: alepha2502.TOptional<alepha2502.TString>;
|
|
6992
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
6993
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
6994
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
6995
|
+
previousContent: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
6996
|
+
migrationLog: alepha2502.TOptional<alepha2502.TString>;
|
|
6437
6997
|
}>>;
|
|
6438
6998
|
}>;
|
|
6439
6999
|
}>;
|
|
@@ -6441,98 +7001,98 @@ declare class ConfigController {
|
|
|
6441
7001
|
* Create a new configuration version.
|
|
6442
7002
|
*/
|
|
6443
7003
|
createVersion: ActionPrimitiveFn<{
|
|
6444
|
-
params:
|
|
6445
|
-
name:
|
|
7004
|
+
params: alepha2502.TObject<{
|
|
7005
|
+
name: alepha2502.TString;
|
|
6446
7006
|
}>;
|
|
6447
|
-
body:
|
|
6448
|
-
content:
|
|
6449
|
-
schemaHash:
|
|
6450
|
-
activationDate:
|
|
6451
|
-
changeDescription:
|
|
6452
|
-
tags:
|
|
6453
|
-
creatorId:
|
|
6454
|
-
creatorName:
|
|
7007
|
+
body: alepha2502.TObject<{
|
|
7008
|
+
content: alepha2502.TRecord<string, alepha2502.TAny>;
|
|
7009
|
+
schemaHash: alepha2502.TString;
|
|
7010
|
+
activationDate: alepha2502.TOptional<alepha2502.TString>;
|
|
7011
|
+
changeDescription: alepha2502.TOptional<alepha2502.TString>;
|
|
7012
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
7013
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
7014
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
6455
7015
|
}>;
|
|
6456
|
-
response:
|
|
6457
|
-
id:
|
|
6458
|
-
createdAt:
|
|
6459
|
-
updatedAt:
|
|
6460
|
-
name:
|
|
6461
|
-
content:
|
|
6462
|
-
schemaHash:
|
|
6463
|
-
status:
|
|
6464
|
-
activationDate:
|
|
6465
|
-
expiredAt:
|
|
6466
|
-
version:
|
|
6467
|
-
changeDescription:
|
|
6468
|
-
tags:
|
|
6469
|
-
creatorId:
|
|
6470
|
-
creatorName:
|
|
6471
|
-
previousContent:
|
|
6472
|
-
migrationLog:
|
|
7016
|
+
response: alepha2502.TObject<{
|
|
7017
|
+
id: alepha2502.TString;
|
|
7018
|
+
createdAt: alepha2502.TString;
|
|
7019
|
+
updatedAt: alepha2502.TString;
|
|
7020
|
+
name: alepha2502.TString;
|
|
7021
|
+
content: alepha2502.TRecord<string, alepha2502.TAny>;
|
|
7022
|
+
schemaHash: alepha2502.TString;
|
|
7023
|
+
status: alepha2502.TUnsafe<"expired" | "current" | "next" | "future">;
|
|
7024
|
+
activationDate: alepha2502.TString;
|
|
7025
|
+
expiredAt: alepha2502.TOptional<alepha2502.TString>;
|
|
7026
|
+
version: alepha2502.TInteger;
|
|
7027
|
+
changeDescription: alepha2502.TOptional<alepha2502.TString>;
|
|
7028
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
7029
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
7030
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
7031
|
+
previousContent: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
7032
|
+
migrationLog: alepha2502.TOptional<alepha2502.TString>;
|
|
6473
7033
|
}>;
|
|
6474
7034
|
}>;
|
|
6475
7035
|
/**
|
|
6476
7036
|
* Rollback to a previous version.
|
|
6477
7037
|
*/
|
|
6478
7038
|
rollback: ActionPrimitiveFn<{
|
|
6479
|
-
params:
|
|
6480
|
-
name:
|
|
7039
|
+
params: alepha2502.TObject<{
|
|
7040
|
+
name: alepha2502.TString;
|
|
6481
7041
|
}>;
|
|
6482
|
-
body:
|
|
6483
|
-
targetVersion:
|
|
6484
|
-
changeDescription:
|
|
6485
|
-
creatorId:
|
|
6486
|
-
creatorName:
|
|
7042
|
+
body: alepha2502.TObject<{
|
|
7043
|
+
targetVersion: alepha2502.TInteger;
|
|
7044
|
+
changeDescription: alepha2502.TOptional<alepha2502.TString>;
|
|
7045
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
7046
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
6487
7047
|
}>;
|
|
6488
|
-
response:
|
|
6489
|
-
id:
|
|
6490
|
-
createdAt:
|
|
6491
|
-
updatedAt:
|
|
6492
|
-
name:
|
|
6493
|
-
content:
|
|
6494
|
-
schemaHash:
|
|
6495
|
-
status:
|
|
6496
|
-
activationDate:
|
|
6497
|
-
expiredAt:
|
|
6498
|
-
version:
|
|
6499
|
-
changeDescription:
|
|
6500
|
-
tags:
|
|
6501
|
-
creatorId:
|
|
6502
|
-
creatorName:
|
|
6503
|
-
previousContent:
|
|
6504
|
-
migrationLog:
|
|
7048
|
+
response: alepha2502.TObject<{
|
|
7049
|
+
id: alepha2502.TString;
|
|
7050
|
+
createdAt: alepha2502.TString;
|
|
7051
|
+
updatedAt: alepha2502.TString;
|
|
7052
|
+
name: alepha2502.TString;
|
|
7053
|
+
content: alepha2502.TRecord<string, alepha2502.TAny>;
|
|
7054
|
+
schemaHash: alepha2502.TString;
|
|
7055
|
+
status: alepha2502.TUnsafe<"expired" | "current" | "next" | "future">;
|
|
7056
|
+
activationDate: alepha2502.TString;
|
|
7057
|
+
expiredAt: alepha2502.TOptional<alepha2502.TString>;
|
|
7058
|
+
version: alepha2502.TInteger;
|
|
7059
|
+
changeDescription: alepha2502.TOptional<alepha2502.TString>;
|
|
7060
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
7061
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
7062
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
7063
|
+
previousContent: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
7064
|
+
migrationLog: alepha2502.TOptional<alepha2502.TString>;
|
|
6505
7065
|
}>;
|
|
6506
7066
|
}>;
|
|
6507
7067
|
/**
|
|
6508
7068
|
* Activate a scheduled version immediately.
|
|
6509
7069
|
*/
|
|
6510
7070
|
activateNow: ActionPrimitiveFn<{
|
|
6511
|
-
params:
|
|
6512
|
-
name:
|
|
7071
|
+
params: alepha2502.TObject<{
|
|
7072
|
+
name: alepha2502.TString;
|
|
6513
7073
|
}>;
|
|
6514
|
-
body:
|
|
6515
|
-
version:
|
|
6516
|
-
creatorId:
|
|
6517
|
-
creatorName:
|
|
7074
|
+
body: alepha2502.TObject<{
|
|
7075
|
+
version: alepha2502.TInteger;
|
|
7076
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
7077
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
6518
7078
|
}>;
|
|
6519
|
-
response:
|
|
6520
|
-
id:
|
|
6521
|
-
createdAt:
|
|
6522
|
-
updatedAt:
|
|
6523
|
-
name:
|
|
6524
|
-
content:
|
|
6525
|
-
schemaHash:
|
|
6526
|
-
status:
|
|
6527
|
-
activationDate:
|
|
6528
|
-
expiredAt:
|
|
6529
|
-
version:
|
|
6530
|
-
changeDescription:
|
|
6531
|
-
tags:
|
|
6532
|
-
creatorId:
|
|
6533
|
-
creatorName:
|
|
6534
|
-
previousContent:
|
|
6535
|
-
migrationLog:
|
|
7079
|
+
response: alepha2502.TObject<{
|
|
7080
|
+
id: alepha2502.TString;
|
|
7081
|
+
createdAt: alepha2502.TString;
|
|
7082
|
+
updatedAt: alepha2502.TString;
|
|
7083
|
+
name: alepha2502.TString;
|
|
7084
|
+
content: alepha2502.TRecord<string, alepha2502.TAny>;
|
|
7085
|
+
schemaHash: alepha2502.TString;
|
|
7086
|
+
status: alepha2502.TUnsafe<"expired" | "current" | "next" | "future">;
|
|
7087
|
+
activationDate: alepha2502.TString;
|
|
7088
|
+
expiredAt: alepha2502.TOptional<alepha2502.TString>;
|
|
7089
|
+
version: alepha2502.TInteger;
|
|
7090
|
+
changeDescription: alepha2502.TOptional<alepha2502.TString>;
|
|
7091
|
+
tags: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
7092
|
+
creatorId: alepha2502.TOptional<alepha2502.TString>;
|
|
7093
|
+
creatorName: alepha2502.TOptional<alepha2502.TString>;
|
|
7094
|
+
previousContent: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
7095
|
+
migrationLog: alepha2502.TOptional<alepha2502.TString>;
|
|
6536
7096
|
}>;
|
|
6537
7097
|
}>;
|
|
6538
7098
|
/**
|
|
@@ -6540,128 +7100,125 @@ declare class ConfigController {
|
|
|
6540
7100
|
* Normally called by a scheduler, but exposed for manual triggering.
|
|
6541
7101
|
*/
|
|
6542
7102
|
checkScheduled: ActionPrimitiveFn<{
|
|
6543
|
-
response:
|
|
6544
|
-
message:
|
|
7103
|
+
response: alepha2502.TObject<{
|
|
7104
|
+
message: alepha2502.TString;
|
|
6545
7105
|
}>;
|
|
6546
7106
|
}>;
|
|
6547
7107
|
}
|
|
6548
7108
|
//#endregion
|
|
6549
|
-
//#region ../../../alepha/src/
|
|
6550
|
-
declare const
|
|
6551
|
-
|
|
6552
|
-
|
|
6553
|
-
|
|
6554
|
-
|
|
6555
|
-
|
|
6556
|
-
|
|
6557
|
-
|
|
6558
|
-
|
|
6559
|
-
|
|
6560
|
-
|
|
6561
|
-
|
|
6562
|
-
|
|
6563
|
-
|
|
6564
|
-
|
|
6565
|
-
|
|
6566
|
-
|
|
6567
|
-
|
|
6568
|
-
|
|
6569
|
-
|
|
6570
|
-
|
|
6571
|
-
|
|
6572
|
-
context: string;
|
|
6573
|
-
};
|
|
6574
|
-
"scheduler:end": {
|
|
6575
|
-
name: string;
|
|
6576
|
-
context: string;
|
|
6577
|
-
};
|
|
6578
|
-
}
|
|
6579
|
-
}
|
|
6580
|
-
/**
|
|
6581
|
-
* Generic interface for scheduling tasks.
|
|
6582
|
-
*
|
|
6583
|
-
* @see {@link $scheduler}
|
|
6584
|
-
* @module alepha.scheduler
|
|
6585
|
-
*/
|
|
6586
|
-
//#endregion
|
|
6587
|
-
//#region ../../../alepha/src/api-users/atoms/realmAuthSettingsAtom.d.ts
|
|
6588
|
-
declare const realmAuthSettingsAtom: alepha1962.Atom<alepha1962.TObject<{
|
|
6589
|
-
displayName: alepha1962.TOptional<alepha1962.TString>;
|
|
6590
|
-
description: alepha1962.TOptional<alepha1962.TString>;
|
|
6591
|
-
logoUrl: alepha1962.TOptional<alepha1962.TString>;
|
|
6592
|
-
registrationAllowed: alepha1962.TBoolean;
|
|
6593
|
-
emailEnabled: alepha1962.TBoolean;
|
|
6594
|
-
emailRequired: alepha1962.TBoolean;
|
|
6595
|
-
usernameEnabled: alepha1962.TBoolean;
|
|
6596
|
-
usernameRequired: alepha1962.TBoolean;
|
|
6597
|
-
phoneEnabled: alepha1962.TBoolean;
|
|
6598
|
-
phoneRequired: alepha1962.TBoolean;
|
|
6599
|
-
verifyEmailRequired: alepha1962.TBoolean;
|
|
6600
|
-
verifyPhoneRequired: alepha1962.TBoolean;
|
|
6601
|
-
firstNameLastNameEnabled: alepha1962.TBoolean;
|
|
6602
|
-
firstNameLastNameRequired: alepha1962.TBoolean;
|
|
6603
|
-
resetPasswordAllowed: alepha1962.TBoolean;
|
|
6604
|
-
passwordPolicy: alepha1962.TObject<{
|
|
6605
|
-
minLength: alepha1962.TInteger;
|
|
6606
|
-
requireUppercase: alepha1962.TBoolean;
|
|
6607
|
-
requireLowercase: alepha1962.TBoolean;
|
|
6608
|
-
requireNumbers: alepha1962.TBoolean;
|
|
6609
|
-
requireSpecialCharacters: alepha1962.TBoolean;
|
|
7109
|
+
//#region ../../../alepha/src/api/users/atoms/realmAuthSettingsAtom.d.ts
|
|
7110
|
+
declare const realmAuthSettingsAtom: alepha2502.Atom<alepha2502.TObject<{
|
|
7111
|
+
displayName: alepha2502.TOptional<alepha2502.TString>;
|
|
7112
|
+
description: alepha2502.TOptional<alepha2502.TString>;
|
|
7113
|
+
logoUrl: alepha2502.TOptional<alepha2502.TString>;
|
|
7114
|
+
registrationAllowed: alepha2502.TBoolean;
|
|
7115
|
+
emailEnabled: alepha2502.TBoolean;
|
|
7116
|
+
emailRequired: alepha2502.TBoolean;
|
|
7117
|
+
usernameEnabled: alepha2502.TBoolean;
|
|
7118
|
+
usernameRequired: alepha2502.TBoolean;
|
|
7119
|
+
phoneEnabled: alepha2502.TBoolean;
|
|
7120
|
+
phoneRequired: alepha2502.TBoolean;
|
|
7121
|
+
verifyEmailRequired: alepha2502.TBoolean;
|
|
7122
|
+
verifyPhoneRequired: alepha2502.TBoolean;
|
|
7123
|
+
firstNameLastNameEnabled: alepha2502.TBoolean;
|
|
7124
|
+
firstNameLastNameRequired: alepha2502.TBoolean;
|
|
7125
|
+
resetPasswordAllowed: alepha2502.TBoolean;
|
|
7126
|
+
passwordPolicy: alepha2502.TObject<{
|
|
7127
|
+
minLength: alepha2502.TInteger;
|
|
7128
|
+
requireUppercase: alepha2502.TBoolean;
|
|
7129
|
+
requireLowercase: alepha2502.TBoolean;
|
|
7130
|
+
requireNumbers: alepha2502.TBoolean;
|
|
7131
|
+
requireSpecialCharacters: alepha2502.TBoolean;
|
|
6610
7132
|
}>;
|
|
6611
7133
|
}>, "alepha.api.users.realmAuthSettings">;
|
|
6612
7134
|
type RealmAuthSettings = Static<typeof realmAuthSettingsAtom.schema>;
|
|
6613
7135
|
//#endregion
|
|
6614
|
-
//#region ../../../alepha/src/api
|
|
6615
|
-
declare const identities: EntityPrimitive<
|
|
6616
|
-
id: PgAttr<PgAttr<
|
|
6617
|
-
version: PgAttr<PgAttr<
|
|
6618
|
-
createdAt: PgAttr<PgAttr<
|
|
6619
|
-
updatedAt: PgAttr<PgAttr<
|
|
6620
|
-
userId: PgAttr<
|
|
6621
|
-
password:
|
|
6622
|
-
provider:
|
|
6623
|
-
providerUserId:
|
|
6624
|
-
providerData:
|
|
7136
|
+
//#region ../../../alepha/src/api/users/entities/identities.d.ts
|
|
7137
|
+
declare const identities: EntityPrimitive<alepha2502.TObject<{
|
|
7138
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7139
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7140
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7141
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7142
|
+
userId: PgAttr<alepha2502.TString, typeof PG_REF>;
|
|
7143
|
+
password: alepha2502.TOptional<alepha2502.TString>;
|
|
7144
|
+
provider: alepha2502.TString;
|
|
7145
|
+
providerUserId: alepha2502.TOptional<alepha2502.TString>;
|
|
7146
|
+
providerData: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
6625
7147
|
}>>;
|
|
6626
7148
|
//#endregion
|
|
6627
|
-
//#region ../../../alepha/src/api
|
|
6628
|
-
declare const sessions: EntityPrimitive<
|
|
6629
|
-
id: PgAttr<PgAttr<
|
|
6630
|
-
version: PgAttr<PgAttr<
|
|
6631
|
-
createdAt: PgAttr<PgAttr<
|
|
6632
|
-
updatedAt: PgAttr<PgAttr<
|
|
6633
|
-
refreshToken:
|
|
6634
|
-
userId: PgAttr<
|
|
6635
|
-
expiresAt:
|
|
6636
|
-
ip:
|
|
6637
|
-
userAgent:
|
|
6638
|
-
os:
|
|
6639
|
-
browser:
|
|
6640
|
-
device:
|
|
7149
|
+
//#region ../../../alepha/src/api/users/entities/sessions.d.ts
|
|
7150
|
+
declare const sessions: EntityPrimitive<alepha2502.TObject<{
|
|
7151
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7152
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7153
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7154
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7155
|
+
refreshToken: alepha2502.TString;
|
|
7156
|
+
userId: PgAttr<alepha2502.TString, typeof PG_REF>;
|
|
7157
|
+
expiresAt: alepha2502.TString;
|
|
7158
|
+
ip: alepha2502.TOptional<alepha2502.TString>;
|
|
7159
|
+
userAgent: alepha2502.TOptional<alepha2502.TObject<{
|
|
7160
|
+
os: alepha2502.TString;
|
|
7161
|
+
browser: alepha2502.TString;
|
|
7162
|
+
device: alepha2502.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
|
|
6641
7163
|
}>>;
|
|
6642
7164
|
}>>;
|
|
6643
7165
|
type SessionEntity = Static<typeof sessions.schema>;
|
|
6644
7166
|
//#endregion
|
|
6645
|
-
//#region ../../../alepha/src/api
|
|
6646
|
-
declare const users: EntityPrimitive<
|
|
6647
|
-
id: PgAttr<PgAttr<
|
|
6648
|
-
version: PgAttr<PgAttr<
|
|
6649
|
-
createdAt: PgAttr<PgAttr<
|
|
6650
|
-
updatedAt: PgAttr<PgAttr<
|
|
6651
|
-
realm: PgAttr<
|
|
6652
|
-
username:
|
|
6653
|
-
email:
|
|
6654
|
-
phoneNumber:
|
|
6655
|
-
roles: PgAttr<
|
|
6656
|
-
firstName:
|
|
6657
|
-
lastName:
|
|
6658
|
-
picture:
|
|
6659
|
-
enabled: PgAttr<
|
|
6660
|
-
emailVerified: PgAttr<
|
|
7167
|
+
//#region ../../../alepha/src/api/users/entities/users.d.ts
|
|
7168
|
+
declare const users: EntityPrimitive<alepha2502.TObject<{
|
|
7169
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7170
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7171
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7172
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7173
|
+
realm: PgAttr<alepha2502.TString, typeof PG_DEFAULT>;
|
|
7174
|
+
username: alepha2502.TOptional<alepha2502.TString>;
|
|
7175
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
7176
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TString>;
|
|
7177
|
+
roles: PgAttr<alepha2502.TArray<alepha2502.TString>, typeof PG_DEFAULT>;
|
|
7178
|
+
firstName: alepha2502.TOptional<alepha2502.TString>;
|
|
7179
|
+
lastName: alepha2502.TOptional<alepha2502.TString>;
|
|
7180
|
+
picture: alepha2502.TOptional<alepha2502.TString>;
|
|
7181
|
+
enabled: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
7182
|
+
emailVerified: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
6661
7183
|
}>>;
|
|
6662
7184
|
type UserEntity = Static<typeof users.schema>;
|
|
6663
7185
|
//#endregion
|
|
6664
|
-
//#region ../../../alepha/src/api
|
|
7186
|
+
//#region ../../../alepha/src/api/users/primitives/$userRealm.d.ts
|
|
7187
|
+
interface UserRealmOptions {
|
|
7188
|
+
/**
|
|
7189
|
+
* Secret key for signing tokens.
|
|
7190
|
+
*
|
|
7191
|
+
* If not provided, the secret from the SecurityProvider will be used (usually from the APP_SECRET environment variable).
|
|
7192
|
+
*/
|
|
7193
|
+
secret?: string;
|
|
7194
|
+
/**
|
|
7195
|
+
* Realm configuration options.
|
|
7196
|
+
*
|
|
7197
|
+
* It's already pre-configured for user management with admin and user roles.
|
|
7198
|
+
*/
|
|
7199
|
+
realm?: Partial<RealmPrimitiveOptions>;
|
|
7200
|
+
/**
|
|
7201
|
+
* Override entities.
|
|
7202
|
+
*/
|
|
7203
|
+
entities?: {
|
|
7204
|
+
users?: Repository<typeof users.schema>;
|
|
7205
|
+
identities?: Repository<typeof identities.schema>;
|
|
7206
|
+
sessions?: Repository<typeof sessions.schema>;
|
|
7207
|
+
};
|
|
7208
|
+
settings?: Partial<RealmAuthSettings>;
|
|
7209
|
+
identities?: {
|
|
7210
|
+
credentials?: true;
|
|
7211
|
+
google?: true;
|
|
7212
|
+
github?: true;
|
|
7213
|
+
};
|
|
7214
|
+
modules?: {
|
|
7215
|
+
files?: boolean;
|
|
7216
|
+
audits?: boolean;
|
|
7217
|
+
jobs?: boolean;
|
|
7218
|
+
};
|
|
7219
|
+
}
|
|
7220
|
+
//#endregion
|
|
7221
|
+
//#region ../../../alepha/src/api/users/providers/UserRealmProvider.d.ts
|
|
6665
7222
|
interface UserRealmRepositories {
|
|
6666
7223
|
identities: Repository<typeof identities.schema>;
|
|
6667
7224
|
sessions: Repository<typeof sessions.schema>;
|
|
@@ -6674,51 +7231,51 @@ interface UserRealm {
|
|
|
6674
7231
|
}
|
|
6675
7232
|
declare class UserRealmProvider {
|
|
6676
7233
|
protected readonly alepha: Alepha;
|
|
6677
|
-
protected readonly defaultIdentities: Repository<
|
|
6678
|
-
id: PgAttr<PgAttr<
|
|
6679
|
-
version: PgAttr<PgAttr<
|
|
6680
|
-
createdAt: PgAttr<PgAttr<
|
|
6681
|
-
updatedAt: PgAttr<PgAttr<
|
|
6682
|
-
userId: PgAttr<
|
|
6683
|
-
password:
|
|
6684
|
-
provider:
|
|
6685
|
-
providerUserId:
|
|
6686
|
-
providerData:
|
|
7234
|
+
protected readonly defaultIdentities: Repository<alepha2502.TObject<{
|
|
7235
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7236
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7237
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7238
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7239
|
+
userId: PgAttr<alepha2502.TString, typeof PG_REF>;
|
|
7240
|
+
password: alepha2502.TOptional<alepha2502.TString>;
|
|
7241
|
+
provider: alepha2502.TString;
|
|
7242
|
+
providerUserId: alepha2502.TOptional<alepha2502.TString>;
|
|
7243
|
+
providerData: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
6687
7244
|
}>>;
|
|
6688
|
-
protected readonly defaultSessions: Repository<
|
|
6689
|
-
id: PgAttr<PgAttr<
|
|
6690
|
-
version: PgAttr<PgAttr<
|
|
6691
|
-
createdAt: PgAttr<PgAttr<
|
|
6692
|
-
updatedAt: PgAttr<PgAttr<
|
|
6693
|
-
refreshToken:
|
|
6694
|
-
userId: PgAttr<
|
|
6695
|
-
expiresAt:
|
|
6696
|
-
ip:
|
|
6697
|
-
userAgent:
|
|
6698
|
-
os:
|
|
6699
|
-
browser:
|
|
6700
|
-
device:
|
|
7245
|
+
protected readonly defaultSessions: Repository<alepha2502.TObject<{
|
|
7246
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7247
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7248
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7249
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7250
|
+
refreshToken: alepha2502.TString;
|
|
7251
|
+
userId: PgAttr<alepha2502.TString, typeof PG_REF>;
|
|
7252
|
+
expiresAt: alepha2502.TString;
|
|
7253
|
+
ip: alepha2502.TOptional<alepha2502.TString>;
|
|
7254
|
+
userAgent: alepha2502.TOptional<alepha2502.TObject<{
|
|
7255
|
+
os: alepha2502.TString;
|
|
7256
|
+
browser: alepha2502.TString;
|
|
7257
|
+
device: alepha2502.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
|
|
6701
7258
|
}>>;
|
|
6702
7259
|
}>>;
|
|
6703
|
-
protected readonly defaultUsers: Repository<
|
|
6704
|
-
id: PgAttr<PgAttr<
|
|
6705
|
-
version: PgAttr<PgAttr<
|
|
6706
|
-
createdAt: PgAttr<PgAttr<
|
|
6707
|
-
updatedAt: PgAttr<PgAttr<
|
|
6708
|
-
realm: PgAttr<
|
|
6709
|
-
username:
|
|
6710
|
-
email:
|
|
6711
|
-
phoneNumber:
|
|
6712
|
-
roles: PgAttr<
|
|
6713
|
-
firstName:
|
|
6714
|
-
lastName:
|
|
6715
|
-
picture:
|
|
6716
|
-
enabled: PgAttr<
|
|
6717
|
-
emailVerified: PgAttr<
|
|
7260
|
+
protected readonly defaultUsers: Repository<alepha2502.TObject<{
|
|
7261
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7262
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7263
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7264
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7265
|
+
realm: PgAttr<alepha2502.TString, typeof PG_DEFAULT>;
|
|
7266
|
+
username: alepha2502.TOptional<alepha2502.TString>;
|
|
7267
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
7268
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TString>;
|
|
7269
|
+
roles: PgAttr<alepha2502.TArray<alepha2502.TString>, typeof PG_DEFAULT>;
|
|
7270
|
+
firstName: alepha2502.TOptional<alepha2502.TString>;
|
|
7271
|
+
lastName: alepha2502.TOptional<alepha2502.TString>;
|
|
7272
|
+
picture: alepha2502.TOptional<alepha2502.TString>;
|
|
7273
|
+
enabled: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
7274
|
+
emailVerified: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
6718
7275
|
}>>;
|
|
6719
7276
|
protected realms: Map<string, UserRealm>;
|
|
6720
7277
|
avatars: BucketPrimitive;
|
|
6721
|
-
protected readonly onConfigure:
|
|
7278
|
+
protected readonly onConfigure: alepha2502.HookPrimitive<"configure">;
|
|
6722
7279
|
register(userRealmName: string, userRealmOptions?: UserRealmOptions): UserRealm;
|
|
6723
7280
|
/**
|
|
6724
7281
|
* Gets a registered realm by name, auto-creating default if needed.
|
|
@@ -6729,32 +7286,32 @@ declare class UserRealmProvider {
|
|
|
6729
7286
|
userRepository(userRealmName?: string): Repository<typeof users.schema>;
|
|
6730
7287
|
}
|
|
6731
7288
|
//#endregion
|
|
6732
|
-
//#region ../../../alepha/src/api
|
|
6733
|
-
declare const sessionQuerySchema:
|
|
6734
|
-
page:
|
|
6735
|
-
size:
|
|
6736
|
-
sort:
|
|
6737
|
-
userId:
|
|
7289
|
+
//#region ../../../alepha/src/api/users/schemas/sessionQuerySchema.d.ts
|
|
7290
|
+
declare const sessionQuerySchema: alepha2502.TObject<{
|
|
7291
|
+
page: alepha2502.TOptional<alepha2502.TInteger>;
|
|
7292
|
+
size: alepha2502.TOptional<alepha2502.TInteger>;
|
|
7293
|
+
sort: alepha2502.TOptional<alepha2502.TString>;
|
|
7294
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
6738
7295
|
}>;
|
|
6739
7296
|
type SessionQuery = Static<typeof sessionQuerySchema>;
|
|
6740
7297
|
//#endregion
|
|
6741
|
-
//#region ../../../alepha/src/api
|
|
7298
|
+
//#region ../../../alepha/src/api/users/services/SessionCrudService.d.ts
|
|
6742
7299
|
declare class SessionCrudService {
|
|
6743
7300
|
protected readonly log: Logger;
|
|
6744
7301
|
protected readonly userRealmProvider: UserRealmProvider;
|
|
6745
|
-
sessions(userRealmName?: string): Repository<
|
|
6746
|
-
id: PgAttr<PgAttr<
|
|
6747
|
-
version: PgAttr<PgAttr<
|
|
6748
|
-
createdAt: PgAttr<PgAttr<
|
|
6749
|
-
updatedAt: PgAttr<PgAttr<
|
|
6750
|
-
refreshToken:
|
|
6751
|
-
userId: PgAttr<
|
|
6752
|
-
expiresAt:
|
|
6753
|
-
ip:
|
|
6754
|
-
userAgent:
|
|
6755
|
-
os:
|
|
6756
|
-
browser:
|
|
6757
|
-
device:
|
|
7302
|
+
sessions(userRealmName?: string): Repository<alepha2502.TObject<{
|
|
7303
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7304
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7305
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7306
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7307
|
+
refreshToken: alepha2502.TString;
|
|
7308
|
+
userId: PgAttr<alepha2502.TString, typeof PG_REF>;
|
|
7309
|
+
expiresAt: alepha2502.TString;
|
|
7310
|
+
ip: alepha2502.TOptional<alepha2502.TString>;
|
|
7311
|
+
userAgent: alepha2502.TOptional<alepha2502.TObject<{
|
|
7312
|
+
os: alepha2502.TString;
|
|
7313
|
+
browser: alepha2502.TString;
|
|
7314
|
+
device: alepha2502.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
|
|
6758
7315
|
}>>;
|
|
6759
7316
|
}>>;
|
|
6760
7317
|
/**
|
|
@@ -6771,7 +7328,7 @@ declare class SessionCrudService {
|
|
|
6771
7328
|
deleteSession(id: string, userRealmName?: string): Promise<void>;
|
|
6772
7329
|
}
|
|
6773
7330
|
//#endregion
|
|
6774
|
-
//#region ../../../alepha/src/api
|
|
7331
|
+
//#region ../../../alepha/src/api/users/controllers/SessionController.d.ts
|
|
6775
7332
|
declare class SessionController {
|
|
6776
7333
|
protected readonly url = "/sessions";
|
|
6777
7334
|
protected readonly group = "sessions";
|
|
@@ -6780,26 +7337,26 @@ declare class SessionController {
|
|
|
6780
7337
|
* Find sessions with pagination and filtering.
|
|
6781
7338
|
*/
|
|
6782
7339
|
readonly findSessions: ActionPrimitiveFn<{
|
|
6783
|
-
query:
|
|
6784
|
-
page:
|
|
6785
|
-
size:
|
|
6786
|
-
sort:
|
|
6787
|
-
userId:
|
|
6788
|
-
userRealmName:
|
|
7340
|
+
query: alepha2502.TObject<{
|
|
7341
|
+
page: alepha2502.TOptional<alepha2502.TInteger>;
|
|
7342
|
+
size: alepha2502.TOptional<alepha2502.TInteger>;
|
|
7343
|
+
sort: alepha2502.TOptional<alepha2502.TString>;
|
|
7344
|
+
userId: alepha2502.TOptional<alepha2502.TString>;
|
|
7345
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
6789
7346
|
}>;
|
|
6790
|
-
response:
|
|
6791
|
-
id:
|
|
6792
|
-
version:
|
|
6793
|
-
createdAt:
|
|
6794
|
-
updatedAt:
|
|
6795
|
-
refreshToken:
|
|
6796
|
-
userId:
|
|
6797
|
-
expiresAt:
|
|
6798
|
-
ip:
|
|
6799
|
-
userAgent:
|
|
6800
|
-
os:
|
|
6801
|
-
browser:
|
|
6802
|
-
device:
|
|
7347
|
+
response: alepha2502.TPage<alepha2502.TObject<{
|
|
7348
|
+
id: alepha2502.TString;
|
|
7349
|
+
version: alepha2502.TNumber;
|
|
7350
|
+
createdAt: alepha2502.TString;
|
|
7351
|
+
updatedAt: alepha2502.TString;
|
|
7352
|
+
refreshToken: alepha2502.TString;
|
|
7353
|
+
userId: alepha2502.TString;
|
|
7354
|
+
expiresAt: alepha2502.TString;
|
|
7355
|
+
ip: alepha2502.TOptional<alepha2502.TString>;
|
|
7356
|
+
userAgent: alepha2502.TOptional<alepha2502.TObject<{
|
|
7357
|
+
os: alepha2502.TString;
|
|
7358
|
+
browser: alepha2502.TString;
|
|
7359
|
+
device: alepha2502.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
|
|
6803
7360
|
}>>;
|
|
6804
7361
|
}>>;
|
|
6805
7362
|
}>;
|
|
@@ -6807,25 +7364,25 @@ declare class SessionController {
|
|
|
6807
7364
|
* Get a session by ID.
|
|
6808
7365
|
*/
|
|
6809
7366
|
readonly getSession: ActionPrimitiveFn<{
|
|
6810
|
-
params:
|
|
6811
|
-
id:
|
|
7367
|
+
params: alepha2502.TObject<{
|
|
7368
|
+
id: alepha2502.TString;
|
|
6812
7369
|
}>;
|
|
6813
|
-
query:
|
|
6814
|
-
userRealmName:
|
|
7370
|
+
query: alepha2502.TObject<{
|
|
7371
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
6815
7372
|
}>;
|
|
6816
|
-
response:
|
|
6817
|
-
id:
|
|
6818
|
-
version:
|
|
6819
|
-
createdAt:
|
|
6820
|
-
updatedAt:
|
|
6821
|
-
refreshToken:
|
|
6822
|
-
userId:
|
|
6823
|
-
expiresAt:
|
|
6824
|
-
ip:
|
|
6825
|
-
userAgent:
|
|
6826
|
-
os:
|
|
6827
|
-
browser:
|
|
6828
|
-
device:
|
|
7373
|
+
response: alepha2502.TObject<{
|
|
7374
|
+
id: alepha2502.TString;
|
|
7375
|
+
version: alepha2502.TNumber;
|
|
7376
|
+
createdAt: alepha2502.TString;
|
|
7377
|
+
updatedAt: alepha2502.TString;
|
|
7378
|
+
refreshToken: alepha2502.TString;
|
|
7379
|
+
userId: alepha2502.TString;
|
|
7380
|
+
expiresAt: alepha2502.TString;
|
|
7381
|
+
ip: alepha2502.TOptional<alepha2502.TString>;
|
|
7382
|
+
userAgent: alepha2502.TOptional<alepha2502.TObject<{
|
|
7383
|
+
os: alepha2502.TString;
|
|
7384
|
+
browser: alepha2502.TString;
|
|
7385
|
+
device: alepha2502.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
|
|
6829
7386
|
}>>;
|
|
6830
7387
|
}>;
|
|
6831
7388
|
}>;
|
|
@@ -6833,72 +7390,72 @@ declare class SessionController {
|
|
|
6833
7390
|
* Delete a session.
|
|
6834
7391
|
*/
|
|
6835
7392
|
readonly deleteSession: ActionPrimitiveFn<{
|
|
6836
|
-
params:
|
|
6837
|
-
id:
|
|
7393
|
+
params: alepha2502.TObject<{
|
|
7394
|
+
id: alepha2502.TString;
|
|
6838
7395
|
}>;
|
|
6839
|
-
query:
|
|
6840
|
-
userRealmName:
|
|
7396
|
+
query: alepha2502.TObject<{
|
|
7397
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
6841
7398
|
}>;
|
|
6842
|
-
response:
|
|
6843
|
-
ok:
|
|
6844
|
-
id:
|
|
6845
|
-
count:
|
|
7399
|
+
response: alepha2502.TObject<{
|
|
7400
|
+
ok: alepha2502.TBoolean;
|
|
7401
|
+
id: alepha2502.TOptional<alepha2502.TUnion<[alepha2502.TString, alepha2502.TInteger]>>;
|
|
7402
|
+
count: alepha2502.TOptional<alepha2502.TNumber>;
|
|
6846
7403
|
}>;
|
|
6847
7404
|
}>;
|
|
6848
7405
|
}
|
|
6849
7406
|
//#endregion
|
|
6850
|
-
//#region ../../../alepha/src/api
|
|
6851
|
-
declare const verifications: EntityPrimitive<
|
|
6852
|
-
id: PgAttr<PgAttr<
|
|
6853
|
-
createdAt: PgAttr<PgAttr<
|
|
6854
|
-
updatedAt: PgAttr<PgAttr<
|
|
6855
|
-
version: PgAttr<PgAttr<
|
|
6856
|
-
type:
|
|
6857
|
-
target:
|
|
6858
|
-
code:
|
|
6859
|
-
verifiedAt:
|
|
6860
|
-
attempts: PgAttr<
|
|
7407
|
+
//#region ../../../alepha/src/api/verifications/entities/verifications.d.ts
|
|
7408
|
+
declare const verifications: EntityPrimitive<alepha2502.TObject<{
|
|
7409
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7410
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7411
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7412
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7413
|
+
type: alepha2502.TUnsafe<"link" | "code">;
|
|
7414
|
+
target: alepha2502.TString;
|
|
7415
|
+
code: alepha2502.TString;
|
|
7416
|
+
verifiedAt: alepha2502.TOptional<alepha2502.TString>;
|
|
7417
|
+
attempts: PgAttr<alepha2502.TInteger, typeof PG_DEFAULT>;
|
|
6861
7418
|
}>>;
|
|
6862
7419
|
type VerificationEntity = Static<typeof verifications.schema>;
|
|
6863
7420
|
//#endregion
|
|
6864
|
-
//#region ../../../alepha/src/api
|
|
6865
|
-
declare const verificationSettingsSchema:
|
|
6866
|
-
code:
|
|
6867
|
-
maxAttempts:
|
|
6868
|
-
codeLength:
|
|
6869
|
-
codeExpiration:
|
|
6870
|
-
verificationCooldown:
|
|
6871
|
-
limitPerDay:
|
|
7421
|
+
//#region ../../../alepha/src/api/verifications/schemas/verificationSettingsSchema.d.ts
|
|
7422
|
+
declare const verificationSettingsSchema: alepha2502.TObject<{
|
|
7423
|
+
code: alepha2502.TObject<{
|
|
7424
|
+
maxAttempts: alepha2502.TInteger;
|
|
7425
|
+
codeLength: alepha2502.TInteger;
|
|
7426
|
+
codeExpiration: alepha2502.TInteger;
|
|
7427
|
+
verificationCooldown: alepha2502.TInteger;
|
|
7428
|
+
limitPerDay: alepha2502.TInteger;
|
|
6872
7429
|
}>;
|
|
6873
|
-
link:
|
|
6874
|
-
maxAttempts:
|
|
6875
|
-
codeExpiration:
|
|
6876
|
-
verificationCooldown:
|
|
6877
|
-
limitPerDay:
|
|
7430
|
+
link: alepha2502.TObject<{
|
|
7431
|
+
maxAttempts: alepha2502.TInteger;
|
|
7432
|
+
codeExpiration: alepha2502.TInteger;
|
|
7433
|
+
verificationCooldown: alepha2502.TInteger;
|
|
7434
|
+
limitPerDay: alepha2502.TInteger;
|
|
6878
7435
|
}>;
|
|
6879
|
-
purgeDays:
|
|
7436
|
+
purgeDays: alepha2502.TInteger;
|
|
6880
7437
|
}>;
|
|
6881
7438
|
type VerificationSettings = Static<typeof verificationSettingsSchema>;
|
|
6882
7439
|
//#endregion
|
|
6883
|
-
//#region ../../../alepha/src/api
|
|
7440
|
+
//#region ../../../alepha/src/api/verifications/parameters/VerificationParameters.d.ts
|
|
6884
7441
|
/**
|
|
6885
7442
|
* Verification settings configuration atom
|
|
6886
7443
|
*/
|
|
6887
|
-
declare const verificationOptions:
|
|
6888
|
-
code:
|
|
6889
|
-
maxAttempts:
|
|
6890
|
-
codeLength:
|
|
6891
|
-
codeExpiration:
|
|
6892
|
-
verificationCooldown:
|
|
6893
|
-
limitPerDay:
|
|
7444
|
+
declare const verificationOptions: alepha2502.Atom<alepha2502.TObject<{
|
|
7445
|
+
code: alepha2502.TObject<{
|
|
7446
|
+
maxAttempts: alepha2502.TInteger;
|
|
7447
|
+
codeLength: alepha2502.TInteger;
|
|
7448
|
+
codeExpiration: alepha2502.TInteger;
|
|
7449
|
+
verificationCooldown: alepha2502.TInteger;
|
|
7450
|
+
limitPerDay: alepha2502.TInteger;
|
|
6894
7451
|
}>;
|
|
6895
|
-
link:
|
|
6896
|
-
maxAttempts:
|
|
6897
|
-
codeExpiration:
|
|
6898
|
-
verificationCooldown:
|
|
6899
|
-
limitPerDay:
|
|
7452
|
+
link: alepha2502.TObject<{
|
|
7453
|
+
maxAttempts: alepha2502.TInteger;
|
|
7454
|
+
codeExpiration: alepha2502.TInteger;
|
|
7455
|
+
verificationCooldown: alepha2502.TInteger;
|
|
7456
|
+
limitPerDay: alepha2502.TInteger;
|
|
6900
7457
|
}>;
|
|
6901
|
-
purgeDays:
|
|
7458
|
+
purgeDays: alepha2502.TInteger;
|
|
6902
7459
|
}>, "alepha.api.verifications.options">;
|
|
6903
7460
|
type VerificationOptions = Static<typeof verificationOptions.schema>;
|
|
6904
7461
|
declare module "alepha" {
|
|
@@ -6926,63 +7483,63 @@ declare class VerificationParameters {
|
|
|
6926
7483
|
get<K$1 extends keyof VerificationSettings>(key: K$1): VerificationSettings[K$1];
|
|
6927
7484
|
}
|
|
6928
7485
|
//#endregion
|
|
6929
|
-
//#region ../../../alepha/src/api
|
|
6930
|
-
declare const requestVerificationCodeResponseSchema:
|
|
6931
|
-
token:
|
|
6932
|
-
codeExpiration:
|
|
6933
|
-
verificationCooldown:
|
|
6934
|
-
maxVerificationAttempts:
|
|
7486
|
+
//#region ../../../alepha/src/api/verifications/schemas/requestVerificationCodeResponseSchema.d.ts
|
|
7487
|
+
declare const requestVerificationCodeResponseSchema: alepha2502.TObject<{
|
|
7488
|
+
token: alepha2502.TString;
|
|
7489
|
+
codeExpiration: alepha2502.TInteger;
|
|
7490
|
+
verificationCooldown: alepha2502.TInteger;
|
|
7491
|
+
maxVerificationAttempts: alepha2502.TInteger;
|
|
6935
7492
|
}>;
|
|
6936
7493
|
type RequestVerificationResponse = Static<typeof requestVerificationCodeResponseSchema>;
|
|
6937
7494
|
//#endregion
|
|
6938
|
-
//#region ../../../alepha/src/api
|
|
6939
|
-
declare const validateVerificationCodeResponseSchema:
|
|
6940
|
-
ok:
|
|
6941
|
-
alreadyVerified:
|
|
7495
|
+
//#region ../../../alepha/src/api/verifications/schemas/validateVerificationCodeResponseSchema.d.ts
|
|
7496
|
+
declare const validateVerificationCodeResponseSchema: alepha2502.TObject<{
|
|
7497
|
+
ok: alepha2502.TBoolean;
|
|
7498
|
+
alreadyVerified: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
6942
7499
|
}>;
|
|
6943
7500
|
type ValidateVerificationCodeResponse = Static<typeof validateVerificationCodeResponseSchema>;
|
|
6944
7501
|
//#endregion
|
|
6945
|
-
//#region ../../../alepha/src/api
|
|
6946
|
-
declare const verificationTypeEnumSchema:
|
|
7502
|
+
//#region ../../../alepha/src/api/verifications/schemas/verificationTypeEnumSchema.d.ts
|
|
7503
|
+
declare const verificationTypeEnumSchema: alepha2502.TUnsafe<"link" | "code">;
|
|
6947
7504
|
type VerificationTypeEnum = Static<typeof verificationTypeEnumSchema>;
|
|
6948
7505
|
//#endregion
|
|
6949
|
-
//#region ../../../alepha/src/api
|
|
7506
|
+
//#region ../../../alepha/src/api/verifications/services/VerificationService.d.ts
|
|
6950
7507
|
declare class VerificationService {
|
|
6951
7508
|
protected readonly log: Logger;
|
|
6952
7509
|
protected readonly dateTimeProvider: DateTimeProvider;
|
|
6953
7510
|
protected readonly verificationParameters: VerificationParameters;
|
|
6954
|
-
protected readonly verificationRepository: Repository<
|
|
6955
|
-
id: PgAttr<PgAttr<
|
|
6956
|
-
createdAt: PgAttr<PgAttr<
|
|
6957
|
-
updatedAt: PgAttr<PgAttr<
|
|
6958
|
-
version: PgAttr<PgAttr<
|
|
6959
|
-
type:
|
|
6960
|
-
target:
|
|
6961
|
-
code:
|
|
6962
|
-
verifiedAt:
|
|
6963
|
-
attempts: PgAttr<
|
|
7511
|
+
protected readonly verificationRepository: Repository<alepha2502.TObject<{
|
|
7512
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7513
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7514
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7515
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7516
|
+
type: alepha2502.TUnsafe<"link" | "code">;
|
|
7517
|
+
target: alepha2502.TString;
|
|
7518
|
+
code: alepha2502.TString;
|
|
7519
|
+
verifiedAt: alepha2502.TOptional<alepha2502.TString>;
|
|
7520
|
+
attempts: PgAttr<alepha2502.TInteger, typeof PG_DEFAULT>;
|
|
6964
7521
|
}>>;
|
|
6965
7522
|
findByEntry(entry: VerificationEntry): Promise<VerificationEntity>;
|
|
6966
|
-
findRecentsByEntry(entry: VerificationEntry): Promise<PgStatic<
|
|
6967
|
-
id: PgAttr<PgAttr<
|
|
6968
|
-
createdAt: PgAttr<PgAttr<
|
|
6969
|
-
updatedAt: PgAttr<PgAttr<
|
|
6970
|
-
version: PgAttr<PgAttr<
|
|
6971
|
-
type:
|
|
6972
|
-
target:
|
|
6973
|
-
code:
|
|
6974
|
-
verifiedAt:
|
|
6975
|
-
attempts: PgAttr<
|
|
6976
|
-
}>, PgRelationMap<
|
|
6977
|
-
id: PgAttr<PgAttr<
|
|
6978
|
-
createdAt: PgAttr<PgAttr<
|
|
6979
|
-
updatedAt: PgAttr<PgAttr<
|
|
6980
|
-
version: PgAttr<PgAttr<
|
|
6981
|
-
type:
|
|
6982
|
-
target:
|
|
6983
|
-
code:
|
|
6984
|
-
verifiedAt:
|
|
6985
|
-
attempts: PgAttr<
|
|
7523
|
+
findRecentsByEntry(entry: VerificationEntry): Promise<PgStatic<alepha2502.TObject<{
|
|
7524
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7525
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7526
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7527
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7528
|
+
type: alepha2502.TUnsafe<"link" | "code">;
|
|
7529
|
+
target: alepha2502.TString;
|
|
7530
|
+
code: alepha2502.TString;
|
|
7531
|
+
verifiedAt: alepha2502.TOptional<alepha2502.TString>;
|
|
7532
|
+
attempts: PgAttr<alepha2502.TInteger, typeof PG_DEFAULT>;
|
|
7533
|
+
}>, PgRelationMap<alepha2502.TObject<{
|
|
7534
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7535
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7536
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7537
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7538
|
+
type: alepha2502.TUnsafe<"link" | "code">;
|
|
7539
|
+
target: alepha2502.TString;
|
|
7540
|
+
code: alepha2502.TString;
|
|
7541
|
+
verifiedAt: alepha2502.TOptional<alepha2502.TString>;
|
|
7542
|
+
attempts: PgAttr<alepha2502.TInteger, typeof PG_DEFAULT>;
|
|
6986
7543
|
}>>>[]>;
|
|
6987
7544
|
/**
|
|
6988
7545
|
* Creates a verification entry and returns the token.
|
|
@@ -6999,97 +7556,97 @@ interface VerificationEntry {
|
|
|
6999
7556
|
target: string;
|
|
7000
7557
|
}
|
|
7001
7558
|
//#endregion
|
|
7002
|
-
//#region ../../../alepha/src/api
|
|
7559
|
+
//#region ../../../alepha/src/api/verifications/controllers/VerificationController.d.ts
|
|
7003
7560
|
declare class VerificationController {
|
|
7004
7561
|
protected readonly verificationService: VerificationService;
|
|
7005
7562
|
readonly url = "/verifications";
|
|
7006
7563
|
readonly group = "verifications";
|
|
7007
7564
|
readonly requestVerificationCode: ActionPrimitiveFn<{
|
|
7008
|
-
params:
|
|
7009
|
-
type:
|
|
7565
|
+
params: alepha2502.TObject<{
|
|
7566
|
+
type: alepha2502.TUnsafe<"link" | "code">;
|
|
7010
7567
|
}>;
|
|
7011
|
-
body:
|
|
7012
|
-
target:
|
|
7568
|
+
body: alepha2502.TObject<{
|
|
7569
|
+
target: alepha2502.TString;
|
|
7013
7570
|
}>;
|
|
7014
|
-
response:
|
|
7015
|
-
token:
|
|
7016
|
-
codeExpiration:
|
|
7017
|
-
verificationCooldown:
|
|
7018
|
-
maxVerificationAttempts:
|
|
7571
|
+
response: alepha2502.TObject<{
|
|
7572
|
+
token: alepha2502.TString;
|
|
7573
|
+
codeExpiration: alepha2502.TInteger;
|
|
7574
|
+
verificationCooldown: alepha2502.TInteger;
|
|
7575
|
+
maxVerificationAttempts: alepha2502.TInteger;
|
|
7019
7576
|
}>;
|
|
7020
7577
|
}>;
|
|
7021
7578
|
readonly validateVerificationCode: ActionPrimitiveFn<{
|
|
7022
|
-
params:
|
|
7023
|
-
type:
|
|
7579
|
+
params: alepha2502.TObject<{
|
|
7580
|
+
type: alepha2502.TUnsafe<"link" | "code">;
|
|
7024
7581
|
}>;
|
|
7025
|
-
body:
|
|
7026
|
-
target:
|
|
7027
|
-
token:
|
|
7582
|
+
body: alepha2502.TObject<{
|
|
7583
|
+
target: alepha2502.TString;
|
|
7584
|
+
token: alepha2502.TString;
|
|
7028
7585
|
}>;
|
|
7029
|
-
response:
|
|
7030
|
-
ok:
|
|
7031
|
-
alreadyVerified:
|
|
7586
|
+
response: alepha2502.TObject<{
|
|
7587
|
+
ok: alepha2502.TBoolean;
|
|
7588
|
+
alreadyVerified: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
7032
7589
|
}>;
|
|
7033
7590
|
}>;
|
|
7034
7591
|
}
|
|
7035
7592
|
//#endregion
|
|
7036
|
-
//#region ../../../alepha/src/api
|
|
7593
|
+
//#region ../../../alepha/src/api/users/notifications/UserNotifications.d.ts
|
|
7037
7594
|
declare class UserNotifications {
|
|
7038
|
-
readonly passwordReset: NotificationPrimitive<
|
|
7039
|
-
email:
|
|
7040
|
-
code:
|
|
7041
|
-
expiresInMinutes:
|
|
7595
|
+
readonly passwordReset: NotificationPrimitive<alepha2502.TObject<{
|
|
7596
|
+
email: alepha2502.TString;
|
|
7597
|
+
code: alepha2502.TString;
|
|
7598
|
+
expiresInMinutes: alepha2502.TNumber;
|
|
7042
7599
|
}>>;
|
|
7043
|
-
readonly emailVerification: NotificationPrimitive<
|
|
7044
|
-
email:
|
|
7045
|
-
code:
|
|
7046
|
-
expiresInMinutes:
|
|
7600
|
+
readonly emailVerification: NotificationPrimitive<alepha2502.TObject<{
|
|
7601
|
+
email: alepha2502.TString;
|
|
7602
|
+
code: alepha2502.TString;
|
|
7603
|
+
expiresInMinutes: alepha2502.TNumber;
|
|
7047
7604
|
}>>;
|
|
7048
|
-
readonly phoneVerification: NotificationPrimitive<
|
|
7049
|
-
phoneNumber:
|
|
7050
|
-
code:
|
|
7051
|
-
expiresInMinutes:
|
|
7605
|
+
readonly phoneVerification: NotificationPrimitive<alepha2502.TObject<{
|
|
7606
|
+
phoneNumber: alepha2502.TString;
|
|
7607
|
+
code: alepha2502.TString;
|
|
7608
|
+
expiresInMinutes: alepha2502.TNumber;
|
|
7052
7609
|
}>>;
|
|
7053
|
-
readonly passwordResetLink: NotificationPrimitive<
|
|
7054
|
-
email:
|
|
7055
|
-
resetUrl:
|
|
7056
|
-
expiresInMinutes:
|
|
7610
|
+
readonly passwordResetLink: NotificationPrimitive<alepha2502.TObject<{
|
|
7611
|
+
email: alepha2502.TString;
|
|
7612
|
+
resetUrl: alepha2502.TString;
|
|
7613
|
+
expiresInMinutes: alepha2502.TNumber;
|
|
7057
7614
|
}>>;
|
|
7058
|
-
readonly emailVerificationLink: NotificationPrimitive<
|
|
7059
|
-
email:
|
|
7060
|
-
verifyUrl:
|
|
7061
|
-
expiresInMinutes:
|
|
7615
|
+
readonly emailVerificationLink: NotificationPrimitive<alepha2502.TObject<{
|
|
7616
|
+
email: alepha2502.TString;
|
|
7617
|
+
verifyUrl: alepha2502.TString;
|
|
7618
|
+
expiresInMinutes: alepha2502.TNumber;
|
|
7062
7619
|
}>>;
|
|
7063
7620
|
}
|
|
7064
7621
|
//#endregion
|
|
7065
|
-
//#region ../../../alepha/src/api
|
|
7622
|
+
//#region ../../../alepha/src/api/users/schemas/completePasswordResetRequestSchema.d.ts
|
|
7066
7623
|
/**
|
|
7067
7624
|
* Request schema for completing a password reset.
|
|
7068
7625
|
*
|
|
7069
7626
|
* Requires the intent ID from Phase 1, the verification code,
|
|
7070
7627
|
* and the new password.
|
|
7071
7628
|
*/
|
|
7072
|
-
declare const completePasswordResetRequestSchema:
|
|
7073
|
-
intentId:
|
|
7074
|
-
code:
|
|
7075
|
-
newPassword:
|
|
7629
|
+
declare const completePasswordResetRequestSchema: alepha2502.TObject<{
|
|
7630
|
+
intentId: alepha2502.TString;
|
|
7631
|
+
code: alepha2502.TString;
|
|
7632
|
+
newPassword: alepha2502.TString;
|
|
7076
7633
|
}>;
|
|
7077
7634
|
type CompletePasswordResetRequest = Static<typeof completePasswordResetRequestSchema>;
|
|
7078
7635
|
//#endregion
|
|
7079
|
-
//#region ../../../alepha/src/api
|
|
7636
|
+
//#region ../../../alepha/src/api/users/schemas/passwordResetIntentResponseSchema.d.ts
|
|
7080
7637
|
/**
|
|
7081
7638
|
* Response schema for password reset intent creation.
|
|
7082
7639
|
*
|
|
7083
7640
|
* Contains the intent ID needed for Phase 2 completion,
|
|
7084
7641
|
* along with expiration time.
|
|
7085
7642
|
*/
|
|
7086
|
-
declare const passwordResetIntentResponseSchema:
|
|
7087
|
-
intentId:
|
|
7088
|
-
expiresAt:
|
|
7643
|
+
declare const passwordResetIntentResponseSchema: alepha2502.TObject<{
|
|
7644
|
+
intentId: alepha2502.TString;
|
|
7645
|
+
expiresAt: alepha2502.TString;
|
|
7089
7646
|
}>;
|
|
7090
7647
|
type PasswordResetIntentResponse = Static<typeof passwordResetIntentResponseSchema>;
|
|
7091
7648
|
//#endregion
|
|
7092
|
-
//#region ../../../alepha/src/api
|
|
7649
|
+
//#region ../../../alepha/src/api/users/services/CredentialService.d.ts
|
|
7093
7650
|
/**
|
|
7094
7651
|
* Intent stored in cache during the password reset flow.
|
|
7095
7652
|
*/
|
|
@@ -7108,47 +7665,47 @@ declare class CredentialService {
|
|
|
7108
7665
|
protected readonly userNotifications: UserNotifications;
|
|
7109
7666
|
protected readonly userRealmProvider: UserRealmProvider;
|
|
7110
7667
|
protected readonly intentCache: CachePrimitiveFn<PasswordResetIntent, any[]>;
|
|
7111
|
-
users(userRealmName?: string): Repository<
|
|
7112
|
-
id: PgAttr<PgAttr<
|
|
7113
|
-
version: PgAttr<PgAttr<
|
|
7114
|
-
createdAt: PgAttr<PgAttr<
|
|
7115
|
-
updatedAt: PgAttr<PgAttr<
|
|
7116
|
-
realm: PgAttr<
|
|
7117
|
-
username:
|
|
7118
|
-
email:
|
|
7119
|
-
phoneNumber:
|
|
7120
|
-
roles: PgAttr<
|
|
7121
|
-
firstName:
|
|
7122
|
-
lastName:
|
|
7123
|
-
picture:
|
|
7124
|
-
enabled: PgAttr<
|
|
7125
|
-
emailVerified: PgAttr<
|
|
7668
|
+
users(userRealmName?: string): Repository<alepha2502.TObject<{
|
|
7669
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7670
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7671
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7672
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7673
|
+
realm: PgAttr<alepha2502.TString, typeof PG_DEFAULT>;
|
|
7674
|
+
username: alepha2502.TOptional<alepha2502.TString>;
|
|
7675
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
7676
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TString>;
|
|
7677
|
+
roles: PgAttr<alepha2502.TArray<alepha2502.TString>, typeof PG_DEFAULT>;
|
|
7678
|
+
firstName: alepha2502.TOptional<alepha2502.TString>;
|
|
7679
|
+
lastName: alepha2502.TOptional<alepha2502.TString>;
|
|
7680
|
+
picture: alepha2502.TOptional<alepha2502.TString>;
|
|
7681
|
+
enabled: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
7682
|
+
emailVerified: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
7126
7683
|
}>>;
|
|
7127
|
-
sessions(userRealmName?: string): Repository<
|
|
7128
|
-
id: PgAttr<PgAttr<
|
|
7129
|
-
version: PgAttr<PgAttr<
|
|
7130
|
-
createdAt: PgAttr<PgAttr<
|
|
7131
|
-
updatedAt: PgAttr<PgAttr<
|
|
7132
|
-
refreshToken:
|
|
7133
|
-
userId: PgAttr<
|
|
7134
|
-
expiresAt:
|
|
7135
|
-
ip:
|
|
7136
|
-
userAgent:
|
|
7137
|
-
os:
|
|
7138
|
-
browser:
|
|
7139
|
-
device:
|
|
7684
|
+
sessions(userRealmName?: string): Repository<alepha2502.TObject<{
|
|
7685
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7686
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7687
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7688
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7689
|
+
refreshToken: alepha2502.TString;
|
|
7690
|
+
userId: PgAttr<alepha2502.TString, typeof PG_REF>;
|
|
7691
|
+
expiresAt: alepha2502.TString;
|
|
7692
|
+
ip: alepha2502.TOptional<alepha2502.TString>;
|
|
7693
|
+
userAgent: alepha2502.TOptional<alepha2502.TObject<{
|
|
7694
|
+
os: alepha2502.TString;
|
|
7695
|
+
browser: alepha2502.TString;
|
|
7696
|
+
device: alepha2502.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
|
|
7140
7697
|
}>>;
|
|
7141
7698
|
}>>;
|
|
7142
|
-
identities(userRealmName?: string): Repository<
|
|
7143
|
-
id: PgAttr<PgAttr<
|
|
7144
|
-
version: PgAttr<PgAttr<
|
|
7145
|
-
createdAt: PgAttr<PgAttr<
|
|
7146
|
-
updatedAt: PgAttr<PgAttr<
|
|
7147
|
-
userId: PgAttr<
|
|
7148
|
-
password:
|
|
7149
|
-
provider:
|
|
7150
|
-
providerUserId:
|
|
7151
|
-
providerData:
|
|
7699
|
+
identities(userRealmName?: string): Repository<alepha2502.TObject<{
|
|
7700
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7701
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7702
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7703
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7704
|
+
userId: PgAttr<alepha2502.TString, typeof PG_REF>;
|
|
7705
|
+
password: alepha2502.TOptional<alepha2502.TString>;
|
|
7706
|
+
provider: alepha2502.TString;
|
|
7707
|
+
providerUserId: alepha2502.TOptional<alepha2502.TString>;
|
|
7708
|
+
providerData: alepha2502.TOptional<alepha2502.TRecord<string, alepha2502.TAny>>;
|
|
7152
7709
|
}>>;
|
|
7153
7710
|
/**
|
|
7154
7711
|
* Phase 1: Create a password reset intent.
|
|
@@ -7184,42 +7741,42 @@ declare class CredentialService {
|
|
|
7184
7741
|
resetPassword(email: string, token: string, newPassword: string, userRealmName?: string): Promise<void>;
|
|
7185
7742
|
}
|
|
7186
7743
|
//#endregion
|
|
7187
|
-
//#region ../../../alepha/src/api
|
|
7188
|
-
declare const completeRegistrationRequestSchema:
|
|
7189
|
-
intentId:
|
|
7190
|
-
emailCode:
|
|
7191
|
-
phoneCode:
|
|
7192
|
-
captchaToken:
|
|
7744
|
+
//#region ../../../alepha/src/api/users/schemas/completeRegistrationRequestSchema.d.ts
|
|
7745
|
+
declare const completeRegistrationRequestSchema: alepha2502.TObject<{
|
|
7746
|
+
intentId: alepha2502.TString;
|
|
7747
|
+
emailCode: alepha2502.TOptional<alepha2502.TString>;
|
|
7748
|
+
phoneCode: alepha2502.TOptional<alepha2502.TString>;
|
|
7749
|
+
captchaToken: alepha2502.TOptional<alepha2502.TString>;
|
|
7193
7750
|
}>;
|
|
7194
7751
|
type CompleteRegistrationRequest = Static<typeof completeRegistrationRequestSchema>;
|
|
7195
7752
|
//#endregion
|
|
7196
|
-
//#region ../../../alepha/src/api
|
|
7753
|
+
//#region ../../../alepha/src/api/users/schemas/registerRequestSchema.d.ts
|
|
7197
7754
|
/**
|
|
7198
7755
|
* Schema for user registration request body.
|
|
7199
7756
|
* Password is always required, other fields depend on realm settings.
|
|
7200
7757
|
*/
|
|
7201
|
-
declare const registerRequestSchema:
|
|
7202
|
-
password:
|
|
7203
|
-
username:
|
|
7204
|
-
email:
|
|
7205
|
-
phoneNumber:
|
|
7206
|
-
firstName:
|
|
7207
|
-
lastName:
|
|
7208
|
-
picture:
|
|
7758
|
+
declare const registerRequestSchema: alepha2502.TObject<{
|
|
7759
|
+
password: alepha2502.TString;
|
|
7760
|
+
username: alepha2502.TOptional<alepha2502.TString>;
|
|
7761
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
7762
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TString>;
|
|
7763
|
+
firstName: alepha2502.TOptional<alepha2502.TString>;
|
|
7764
|
+
lastName: alepha2502.TOptional<alepha2502.TString>;
|
|
7765
|
+
picture: alepha2502.TOptional<alepha2502.TString>;
|
|
7209
7766
|
}>;
|
|
7210
7767
|
type RegisterRequest = Static<typeof registerRequestSchema>;
|
|
7211
7768
|
//#endregion
|
|
7212
|
-
//#region ../../../alepha/src/api
|
|
7213
|
-
declare const registrationIntentResponseSchema:
|
|
7214
|
-
intentId:
|
|
7215
|
-
expectCaptcha:
|
|
7216
|
-
expectEmailVerification:
|
|
7217
|
-
expectPhoneVerification:
|
|
7218
|
-
expiresAt:
|
|
7769
|
+
//#region ../../../alepha/src/api/users/schemas/registrationIntentResponseSchema.d.ts
|
|
7770
|
+
declare const registrationIntentResponseSchema: alepha2502.TObject<{
|
|
7771
|
+
intentId: alepha2502.TString;
|
|
7772
|
+
expectCaptcha: alepha2502.TBoolean;
|
|
7773
|
+
expectEmailVerification: alepha2502.TBoolean;
|
|
7774
|
+
expectPhoneVerification: alepha2502.TBoolean;
|
|
7775
|
+
expiresAt: alepha2502.TString;
|
|
7219
7776
|
}>;
|
|
7220
7777
|
type RegistrationIntentResponse = Static<typeof registrationIntentResponseSchema>;
|
|
7221
7778
|
//#endregion
|
|
7222
|
-
//#region ../../../alepha/src/api
|
|
7779
|
+
//#region ../../../alepha/src/api/users/services/RegistrationService.d.ts
|
|
7223
7780
|
/**
|
|
7224
7781
|
* Intent stored in cache during the registration flow.
|
|
7225
7782
|
*/
|
|
@@ -7285,71 +7842,71 @@ declare class RegistrationService {
|
|
|
7285
7842
|
protected verifyPhoneCode(phoneNumber: string, code: string): Promise<void>;
|
|
7286
7843
|
}
|
|
7287
7844
|
//#endregion
|
|
7288
|
-
//#region ../../../alepha/src/api
|
|
7289
|
-
declare const createUserSchema:
|
|
7290
|
-
id:
|
|
7291
|
-
email:
|
|
7292
|
-
username:
|
|
7293
|
-
picture:
|
|
7294
|
-
roles:
|
|
7295
|
-
version:
|
|
7296
|
-
createdAt:
|
|
7297
|
-
updatedAt:
|
|
7298
|
-
phoneNumber:
|
|
7299
|
-
firstName:
|
|
7300
|
-
lastName:
|
|
7301
|
-
enabled:
|
|
7302
|
-
emailVerified:
|
|
7845
|
+
//#region ../../../alepha/src/api/users/schemas/createUserSchema.d.ts
|
|
7846
|
+
declare const createUserSchema: alepha2502.TObject<{
|
|
7847
|
+
id: alepha2502.TOptional<PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>>;
|
|
7848
|
+
email: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
7849
|
+
username: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
7850
|
+
picture: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
7851
|
+
roles: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
7852
|
+
version: alepha2502.TOptional<PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>>;
|
|
7853
|
+
createdAt: alepha2502.TOptional<PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>>;
|
|
7854
|
+
updatedAt: alepha2502.TOptional<PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>>;
|
|
7855
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
7856
|
+
firstName: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
7857
|
+
lastName: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
7858
|
+
enabled: alepha2502.TOptional<PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>>;
|
|
7859
|
+
emailVerified: alepha2502.TOptional<PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>>;
|
|
7303
7860
|
}>;
|
|
7304
7861
|
type CreateUser = Static<typeof createUserSchema>;
|
|
7305
7862
|
//#endregion
|
|
7306
|
-
//#region ../../../alepha/src/api
|
|
7307
|
-
declare const updateUserSchema:
|
|
7308
|
-
realm:
|
|
7309
|
-
email:
|
|
7310
|
-
picture:
|
|
7311
|
-
roles:
|
|
7312
|
-
phoneNumber:
|
|
7313
|
-
firstName:
|
|
7314
|
-
lastName:
|
|
7315
|
-
enabled:
|
|
7863
|
+
//#region ../../../alepha/src/api/users/schemas/updateUserSchema.d.ts
|
|
7864
|
+
declare const updateUserSchema: alepha2502.TObject<{
|
|
7865
|
+
realm: alepha2502.TOptional<PgAttr<alepha2502.TString, typeof PG_DEFAULT>>;
|
|
7866
|
+
email: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
7867
|
+
picture: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
7868
|
+
roles: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
7869
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
7870
|
+
firstName: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
7871
|
+
lastName: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
7872
|
+
enabled: alepha2502.TOptional<PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>>;
|
|
7316
7873
|
}>;
|
|
7317
7874
|
type UpdateUser = Static<typeof updateUserSchema>;
|
|
7318
7875
|
//#endregion
|
|
7319
|
-
//#region ../../../alepha/src/api
|
|
7320
|
-
declare const userQuerySchema:
|
|
7321
|
-
page:
|
|
7322
|
-
size:
|
|
7323
|
-
sort:
|
|
7324
|
-
email:
|
|
7325
|
-
enabled:
|
|
7326
|
-
emailVerified:
|
|
7327
|
-
roles:
|
|
7328
|
-
query:
|
|
7876
|
+
//#region ../../../alepha/src/api/users/schemas/userQuerySchema.d.ts
|
|
7877
|
+
declare const userQuerySchema: alepha2502.TObject<{
|
|
7878
|
+
page: alepha2502.TOptional<alepha2502.TInteger>;
|
|
7879
|
+
size: alepha2502.TOptional<alepha2502.TInteger>;
|
|
7880
|
+
sort: alepha2502.TOptional<alepha2502.TString>;
|
|
7881
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
7882
|
+
enabled: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
7883
|
+
emailVerified: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
7884
|
+
roles: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
7885
|
+
query: alepha2502.TOptional<alepha2502.TString>;
|
|
7329
7886
|
}>;
|
|
7330
7887
|
type UserQuery = Static<typeof userQuerySchema>;
|
|
7331
7888
|
//#endregion
|
|
7332
|
-
//#region ../../../alepha/src/api
|
|
7889
|
+
//#region ../../../alepha/src/api/users/services/UserService.d.ts
|
|
7333
7890
|
declare class UserService {
|
|
7334
7891
|
protected readonly log: Logger;
|
|
7335
7892
|
protected readonly verificationController: HttpVirtualClient<VerificationController>;
|
|
7336
7893
|
protected readonly userNotifications: UserNotifications;
|
|
7337
7894
|
protected readonly userRealmProvider: UserRealmProvider;
|
|
7338
|
-
users(userRealmName?: string): Repository<
|
|
7339
|
-
id: PgAttr<PgAttr<
|
|
7340
|
-
version: PgAttr<PgAttr<
|
|
7341
|
-
createdAt: PgAttr<PgAttr<
|
|
7342
|
-
updatedAt: PgAttr<PgAttr<
|
|
7343
|
-
realm: PgAttr<
|
|
7344
|
-
username:
|
|
7345
|
-
email:
|
|
7346
|
-
phoneNumber:
|
|
7347
|
-
roles: PgAttr<
|
|
7348
|
-
firstName:
|
|
7349
|
-
lastName:
|
|
7350
|
-
picture:
|
|
7351
|
-
enabled: PgAttr<
|
|
7352
|
-
emailVerified: PgAttr<
|
|
7895
|
+
users(userRealmName?: string): Repository<alepha2502.TObject<{
|
|
7896
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7897
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
7898
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
7899
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
7900
|
+
realm: PgAttr<alepha2502.TString, typeof PG_DEFAULT>;
|
|
7901
|
+
username: alepha2502.TOptional<alepha2502.TString>;
|
|
7902
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
7903
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TString>;
|
|
7904
|
+
roles: PgAttr<alepha2502.TArray<alepha2502.TString>, typeof PG_DEFAULT>;
|
|
7905
|
+
firstName: alepha2502.TOptional<alepha2502.TString>;
|
|
7906
|
+
lastName: alepha2502.TOptional<alepha2502.TString>;
|
|
7907
|
+
picture: alepha2502.TOptional<alepha2502.TString>;
|
|
7908
|
+
enabled: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
7909
|
+
emailVerified: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
7353
7910
|
}>>;
|
|
7354
7911
|
/**
|
|
7355
7912
|
* Request email verification for a user.
|
|
@@ -7390,7 +7947,7 @@ declare class UserService {
|
|
|
7390
7947
|
deleteUser(id: string, userRealmName?: string): Promise<void>;
|
|
7391
7948
|
}
|
|
7392
7949
|
//#endregion
|
|
7393
|
-
//#region ../../../alepha/src/api
|
|
7950
|
+
//#region ../../../alepha/src/api/users/controllers/UserController.d.ts
|
|
7394
7951
|
declare class UserController {
|
|
7395
7952
|
protected readonly url = "/users";
|
|
7396
7953
|
protected readonly group = "users";
|
|
@@ -7402,122 +7959,122 @@ declare class UserController {
|
|
|
7402
7959
|
* Validates data, creates verification sessions, and stores intent in cache.
|
|
7403
7960
|
*/
|
|
7404
7961
|
readonly createRegistrationIntent: ActionPrimitiveFn<{
|
|
7405
|
-
body:
|
|
7406
|
-
password:
|
|
7407
|
-
username:
|
|
7408
|
-
email:
|
|
7409
|
-
phoneNumber:
|
|
7410
|
-
firstName:
|
|
7411
|
-
lastName:
|
|
7412
|
-
picture:
|
|
7962
|
+
body: alepha2502.TObject<{
|
|
7963
|
+
password: alepha2502.TString;
|
|
7964
|
+
username: alepha2502.TOptional<alepha2502.TString>;
|
|
7965
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
7966
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TString>;
|
|
7967
|
+
firstName: alepha2502.TOptional<alepha2502.TString>;
|
|
7968
|
+
lastName: alepha2502.TOptional<alepha2502.TString>;
|
|
7969
|
+
picture: alepha2502.TOptional<alepha2502.TString>;
|
|
7413
7970
|
}>;
|
|
7414
|
-
query:
|
|
7415
|
-
userRealmName:
|
|
7971
|
+
query: alepha2502.TObject<{
|
|
7972
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
7416
7973
|
}>;
|
|
7417
|
-
response:
|
|
7418
|
-
intentId:
|
|
7419
|
-
expectCaptcha:
|
|
7420
|
-
expectEmailVerification:
|
|
7421
|
-
expectPhoneVerification:
|
|
7422
|
-
expiresAt:
|
|
7974
|
+
response: alepha2502.TObject<{
|
|
7975
|
+
intentId: alepha2502.TString;
|
|
7976
|
+
expectCaptcha: alepha2502.TBoolean;
|
|
7977
|
+
expectEmailVerification: alepha2502.TBoolean;
|
|
7978
|
+
expectPhoneVerification: alepha2502.TBoolean;
|
|
7979
|
+
expiresAt: alepha2502.TString;
|
|
7423
7980
|
}>;
|
|
7424
7981
|
}>;
|
|
7425
7982
|
/**
|
|
7426
7983
|
* Find users with pagination and filtering.
|
|
7427
7984
|
*/
|
|
7428
7985
|
readonly findUsers: ActionPrimitiveFn<{
|
|
7429
|
-
query:
|
|
7430
|
-
page:
|
|
7431
|
-
size:
|
|
7432
|
-
sort:
|
|
7433
|
-
email:
|
|
7434
|
-
enabled:
|
|
7435
|
-
emailVerified:
|
|
7436
|
-
roles:
|
|
7437
|
-
query:
|
|
7438
|
-
userRealmName:
|
|
7986
|
+
query: alepha2502.TObject<{
|
|
7987
|
+
page: alepha2502.TOptional<alepha2502.TInteger>;
|
|
7988
|
+
size: alepha2502.TOptional<alepha2502.TInteger>;
|
|
7989
|
+
sort: alepha2502.TOptional<alepha2502.TString>;
|
|
7990
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
7991
|
+
enabled: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
7992
|
+
emailVerified: alepha2502.TOptional<alepha2502.TBoolean>;
|
|
7993
|
+
roles: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
7994
|
+
query: alepha2502.TOptional<alepha2502.TString>;
|
|
7995
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
7439
7996
|
}>;
|
|
7440
|
-
response:
|
|
7441
|
-
id: PgAttr<PgAttr<
|
|
7442
|
-
version: PgAttr<PgAttr<
|
|
7443
|
-
createdAt: PgAttr<PgAttr<
|
|
7444
|
-
updatedAt: PgAttr<PgAttr<
|
|
7445
|
-
realm: PgAttr<
|
|
7446
|
-
username:
|
|
7447
|
-
email:
|
|
7448
|
-
phoneNumber:
|
|
7449
|
-
roles: PgAttr<
|
|
7450
|
-
firstName:
|
|
7451
|
-
lastName:
|
|
7452
|
-
picture:
|
|
7453
|
-
enabled: PgAttr<
|
|
7454
|
-
emailVerified: PgAttr<
|
|
7997
|
+
response: alepha2502.TPage<alepha2502.TObject<{
|
|
7998
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
7999
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
8000
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
8001
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
8002
|
+
realm: PgAttr<alepha2502.TString, typeof PG_DEFAULT>;
|
|
8003
|
+
username: alepha2502.TOptional<alepha2502.TString>;
|
|
8004
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
8005
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TString>;
|
|
8006
|
+
roles: PgAttr<alepha2502.TArray<alepha2502.TString>, typeof PG_DEFAULT>;
|
|
8007
|
+
firstName: alepha2502.TOptional<alepha2502.TString>;
|
|
8008
|
+
lastName: alepha2502.TOptional<alepha2502.TString>;
|
|
8009
|
+
picture: alepha2502.TOptional<alepha2502.TString>;
|
|
8010
|
+
enabled: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
8011
|
+
emailVerified: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
7455
8012
|
}>>;
|
|
7456
8013
|
}>;
|
|
7457
8014
|
/**
|
|
7458
8015
|
* Get a user by ID.
|
|
7459
8016
|
*/
|
|
7460
8017
|
readonly getUser: ActionPrimitiveFn<{
|
|
7461
|
-
params:
|
|
7462
|
-
id:
|
|
8018
|
+
params: alepha2502.TObject<{
|
|
8019
|
+
id: alepha2502.TString;
|
|
7463
8020
|
}>;
|
|
7464
|
-
query:
|
|
7465
|
-
userRealmName:
|
|
8021
|
+
query: alepha2502.TObject<{
|
|
8022
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
7466
8023
|
}>;
|
|
7467
|
-
response:
|
|
7468
|
-
id: PgAttr<PgAttr<
|
|
7469
|
-
version: PgAttr<PgAttr<
|
|
7470
|
-
createdAt: PgAttr<PgAttr<
|
|
7471
|
-
updatedAt: PgAttr<PgAttr<
|
|
7472
|
-
realm: PgAttr<
|
|
7473
|
-
username:
|
|
7474
|
-
email:
|
|
7475
|
-
phoneNumber:
|
|
7476
|
-
roles: PgAttr<
|
|
7477
|
-
firstName:
|
|
7478
|
-
lastName:
|
|
7479
|
-
picture:
|
|
7480
|
-
enabled: PgAttr<
|
|
7481
|
-
emailVerified: PgAttr<
|
|
8024
|
+
response: alepha2502.TObject<{
|
|
8025
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
8026
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
8027
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
8028
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
8029
|
+
realm: PgAttr<alepha2502.TString, typeof PG_DEFAULT>;
|
|
8030
|
+
username: alepha2502.TOptional<alepha2502.TString>;
|
|
8031
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
8032
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TString>;
|
|
8033
|
+
roles: PgAttr<alepha2502.TArray<alepha2502.TString>, typeof PG_DEFAULT>;
|
|
8034
|
+
firstName: alepha2502.TOptional<alepha2502.TString>;
|
|
8035
|
+
lastName: alepha2502.TOptional<alepha2502.TString>;
|
|
8036
|
+
picture: alepha2502.TOptional<alepha2502.TString>;
|
|
8037
|
+
enabled: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
8038
|
+
emailVerified: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
7482
8039
|
}>;
|
|
7483
8040
|
}>;
|
|
7484
8041
|
/**
|
|
7485
8042
|
* Create a new user.
|
|
7486
8043
|
*/
|
|
7487
8044
|
readonly createUser: ActionPrimitiveFn<{
|
|
7488
|
-
query:
|
|
7489
|
-
userRealmName:
|
|
8045
|
+
query: alepha2502.TObject<{
|
|
8046
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
7490
8047
|
}>;
|
|
7491
|
-
body:
|
|
7492
|
-
id:
|
|
7493
|
-
email:
|
|
7494
|
-
username:
|
|
7495
|
-
picture:
|
|
7496
|
-
roles:
|
|
7497
|
-
version:
|
|
7498
|
-
createdAt:
|
|
7499
|
-
updatedAt:
|
|
7500
|
-
phoneNumber:
|
|
7501
|
-
firstName:
|
|
7502
|
-
lastName:
|
|
7503
|
-
enabled:
|
|
7504
|
-
emailVerified:
|
|
8048
|
+
body: alepha2502.TObject<{
|
|
8049
|
+
id: alepha2502.TOptional<PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>>;
|
|
8050
|
+
email: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
8051
|
+
username: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
8052
|
+
picture: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
8053
|
+
roles: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
8054
|
+
version: alepha2502.TOptional<PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>>;
|
|
8055
|
+
createdAt: alepha2502.TOptional<PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>>;
|
|
8056
|
+
updatedAt: alepha2502.TOptional<PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>>;
|
|
8057
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
8058
|
+
firstName: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
8059
|
+
lastName: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
8060
|
+
enabled: alepha2502.TOptional<PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>>;
|
|
8061
|
+
emailVerified: alepha2502.TOptional<PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>>;
|
|
7505
8062
|
}>;
|
|
7506
|
-
response:
|
|
7507
|
-
id: PgAttr<PgAttr<
|
|
7508
|
-
version: PgAttr<PgAttr<
|
|
7509
|
-
createdAt: PgAttr<PgAttr<
|
|
7510
|
-
updatedAt: PgAttr<PgAttr<
|
|
7511
|
-
realm: PgAttr<
|
|
7512
|
-
username:
|
|
7513
|
-
email:
|
|
7514
|
-
phoneNumber:
|
|
7515
|
-
roles: PgAttr<
|
|
7516
|
-
firstName:
|
|
7517
|
-
lastName:
|
|
7518
|
-
picture:
|
|
7519
|
-
enabled: PgAttr<
|
|
7520
|
-
emailVerified: PgAttr<
|
|
8063
|
+
response: alepha2502.TObject<{
|
|
8064
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
8065
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
8066
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
8067
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
8068
|
+
realm: PgAttr<alepha2502.TString, typeof PG_DEFAULT>;
|
|
8069
|
+
username: alepha2502.TOptional<alepha2502.TString>;
|
|
8070
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
8071
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TString>;
|
|
8072
|
+
roles: PgAttr<alepha2502.TArray<alepha2502.TString>, typeof PG_DEFAULT>;
|
|
8073
|
+
firstName: alepha2502.TOptional<alepha2502.TString>;
|
|
8074
|
+
lastName: alepha2502.TOptional<alepha2502.TString>;
|
|
8075
|
+
picture: alepha2502.TOptional<alepha2502.TString>;
|
|
8076
|
+
enabled: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
8077
|
+
emailVerified: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
7521
8078
|
}>;
|
|
7522
8079
|
}>;
|
|
7523
8080
|
/**
|
|
@@ -7525,80 +8082,80 @@ declare class UserController {
|
|
|
7525
8082
|
* Validates verification codes and creates the user.
|
|
7526
8083
|
*/
|
|
7527
8084
|
readonly createUserFromIntent: ActionPrimitiveFn<{
|
|
7528
|
-
body:
|
|
7529
|
-
intentId:
|
|
7530
|
-
emailCode:
|
|
7531
|
-
phoneCode:
|
|
7532
|
-
captchaToken:
|
|
8085
|
+
body: alepha2502.TObject<{
|
|
8086
|
+
intentId: alepha2502.TString;
|
|
8087
|
+
emailCode: alepha2502.TOptional<alepha2502.TString>;
|
|
8088
|
+
phoneCode: alepha2502.TOptional<alepha2502.TString>;
|
|
8089
|
+
captchaToken: alepha2502.TOptional<alepha2502.TString>;
|
|
7533
8090
|
}>;
|
|
7534
|
-
response:
|
|
7535
|
-
id: PgAttr<PgAttr<
|
|
7536
|
-
version: PgAttr<PgAttr<
|
|
7537
|
-
createdAt: PgAttr<PgAttr<
|
|
7538
|
-
updatedAt: PgAttr<PgAttr<
|
|
7539
|
-
realm: PgAttr<
|
|
7540
|
-
username:
|
|
7541
|
-
email:
|
|
7542
|
-
phoneNumber:
|
|
7543
|
-
roles: PgAttr<
|
|
7544
|
-
firstName:
|
|
7545
|
-
lastName:
|
|
7546
|
-
picture:
|
|
7547
|
-
enabled: PgAttr<
|
|
7548
|
-
emailVerified: PgAttr<
|
|
8091
|
+
response: alepha2502.TObject<{
|
|
8092
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
8093
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
8094
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
8095
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
8096
|
+
realm: PgAttr<alepha2502.TString, typeof PG_DEFAULT>;
|
|
8097
|
+
username: alepha2502.TOptional<alepha2502.TString>;
|
|
8098
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
8099
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TString>;
|
|
8100
|
+
roles: PgAttr<alepha2502.TArray<alepha2502.TString>, typeof PG_DEFAULT>;
|
|
8101
|
+
firstName: alepha2502.TOptional<alepha2502.TString>;
|
|
8102
|
+
lastName: alepha2502.TOptional<alepha2502.TString>;
|
|
8103
|
+
picture: alepha2502.TOptional<alepha2502.TString>;
|
|
8104
|
+
enabled: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
8105
|
+
emailVerified: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
7549
8106
|
}>;
|
|
7550
8107
|
}>;
|
|
7551
8108
|
/**
|
|
7552
8109
|
* Update a user.
|
|
7553
8110
|
*/
|
|
7554
8111
|
readonly updateUser: ActionPrimitiveFn<{
|
|
7555
|
-
params:
|
|
7556
|
-
id:
|
|
8112
|
+
params: alepha2502.TObject<{
|
|
8113
|
+
id: alepha2502.TString;
|
|
7557
8114
|
}>;
|
|
7558
|
-
query:
|
|
7559
|
-
userRealmName:
|
|
8115
|
+
query: alepha2502.TObject<{
|
|
8116
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
7560
8117
|
}>;
|
|
7561
|
-
body:
|
|
7562
|
-
realm:
|
|
7563
|
-
email:
|
|
7564
|
-
picture:
|
|
7565
|
-
roles:
|
|
7566
|
-
phoneNumber:
|
|
7567
|
-
firstName:
|
|
7568
|
-
lastName:
|
|
7569
|
-
enabled:
|
|
8118
|
+
body: alepha2502.TObject<{
|
|
8119
|
+
realm: alepha2502.TOptional<PgAttr<alepha2502.TString, typeof PG_DEFAULT>>;
|
|
8120
|
+
email: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
8121
|
+
picture: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
8122
|
+
roles: alepha2502.TOptional<alepha2502.TArray<alepha2502.TString>>;
|
|
8123
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
8124
|
+
firstName: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
8125
|
+
lastName: alepha2502.TOptional<alepha2502.TOptional<alepha2502.TString>>;
|
|
8126
|
+
enabled: alepha2502.TOptional<PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>>;
|
|
7570
8127
|
}>;
|
|
7571
|
-
response:
|
|
7572
|
-
id: PgAttr<PgAttr<
|
|
7573
|
-
version: PgAttr<PgAttr<
|
|
7574
|
-
createdAt: PgAttr<PgAttr<
|
|
7575
|
-
updatedAt: PgAttr<PgAttr<
|
|
7576
|
-
realm: PgAttr<
|
|
7577
|
-
username:
|
|
7578
|
-
email:
|
|
7579
|
-
phoneNumber:
|
|
7580
|
-
roles: PgAttr<
|
|
7581
|
-
firstName:
|
|
7582
|
-
lastName:
|
|
7583
|
-
picture:
|
|
7584
|
-
enabled: PgAttr<
|
|
7585
|
-
emailVerified: PgAttr<
|
|
8128
|
+
response: alepha2502.TObject<{
|
|
8129
|
+
id: PgAttr<PgAttr<alepha2502.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
|
|
8130
|
+
version: PgAttr<PgAttr<alepha2502.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
|
|
8131
|
+
createdAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
|
|
8132
|
+
updatedAt: PgAttr<PgAttr<alepha2502.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
|
|
8133
|
+
realm: PgAttr<alepha2502.TString, typeof PG_DEFAULT>;
|
|
8134
|
+
username: alepha2502.TOptional<alepha2502.TString>;
|
|
8135
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
8136
|
+
phoneNumber: alepha2502.TOptional<alepha2502.TString>;
|
|
8137
|
+
roles: PgAttr<alepha2502.TArray<alepha2502.TString>, typeof PG_DEFAULT>;
|
|
8138
|
+
firstName: alepha2502.TOptional<alepha2502.TString>;
|
|
8139
|
+
lastName: alepha2502.TOptional<alepha2502.TString>;
|
|
8140
|
+
picture: alepha2502.TOptional<alepha2502.TString>;
|
|
8141
|
+
enabled: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
8142
|
+
emailVerified: PgAttr<alepha2502.TBoolean, typeof PG_DEFAULT>;
|
|
7586
8143
|
}>;
|
|
7587
8144
|
}>;
|
|
7588
8145
|
/**
|
|
7589
8146
|
* Delete a user.
|
|
7590
8147
|
*/
|
|
7591
8148
|
readonly deleteUser: ActionPrimitiveFn<{
|
|
7592
|
-
params:
|
|
7593
|
-
id:
|
|
8149
|
+
params: alepha2502.TObject<{
|
|
8150
|
+
id: alepha2502.TString;
|
|
7594
8151
|
}>;
|
|
7595
|
-
query:
|
|
7596
|
-
userRealmName:
|
|
8152
|
+
query: alepha2502.TObject<{
|
|
8153
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
7597
8154
|
}>;
|
|
7598
|
-
response:
|
|
7599
|
-
ok:
|
|
7600
|
-
id:
|
|
7601
|
-
count:
|
|
8155
|
+
response: alepha2502.TObject<{
|
|
8156
|
+
ok: alepha2502.TBoolean;
|
|
8157
|
+
id: alepha2502.TOptional<alepha2502.TUnion<[alepha2502.TString, alepha2502.TInteger]>>;
|
|
8158
|
+
count: alepha2502.TOptional<alepha2502.TNumber>;
|
|
7602
8159
|
}>;
|
|
7603
8160
|
}>;
|
|
7604
8161
|
/**
|
|
@@ -7606,15 +8163,15 @@ declare class UserController {
|
|
|
7606
8163
|
* Validates email, sends verification code, and stores intent in cache.
|
|
7607
8164
|
*/
|
|
7608
8165
|
readonly createPasswordResetIntent: ActionPrimitiveFn<{
|
|
7609
|
-
query:
|
|
7610
|
-
userRealmName:
|
|
8166
|
+
query: alepha2502.TObject<{
|
|
8167
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
7611
8168
|
}>;
|
|
7612
|
-
body:
|
|
7613
|
-
email:
|
|
8169
|
+
body: alepha2502.TObject<{
|
|
8170
|
+
email: alepha2502.TString;
|
|
7614
8171
|
}>;
|
|
7615
|
-
response:
|
|
7616
|
-
intentId:
|
|
7617
|
-
expiresAt:
|
|
8172
|
+
response: alepha2502.TObject<{
|
|
8173
|
+
intentId: alepha2502.TString;
|
|
8174
|
+
expiresAt: alepha2502.TString;
|
|
7618
8175
|
}>;
|
|
7619
8176
|
}>;
|
|
7620
8177
|
/**
|
|
@@ -7622,61 +8179,61 @@ declare class UserController {
|
|
|
7622
8179
|
* Validates verification code, updates password, and invalidates sessions.
|
|
7623
8180
|
*/
|
|
7624
8181
|
readonly completePasswordReset: ActionPrimitiveFn<{
|
|
7625
|
-
body:
|
|
7626
|
-
intentId:
|
|
7627
|
-
code:
|
|
7628
|
-
newPassword:
|
|
8182
|
+
body: alepha2502.TObject<{
|
|
8183
|
+
intentId: alepha2502.TString;
|
|
8184
|
+
code: alepha2502.TString;
|
|
8185
|
+
newPassword: alepha2502.TString;
|
|
7629
8186
|
}>;
|
|
7630
|
-
response:
|
|
7631
|
-
ok:
|
|
7632
|
-
id:
|
|
7633
|
-
count:
|
|
8187
|
+
response: alepha2502.TObject<{
|
|
8188
|
+
ok: alepha2502.TBoolean;
|
|
8189
|
+
id: alepha2502.TOptional<alepha2502.TUnion<[alepha2502.TString, alepha2502.TInteger]>>;
|
|
8190
|
+
count: alepha2502.TOptional<alepha2502.TNumber>;
|
|
7634
8191
|
}>;
|
|
7635
8192
|
}>;
|
|
7636
8193
|
/**
|
|
7637
8194
|
* @deprecated Use createPasswordResetIntent instead
|
|
7638
8195
|
*/
|
|
7639
8196
|
requestPasswordReset: ActionPrimitiveFn<{
|
|
7640
|
-
query:
|
|
7641
|
-
userRealmName:
|
|
8197
|
+
query: alepha2502.TObject<{
|
|
8198
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
7642
8199
|
}>;
|
|
7643
|
-
body:
|
|
7644
|
-
email:
|
|
8200
|
+
body: alepha2502.TObject<{
|
|
8201
|
+
email: alepha2502.TString;
|
|
7645
8202
|
}>;
|
|
7646
|
-
response:
|
|
7647
|
-
success:
|
|
7648
|
-
message:
|
|
8203
|
+
response: alepha2502.TObject<{
|
|
8204
|
+
success: alepha2502.TBoolean;
|
|
8205
|
+
message: alepha2502.TString;
|
|
7649
8206
|
}>;
|
|
7650
8207
|
}>;
|
|
7651
8208
|
/**
|
|
7652
8209
|
* @deprecated Use completePasswordReset instead
|
|
7653
8210
|
*/
|
|
7654
8211
|
validateResetToken: ActionPrimitiveFn<{
|
|
7655
|
-
query:
|
|
7656
|
-
email:
|
|
7657
|
-
token:
|
|
7658
|
-
userRealmName:
|
|
8212
|
+
query: alepha2502.TObject<{
|
|
8213
|
+
email: alepha2502.TString;
|
|
8214
|
+
token: alepha2502.TString;
|
|
8215
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
7659
8216
|
}>;
|
|
7660
|
-
response:
|
|
7661
|
-
valid:
|
|
7662
|
-
email:
|
|
8217
|
+
response: alepha2502.TObject<{
|
|
8218
|
+
valid: alepha2502.TBoolean;
|
|
8219
|
+
email: alepha2502.TOptional<alepha2502.TString>;
|
|
7663
8220
|
}>;
|
|
7664
8221
|
}>;
|
|
7665
8222
|
/**
|
|
7666
8223
|
* @deprecated Use completePasswordReset instead
|
|
7667
8224
|
*/
|
|
7668
8225
|
resetPassword: ActionPrimitiveFn<{
|
|
7669
|
-
query:
|
|
7670
|
-
userRealmName:
|
|
8226
|
+
query: alepha2502.TObject<{
|
|
8227
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
7671
8228
|
}>;
|
|
7672
|
-
body:
|
|
7673
|
-
email:
|
|
7674
|
-
token:
|
|
7675
|
-
newPassword:
|
|
8229
|
+
body: alepha2502.TObject<{
|
|
8230
|
+
email: alepha2502.TString;
|
|
8231
|
+
token: alepha2502.TString;
|
|
8232
|
+
newPassword: alepha2502.TString;
|
|
7676
8233
|
}>;
|
|
7677
|
-
response:
|
|
7678
|
-
success:
|
|
7679
|
-
message:
|
|
8234
|
+
response: alepha2502.TObject<{
|
|
8235
|
+
success: alepha2502.TBoolean;
|
|
8236
|
+
message: alepha2502.TString;
|
|
7680
8237
|
}>;
|
|
7681
8238
|
}>;
|
|
7682
8239
|
/**
|
|
@@ -7686,17 +8243,17 @@ declare class UserController {
|
|
|
7686
8243
|
* @param verifyUrl - Required when method is "link". The base URL for the verification link. Token and email will be appended as query params.
|
|
7687
8244
|
*/
|
|
7688
8245
|
requestEmailVerification: ActionPrimitiveFn<{
|
|
7689
|
-
query:
|
|
7690
|
-
userRealmName:
|
|
7691
|
-
method:
|
|
7692
|
-
verifyUrl:
|
|
8246
|
+
query: alepha2502.TObject<{
|
|
8247
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
8248
|
+
method: alepha2502.TOptional<alepha2502.TUnsafe<"link" | "code">>;
|
|
8249
|
+
verifyUrl: alepha2502.TOptional<alepha2502.TString>;
|
|
7693
8250
|
}>;
|
|
7694
|
-
body:
|
|
7695
|
-
email:
|
|
8251
|
+
body: alepha2502.TObject<{
|
|
8252
|
+
email: alepha2502.TString;
|
|
7696
8253
|
}>;
|
|
7697
|
-
response:
|
|
7698
|
-
success:
|
|
7699
|
-
message:
|
|
8254
|
+
response: alepha2502.TObject<{
|
|
8255
|
+
success: alepha2502.TBoolean;
|
|
8256
|
+
message: alepha2502.TString;
|
|
7700
8257
|
}>;
|
|
7701
8258
|
}>;
|
|
7702
8259
|
/**
|
|
@@ -7704,67 +8261,32 @@ declare class UserController {
|
|
|
7704
8261
|
* Updates the user's emailVerified status.
|
|
7705
8262
|
*/
|
|
7706
8263
|
verifyEmail: ActionPrimitiveFn<{
|
|
7707
|
-
query:
|
|
7708
|
-
userRealmName:
|
|
8264
|
+
query: alepha2502.TObject<{
|
|
8265
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
7709
8266
|
}>;
|
|
7710
|
-
body:
|
|
7711
|
-
email:
|
|
7712
|
-
token:
|
|
8267
|
+
body: alepha2502.TObject<{
|
|
8268
|
+
email: alepha2502.TString;
|
|
8269
|
+
token: alepha2502.TString;
|
|
7713
8270
|
}>;
|
|
7714
|
-
response:
|
|
7715
|
-
success:
|
|
7716
|
-
message:
|
|
8271
|
+
response: alepha2502.TObject<{
|
|
8272
|
+
success: alepha2502.TBoolean;
|
|
8273
|
+
message: alepha2502.TString;
|
|
7717
8274
|
}>;
|
|
7718
8275
|
}>;
|
|
7719
8276
|
/**
|
|
7720
8277
|
* Check if an email is verified.
|
|
7721
8278
|
*/
|
|
7722
8279
|
checkEmailVerification: ActionPrimitiveFn<{
|
|
7723
|
-
query:
|
|
7724
|
-
email:
|
|
7725
|
-
userRealmName:
|
|
8280
|
+
query: alepha2502.TObject<{
|
|
8281
|
+
email: alepha2502.TString;
|
|
8282
|
+
userRealmName: alepha2502.TOptional<alepha2502.TString>;
|
|
7726
8283
|
}>;
|
|
7727
|
-
response:
|
|
7728
|
-
verified:
|
|
8284
|
+
response: alepha2502.TObject<{
|
|
8285
|
+
verified: alepha2502.TBoolean;
|
|
7729
8286
|
}>;
|
|
7730
8287
|
}>;
|
|
7731
8288
|
}
|
|
7732
8289
|
//#endregion
|
|
7733
|
-
//#region ../../../alepha/src/api-users/primitives/$userRealm.d.ts
|
|
7734
|
-
interface UserRealmOptions {
|
|
7735
|
-
/**
|
|
7736
|
-
* Secret key for signing tokens.
|
|
7737
|
-
*
|
|
7738
|
-
* If not provided, the secret from the SecurityProvider will be used (usually from the APP_SECRET environment variable).
|
|
7739
|
-
*/
|
|
7740
|
-
secret?: string;
|
|
7741
|
-
/**
|
|
7742
|
-
* Realm configuration options.
|
|
7743
|
-
*
|
|
7744
|
-
* It's already pre-configured for user management with admin and user roles.
|
|
7745
|
-
*/
|
|
7746
|
-
realm?: Partial<RealmPrimitiveOptions>;
|
|
7747
|
-
/**
|
|
7748
|
-
* Override entities.
|
|
7749
|
-
*/
|
|
7750
|
-
entities?: {
|
|
7751
|
-
users?: Repository<typeof users.schema>;
|
|
7752
|
-
identities?: Repository<typeof identities.schema>;
|
|
7753
|
-
sessions?: Repository<typeof sessions.schema>;
|
|
7754
|
-
};
|
|
7755
|
-
settings?: Partial<RealmAuthSettings>;
|
|
7756
|
-
identities?: {
|
|
7757
|
-
credentials?: true;
|
|
7758
|
-
google?: true;
|
|
7759
|
-
github?: true;
|
|
7760
|
-
};
|
|
7761
|
-
modules?: {
|
|
7762
|
-
files?: boolean;
|
|
7763
|
-
audits?: boolean;
|
|
7764
|
-
jobs?: boolean;
|
|
7765
|
-
};
|
|
7766
|
-
}
|
|
7767
|
-
//#endregion
|
|
7768
8290
|
//#region ../../src/admin/AdminRouter.d.ts
|
|
7769
8291
|
declare class AdminRouter {
|
|
7770
8292
|
protected readonly router: ReactRouter<object>;
|
|
@@ -7889,7 +8411,7 @@ declare class MainRouter {
|
|
|
7889
8411
|
*
|
|
7890
8412
|
* @module alepha.ui.admin
|
|
7891
8413
|
*/
|
|
7892
|
-
declare const AlephaUIAdmin:
|
|
8414
|
+
declare const AlephaUIAdmin: alepha2502.Service<alepha2502.Module>;
|
|
7893
8415
|
//#endregion
|
|
7894
8416
|
export { AdminAudits, AdminFiles, AdminJobs, AdminLayout, AdminNotifications, AdminParameters, AdminRouter, AdminSessions, AdminUserAudits, AdminUserCreate, AdminUserDetails, AdminUserLayout, AdminUserSessions, AdminUserSettings, AdminUsers, AdminVerifications, AlephaUIAdmin, MainRouter };
|
|
7895
8417
|
//# sourceMappingURL=index.d.ts.map
|