@lyxa.ai/types 1.0.292 → 1.0.293
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
package/package.json
CHANGED
|
@@ -571,7 +571,7 @@ export declare const createResponseSchema: <T>(schema: z.ZodSchema<T>) => z.ZodO
|
|
|
571
571
|
totalPages: number;
|
|
572
572
|
} | undefined;
|
|
573
573
|
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
574
|
-
}>, any> extends infer T_1 ? { [k in keyof T_1]:
|
|
574
|
+
}>, any> extends infer T_1 ? { [k in keyof T_1]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
|
|
575
575
|
success: z.ZodBoolean;
|
|
576
576
|
message: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
577
577
|
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
@@ -609,7 +609,83 @@ export declare const createResponseSchema: <T>(schema: z.ZodSchema<T>) => z.ZodO
|
|
|
609
609
|
totalPages: number;
|
|
610
610
|
} | undefined;
|
|
611
611
|
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
612
|
-
}>
|
|
612
|
+
}>, any>[k]; } : never, z.baseObjectInputType<{
|
|
613
|
+
success: z.ZodBoolean;
|
|
614
|
+
message: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
615
|
+
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
616
|
+
metadata: z.ZodOptional<z.ZodObject<{
|
|
617
|
+
page: z.ZodNumber;
|
|
618
|
+
size: z.ZodNumber;
|
|
619
|
+
totalElements: z.ZodNumber;
|
|
620
|
+
totalPages: z.ZodNumber;
|
|
621
|
+
}, "strip", z.ZodTypeAny, {
|
|
622
|
+
size: number;
|
|
623
|
+
page: number;
|
|
624
|
+
totalElements: number;
|
|
625
|
+
totalPages: number;
|
|
626
|
+
}, {
|
|
627
|
+
size: number;
|
|
628
|
+
page: number;
|
|
629
|
+
totalElements: number;
|
|
630
|
+
totalPages: number;
|
|
631
|
+
}>>;
|
|
632
|
+
documents: z.ZodArray<z.ZodType<T, z.ZodTypeDef, T>, "many">;
|
|
633
|
+
}, "strip", z.ZodTypeAny, {
|
|
634
|
+
documents: T[];
|
|
635
|
+
metadata?: {
|
|
636
|
+
size: number;
|
|
637
|
+
page: number;
|
|
638
|
+
totalElements: number;
|
|
639
|
+
totalPages: number;
|
|
640
|
+
} | undefined;
|
|
641
|
+
}, {
|
|
642
|
+
documents: T[];
|
|
643
|
+
metadata?: {
|
|
644
|
+
size: number;
|
|
645
|
+
page: number;
|
|
646
|
+
totalElements: number;
|
|
647
|
+
totalPages: number;
|
|
648
|
+
} | undefined;
|
|
649
|
+
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
650
|
+
}> extends infer T_2 ? { [k_1 in keyof T_2]: z.baseObjectInputType<{
|
|
651
|
+
success: z.ZodBoolean;
|
|
652
|
+
message: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
653
|
+
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
654
|
+
metadata: z.ZodOptional<z.ZodObject<{
|
|
655
|
+
page: z.ZodNumber;
|
|
656
|
+
size: z.ZodNumber;
|
|
657
|
+
totalElements: z.ZodNumber;
|
|
658
|
+
totalPages: z.ZodNumber;
|
|
659
|
+
}, "strip", z.ZodTypeAny, {
|
|
660
|
+
size: number;
|
|
661
|
+
page: number;
|
|
662
|
+
totalElements: number;
|
|
663
|
+
totalPages: number;
|
|
664
|
+
}, {
|
|
665
|
+
size: number;
|
|
666
|
+
page: number;
|
|
667
|
+
totalElements: number;
|
|
668
|
+
totalPages: number;
|
|
669
|
+
}>>;
|
|
670
|
+
documents: z.ZodArray<z.ZodType<T, z.ZodTypeDef, T>, "many">;
|
|
671
|
+
}, "strip", z.ZodTypeAny, {
|
|
672
|
+
documents: T[];
|
|
673
|
+
metadata?: {
|
|
674
|
+
size: number;
|
|
675
|
+
page: number;
|
|
676
|
+
totalElements: number;
|
|
677
|
+
totalPages: number;
|
|
678
|
+
} | undefined;
|
|
679
|
+
}, {
|
|
680
|
+
documents: T[];
|
|
681
|
+
metadata?: {
|
|
682
|
+
size: number;
|
|
683
|
+
page: number;
|
|
684
|
+
totalElements: number;
|
|
685
|
+
totalPages: number;
|
|
686
|
+
} | undefined;
|
|
687
|
+
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
688
|
+
}>[k_1]; } : never>;
|
|
613
689
|
export declare const TokenSchema: z.ZodObject<{
|
|
614
690
|
accessToken: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
615
691
|
refreshToken: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
@@ -62,22 +62,34 @@ export declare class SchemaBuilder<T extends z.ZodRawShape> {
|
|
|
62
62
|
private baseSchema;
|
|
63
63
|
constructor(baseFields: T, includeTimestamps?: boolean, includeTracking?: boolean);
|
|
64
64
|
private createBaseSchema;
|
|
65
|
-
getBaseSchema(): z.ZodObject<T, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any> extends infer T_1 ? { [k in keyof T_1]:
|
|
65
|
+
getBaseSchema(): z.ZodObject<T, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any> extends infer T_1 ? { [k in keyof T_1]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any>[k]; } : never, z.baseObjectInputType<T> extends infer T_2 ? { [k_1 in keyof T_2]: z.baseObjectInputType<T>[k_1]; } : never>;
|
|
66
66
|
getEntitySchema(): z.ZodObject<z.objectUtil.extendShape<T, {
|
|
67
67
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
68
|
-
}> extends infer T_1 extends z.ZodRawShape ? { [k in keyof T_1]: z.ZodOptional<
|
|
68
|
+
}> extends infer T_1 extends z.ZodRawShape ? { [k in keyof T_1]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
69
69
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
70
|
-
}>
|
|
70
|
+
}>[k]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
71
71
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
72
|
-
}> extends infer
|
|
72
|
+
}> extends infer T_2 extends z.ZodRawShape ? { [k in keyof T_2]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
73
|
+
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
74
|
+
}>[k]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
75
|
+
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
76
|
+
}> extends infer T_3 extends z.ZodRawShape ? { [k in keyof T_3]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
77
|
+
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
78
|
+
}>[k]>; } : never, z.ZodTypeAny, "passthrough">>;
|
|
73
79
|
getIdSchema(): z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
74
80
|
getUpdateSchema(excludeFields?: ExcludeFromUpdate): z.ZodObject<z.objectUtil.extendShape<T, {
|
|
75
81
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
76
|
-
}> extends infer T_1 extends z.ZodRawShape ? { [k in keyof T_1]: z.ZodOptional<
|
|
82
|
+
}> extends infer T_1 extends z.ZodRawShape ? { [k in keyof T_1]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
83
|
+
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
84
|
+
}>[k]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
85
|
+
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
86
|
+
}> extends infer T_2 extends z.ZodRawShape ? { [k in keyof T_2]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
87
|
+
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
88
|
+
}>[k]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
77
89
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
78
|
-
}> extends infer
|
|
90
|
+
}> extends infer T_3 extends z.ZodRawShape ? { [k in keyof T_3]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
79
91
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
80
|
-
}>
|
|
92
|
+
}>[k]>; } : never, z.ZodTypeAny, "passthrough">> | z.ZodObject<{
|
|
81
93
|
[x: string]: z.ZodOptional<z.ZodTypeAny>;
|
|
82
94
|
}, "strict", z.ZodTypeAny, {
|
|
83
95
|
[x: string]: any;
|
|
@@ -100,22 +112,34 @@ export declare class SchemaBuilder<T extends z.ZodRawShape> {
|
|
|
100
112
|
[x: string]: any;
|
|
101
113
|
}>;
|
|
102
114
|
getAllSchemas(excludeFromUpdate?: ExcludeFromUpdate): {
|
|
103
|
-
BaseSchema: z.ZodObject<T, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any> extends infer T_1 ? { [k in keyof T_1]:
|
|
115
|
+
BaseSchema: z.ZodObject<T, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any> extends infer T_1 ? { [k in keyof T_1]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any>[k]; } : never, z.baseObjectInputType<T> extends infer T_2 ? { [k_1 in keyof T_2]: z.baseObjectInputType<T>[k_1]; } : never>;
|
|
104
116
|
EntitySchema: z.ZodObject<z.objectUtil.extendShape<T, {
|
|
105
117
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
106
|
-
}> extends infer T_3 extends z.ZodRawShape ? { [k_2 in keyof T_3]: z.ZodOptional<
|
|
118
|
+
}> extends infer T_3 extends z.ZodRawShape ? { [k_2 in keyof T_3]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
107
119
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
108
|
-
}>
|
|
120
|
+
}>[k_2]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
109
121
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
110
|
-
}> extends infer
|
|
122
|
+
}> extends infer T_4 extends z.ZodRawShape ? { [k_2 in keyof T_4]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
123
|
+
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
124
|
+
}>[k_2]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
125
|
+
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
126
|
+
}> extends infer T_5 extends z.ZodRawShape ? { [k_2 in keyof T_5]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
127
|
+
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
128
|
+
}>[k_2]>; } : never, z.ZodTypeAny, "passthrough">>;
|
|
111
129
|
IdSchema: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
112
130
|
UpdateSchema: z.ZodObject<z.objectUtil.extendShape<T, {
|
|
113
131
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
114
|
-
}> extends infer T_6 extends z.ZodRawShape ? { [k_2 in keyof T_6]: z.ZodOptional<
|
|
132
|
+
}> extends infer T_6 extends z.ZodRawShape ? { [k_2 in keyof T_6]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
133
|
+
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
134
|
+
}>[k_2]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
135
|
+
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
136
|
+
}> extends infer T_7 extends z.ZodRawShape ? { [k_2 in keyof T_7]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
137
|
+
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
138
|
+
}>[k_2]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
115
139
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
116
|
-
}> extends infer
|
|
140
|
+
}> extends infer T_8 extends z.ZodRawShape ? { [k_2 in keyof T_8]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
117
141
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
118
|
-
}>
|
|
142
|
+
}>[k_2]>; } : never, z.ZodTypeAny, "passthrough">> | z.ZodObject<{
|
|
119
143
|
[x: string]: z.ZodOptional<z.ZodTypeAny>;
|
|
120
144
|
}, "strict", z.ZodTypeAny, {
|
|
121
145
|
[x: string]: any;
|