@aeriajs/builtins 0.0.164 → 0.0.166
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/collections/file/index.d.ts +14 -197
- package/dist/collections/log/index.d.ts +7 -45
- package/dist/collections/resourceUsage/index.d.ts +3 -39
- package/dist/collections/user/createAccount.d.ts +1 -0
- package/dist/collections/user/description.d.ts +1 -0
- package/dist/collections/user/description.js +1 -0
- package/dist/collections/user/description.mjs +2 -1
- package/dist/collections/user/getCurrentUser.d.ts +1 -0
- package/dist/collections/user/index.d.ts +18 -481
- package/dist/collections/user/index.js +3 -1
- package/dist/collections/user/index.mjs +5 -3
- package/dist/functions/describe.d.ts +1 -1
- package/dist/index.d.ts +119 -840
- package/package.json +6 -6
package/dist/index.d.ts
CHANGED
|
@@ -9,159 +9,7 @@ type Log = typeof log.item;
|
|
|
9
9
|
type ResourceUsage = typeof resourceUsage.item;
|
|
10
10
|
type User = typeof user.item;
|
|
11
11
|
export declare const collections: {
|
|
12
|
-
file: Omit<import("@aeriajs/types").Collection<{
|
|
13
|
-
description: {
|
|
14
|
-
readonly $id: "file";
|
|
15
|
-
readonly icon: "paperclip";
|
|
16
|
-
readonly owned: "always";
|
|
17
|
-
readonly presets: readonly ["owned"];
|
|
18
|
-
readonly indexes: readonly ["name", "link", "type"];
|
|
19
|
-
readonly properties: {
|
|
20
|
-
readonly type: {
|
|
21
|
-
readonly type: "string";
|
|
22
|
-
};
|
|
23
|
-
readonly size: {
|
|
24
|
-
readonly type: "number";
|
|
25
|
-
};
|
|
26
|
-
readonly last_modified: {
|
|
27
|
-
readonly type: "string";
|
|
28
|
-
readonly format: "date-time";
|
|
29
|
-
};
|
|
30
|
-
readonly name: {
|
|
31
|
-
readonly type: "string";
|
|
32
|
-
};
|
|
33
|
-
readonly absolute_path: {
|
|
34
|
-
readonly type: "string";
|
|
35
|
-
};
|
|
36
|
-
readonly relative_path: {
|
|
37
|
-
readonly type: "string";
|
|
38
|
-
};
|
|
39
|
-
readonly immutable: {
|
|
40
|
-
readonly type: "boolean";
|
|
41
|
-
};
|
|
42
|
-
readonly link: {
|
|
43
|
-
readonly getter: (doc: object) => Promise<string | undefined>;
|
|
44
|
-
};
|
|
45
|
-
readonly download_link: {
|
|
46
|
-
readonly getter: (doc: object) => Promise<string | undefined>;
|
|
47
|
-
};
|
|
48
|
-
};
|
|
49
|
-
readonly actions: {
|
|
50
|
-
readonly deleteAll: {
|
|
51
|
-
readonly label: "Remover";
|
|
52
|
-
readonly ask: true;
|
|
53
|
-
readonly selection: true;
|
|
54
|
-
};
|
|
55
|
-
};
|
|
56
|
-
readonly individualActions: {
|
|
57
|
-
readonly remove: {
|
|
58
|
-
readonly label: "Remover";
|
|
59
|
-
readonly icon: "trash";
|
|
60
|
-
readonly ask: true;
|
|
61
|
-
};
|
|
62
|
-
};
|
|
63
|
-
};
|
|
64
|
-
functions: {
|
|
65
|
-
readonly get: (payload: import("@aeriajs/types").GetPayload<import("@aeriajs/types").SchemaWithId<any>>, context: import("@aeriajs/types").StrictContext<any>, options?: import("@aeriajs/core").GetOptions) => Promise<import("@aeriajs/types").GetReturnType<import("@aeriajs/types").SchemaWithId<any>>>;
|
|
66
|
-
readonly insert: (payload: {
|
|
67
|
-
what: {
|
|
68
|
-
content: string;
|
|
69
|
-
} & Pick<import("@aeriajs/types").PackReferences<import("@aeriajs/types").SchemaWithId<typeof import("./collections/file/description.js").description>>, "_id" | "name" | "owner" | "absolute_path">;
|
|
70
|
-
}, context: import("@aeriajs/types").Context<typeof import("./collections/file/description.js").description>) => Promise<import("@aeriajs/types").InsertReturnType<import("@aeriajs/types").SchemaWithId<{
|
|
71
|
-
readonly $id: "file";
|
|
72
|
-
readonly icon: "paperclip";
|
|
73
|
-
readonly owned: "always";
|
|
74
|
-
readonly presets: readonly ["owned"];
|
|
75
|
-
readonly indexes: readonly ["name", "link", "type"];
|
|
76
|
-
readonly properties: {
|
|
77
|
-
readonly type: {
|
|
78
|
-
readonly type: "string";
|
|
79
|
-
};
|
|
80
|
-
readonly size: {
|
|
81
|
-
readonly type: "number";
|
|
82
|
-
};
|
|
83
|
-
readonly last_modified: {
|
|
84
|
-
readonly type: "string";
|
|
85
|
-
readonly format: "date-time";
|
|
86
|
-
};
|
|
87
|
-
readonly name: {
|
|
88
|
-
readonly type: "string";
|
|
89
|
-
};
|
|
90
|
-
readonly absolute_path: {
|
|
91
|
-
readonly type: "string";
|
|
92
|
-
};
|
|
93
|
-
readonly relative_path: {
|
|
94
|
-
readonly type: "string";
|
|
95
|
-
};
|
|
96
|
-
readonly immutable: {
|
|
97
|
-
readonly type: "boolean";
|
|
98
|
-
};
|
|
99
|
-
readonly link: {
|
|
100
|
-
readonly getter: (doc: object) => Promise<string | undefined>;
|
|
101
|
-
};
|
|
102
|
-
readonly download_link: {
|
|
103
|
-
readonly getter: (doc: object) => Promise<string | undefined>;
|
|
104
|
-
};
|
|
105
|
-
};
|
|
106
|
-
readonly actions: {
|
|
107
|
-
readonly deleteAll: {
|
|
108
|
-
readonly label: "Remover";
|
|
109
|
-
readonly ask: true;
|
|
110
|
-
readonly selection: true;
|
|
111
|
-
};
|
|
112
|
-
};
|
|
113
|
-
readonly individualActions: {
|
|
114
|
-
readonly remove: {
|
|
115
|
-
readonly label: "Remover";
|
|
116
|
-
readonly icon: "trash";
|
|
117
|
-
readonly ask: true;
|
|
118
|
-
};
|
|
119
|
-
};
|
|
120
|
-
}>>>;
|
|
121
|
-
readonly download: (payload: {
|
|
122
|
-
fileId: string;
|
|
123
|
-
options: readonly ("picture" | "download")[];
|
|
124
|
-
noHeaders?: boolean;
|
|
125
|
-
}, context: import("@aeriajs/types").Context<typeof import("./collections/file/description.js").description>) => Promise<import("@aeriajs/types").Result.Error<{
|
|
126
|
-
readonly code: import("@aeriajs/types").ACError.ResourceNotFound;
|
|
127
|
-
} & {
|
|
128
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.NotFound;
|
|
129
|
-
}> | import("fs").ReadStream>;
|
|
130
|
-
readonly remove: (payload: import("@aeriajs/types").RemovePayload<import("@aeriajs/types").SchemaWithId<typeof import("./collections/file/description.js").description>>, context: import("@aeriajs/types").Context<typeof import("./collections/file/description.js").description>) => Promise<{
|
|
131
|
-
readonly _tag: "Result";
|
|
132
|
-
readonly error: undefined;
|
|
133
|
-
readonly result: import("mongodb").WithId<Omit<import("@aeriajs/types").PackReferences<import("@aeriajs/types").SchemaWithId<import("@aeriajs/types").Description>>, "_id">> | null;
|
|
134
|
-
} | import("@aeriajs/types").Result.Error<{
|
|
135
|
-
readonly code: import("@aeriajs/types").ACError.ResourceNotFound;
|
|
136
|
-
} & {
|
|
137
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.NotFound;
|
|
138
|
-
}> | import("@aeriajs/types").Result.Error<{
|
|
139
|
-
readonly code: import("@aeriajs/types").ACError.OwnershipError;
|
|
140
|
-
} & {
|
|
141
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.Forbidden;
|
|
142
|
-
}>>;
|
|
143
|
-
readonly removeAll: (payload: import("@aeriajs/types").RemoveAllPayload, context: import("@aeriajs/types").Context<typeof import("./collections/file/description.js").description>) => Promise<{
|
|
144
|
-
readonly _tag: "Result";
|
|
145
|
-
readonly error: undefined;
|
|
146
|
-
readonly result: import("mongodb").WithId<Omit<import("@aeriajs/types").PackReferences<import("@aeriajs/types").SchemaWithId<import("@aeriajs/types").Description>>, "_id">> | null;
|
|
147
|
-
} | import("@aeriajs/types").Result.Error<{
|
|
148
|
-
readonly code: import("@aeriajs/types").ACError.ResourceNotFound;
|
|
149
|
-
} & {
|
|
150
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.NotFound;
|
|
151
|
-
}> | import("@aeriajs/types").Result.Error<{
|
|
152
|
-
readonly code: import("@aeriajs/types").ACError.OwnershipError;
|
|
153
|
-
} & {
|
|
154
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.Forbidden;
|
|
155
|
-
}>>;
|
|
156
|
-
};
|
|
157
|
-
exposedFunctions: {
|
|
158
|
-
readonly get: "unauthenticated";
|
|
159
|
-
readonly insert: true;
|
|
160
|
-
readonly download: "unauthenticated";
|
|
161
|
-
readonly remove: true;
|
|
162
|
-
readonly removeAll: true;
|
|
163
|
-
};
|
|
164
|
-
}>, "description" | "functions" | "item" | "exposedFunctions" | "security"> & {
|
|
12
|
+
file: Omit<import("@aeriajs/types").Collection<never>, "functions" | "description" | "middlewares" | "item" | "exposedFunctions" | "security"> & {
|
|
165
13
|
item: import("@aeriajs/types").SchemaWithId<{
|
|
166
14
|
readonly $id: "file";
|
|
167
15
|
readonly icon: "paperclip";
|
|
@@ -265,8 +113,8 @@ export declare const collections: {
|
|
|
265
113
|
};
|
|
266
114
|
};
|
|
267
115
|
functions: {
|
|
268
|
-
|
|
269
|
-
|
|
116
|
+
get: (payload: import("@aeriajs/types").GetPayload<import("@aeriajs/types").SchemaWithId<any>>, context: import("@aeriajs/types").StrictContext<any>, options?: import("@aeriajs/core").GetOptions) => Promise<import("@aeriajs/types").GetReturnType<import("@aeriajs/types").SchemaWithId<any>>>;
|
|
117
|
+
insert: (payload: {
|
|
270
118
|
what: {
|
|
271
119
|
content: string;
|
|
272
120
|
} & Pick<import("@aeriajs/types").PackReferences<import("@aeriajs/types").SchemaWithId<typeof import("./collections/file/description.js").description>>, "_id" | "name" | "owner" | "absolute_path">;
|
|
@@ -321,7 +169,7 @@ export declare const collections: {
|
|
|
321
169
|
};
|
|
322
170
|
};
|
|
323
171
|
}>>>;
|
|
324
|
-
|
|
172
|
+
download: (payload: {
|
|
325
173
|
fileId: string;
|
|
326
174
|
options: readonly ("picture" | "download")[];
|
|
327
175
|
noHeaders?: boolean;
|
|
@@ -330,7 +178,7 @@ export declare const collections: {
|
|
|
330
178
|
} & {
|
|
331
179
|
httpStatus: import("@aeriajs/types").HTTPStatus.NotFound;
|
|
332
180
|
}> | import("fs").ReadStream>;
|
|
333
|
-
|
|
181
|
+
remove: (payload: import("@aeriajs/types").RemovePayload<import("@aeriajs/types").SchemaWithId<typeof import("./collections/file/description.js").description>>, context: import("@aeriajs/types").Context<typeof import("./collections/file/description.js").description>) => Promise<{
|
|
334
182
|
readonly _tag: "Result";
|
|
335
183
|
readonly error: undefined;
|
|
336
184
|
readonly result: import("mongodb").WithId<Omit<import("@aeriajs/types").PackReferences<import("@aeriajs/types").SchemaWithId<import("@aeriajs/types").Description>>, "_id">> | null;
|
|
@@ -343,7 +191,7 @@ export declare const collections: {
|
|
|
343
191
|
} & {
|
|
344
192
|
httpStatus: import("@aeriajs/types").HTTPStatus.Forbidden;
|
|
345
193
|
}>>;
|
|
346
|
-
|
|
194
|
+
removeAll: (payload: import("@aeriajs/types").RemoveAllPayload, context: import("@aeriajs/types").Context<typeof import("./collections/file/description.js").description>) => Promise<{
|
|
347
195
|
readonly _tag: "Result";
|
|
348
196
|
readonly error: undefined;
|
|
349
197
|
readonly result: import("mongodb").WithId<Omit<import("@aeriajs/types").PackReferences<import("@aeriajs/types").SchemaWithId<import("@aeriajs/types").Description>>, "_id">> | null;
|
|
@@ -358,45 +206,14 @@ export declare const collections: {
|
|
|
358
206
|
}>>;
|
|
359
207
|
};
|
|
360
208
|
contracts: {
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
209
|
+
get?: import("@aeriajs/types").Contract | undefined;
|
|
210
|
+
insert?: import("@aeriajs/types").Contract | undefined;
|
|
211
|
+
download?: import("@aeriajs/types").Contract | undefined;
|
|
212
|
+
remove?: import("@aeriajs/types").Contract | undefined;
|
|
213
|
+
removeAll?: import("@aeriajs/types").Contract | undefined;
|
|
366
214
|
};
|
|
367
215
|
};
|
|
368
|
-
tempFile: Omit<import("@aeriajs/types").Collection<{
|
|
369
|
-
description: {
|
|
370
|
-
readonly $id: "tempFile";
|
|
371
|
-
readonly icon: "file";
|
|
372
|
-
readonly hidden: true;
|
|
373
|
-
readonly temporary: {
|
|
374
|
-
readonly index: "created_at";
|
|
375
|
-
readonly expireAfterSeconds: 3600;
|
|
376
|
-
};
|
|
377
|
-
readonly properties: {
|
|
378
|
-
readonly created_at: {
|
|
379
|
-
readonly type: "string";
|
|
380
|
-
readonly format: "date-time";
|
|
381
|
-
};
|
|
382
|
-
readonly absolute_path: {
|
|
383
|
-
readonly type: "string";
|
|
384
|
-
};
|
|
385
|
-
readonly size: {
|
|
386
|
-
readonly type: "number";
|
|
387
|
-
};
|
|
388
|
-
readonly mime: {
|
|
389
|
-
readonly type: "number";
|
|
390
|
-
};
|
|
391
|
-
readonly collection: {
|
|
392
|
-
readonly type: "string";
|
|
393
|
-
};
|
|
394
|
-
readonly filename: {
|
|
395
|
-
readonly type: "string";
|
|
396
|
-
};
|
|
397
|
-
};
|
|
398
|
-
};
|
|
399
|
-
}>, "description" | "functions" | "item" | "exposedFunctions" | "security"> & {
|
|
216
|
+
tempFile: Omit<import("@aeriajs/types").Collection<never>, "functions" | "description" | "middlewares" | "item" | "exposedFunctions" | "security"> & {
|
|
400
217
|
item: import("@aeriajs/types").SchemaWithId<{
|
|
401
218
|
readonly $id: "tempFile";
|
|
402
219
|
readonly icon: "file";
|
|
@@ -457,50 +274,12 @@ export declare const collections: {
|
|
|
457
274
|
};
|
|
458
275
|
};
|
|
459
276
|
};
|
|
460
|
-
functions: Record<string, (payload: any, context: import("@aeriajs/types").StrictContext<any>) => any> & {};
|
|
277
|
+
functions: (Record<string, (payload: any, context: import("@aeriajs/types").StrictContext<any>) => any> & {}) | undefined;
|
|
461
278
|
contracts: {
|
|
462
279
|
[x: string]: import("@aeriajs/types").Contract | undefined;
|
|
463
|
-
};
|
|
280
|
+
} | undefined;
|
|
464
281
|
};
|
|
465
|
-
log: Omit<import("@aeriajs/types").Collection<{
|
|
466
|
-
description: {
|
|
467
|
-
readonly $id: "log";
|
|
468
|
-
readonly icon: "magnifying-glass";
|
|
469
|
-
readonly required: readonly ["context", "message"];
|
|
470
|
-
readonly properties: {
|
|
471
|
-
readonly owner: {
|
|
472
|
-
readonly $ref: "user";
|
|
473
|
-
readonly noForm: true;
|
|
474
|
-
};
|
|
475
|
-
readonly context: {
|
|
476
|
-
readonly type: "string";
|
|
477
|
-
};
|
|
478
|
-
readonly message: {
|
|
479
|
-
readonly type: "string";
|
|
480
|
-
};
|
|
481
|
-
readonly details: {
|
|
482
|
-
readonly type: "object";
|
|
483
|
-
readonly variable: true;
|
|
484
|
-
};
|
|
485
|
-
readonly created_at: {
|
|
486
|
-
readonly type: "string";
|
|
487
|
-
readonly format: "date-time";
|
|
488
|
-
};
|
|
489
|
-
};
|
|
490
|
-
readonly presets: readonly ["view"];
|
|
491
|
-
readonly filters: readonly ["context", "message", "owner"];
|
|
492
|
-
};
|
|
493
|
-
functions: {
|
|
494
|
-
readonly get: (payload: import("@aeriajs/types").GetPayload<import("@aeriajs/types").SchemaWithId<any>>, context: import("@aeriajs/types").StrictContext<any>, options?: import("@aeriajs/core").GetOptions) => Promise<import("@aeriajs/types").GetReturnType<import("@aeriajs/types").SchemaWithId<any>>>;
|
|
495
|
-
readonly getAll: (payload: import("@aeriajs/types").GetAllPayload<import("@aeriajs/types").SchemaWithId<any>> | undefined, context: import("@aeriajs/types").StrictContext<any>, options?: import("@aeriajs/core").GetAllOptions) => Promise<import("@aeriajs/types").Result.Either<any, any>>;
|
|
496
|
-
readonly insert: (payload: import("@aeriajs/types").InsertPayload<import("@aeriajs/types").SchemaWithId<any>>, context: import("@aeriajs/types").StrictContext<any>, options?: import("@aeriajs/core").InsertOptions) => Promise<import("@aeriajs/types").InsertReturnType<import("@aeriajs/types").SchemaWithId<any>>>;
|
|
497
|
-
};
|
|
498
|
-
exposedFunctions: {
|
|
499
|
-
readonly get: true;
|
|
500
|
-
readonly getAll: true;
|
|
501
|
-
readonly insert: true;
|
|
502
|
-
};
|
|
503
|
-
}>, "description" | "functions" | "item" | "exposedFunctions" | "security"> & {
|
|
282
|
+
log: Omit<import("@aeriajs/types").Collection<never>, "functions" | "description" | "middlewares" | "item" | "exposedFunctions" | "security"> & {
|
|
504
283
|
item: import("@aeriajs/types").SchemaWithId<{
|
|
505
284
|
readonly $id: "log";
|
|
506
285
|
readonly icon: "magnifying-glass";
|
|
@@ -538,622 +317,111 @@ export declare const collections: {
|
|
|
538
317
|
readonly noForm: true;
|
|
539
318
|
};
|
|
540
319
|
readonly context: {
|
|
541
|
-
readonly type: "string";
|
|
542
|
-
};
|
|
543
|
-
readonly message: {
|
|
544
|
-
readonly type: "string";
|
|
545
|
-
};
|
|
546
|
-
readonly details: {
|
|
547
|
-
readonly type: "object";
|
|
548
|
-
readonly variable: true;
|
|
549
|
-
};
|
|
550
|
-
readonly created_at: {
|
|
551
|
-
readonly type: "string";
|
|
552
|
-
readonly format: "date-time";
|
|
553
|
-
};
|
|
554
|
-
};
|
|
555
|
-
readonly presets: readonly ["view"];
|
|
556
|
-
readonly filters: readonly ["context", "message", "owner"];
|
|
557
|
-
};
|
|
558
|
-
functions: {
|
|
559
|
-
readonly get: (payload: import("@aeriajs/types").GetPayload<import("@aeriajs/types").SchemaWithId<any>>, context: import("@aeriajs/types").StrictContext<any>, options?: import("@aeriajs/core").GetOptions) => Promise<import("@aeriajs/types").GetReturnType<import("@aeriajs/types").SchemaWithId<any>>>;
|
|
560
|
-
readonly getAll: (payload: import("@aeriajs/types").GetAllPayload<import("@aeriajs/types").SchemaWithId<any>> | undefined, context: import("@aeriajs/types").StrictContext<any>, options?: import("@aeriajs/core").GetAllOptions) => Promise<import("@aeriajs/types").Result.Either<any, any>>;
|
|
561
|
-
readonly insert: (payload: import("@aeriajs/types").InsertPayload<import("@aeriajs/types").SchemaWithId<any>>, context: import("@aeriajs/types").StrictContext<any>, options?: import("@aeriajs/core").InsertOptions) => Promise<import("@aeriajs/types").InsertReturnType<import("@aeriajs/types").SchemaWithId<any>>>;
|
|
562
|
-
};
|
|
563
|
-
contracts: {
|
|
564
|
-
readonly get?: import("@aeriajs/types").Contract | undefined;
|
|
565
|
-
readonly getAll?: import("@aeriajs/types").Contract | undefined;
|
|
566
|
-
readonly insert?: import("@aeriajs/types").Contract | undefined;
|
|
567
|
-
};
|
|
568
|
-
};
|
|
569
|
-
resourceUsage: Omit<import("@aeriajs/types").Collection<{
|
|
570
|
-
description: {
|
|
571
|
-
readonly $id: "resourceUsage";
|
|
572
|
-
readonly icon: "wrench";
|
|
573
|
-
readonly required: readonly ["usage"];
|
|
574
|
-
readonly properties: {
|
|
575
|
-
readonly user: {
|
|
576
|
-
readonly $ref: "user";
|
|
577
|
-
};
|
|
578
|
-
readonly address: {
|
|
579
|
-
readonly type: "string";
|
|
580
|
-
};
|
|
581
|
-
readonly usage: {
|
|
582
|
-
readonly type: "object";
|
|
583
|
-
readonly additionalProperties: {
|
|
584
|
-
readonly type: "object";
|
|
585
|
-
readonly properties: {
|
|
586
|
-
readonly hits: {
|
|
587
|
-
readonly type: "integer";
|
|
588
|
-
};
|
|
589
|
-
readonly points: {
|
|
590
|
-
readonly type: "integer";
|
|
591
|
-
};
|
|
592
|
-
readonly last_reach: {
|
|
593
|
-
readonly type: "string";
|
|
594
|
-
readonly format: "date-time";
|
|
595
|
-
};
|
|
596
|
-
readonly last_maximum_reach: {
|
|
597
|
-
readonly type: "string";
|
|
598
|
-
readonly format: "date-time";
|
|
599
|
-
};
|
|
600
|
-
};
|
|
601
|
-
};
|
|
602
|
-
};
|
|
603
|
-
};
|
|
604
|
-
};
|
|
605
|
-
}>, "description" | "functions" | "item" | "exposedFunctions" | "security"> & {
|
|
606
|
-
item: import("@aeriajs/types").SchemaWithId<{
|
|
607
|
-
readonly $id: "resourceUsage";
|
|
608
|
-
readonly icon: "wrench";
|
|
609
|
-
readonly required: readonly ["usage"];
|
|
610
|
-
readonly properties: {
|
|
611
|
-
readonly user: {
|
|
612
|
-
readonly $ref: "user";
|
|
613
|
-
};
|
|
614
|
-
readonly address: {
|
|
615
|
-
readonly type: "string";
|
|
616
|
-
};
|
|
617
|
-
readonly usage: {
|
|
618
|
-
readonly type: "object";
|
|
619
|
-
readonly additionalProperties: {
|
|
620
|
-
readonly type: "object";
|
|
621
|
-
readonly properties: {
|
|
622
|
-
readonly hits: {
|
|
623
|
-
readonly type: "integer";
|
|
624
|
-
};
|
|
625
|
-
readonly points: {
|
|
626
|
-
readonly type: "integer";
|
|
627
|
-
};
|
|
628
|
-
readonly last_reach: {
|
|
629
|
-
readonly type: "string";
|
|
630
|
-
readonly format: "date-time";
|
|
631
|
-
};
|
|
632
|
-
readonly last_maximum_reach: {
|
|
633
|
-
readonly type: "string";
|
|
634
|
-
readonly format: "date-time";
|
|
635
|
-
};
|
|
636
|
-
};
|
|
637
|
-
};
|
|
638
|
-
};
|
|
639
|
-
};
|
|
640
|
-
}>;
|
|
641
|
-
description: {
|
|
642
|
-
readonly $id: "resourceUsage";
|
|
643
|
-
readonly icon: "wrench";
|
|
644
|
-
readonly required: readonly ["usage"];
|
|
645
|
-
readonly properties: {
|
|
646
|
-
readonly user: {
|
|
647
|
-
readonly $ref: "user";
|
|
648
|
-
};
|
|
649
|
-
readonly address: {
|
|
650
|
-
readonly type: "string";
|
|
651
|
-
};
|
|
652
|
-
readonly usage: {
|
|
653
|
-
readonly type: "object";
|
|
654
|
-
readonly additionalProperties: {
|
|
655
|
-
readonly type: "object";
|
|
656
|
-
readonly properties: {
|
|
657
|
-
readonly hits: {
|
|
658
|
-
readonly type: "integer";
|
|
659
|
-
};
|
|
660
|
-
readonly points: {
|
|
661
|
-
readonly type: "integer";
|
|
662
|
-
};
|
|
663
|
-
readonly last_reach: {
|
|
664
|
-
readonly type: "string";
|
|
665
|
-
readonly format: "date-time";
|
|
666
|
-
};
|
|
667
|
-
readonly last_maximum_reach: {
|
|
668
|
-
readonly type: "string";
|
|
669
|
-
readonly format: "date-time";
|
|
670
|
-
};
|
|
671
|
-
};
|
|
672
|
-
};
|
|
673
|
-
};
|
|
674
|
-
};
|
|
675
|
-
};
|
|
676
|
-
functions: Record<string, (payload: any, context: import("@aeriajs/types").StrictContext<any>) => any> & {};
|
|
677
|
-
contracts: {
|
|
678
|
-
[x: string]: import("@aeriajs/types").Contract | undefined;
|
|
679
|
-
};
|
|
680
|
-
};
|
|
681
|
-
user: {
|
|
682
|
-
description: {
|
|
683
|
-
readonly $id: "user";
|
|
684
|
-
readonly icon: "users";
|
|
685
|
-
readonly required: readonly ["name", "roles", "email"];
|
|
686
|
-
readonly form: readonly ["name", "active", "roles", "email", "phone_number", "picture_file"];
|
|
687
|
-
readonly indexes: readonly ["name"];
|
|
688
|
-
readonly properties: {
|
|
689
|
-
readonly name: {
|
|
690
|
-
readonly type: "string";
|
|
691
|
-
};
|
|
692
|
-
readonly given_name: {
|
|
693
|
-
readonly getter: (doc: object) => string | undefined;
|
|
694
|
-
};
|
|
695
|
-
readonly family_name: {
|
|
696
|
-
readonly getter: (doc: object) => string | undefined;
|
|
697
|
-
};
|
|
698
|
-
readonly active: {
|
|
699
|
-
readonly type: "boolean";
|
|
700
|
-
};
|
|
701
|
-
readonly roles: {
|
|
702
|
-
readonly type: "array";
|
|
703
|
-
readonly items: {
|
|
704
|
-
readonly type: "string";
|
|
705
|
-
};
|
|
706
|
-
readonly uniqueItems: true;
|
|
707
|
-
};
|
|
708
|
-
readonly email: {
|
|
709
|
-
readonly type: "string";
|
|
710
|
-
readonly inputType: "email";
|
|
711
|
-
readonly unique: true;
|
|
712
|
-
};
|
|
713
|
-
readonly password: {
|
|
714
|
-
readonly type: "string";
|
|
715
|
-
readonly inputType: "password";
|
|
716
|
-
readonly hidden: true;
|
|
717
|
-
};
|
|
718
|
-
readonly phone_number: {
|
|
719
|
-
readonly type: "string";
|
|
720
|
-
readonly mask: "(##) #####-####";
|
|
721
|
-
};
|
|
722
|
-
readonly picture_file: {
|
|
723
|
-
readonly $ref: "file";
|
|
724
|
-
readonly accept: readonly ["image/*"];
|
|
725
|
-
};
|
|
726
|
-
readonly picture: {
|
|
727
|
-
readonly getter: (doc: object) => string | undefined;
|
|
728
|
-
};
|
|
729
|
-
readonly group: {
|
|
730
|
-
readonly type: "string";
|
|
731
|
-
};
|
|
732
|
-
readonly self_registered: {
|
|
733
|
-
readonly type: "boolean";
|
|
734
|
-
readonly readOnly: true;
|
|
735
|
-
};
|
|
736
|
-
readonly updated_at: {
|
|
737
|
-
readonly type: "string";
|
|
738
|
-
readonly format: "date-time";
|
|
739
|
-
};
|
|
740
|
-
};
|
|
741
|
-
readonly presets: readonly ["crud", "duplicate"];
|
|
742
|
-
readonly layout: {
|
|
743
|
-
readonly name: "grid";
|
|
744
|
-
readonly options: {
|
|
745
|
-
readonly title: "name";
|
|
746
|
-
readonly badge: "roles";
|
|
747
|
-
readonly picture: "picture_file";
|
|
748
|
-
readonly information: "email";
|
|
749
|
-
readonly active: "active";
|
|
750
|
-
};
|
|
751
|
-
};
|
|
752
|
-
readonly individualActions: {
|
|
753
|
-
readonly changePassword: {
|
|
754
|
-
readonly label: "change_password";
|
|
755
|
-
readonly icon: "key";
|
|
756
|
-
readonly translate: true;
|
|
757
|
-
readonly route: {
|
|
758
|
-
readonly name: "/dashboard/user/changepass";
|
|
759
|
-
readonly fetchItem: true;
|
|
760
|
-
};
|
|
761
|
-
};
|
|
762
|
-
readonly copyActivationLink: {
|
|
763
|
-
readonly label: "copy_activation_link";
|
|
764
|
-
readonly icon: "link";
|
|
765
|
-
readonly translate: true;
|
|
766
|
-
};
|
|
767
|
-
};
|
|
768
|
-
readonly filters: readonly ["name", "roles", "email", "phone_number"];
|
|
769
|
-
readonly table: readonly ["name", "roles", "picture_file", "active", "updated_at"];
|
|
770
|
-
readonly tableMeta: readonly ["email"];
|
|
771
|
-
readonly formLayout: {
|
|
772
|
-
readonly fields: {
|
|
773
|
-
readonly given_name: {
|
|
774
|
-
readonly span: 3;
|
|
775
|
-
};
|
|
776
|
-
readonly family_name: {
|
|
777
|
-
readonly span: 3;
|
|
778
|
-
};
|
|
779
|
-
};
|
|
780
|
-
};
|
|
781
|
-
};
|
|
782
|
-
functions: {
|
|
783
|
-
get: <TContext extends import("@aeriajs/types").Context>(payload: import("@aeriajs/types").GetPayload<import("@aeriajs/types").SchemaWithId<TContext["description"]>>, context: TContext, options?: import("@aeriajs/core").GetOptions) => Promise<import("@aeriajs/types").GetReturnType<import("@aeriajs/types").SchemaWithId<TContext["description"]>>>;
|
|
784
|
-
getAll: <TContext extends import("@aeriajs/types").Context>(payload: import("@aeriajs/types").GetAllPayload<import("@aeriajs/types").SchemaWithId<TContext["description"]>> | undefined, context: TContext, options?: import("@aeriajs/core").GetAllOptions) => Promise<import("@aeriajs/types").Result.Either<any, any>>;
|
|
785
|
-
remove: <TContext extends import("@aeriajs/types").Context>(payload: import("@aeriajs/types").RemovePayload<import("@aeriajs/types").SchemaWithId<TContext["description"]>>, context: TContext, options?: import("@aeriajs/core").RemoveOptions) => Promise<{
|
|
786
|
-
readonly _tag: "Result";
|
|
787
|
-
readonly error: undefined;
|
|
788
|
-
readonly result: import("mongodb").WithId<Omit<import("@aeriajs/types").PackReferences<import("@aeriajs/types").SchemaWithId<import("@aeriajs/types").Description>>, "_id">> | null;
|
|
789
|
-
} | import("@aeriajs/types").Result.Error<{
|
|
790
|
-
readonly code: import("@aeriajs/types").ACError.ResourceNotFound;
|
|
791
|
-
} & {
|
|
792
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.NotFound;
|
|
793
|
-
}> | import("@aeriajs/types").Result.Error<{
|
|
794
|
-
readonly code: import("@aeriajs/types").ACError.OwnershipError;
|
|
795
|
-
} & {
|
|
796
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.Forbidden;
|
|
797
|
-
}>>;
|
|
798
|
-
upload: <TContext extends import("@aeriajs/types").Context>(_props: unknown, context: TContext) => Promise<import("@aeriajs/types").Result.Error<{
|
|
799
|
-
readonly code: import("@aeriajs/types").ACError.MalformedInput;
|
|
800
|
-
readonly details: import("@aeriajs/types").ValidationError | import("@aeriajs/types").PropertyValidationError;
|
|
801
|
-
} & {
|
|
802
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.BadRequest;
|
|
803
|
-
}> | {
|
|
804
|
-
readonly _tag: "Result";
|
|
805
|
-
readonly error: undefined;
|
|
806
|
-
readonly result: {
|
|
807
|
-
readonly tempId: any;
|
|
808
|
-
};
|
|
809
|
-
}>;
|
|
810
|
-
removeFile: <TContext extends import("@aeriajs/types").Context>(payload: import("@aeriajs/types").RemoveFilePayload, context: TContext, options?: import("@aeriajs/core").RemoveFileOptions) => Promise<{
|
|
811
|
-
readonly _tag: "Result";
|
|
812
|
-
readonly error: undefined;
|
|
813
|
-
readonly result: any;
|
|
814
|
-
} | import("@aeriajs/types").Result.Error<{
|
|
815
|
-
readonly code: import("@aeriajs/types").ACError.OwnershipError;
|
|
816
|
-
} & {
|
|
817
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.Forbidden;
|
|
818
|
-
}>>;
|
|
819
|
-
insert: <TDescription extends import("@aeriajs/types").Description, TInsertPayload extends import("@aeriajs/types").InsertPayload<import("@aeriajs/types").SchemaWithId<TDescription>>>(payload: NoInfer<TInsertPayload>, context: import("@aeriajs/types").Context<TDescription>) => Promise<import("@aeriajs/types").InsertReturnType<import("@aeriajs/types").SchemaWithId<TDescription>>>;
|
|
820
|
-
authenticate: (props: {
|
|
821
|
-
email: string;
|
|
822
|
-
password: string;
|
|
823
|
-
} | {
|
|
824
|
-
token?: import("@aeriajs/types").TokenRecipient;
|
|
825
|
-
revalidate: true;
|
|
826
|
-
}, context: import("@aeriajs/types").Context<typeof import("./collections/user/description.js").description>) => Promise<import("@aeriajs/types").Result.Error<{
|
|
827
|
-
readonly code: import("@aeriajs/types").ACError.AuthorizationError;
|
|
828
|
-
} & {
|
|
829
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.Unauthorized;
|
|
830
|
-
}> | {
|
|
831
|
-
readonly _tag: "Result";
|
|
832
|
-
readonly error: undefined;
|
|
833
|
-
readonly result: {
|
|
834
|
-
user: {
|
|
835
|
-
_id: null;
|
|
836
|
-
name: string;
|
|
837
|
-
email: string;
|
|
838
|
-
roles: string[];
|
|
839
|
-
active: boolean;
|
|
840
|
-
};
|
|
841
|
-
token: {
|
|
842
|
-
type: string;
|
|
843
|
-
content: string;
|
|
844
|
-
};
|
|
845
|
-
};
|
|
846
|
-
} | {
|
|
847
|
-
readonly _tag: "Result";
|
|
848
|
-
readonly error: undefined;
|
|
849
|
-
readonly result: import("./authentication.js").SuccessfulAuthentication;
|
|
850
|
-
} | import("@aeriajs/types").Result.Error<{
|
|
851
|
-
readonly code: import("./authentication.js").AuthenticationError.InvalidCredentials;
|
|
852
|
-
} & {
|
|
853
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.Unauthorized;
|
|
854
|
-
}> | import("@aeriajs/types").Result.Error<{
|
|
855
|
-
readonly code: import("./authentication.js").AuthenticationError.InactiveUser;
|
|
856
|
-
} & {
|
|
857
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.Unauthorized;
|
|
858
|
-
}>>;
|
|
859
|
-
activate: (payload: {
|
|
860
|
-
password: string;
|
|
861
|
-
}, context: import("@aeriajs/types").Context<typeof import("./collections/user/description.js").description> & {
|
|
862
|
-
request: {
|
|
863
|
-
query: {
|
|
864
|
-
u?: string;
|
|
865
|
-
t?: string;
|
|
866
|
-
};
|
|
867
|
-
payload: {
|
|
868
|
-
password?: string;
|
|
869
|
-
};
|
|
870
|
-
};
|
|
871
|
-
}) => Promise<import("@aeriajs/types").GenericResponse | import("@aeriajs/types").Result.Error<{
|
|
872
|
-
readonly code: import("./collections/user/activate.js").ActivationError.InvalidLink;
|
|
873
|
-
} & {
|
|
874
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.NotFound;
|
|
875
|
-
}> | import("@aeriajs/types").Result.Error<{
|
|
876
|
-
readonly code: import("./collections/user/activate.js").ActivationError.UserNotFound;
|
|
877
|
-
} & {
|
|
878
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.NotFound;
|
|
879
|
-
}> | import("@aeriajs/types").Result.Error<{
|
|
880
|
-
readonly code: import("./collections/user/activate.js").ActivationError.AlreadyActiveUser;
|
|
881
|
-
} & {
|
|
882
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.Forbidden;
|
|
883
|
-
}> | import("@aeriajs/types").Result.Error<{
|
|
884
|
-
readonly code: import("@aeriajs/types").ACError.MalformedInput;
|
|
885
|
-
} & {
|
|
886
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.UnprocessableContent;
|
|
887
|
-
}> | {
|
|
888
|
-
readonly _tag: "Result";
|
|
889
|
-
readonly error: undefined;
|
|
890
|
-
readonly result: {
|
|
891
|
-
readonly userId: any;
|
|
892
|
-
};
|
|
893
|
-
} | undefined>;
|
|
894
|
-
createAccount: (payload: Partial<import("@aeriajs/types").SchemaWithId<typeof import("./collections/user/description.js").description>>, context: import("@aeriajs/types").Context<typeof import("./collections/user/description.js").description>) => Promise<import("@aeriajs/types").Result.Error<{
|
|
895
|
-
readonly code: import("./collections/user/createAccount.js").CreateAccountError;
|
|
896
|
-
} & {
|
|
897
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.Forbidden;
|
|
898
|
-
}> | import("@aeriajs/types").Result.Error<{
|
|
899
|
-
readonly code: import("@aeriajs/types").ACError.MalformedInput;
|
|
900
|
-
readonly details: import("@aeriajs/types").PropertyValidationError | import("@aeriajs/types").ValidationError;
|
|
901
|
-
} & {
|
|
902
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.BadRequest;
|
|
903
|
-
}> | import("@aeriajs/types").InsertReturnType<import("@aeriajs/types").SchemaWithId<{
|
|
904
|
-
readonly $id: "user";
|
|
905
|
-
readonly icon: "users";
|
|
906
|
-
readonly required: readonly ["name", "roles", "email"];
|
|
907
|
-
readonly form: readonly ["name", "active", "roles", "email", "phone_number", "picture_file"];
|
|
908
|
-
readonly indexes: readonly ["name"];
|
|
909
|
-
readonly properties: {
|
|
910
|
-
readonly name: {
|
|
911
|
-
readonly type: "string";
|
|
912
|
-
};
|
|
913
|
-
readonly given_name: {
|
|
914
|
-
readonly getter: (doc: object) => string | undefined;
|
|
915
|
-
};
|
|
916
|
-
readonly family_name: {
|
|
917
|
-
readonly getter: (doc: object) => string | undefined;
|
|
918
|
-
};
|
|
919
|
-
readonly active: {
|
|
920
|
-
readonly type: "boolean";
|
|
921
|
-
};
|
|
922
|
-
readonly roles: {
|
|
923
|
-
readonly type: "array";
|
|
924
|
-
readonly items: {
|
|
925
|
-
readonly type: "string";
|
|
926
|
-
};
|
|
927
|
-
readonly uniqueItems: true;
|
|
928
|
-
};
|
|
929
|
-
readonly email: {
|
|
930
|
-
readonly type: "string";
|
|
931
|
-
readonly inputType: "email";
|
|
932
|
-
readonly unique: true;
|
|
933
|
-
};
|
|
934
|
-
readonly password: {
|
|
935
|
-
readonly type: "string";
|
|
936
|
-
readonly inputType: "password";
|
|
937
|
-
readonly hidden: true;
|
|
938
|
-
};
|
|
939
|
-
readonly phone_number: {
|
|
940
|
-
readonly type: "string";
|
|
941
|
-
readonly mask: "(##) #####-####";
|
|
942
|
-
};
|
|
943
|
-
readonly picture_file: {
|
|
944
|
-
readonly $ref: "file";
|
|
945
|
-
readonly accept: readonly ["image/*"];
|
|
946
|
-
};
|
|
947
|
-
readonly picture: {
|
|
948
|
-
readonly getter: (doc: object) => string | undefined;
|
|
949
|
-
};
|
|
950
|
-
readonly group: {
|
|
951
|
-
readonly type: "string";
|
|
952
|
-
};
|
|
953
|
-
readonly self_registered: {
|
|
954
|
-
readonly type: "boolean";
|
|
955
|
-
readonly readOnly: true;
|
|
956
|
-
};
|
|
957
|
-
readonly updated_at: {
|
|
958
|
-
readonly type: "string";
|
|
959
|
-
readonly format: "date-time";
|
|
960
|
-
};
|
|
320
|
+
readonly type: "string";
|
|
961
321
|
};
|
|
962
|
-
readonly
|
|
963
|
-
|
|
964
|
-
readonly name: "grid";
|
|
965
|
-
readonly options: {
|
|
966
|
-
readonly title: "name";
|
|
967
|
-
readonly badge: "roles";
|
|
968
|
-
readonly picture: "picture_file";
|
|
969
|
-
readonly information: "email";
|
|
970
|
-
readonly active: "active";
|
|
971
|
-
};
|
|
322
|
+
readonly message: {
|
|
323
|
+
readonly type: "string";
|
|
972
324
|
};
|
|
973
|
-
readonly
|
|
974
|
-
readonly
|
|
975
|
-
|
|
976
|
-
readonly icon: "key";
|
|
977
|
-
readonly translate: true;
|
|
978
|
-
readonly route: {
|
|
979
|
-
readonly name: "/dashboard/user/changepass";
|
|
980
|
-
readonly fetchItem: true;
|
|
981
|
-
};
|
|
982
|
-
};
|
|
983
|
-
readonly copyActivationLink: {
|
|
984
|
-
readonly label: "copy_activation_link";
|
|
985
|
-
readonly icon: "link";
|
|
986
|
-
readonly translate: true;
|
|
987
|
-
};
|
|
325
|
+
readonly details: {
|
|
326
|
+
readonly type: "object";
|
|
327
|
+
readonly variable: true;
|
|
988
328
|
};
|
|
989
|
-
readonly
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
readonly formLayout: {
|
|
993
|
-
readonly fields: {
|
|
994
|
-
readonly given_name: {
|
|
995
|
-
readonly span: 3;
|
|
996
|
-
};
|
|
997
|
-
readonly family_name: {
|
|
998
|
-
readonly span: 3;
|
|
999
|
-
};
|
|
1000
|
-
};
|
|
329
|
+
readonly created_at: {
|
|
330
|
+
readonly type: "string";
|
|
331
|
+
readonly format: "date-time";
|
|
1001
332
|
};
|
|
1002
|
-
}
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
333
|
+
};
|
|
334
|
+
readonly presets: readonly ["view"];
|
|
335
|
+
readonly filters: readonly ["context", "message", "owner"];
|
|
336
|
+
};
|
|
337
|
+
functions: {
|
|
338
|
+
get: (payload: import("@aeriajs/types").GetPayload<import("@aeriajs/types").SchemaWithId<any>>, context: import("@aeriajs/types").StrictContext<any>, options?: import("@aeriajs/core").GetOptions) => Promise<import("@aeriajs/types").GetReturnType<import("@aeriajs/types").SchemaWithId<any>>>;
|
|
339
|
+
getAll: (payload: import("@aeriajs/types").GetAllPayload<import("@aeriajs/types").SchemaWithId<any>> | undefined, context: import("@aeriajs/types").StrictContext<any>, options?: import("@aeriajs/core").GetAllOptions) => Promise<import("@aeriajs/types").Result.Either<any, any>>;
|
|
340
|
+
insert: (payload: import("@aeriajs/types").InsertPayload<import("@aeriajs/types").SchemaWithId<any>>, context: import("@aeriajs/types").StrictContext<any>, options?: import("@aeriajs/core").InsertOptions) => Promise<import("@aeriajs/types").InsertReturnType<import("@aeriajs/types").SchemaWithId<any>>>;
|
|
341
|
+
};
|
|
342
|
+
contracts: {
|
|
343
|
+
get?: import("@aeriajs/types").Contract | undefined;
|
|
344
|
+
getAll?: import("@aeriajs/types").Contract | undefined;
|
|
345
|
+
insert?: import("@aeriajs/types").Contract | undefined;
|
|
346
|
+
};
|
|
347
|
+
};
|
|
348
|
+
resourceUsage: Omit<import("@aeriajs/types").Collection<never>, "functions" | "description" | "middlewares" | "item" | "exposedFunctions" | "security"> & {
|
|
349
|
+
item: import("@aeriajs/types").SchemaWithId<{
|
|
350
|
+
readonly $id: "resourceUsage";
|
|
351
|
+
readonly icon: "wrench";
|
|
352
|
+
readonly required: readonly ["usage"];
|
|
353
|
+
readonly properties: {
|
|
354
|
+
readonly user: {
|
|
355
|
+
readonly $ref: "user";
|
|
1024
356
|
};
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
readonly
|
|
1029
|
-
|
|
1030
|
-
readonly
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
readonly getter: (doc: object) => string | undefined;
|
|
1041
|
-
};
|
|
1042
|
-
readonly family_name: {
|
|
1043
|
-
readonly getter: (doc: object) => string | undefined;
|
|
1044
|
-
};
|
|
1045
|
-
readonly active: {
|
|
1046
|
-
readonly type: "boolean";
|
|
1047
|
-
};
|
|
1048
|
-
readonly roles: {
|
|
1049
|
-
readonly type: "array";
|
|
1050
|
-
readonly items: {
|
|
357
|
+
readonly address: {
|
|
358
|
+
readonly type: "string";
|
|
359
|
+
};
|
|
360
|
+
readonly usage: {
|
|
361
|
+
readonly type: "object";
|
|
362
|
+
readonly additionalProperties: {
|
|
363
|
+
readonly type: "object";
|
|
364
|
+
readonly properties: {
|
|
365
|
+
readonly hits: {
|
|
366
|
+
readonly type: "integer";
|
|
367
|
+
};
|
|
368
|
+
readonly points: {
|
|
369
|
+
readonly type: "integer";
|
|
370
|
+
};
|
|
371
|
+
readonly last_reach: {
|
|
1051
372
|
readonly type: "string";
|
|
373
|
+
readonly format: "date-time";
|
|
1052
374
|
};
|
|
1053
|
-
readonly
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
readonly type: "string";
|
|
1057
|
-
readonly inputType: "email";
|
|
1058
|
-
readonly unique: true;
|
|
1059
|
-
};
|
|
1060
|
-
readonly password: {
|
|
1061
|
-
readonly type: "string";
|
|
1062
|
-
readonly inputType: "password";
|
|
1063
|
-
readonly hidden: true;
|
|
1064
|
-
};
|
|
1065
|
-
readonly phone_number: {
|
|
1066
|
-
readonly type: "string";
|
|
1067
|
-
readonly mask: "(##) #####-####";
|
|
1068
|
-
};
|
|
1069
|
-
readonly picture_file: {
|
|
1070
|
-
readonly $ref: "file";
|
|
1071
|
-
readonly accept: readonly ["image/*"];
|
|
1072
|
-
};
|
|
1073
|
-
readonly picture: {
|
|
1074
|
-
readonly getter: (doc: object) => string | undefined;
|
|
1075
|
-
};
|
|
1076
|
-
readonly group: {
|
|
1077
|
-
readonly type: "string";
|
|
1078
|
-
};
|
|
1079
|
-
readonly self_registered: {
|
|
1080
|
-
readonly type: "boolean";
|
|
1081
|
-
readonly readOnly: true;
|
|
1082
|
-
};
|
|
1083
|
-
readonly updated_at: {
|
|
1084
|
-
readonly type: "string";
|
|
1085
|
-
readonly format: "date-time";
|
|
1086
|
-
};
|
|
1087
|
-
};
|
|
1088
|
-
readonly presets: readonly ["crud", "duplicate"];
|
|
1089
|
-
readonly layout: {
|
|
1090
|
-
readonly name: "grid";
|
|
1091
|
-
readonly options: {
|
|
1092
|
-
readonly title: "name";
|
|
1093
|
-
readonly badge: "roles";
|
|
1094
|
-
readonly picture: "picture_file";
|
|
1095
|
-
readonly information: "email";
|
|
1096
|
-
readonly active: "active";
|
|
1097
|
-
};
|
|
1098
|
-
};
|
|
1099
|
-
readonly individualActions: {
|
|
1100
|
-
readonly changePassword: {
|
|
1101
|
-
readonly label: "change_password";
|
|
1102
|
-
readonly icon: "key";
|
|
1103
|
-
readonly translate: true;
|
|
1104
|
-
readonly route: {
|
|
1105
|
-
readonly name: "/dashboard/user/changepass";
|
|
1106
|
-
readonly fetchItem: true;
|
|
375
|
+
readonly last_maximum_reach: {
|
|
376
|
+
readonly type: "string";
|
|
377
|
+
readonly format: "date-time";
|
|
1107
378
|
};
|
|
1108
379
|
};
|
|
1109
|
-
readonly copyActivationLink: {
|
|
1110
|
-
readonly label: "copy_activation_link";
|
|
1111
|
-
readonly icon: "link";
|
|
1112
|
-
readonly translate: true;
|
|
1113
|
-
};
|
|
1114
380
|
};
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
381
|
+
};
|
|
382
|
+
};
|
|
383
|
+
}>;
|
|
384
|
+
description: {
|
|
385
|
+
readonly $id: "resourceUsage";
|
|
386
|
+
readonly icon: "wrench";
|
|
387
|
+
readonly required: readonly ["usage"];
|
|
388
|
+
readonly properties: {
|
|
389
|
+
readonly user: {
|
|
390
|
+
readonly $ref: "user";
|
|
391
|
+
};
|
|
392
|
+
readonly address: {
|
|
393
|
+
readonly type: "string";
|
|
394
|
+
};
|
|
395
|
+
readonly usage: {
|
|
396
|
+
readonly type: "object";
|
|
397
|
+
readonly additionalProperties: {
|
|
398
|
+
readonly type: "object";
|
|
399
|
+
readonly properties: {
|
|
400
|
+
readonly hits: {
|
|
401
|
+
readonly type: "integer";
|
|
1122
402
|
};
|
|
1123
|
-
readonly
|
|
1124
|
-
readonly
|
|
403
|
+
readonly points: {
|
|
404
|
+
readonly type: "integer";
|
|
405
|
+
};
|
|
406
|
+
readonly last_reach: {
|
|
407
|
+
readonly type: "string";
|
|
408
|
+
readonly format: "date-time";
|
|
409
|
+
};
|
|
410
|
+
readonly last_maximum_reach: {
|
|
411
|
+
readonly type: "string";
|
|
412
|
+
readonly format: "date-time";
|
|
1125
413
|
};
|
|
1126
414
|
};
|
|
1127
415
|
};
|
|
1128
|
-
}>;
|
|
1129
|
-
}>;
|
|
1130
|
-
getActivationLink: (payload: {
|
|
1131
|
-
userId: import("mongodb").ObjectId | string;
|
|
1132
|
-
}, context: import("@aeriajs/types").Context) => Promise<{
|
|
1133
|
-
readonly _tag: "Error";
|
|
1134
|
-
readonly error: import("@aeriajs/types").StrictEndpointError<import("@aeriajs/types").ACError.OwnershipError | import("@aeriajs/types").ACError.ResourceNotFound | import("@aeriajs/types").ACError.MalformedInput, unknown, import("@aeriajs/types").HTTPStatus.BadRequest | import("@aeriajs/types").HTTPStatus.Forbidden | import("@aeriajs/types").HTTPStatus.NotFound>;
|
|
1135
|
-
readonly result: undefined;
|
|
1136
|
-
} | import("@aeriajs/types").Result.Error<{
|
|
1137
|
-
readonly code: import("./collections/user/activate.js").ActivationError.AlreadyActiveUser;
|
|
1138
|
-
} & {
|
|
1139
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.Forbidden;
|
|
1140
|
-
}> | {
|
|
1141
|
-
readonly _tag: "Result";
|
|
1142
|
-
readonly error: undefined;
|
|
1143
|
-
readonly result: {
|
|
1144
|
-
readonly url: string;
|
|
1145
|
-
};
|
|
1146
|
-
}>;
|
|
1147
|
-
};
|
|
1148
|
-
contracts: {
|
|
1149
|
-
readonly getCurrentUser: {
|
|
1150
|
-
readonly response: {
|
|
1151
|
-
readonly $ref: "user";
|
|
1152
416
|
};
|
|
1153
417
|
};
|
|
1154
418
|
};
|
|
1155
|
-
|
|
1156
|
-
|
|
419
|
+
functions: (Record<string, (payload: any, context: import("@aeriajs/types").StrictContext<any>) => any> & {}) | undefined;
|
|
420
|
+
contracts: {
|
|
421
|
+
[x: string]: import("@aeriajs/types").Contract | undefined;
|
|
422
|
+
} | undefined;
|
|
423
|
+
};
|
|
424
|
+
user: Omit<import("@aeriajs/types").Collection<never>, "functions" | "description" | "middlewares" | "item" | "exposedFunctions" | "security"> & {
|
|
1157
425
|
item: import("@aeriajs/types").SchemaWithId<{
|
|
1158
426
|
readonly $id: "user";
|
|
1159
427
|
readonly icon: "users";
|
|
@@ -1179,6 +447,7 @@ export declare const collections: {
|
|
|
1179
447
|
readonly type: "string";
|
|
1180
448
|
};
|
|
1181
449
|
readonly uniqueItems: true;
|
|
450
|
+
readonly minItems: 1;
|
|
1182
451
|
};
|
|
1183
452
|
readonly email: {
|
|
1184
453
|
readonly type: "string";
|
|
@@ -1279,6 +548,7 @@ export declare const collections: {
|
|
|
1279
548
|
readonly type: "string";
|
|
1280
549
|
};
|
|
1281
550
|
readonly uniqueItems: true;
|
|
551
|
+
readonly minItems: 1;
|
|
1282
552
|
};
|
|
1283
553
|
readonly email: {
|
|
1284
554
|
readonly type: "string";
|
|
@@ -1500,6 +770,7 @@ export declare const collections: {
|
|
|
1500
770
|
readonly type: "string";
|
|
1501
771
|
};
|
|
1502
772
|
readonly uniqueItems: true;
|
|
773
|
+
readonly minItems: 1;
|
|
1503
774
|
};
|
|
1504
775
|
readonly email: {
|
|
1505
776
|
readonly type: "string";
|
|
@@ -1626,6 +897,7 @@ export declare const collections: {
|
|
|
1626
897
|
readonly type: "string";
|
|
1627
898
|
};
|
|
1628
899
|
readonly uniqueItems: true;
|
|
900
|
+
readonly minItems: 1;
|
|
1629
901
|
};
|
|
1630
902
|
readonly email: {
|
|
1631
903
|
readonly type: "string";
|
|
@@ -1721,11 +993,18 @@ export declare const collections: {
|
|
|
1721
993
|
}>;
|
|
1722
994
|
};
|
|
1723
995
|
contracts: {
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
996
|
+
get?: import("@aeriajs/types").Contract | undefined;
|
|
997
|
+
getAll?: import("@aeriajs/types").Contract | undefined;
|
|
998
|
+
remove?: import("@aeriajs/types").Contract | undefined;
|
|
999
|
+
upload?: import("@aeriajs/types").Contract | undefined;
|
|
1000
|
+
removeFile?: import("@aeriajs/types").Contract | undefined;
|
|
1001
|
+
insert?: import("@aeriajs/types").Contract | undefined;
|
|
1002
|
+
authenticate?: import("@aeriajs/types").Contract | undefined;
|
|
1003
|
+
activate?: import("@aeriajs/types").Contract | undefined;
|
|
1004
|
+
createAccount?: import("@aeriajs/types").Contract | undefined;
|
|
1005
|
+
getInfo?: import("@aeriajs/types").Contract | undefined;
|
|
1006
|
+
getCurrentUser?: import("@aeriajs/types").Contract | undefined;
|
|
1007
|
+
getActivationLink?: import("@aeriajs/types").Contract | undefined;
|
|
1729
1008
|
};
|
|
1730
1009
|
};
|
|
1731
1010
|
};
|