@restura/core 0.1.0-alpha.10 → 0.1.0-alpha.11

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/index.d.mts CHANGED
@@ -75,8 +75,8 @@ declare const resturaZodSchema: z.ZodObject<{
75
75
  }, "strict", z.ZodTypeAny, {
76
76
  type: "SMALLINT" | "INTEGER" | "BIGINT" | "DECIMAL" | "NUMERIC" | "REAL" | "DOUBLE PRECISION" | "SERIAL" | "BIGSERIAL" | "CHAR" | "VARCHAR" | "TEXT" | "BYTEA" | "DATE" | "TIMESTAMP" | "TIMESTAMPTZ" | "TIME" | "INTERVAL" | "BOOLEAN" | "TINYINT" | "MEDIUMINT" | "FLOAT" | "DOUBLE" | "TINYTEXT" | "TINYBLOB" | "BLOB" | "MEDIUMTEXT" | "MEDIUMBLOB" | "LONGTEXT" | "JSON" | "LONGBLOB" | "ENUM" | "DATETIME";
77
77
  name: string;
78
- roles: string[];
79
78
  isNullable: boolean;
79
+ roles: string[];
80
80
  length?: number | undefined;
81
81
  value?: string | undefined;
82
82
  default?: string | undefined;
@@ -87,8 +87,8 @@ declare const resturaZodSchema: z.ZodObject<{
87
87
  }, {
88
88
  type: "SMALLINT" | "INTEGER" | "BIGINT" | "DECIMAL" | "NUMERIC" | "REAL" | "DOUBLE PRECISION" | "SERIAL" | "BIGSERIAL" | "CHAR" | "VARCHAR" | "TEXT" | "BYTEA" | "DATE" | "TIMESTAMP" | "TIMESTAMPTZ" | "TIME" | "INTERVAL" | "BOOLEAN" | "TINYINT" | "MEDIUMINT" | "FLOAT" | "DOUBLE" | "TINYTEXT" | "TINYBLOB" | "BLOB" | "MEDIUMTEXT" | "MEDIUMBLOB" | "LONGTEXT" | "JSON" | "LONGBLOB" | "ENUM" | "DATETIME";
89
89
  name: string;
90
- roles: string[];
91
90
  isNullable: boolean;
91
+ roles: string[];
92
92
  length?: number | undefined;
93
93
  value?: string | undefined;
94
94
  default?: string | undefined;
@@ -155,8 +155,8 @@ declare const resturaZodSchema: z.ZodObject<{
155
155
  columns: {
156
156
  type: "SMALLINT" | "INTEGER" | "BIGINT" | "DECIMAL" | "NUMERIC" | "REAL" | "DOUBLE PRECISION" | "SERIAL" | "BIGSERIAL" | "CHAR" | "VARCHAR" | "TEXT" | "BYTEA" | "DATE" | "TIMESTAMP" | "TIMESTAMPTZ" | "TIME" | "INTERVAL" | "BOOLEAN" | "TINYINT" | "MEDIUMINT" | "FLOAT" | "DOUBLE" | "TINYTEXT" | "TINYBLOB" | "BLOB" | "MEDIUMTEXT" | "MEDIUMBLOB" | "LONGTEXT" | "JSON" | "LONGBLOB" | "ENUM" | "DATETIME";
157
157
  name: string;
158
- roles: string[];
159
158
  isNullable: boolean;
159
+ roles: string[];
160
160
  length?: number | undefined;
161
161
  value?: string | undefined;
162
162
  default?: string | undefined;
@@ -190,8 +190,8 @@ declare const resturaZodSchema: z.ZodObject<{
190
190
  columns: {
191
191
  type: "SMALLINT" | "INTEGER" | "BIGINT" | "DECIMAL" | "NUMERIC" | "REAL" | "DOUBLE PRECISION" | "SERIAL" | "BIGSERIAL" | "CHAR" | "VARCHAR" | "TEXT" | "BYTEA" | "DATE" | "TIMESTAMP" | "TIMESTAMPTZ" | "TIME" | "INTERVAL" | "BOOLEAN" | "TINYINT" | "MEDIUMINT" | "FLOAT" | "DOUBLE" | "TINYTEXT" | "TINYBLOB" | "BLOB" | "MEDIUMTEXT" | "MEDIUMBLOB" | "LONGTEXT" | "JSON" | "LONGBLOB" | "ENUM" | "DATETIME";
192
192
  name: string;
193
- roles: string[];
194
193
  isNullable: boolean;
194
+ roles: string[];
195
195
  length?: number | undefined;
196
196
  value?: string | undefined;
197
197
  default?: string | undefined;
@@ -290,6 +290,7 @@ declare const resturaZodSchema: z.ZodObject<{
290
290
  request: z.ZodArray<z.ZodObject<{
291
291
  name: z.ZodString;
292
292
  required: z.ZodBoolean;
293
+ isNullable: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
293
294
  validator: z.ZodArray<z.ZodObject<{
294
295
  type: z.ZodEnum<["TYPE_CHECK", "MIN", "MAX", "ONE_OF"]>;
295
296
  value: z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">, z.ZodNumber, z.ZodArray<z.ZodNumber, "many">]>;
@@ -301,19 +302,21 @@ declare const resturaZodSchema: z.ZodObject<{
301
302
  value: string | number | string[] | number[];
302
303
  }>, "many">;
303
304
  }, "strict", z.ZodTypeAny, {
305
+ name: string;
306
+ required: boolean;
307
+ isNullable: boolean;
304
308
  validator: {
305
309
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
306
310
  value: string | number | string[] | number[];
307
311
  }[];
312
+ }, {
308
313
  name: string;
309
314
  required: boolean;
310
- }, {
311
315
  validator: {
312
316
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
313
317
  value: string | number | string[] | number[];
314
318
  }[];
315
- name: string;
316
- required: boolean;
319
+ isNullable?: boolean | undefined;
317
320
  }>, "many">;
318
321
  response: z.ZodArray<z.ZodObject<{
319
322
  name: z.ZodString;
@@ -535,7 +538,7 @@ declare const resturaZodSchema: z.ZodObject<{
535
538
  }>>;
536
539
  }>, "strict", z.ZodTypeAny, {
537
540
  path: string;
538
- type: "PAGED" | "ARRAY" | "ONE";
541
+ type: "ONE" | "ARRAY" | "PAGED";
539
542
  name: string;
540
543
  table: string;
541
544
  joins: {
@@ -562,12 +565,13 @@ declare const resturaZodSchema: z.ZodObject<{
562
565
  name: string;
563
566
  }[];
564
567
  request: {
568
+ name: string;
569
+ required: boolean;
570
+ isNullable: boolean;
565
571
  validator: {
566
572
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
567
573
  value: string | number | string[] | number[];
568
574
  }[];
569
- name: string;
570
- required: boolean;
571
575
  }[];
572
576
  response: {
573
577
  name: string;
@@ -613,7 +617,7 @@ declare const resturaZodSchema: z.ZodObject<{
613
617
  } | undefined;
614
618
  }, {
615
619
  path: string;
616
- type: "PAGED" | "ARRAY" | "ONE";
620
+ type: "ONE" | "ARRAY" | "PAGED";
617
621
  name: string;
618
622
  table: string;
619
623
  joins: {
@@ -640,12 +644,13 @@ declare const resturaZodSchema: z.ZodObject<{
640
644
  name: string;
641
645
  }[];
642
646
  request: {
647
+ name: string;
648
+ required: boolean;
643
649
  validator: {
644
650
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
645
651
  value: string | number | string[] | number[];
646
652
  }[];
647
- name: string;
648
- required: boolean;
653
+ isNullable?: boolean | undefined;
649
654
  }[];
650
655
  response: {
651
656
  name: string;
@@ -702,6 +707,7 @@ declare const resturaZodSchema: z.ZodObject<{
702
707
  request: z.ZodOptional<z.ZodArray<z.ZodObject<{
703
708
  name: z.ZodString;
704
709
  required: z.ZodBoolean;
710
+ isNullable: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
705
711
  validator: z.ZodArray<z.ZodObject<{
706
712
  type: z.ZodEnum<["TYPE_CHECK", "MIN", "MAX", "ONE_OF"]>;
707
713
  value: z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">, z.ZodNumber, z.ZodArray<z.ZodNumber, "many">]>;
@@ -713,19 +719,21 @@ declare const resturaZodSchema: z.ZodObject<{
713
719
  value: string | number | string[] | number[];
714
720
  }>, "many">;
715
721
  }, "strict", z.ZodTypeAny, {
722
+ name: string;
723
+ required: boolean;
724
+ isNullable: boolean;
716
725
  validator: {
717
726
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
718
727
  value: string | number | string[] | number[];
719
728
  }[];
729
+ }, {
720
730
  name: string;
721
731
  required: boolean;
722
- }, {
723
732
  validator: {
724
733
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
725
734
  value: string | number | string[] | number[];
726
735
  }[];
727
- name: string;
728
- required: boolean;
736
+ isNullable?: boolean | undefined;
729
737
  }>, "many">>;
730
738
  table: z.ZodUndefined;
731
739
  joins: z.ZodUndefined;
@@ -743,12 +751,13 @@ declare const resturaZodSchema: z.ZodObject<{
743
751
  joins?: undefined;
744
752
  assignments?: undefined;
745
753
  request?: {
754
+ name: string;
755
+ required: boolean;
756
+ isNullable: boolean;
746
757
  validator: {
747
758
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
748
759
  value: string | number | string[] | number[];
749
760
  }[];
750
- name: string;
751
- required: boolean;
752
761
  }[] | undefined;
753
762
  requestType?: string | undefined;
754
763
  fileUploadType?: "SINGLE" | "MULTIPLE" | undefined;
@@ -764,12 +773,13 @@ declare const resturaZodSchema: z.ZodObject<{
764
773
  joins?: undefined;
765
774
  assignments?: undefined;
766
775
  request?: {
776
+ name: string;
777
+ required: boolean;
767
778
  validator: {
768
779
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
769
780
  value: string | number | string[] | number[];
770
781
  }[];
771
- name: string;
772
- required: boolean;
782
+ isNullable?: boolean | undefined;
773
783
  }[] | undefined;
774
784
  requestType?: string | undefined;
775
785
  fileUploadType?: "SINGLE" | "MULTIPLE" | undefined;
@@ -780,7 +790,7 @@ declare const resturaZodSchema: z.ZodObject<{
780
790
  baseUrl: string;
781
791
  routes: ({
782
792
  path: string;
783
- type: "PAGED" | "ARRAY" | "ONE";
793
+ type: "ONE" | "ARRAY" | "PAGED";
784
794
  name: string;
785
795
  table: string;
786
796
  joins: {
@@ -807,12 +817,13 @@ declare const resturaZodSchema: z.ZodObject<{
807
817
  name: string;
808
818
  }[];
809
819
  request: {
820
+ name: string;
821
+ required: boolean;
822
+ isNullable: boolean;
810
823
  validator: {
811
824
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
812
825
  value: string | number | string[] | number[];
813
826
  }[];
814
- name: string;
815
- required: boolean;
816
827
  }[];
817
828
  response: {
818
829
  name: string;
@@ -868,12 +879,13 @@ declare const resturaZodSchema: z.ZodObject<{
868
879
  joins?: undefined;
869
880
  assignments?: undefined;
870
881
  request?: {
882
+ name: string;
883
+ required: boolean;
884
+ isNullable: boolean;
871
885
  validator: {
872
886
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
873
887
  value: string | number | string[] | number[];
874
888
  }[];
875
- name: string;
876
- required: boolean;
877
889
  }[] | undefined;
878
890
  requestType?: string | undefined;
879
891
  fileUploadType?: "SINGLE" | "MULTIPLE" | undefined;
@@ -884,7 +896,7 @@ declare const resturaZodSchema: z.ZodObject<{
884
896
  baseUrl: string;
885
897
  routes: ({
886
898
  path: string;
887
- type: "PAGED" | "ARRAY" | "ONE";
899
+ type: "ONE" | "ARRAY" | "PAGED";
888
900
  name: string;
889
901
  table: string;
890
902
  joins: {
@@ -911,12 +923,13 @@ declare const resturaZodSchema: z.ZodObject<{
911
923
  name: string;
912
924
  }[];
913
925
  request: {
926
+ name: string;
927
+ required: boolean;
914
928
  validator: {
915
929
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
916
930
  value: string | number | string[] | number[];
917
931
  }[];
918
- name: string;
919
- required: boolean;
932
+ isNullable?: boolean | undefined;
920
933
  }[];
921
934
  response: {
922
935
  name: string;
@@ -972,12 +985,13 @@ declare const resturaZodSchema: z.ZodObject<{
972
985
  joins?: undefined;
973
986
  assignments?: undefined;
974
987
  request?: {
988
+ name: string;
989
+ required: boolean;
975
990
  validator: {
976
991
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
977
992
  value: string | number | string[] | number[];
978
993
  }[];
979
- name: string;
980
- required: boolean;
994
+ isNullable?: boolean | undefined;
981
995
  }[] | undefined;
982
996
  requestType?: string | undefined;
983
997
  fileUploadType?: "SINGLE" | "MULTIPLE" | undefined;
@@ -994,8 +1008,8 @@ declare const resturaZodSchema: z.ZodObject<{
994
1008
  columns: {
995
1009
  type: "SMALLINT" | "INTEGER" | "BIGINT" | "DECIMAL" | "NUMERIC" | "REAL" | "DOUBLE PRECISION" | "SERIAL" | "BIGSERIAL" | "CHAR" | "VARCHAR" | "TEXT" | "BYTEA" | "DATE" | "TIMESTAMP" | "TIMESTAMPTZ" | "TIME" | "INTERVAL" | "BOOLEAN" | "TINYINT" | "MEDIUMINT" | "FLOAT" | "DOUBLE" | "TINYTEXT" | "TINYBLOB" | "BLOB" | "MEDIUMTEXT" | "MEDIUMBLOB" | "LONGTEXT" | "JSON" | "LONGBLOB" | "ENUM" | "DATETIME";
996
1010
  name: string;
997
- roles: string[];
998
1011
  isNullable: boolean;
1012
+ roles: string[];
999
1013
  length?: number | undefined;
1000
1014
  value?: string | undefined;
1001
1015
  default?: string | undefined;
@@ -1030,7 +1044,7 @@ declare const resturaZodSchema: z.ZodObject<{
1030
1044
  baseUrl: string;
1031
1045
  routes: ({
1032
1046
  path: string;
1033
- type: "PAGED" | "ARRAY" | "ONE";
1047
+ type: "ONE" | "ARRAY" | "PAGED";
1034
1048
  name: string;
1035
1049
  table: string;
1036
1050
  joins: {
@@ -1057,12 +1071,13 @@ declare const resturaZodSchema: z.ZodObject<{
1057
1071
  name: string;
1058
1072
  }[];
1059
1073
  request: {
1074
+ name: string;
1075
+ required: boolean;
1076
+ isNullable: boolean;
1060
1077
  validator: {
1061
1078
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
1062
1079
  value: string | number | string[] | number[];
1063
1080
  }[];
1064
- name: string;
1065
- required: boolean;
1066
1081
  }[];
1067
1082
  response: {
1068
1083
  name: string;
@@ -1118,12 +1133,13 @@ declare const resturaZodSchema: z.ZodObject<{
1118
1133
  joins?: undefined;
1119
1134
  assignments?: undefined;
1120
1135
  request?: {
1136
+ name: string;
1137
+ required: boolean;
1138
+ isNullable: boolean;
1121
1139
  validator: {
1122
1140
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
1123
1141
  value: string | number | string[] | number[];
1124
1142
  }[];
1125
- name: string;
1126
- required: boolean;
1127
1143
  }[] | undefined;
1128
1144
  requestType?: string | undefined;
1129
1145
  fileUploadType?: "SINGLE" | "MULTIPLE" | undefined;
@@ -1139,8 +1155,8 @@ declare const resturaZodSchema: z.ZodObject<{
1139
1155
  columns: {
1140
1156
  type: "SMALLINT" | "INTEGER" | "BIGINT" | "DECIMAL" | "NUMERIC" | "REAL" | "DOUBLE PRECISION" | "SERIAL" | "BIGSERIAL" | "CHAR" | "VARCHAR" | "TEXT" | "BYTEA" | "DATE" | "TIMESTAMP" | "TIMESTAMPTZ" | "TIME" | "INTERVAL" | "BOOLEAN" | "TINYINT" | "MEDIUMINT" | "FLOAT" | "DOUBLE" | "TINYTEXT" | "TINYBLOB" | "BLOB" | "MEDIUMTEXT" | "MEDIUMBLOB" | "LONGTEXT" | "JSON" | "LONGBLOB" | "ENUM" | "DATETIME";
1141
1157
  name: string;
1142
- roles: string[];
1143
1158
  isNullable: boolean;
1159
+ roles: string[];
1144
1160
  length?: number | undefined;
1145
1161
  value?: string | undefined;
1146
1162
  default?: string | undefined;
@@ -1175,7 +1191,7 @@ declare const resturaZodSchema: z.ZodObject<{
1175
1191
  baseUrl: string;
1176
1192
  routes: ({
1177
1193
  path: string;
1178
- type: "PAGED" | "ARRAY" | "ONE";
1194
+ type: "ONE" | "ARRAY" | "PAGED";
1179
1195
  name: string;
1180
1196
  table: string;
1181
1197
  joins: {
@@ -1202,12 +1218,13 @@ declare const resturaZodSchema: z.ZodObject<{
1202
1218
  name: string;
1203
1219
  }[];
1204
1220
  request: {
1221
+ name: string;
1222
+ required: boolean;
1205
1223
  validator: {
1206
1224
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
1207
1225
  value: string | number | string[] | number[];
1208
1226
  }[];
1209
- name: string;
1210
- required: boolean;
1227
+ isNullable?: boolean | undefined;
1211
1228
  }[];
1212
1229
  response: {
1213
1230
  name: string;
@@ -1263,12 +1280,13 @@ declare const resturaZodSchema: z.ZodObject<{
1263
1280
  joins?: undefined;
1264
1281
  assignments?: undefined;
1265
1282
  request?: {
1283
+ name: string;
1284
+ required: boolean;
1266
1285
  validator: {
1267
1286
  type: "TYPE_CHECK" | "MIN" | "MAX" | "ONE_OF";
1268
1287
  value: string | number | string[] | number[];
1269
1288
  }[];
1270
- name: string;
1271
- required: boolean;
1289
+ isNullable?: boolean | undefined;
1272
1290
  }[] | undefined;
1273
1291
  requestType?: string | undefined;
1274
1292
  fileUploadType?: "SINGLE" | "MULTIPLE" | undefined;