@baseplate-dev/project-builder-lib 0.2.1 → 0.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (191) hide show
  1. package/dist/definition/feature/feature-utils.js +1 -1
  2. package/dist/definition/feature/feature-utils.js.map +1 -1
  3. package/dist/definition/project-definition-container.d.ts +3 -2
  4. package/dist/definition/project-definition-container.d.ts.map +1 -1
  5. package/dist/definition/project-definition-container.js +13 -7
  6. package/dist/definition/project-definition-container.js.map +1 -1
  7. package/dist/definition/project-definition-container.test-utils.d.ts.map +1 -1
  8. package/dist/definition/project-definition-container.test-utils.js +3 -7
  9. package/dist/definition/project-definition-container.test-utils.js.map +1 -1
  10. package/dist/migrations/index.d.ts.map +1 -1
  11. package/dist/migrations/index.js +2 -0
  12. package/dist/migrations/index.js.map +1 -1
  13. package/dist/migrations/migration-015-null-parent-refs.d.ts +17 -0
  14. package/dist/migrations/migration-015-null-parent-refs.d.ts.map +1 -0
  15. package/dist/migrations/migration-015-null-parent-refs.js +20 -0
  16. package/dist/migrations/migration-015-null-parent-refs.js.map +1 -0
  17. package/dist/parser/parser.d.ts +2 -2
  18. package/dist/parser/parser.d.ts.map +1 -1
  19. package/dist/parser/parser.js +11 -7
  20. package/dist/parser/parser.js.map +1 -1
  21. package/dist/plugins/metadata/types.d.ts +8 -0
  22. package/dist/plugins/metadata/types.d.ts.map +1 -1
  23. package/dist/plugins/metadata/types.js +6 -0
  24. package/dist/plugins/metadata/types.js.map +1 -1
  25. package/dist/plugins/migrations/run-migrations.js.map +1 -1
  26. package/dist/plugins/schema/index.d.ts +0 -2
  27. package/dist/plugins/schema/index.d.ts.map +1 -1
  28. package/dist/plugins/schema/index.js +0 -2
  29. package/dist/plugins/schema/index.js.map +1 -1
  30. package/dist/plugins/spec/config-spec.d.ts +3 -3
  31. package/dist/plugins/spec/config-spec.d.ts.map +1 -1
  32. package/dist/plugins/spec/config-spec.js +3 -3
  33. package/dist/plugins/spec/config-spec.js.map +1 -1
  34. package/dist/references/{ref-builder.d.ts → definition-ref-builder.d.ts} +13 -137
  35. package/dist/references/definition-ref-builder.d.ts.map +1 -0
  36. package/dist/references/definition-ref-builder.js +242 -0
  37. package/dist/references/definition-ref-builder.js.map +1 -0
  38. package/dist/references/deserialize-schema.d.ts +12 -1
  39. package/dist/references/deserialize-schema.d.ts.map +1 -1
  40. package/dist/references/deserialize-schema.js +24 -4
  41. package/dist/references/deserialize-schema.js.map +1 -1
  42. package/dist/references/extend-parser-context-with-refs.d.ts +16 -0
  43. package/dist/references/extend-parser-context-with-refs.d.ts.map +1 -0
  44. package/dist/references/extend-parser-context-with-refs.js +82 -0
  45. package/dist/references/extend-parser-context-with-refs.js.map +1 -0
  46. package/dist/references/extract-definition-refs.d.ts +19 -0
  47. package/dist/references/extract-definition-refs.d.ts.map +1 -0
  48. package/dist/references/extract-definition-refs.js +71 -0
  49. package/dist/references/extract-definition-refs.js.map +1 -0
  50. package/dist/references/fix-ref-deletions.d.ts +6 -6
  51. package/dist/references/fix-ref-deletions.d.ts.map +1 -1
  52. package/dist/references/fix-ref-deletions.js +13 -5
  53. package/dist/references/fix-ref-deletions.js.map +1 -1
  54. package/dist/references/index.d.ts +2 -1
  55. package/dist/references/index.d.ts.map +1 -1
  56. package/dist/references/index.js +2 -1
  57. package/dist/references/index.js.map +1 -1
  58. package/dist/references/markers.d.ts +22 -0
  59. package/dist/references/markers.d.ts.map +1 -0
  60. package/dist/references/markers.js +21 -0
  61. package/dist/references/markers.js.map +1 -0
  62. package/dist/references/parse-schema-with-references.d.ts +2 -2
  63. package/dist/references/parse-schema-with-references.d.ts.map +1 -1
  64. package/dist/references/parse-schema-with-references.js +13 -4
  65. package/dist/references/parse-schema-with-references.js.map +1 -1
  66. package/dist/references/resolve-zod-ref-payload-names.d.ts +1 -1
  67. package/dist/references/resolve-zod-ref-payload-names.d.ts.map +1 -1
  68. package/dist/references/serialize-schema.d.ts +2 -2
  69. package/dist/references/serialize-schema.d.ts.map +1 -1
  70. package/dist/references/serialize-schema.js +4 -3
  71. package/dist/references/serialize-schema.js.map +1 -1
  72. package/dist/references/strip-ref-markers.d.ts +7 -0
  73. package/dist/references/strip-ref-markers.d.ts.map +1 -0
  74. package/dist/references/strip-ref-markers.js +22 -0
  75. package/dist/references/strip-ref-markers.js.map +1 -0
  76. package/dist/references/types.d.ts +2 -2
  77. package/dist/references/types.d.ts.map +1 -1
  78. package/dist/schema/apps/admin/app.d.ts +958 -200
  79. package/dist/schema/apps/admin/app.d.ts.map +1 -1
  80. package/dist/schema/apps/admin/app.js +2 -3
  81. package/dist/schema/apps/admin/app.js.map +1 -1
  82. package/dist/schema/apps/admin/sections/base.d.ts +15 -3
  83. package/dist/schema/apps/admin/sections/base.d.ts.map +1 -1
  84. package/dist/schema/apps/admin/sections/base.js +4 -4
  85. package/dist/schema/apps/admin/sections/base.js.map +1 -1
  86. package/dist/schema/apps/admin/sections/crud-form/admin-crud-input.d.ts +12 -6
  87. package/dist/schema/apps/admin/sections/crud-form/admin-crud-input.d.ts.map +1 -1
  88. package/dist/schema/apps/admin/sections/crud-form/admin-crud-input.js +9 -5
  89. package/dist/schema/apps/admin/sections/crud-form/admin-crud-input.js.map +1 -1
  90. package/dist/schema/apps/admin/sections/crud-form/built-in-input.d.ts +19 -19
  91. package/dist/schema/apps/admin/sections/crud-form/built-in-input.d.ts.map +1 -1
  92. package/dist/schema/apps/admin/sections/crud-form/built-in-input.js +18 -19
  93. package/dist/schema/apps/admin/sections/crud-form/built-in-input.js.map +1 -1
  94. package/dist/schema/apps/admin/sections/crud-form/types.d.ts +1 -1
  95. package/dist/schema/apps/admin/sections/crud-form/types.d.ts.map +1 -1
  96. package/dist/schema/apps/admin/sections/crud.d.ts +468 -130
  97. package/dist/schema/apps/admin/sections/crud.d.ts.map +1 -1
  98. package/dist/schema/apps/admin/sections/crud.js +14 -14
  99. package/dist/schema/apps/admin/sections/crud.js.map +1 -1
  100. package/dist/schema/apps/backend/index.d.ts +1 -1
  101. package/dist/schema/apps/types.d.ts +1 -1
  102. package/dist/schema/apps/types.js +1 -1
  103. package/dist/schema/apps/web/index.d.ts +2 -2
  104. package/dist/schema/apps/web/index.d.ts.map +1 -1
  105. package/dist/schema/apps/web/index.js +2 -3
  106. package/dist/schema/apps/web/index.js.map +1 -1
  107. package/dist/schema/auth/index.d.ts +1 -1
  108. package/dist/schema/auth/index.js +1 -1
  109. package/dist/schema/creator/extend-parser-context-with-defaults.d.ts +13 -0
  110. package/dist/schema/creator/extend-parser-context-with-defaults.d.ts.map +1 -0
  111. package/dist/schema/creator/extend-parser-context-with-defaults.js +52 -0
  112. package/dist/schema/creator/extend-parser-context-with-defaults.js.map +1 -0
  113. package/dist/schema/creator/schema-creator.d.ts +3 -2
  114. package/dist/schema/creator/schema-creator.d.ts.map +1 -1
  115. package/dist/schema/creator/schema-creator.js +10 -1
  116. package/dist/schema/creator/schema-creator.js.map +1 -1
  117. package/dist/schema/creator/types.d.ts +57 -2
  118. package/dist/schema/creator/types.d.ts.map +1 -1
  119. package/dist/schema/features/feature.d.ts +29 -15
  120. package/dist/schema/features/feature.d.ts.map +1 -1
  121. package/dist/schema/features/feature.js +7 -4
  122. package/dist/schema/features/feature.js.map +1 -1
  123. package/dist/schema/features/theme.d.ts +12 -12
  124. package/dist/schema/models/enums.d.ts +62 -19
  125. package/dist/schema/models/enums.d.ts.map +1 -1
  126. package/dist/schema/models/enums.js +5 -4
  127. package/dist/schema/models/enums.js.map +1 -1
  128. package/dist/schema/models/graphql.d.ts +139 -55
  129. package/dist/schema/models/graphql.d.ts.map +1 -1
  130. package/dist/schema/models/graphql.js +36 -80
  131. package/dist/schema/models/graphql.js.map +1 -1
  132. package/dist/schema/models/index.d.ts +881 -299
  133. package/dist/schema/models/index.d.ts.map +1 -1
  134. package/dist/schema/models/index.js +24 -19
  135. package/dist/schema/models/index.js.map +1 -1
  136. package/dist/schema/models/transformers/built-in-transformers.d.ts +87 -23
  137. package/dist/schema/models/transformers/built-in-transformers.d.ts.map +1 -1
  138. package/dist/schema/models/transformers/built-in-transformers.js +10 -10
  139. package/dist/schema/models/transformers/built-in-transformers.js.map +1 -1
  140. package/dist/schema/models/transformers/transformers.d.ts +14 -8
  141. package/dist/schema/models/transformers/transformers.d.ts.map +1 -1
  142. package/dist/schema/models/transformers/transformers.js +9 -5
  143. package/dist/schema/models/transformers/transformers.js.map +1 -1
  144. package/dist/schema/models/transformers/types.d.ts +4 -3
  145. package/dist/schema/models/transformers/types.d.ts.map +1 -1
  146. package/dist/schema/models/transformers/types.js +2 -4
  147. package/dist/schema/models/transformers/types.js.map +1 -1
  148. package/dist/schema/plugins/definition.d.ts +64 -70
  149. package/dist/schema/plugins/definition.d.ts.map +1 -1
  150. package/dist/schema/plugins/definition.js +18 -16
  151. package/dist/schema/plugins/definition.js.map +1 -1
  152. package/dist/schema/project-definition.d.ts +2192 -682
  153. package/dist/schema/project-definition.d.ts.map +1 -1
  154. package/dist/schema/project-definition.js +1 -2
  155. package/dist/schema/project-definition.js.map +1 -1
  156. package/dist/schema/settings.d.ts +15 -15
  157. package/dist/schema/template-extractor/index.d.ts +1 -1
  158. package/dist/tools/model-merger/model-merger.d.ts +15 -14
  159. package/dist/tools/model-merger/model-merger.d.ts.map +1 -1
  160. package/dist/tools/model-merger/model-merger.js +8 -4
  161. package/dist/tools/model-merger/model-merger.js.map +1 -1
  162. package/dist/web/hooks/index.d.ts +1 -1
  163. package/dist/web/hooks/index.d.ts.map +1 -1
  164. package/dist/web/hooks/index.js +1 -1
  165. package/dist/web/hooks/index.js.map +1 -1
  166. package/dist/web/hooks/use-definition-schema.d.ts +3 -0
  167. package/dist/web/hooks/use-definition-schema.d.ts.map +1 -0
  168. package/dist/web/hooks/use-definition-schema.js +7 -0
  169. package/dist/web/hooks/use-definition-schema.js.map +1 -0
  170. package/dist/web/hooks/use-project-definition.d.ts +3 -3
  171. package/dist/web/hooks/use-project-definition.d.ts.map +1 -1
  172. package/package.json +6 -6
  173. package/dist/plugins/schema/common.d.ts +0 -6
  174. package/dist/plugins/schema/common.d.ts.map +0 -1
  175. package/dist/plugins/schema/common.js +0 -2
  176. package/dist/plugins/schema/common.js.map +0 -1
  177. package/dist/plugins/schema/parser.d.ts +0 -19
  178. package/dist/plugins/schema/parser.d.ts.map +0 -1
  179. package/dist/plugins/schema/parser.js +0 -41
  180. package/dist/plugins/schema/parser.js.map +0 -1
  181. package/dist/plugins/schema/zod-with-plugins.d.ts +0 -12
  182. package/dist/plugins/schema/zod-with-plugins.d.ts.map +0 -1
  183. package/dist/plugins/schema/zod-with-plugins.js +0 -26
  184. package/dist/plugins/schema/zod-with-plugins.js.map +0 -1
  185. package/dist/references/ref-builder.d.ts.map +0 -1
  186. package/dist/references/ref-builder.js +0 -492
  187. package/dist/references/ref-builder.js.map +0 -1
  188. package/dist/web/hooks/use-plugin-enhanced-schema.d.ts +0 -4
  189. package/dist/web/hooks/use-plugin-enhanced-schema.d.ts.map +0 -1
  190. package/dist/web/hooks/use-plugin-enhanced-schema.js +0 -8
  191. package/dist/web/hooks/use-plugin-enhanced-schema.js.map +0 -1
@@ -4,16 +4,17 @@ export * from './enums.js';
4
4
  export * from './graphql.js';
5
5
  export * from './transformers/index.js';
6
6
  export * from './types.js';
7
- export declare const createModelScalarFieldSchema: (options: import("#src/schema/creator/index.js").DefinitionSchemaCreatorOptions) => z.ZodEffects<z.ZodEffects<import("#src/references/index.js").ZodRef<z.ZodObject<{
7
+ export declare const createModelScalarFieldSchema: (context: import("#src/schema/creator/index.js").DefinitionSchemaParserContext) => z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodObject<{
8
+ id: z.ZodString;
8
9
  name: z.ZodString;
9
10
  type: z.ZodEnum<["string", "uuid", "int", "boolean", "dateTime", "float", "decimal", "json", "date", "enum"]>;
10
11
  isOptional: z.ZodDefault<z.ZodBoolean>;
11
- options: import("#src/references/index.js").ZodRef<z.ZodDefault<z.ZodEffects<z.ZodObject<{
12
+ options: z.ZodEffects<z.ZodDefault<z.ZodEffects<z.ZodObject<{
12
13
  default: z.ZodDefault<z.ZodString>;
13
14
  genUuid: z.ZodOptional<z.ZodBoolean>;
14
15
  updatedAt: z.ZodOptional<z.ZodBoolean>;
15
16
  defaultToNow: z.ZodOptional<z.ZodBoolean>;
16
- enumRef: import("#src/references/index.js").ZodRef<z.ZodOptional<z.ZodString>>;
17
+ enumRef: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
17
18
  defaultEnumValueRef: z.ZodOptional<z.ZodString>;
18
19
  }, "strip", z.ZodTypeAny, {
19
20
  default: string;
@@ -43,9 +44,21 @@ export declare const createModelScalarFieldSchema: (options: import("#src/schema
43
44
  defaultToNow?: boolean | undefined;
44
45
  enumRef?: string | undefined;
45
46
  defaultEnumValueRef?: string | undefined;
46
- }>>>;
47
- } & {
48
- id: z.ZodType<string, z.ZodAnyDef, string>;
47
+ }>>, {
48
+ defaultEnumValueRef?: string | undefined;
49
+ default: string;
50
+ genUuid?: boolean | undefined;
51
+ updatedAt?: boolean | undefined;
52
+ defaultToNow?: boolean | undefined;
53
+ enumRef?: string | undefined;
54
+ }, {
55
+ default?: string | undefined;
56
+ genUuid?: boolean | undefined;
57
+ updatedAt?: boolean | undefined;
58
+ defaultToNow?: boolean | undefined;
59
+ enumRef?: string | undefined;
60
+ defaultEnumValueRef?: string | undefined;
61
+ } | undefined>;
49
62
  }, "strip", z.ZodTypeAny, {
50
63
  options: {
51
64
  defaultEnumValueRef?: string | undefined;
@@ -72,7 +85,33 @@ export declare const createModelScalarFieldSchema: (options: import("#src/schema
72
85
  defaultEnumValueRef?: string | undefined;
73
86
  } | undefined;
74
87
  isOptional?: boolean | undefined;
75
- }>>, {
88
+ }>, {
89
+ options: {
90
+ defaultEnumValueRef?: string | undefined;
91
+ default: string;
92
+ genUuid?: boolean | undefined;
93
+ updatedAt?: boolean | undefined;
94
+ defaultToNow?: boolean | undefined;
95
+ enumRef?: string | undefined;
96
+ };
97
+ type: "string" | "boolean" | "float" | "date" | "uuid" | "int" | "dateTime" | "decimal" | "json" | "enum";
98
+ name: string;
99
+ id: string;
100
+ isOptional: boolean;
101
+ }, {
102
+ type: "string" | "boolean" | "float" | "date" | "uuid" | "int" | "dateTime" | "decimal" | "json" | "enum";
103
+ name: string;
104
+ id: string;
105
+ options?: {
106
+ default?: string | undefined;
107
+ genUuid?: boolean | undefined;
108
+ updatedAt?: boolean | undefined;
109
+ defaultToNow?: boolean | undefined;
110
+ enumRef?: string | undefined;
111
+ defaultEnumValueRef?: string | undefined;
112
+ } | undefined;
113
+ isOptional?: boolean | undefined;
114
+ }>, {
76
115
  options: {
77
116
  defaultEnumValueRef?: string | undefined;
78
117
  default: string;
@@ -128,13 +167,13 @@ export declare const createModelScalarFieldSchema: (options: import("#src/schema
128
167
  export type ModelScalarFieldConfig = def.InferOutput<typeof createModelScalarFieldSchema>;
129
168
  export type ModelScalarFieldConfigInput = def.InferInput<typeof createModelScalarFieldSchema>;
130
169
  export declare const REFERENTIAL_ACTIONS: readonly ["Cascade", "Restrict", "NoAction", "SetNull", "SetDefault"];
131
- export declare const createModelRelationFieldSchema: (options: import("#src/schema/creator/index.js").DefinitionSchemaCreatorOptions) => import("#src/references/index.js").ZodRef<z.ZodObject<{
170
+ export declare const createModelRelationFieldSchema: (context: import("#src/schema/creator/index.js").DefinitionSchemaParserContext) => z.ZodEffects<z.ZodObject<{
132
171
  id: z.ZodString;
133
172
  foreignId: z.ZodDefault<z.ZodString>;
134
173
  name: z.ZodString;
135
174
  references: z.ZodArray<z.ZodObject<{
136
- localRef: import("#src/references/index.js").ZodRef<z.ZodString>;
137
- foreignRef: import("#src/references/index.js").ZodRef<z.ZodString>;
175
+ localRef: z.ZodEffects<z.ZodString, string, string>;
176
+ foreignRef: z.ZodEffects<z.ZodString, string, string>;
138
177
  }, "strip", z.ZodTypeAny, {
139
178
  localRef: string;
140
179
  foreignRef: string;
@@ -170,19 +209,42 @@ export declare const createModelRelationFieldSchema: (options: import("#src/sche
170
209
  onDelete?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
171
210
  foreignId?: string | undefined;
172
211
  onUpdate?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
173
- }>>;
212
+ }>, {
213
+ name: string;
214
+ id: string;
215
+ onDelete: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault";
216
+ references: {
217
+ localRef: string;
218
+ foreignRef: string;
219
+ }[];
220
+ modelRef: string;
221
+ foreignId: string;
222
+ foreignRelationName: string;
223
+ onUpdate: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault";
224
+ }, {
225
+ name: string;
226
+ id: string;
227
+ references: {
228
+ localRef: string;
229
+ foreignRef: string;
230
+ }[];
231
+ modelRef: string;
232
+ foreignRelationName: string;
233
+ onDelete?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
234
+ foreignId?: string | undefined;
235
+ onUpdate?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
236
+ }>;
174
237
  export type ModelRelationFieldConfig = def.InferOutput<typeof createModelRelationFieldSchema>;
175
238
  export type ModelRelationFieldConfigInput = def.InferInput<typeof createModelRelationFieldSchema>;
176
- export declare const createModelUniqueConstraintSchema: (options: import("#src/schema/creator/index.js").DefinitionSchemaCreatorOptions) => import("#src/references/index.js").ZodRef<z.ZodObject<{
239
+ export declare const createModelUniqueConstraintSchema: (context: import("#src/schema/creator/index.js").DefinitionSchemaParserContext) => z.ZodEffects<z.ZodObject<{
240
+ id: z.ZodString;
177
241
  fields: z.ZodArray<z.ZodObject<{
178
- fieldRef: import("#src/references/index.js").ZodRef<z.ZodString>;
242
+ fieldRef: z.ZodEffects<z.ZodString, string, string>;
179
243
  }, "strip", z.ZodTypeAny, {
180
244
  fieldRef: string;
181
245
  }, {
182
246
  fieldRef: string;
183
247
  }>, "many">;
184
- } & {
185
- id: z.ZodType<string, z.ZodAnyDef, string>;
186
248
  }, "strip", z.ZodTypeAny, {
187
249
  id: string;
188
250
  fields: {
@@ -193,14 +255,24 @@ export declare const createModelUniqueConstraintSchema: (options: import("#src/s
193
255
  fields: {
194
256
  fieldRef: string;
195
257
  }[];
196
- }>>;
258
+ }>, {
259
+ id: string;
260
+ fields: {
261
+ fieldRef: string;
262
+ }[];
263
+ }, {
264
+ id: string;
265
+ fields: {
266
+ fieldRef: string;
267
+ }[];
268
+ }>;
197
269
  export type ModelUniqueConstraintConfig = def.InferOutput<typeof createModelUniqueConstraintSchema>;
198
270
  export type ModelUniqueConstraintConfigInput = def.InferInput<typeof createModelUniqueConstraintSchema>;
199
- export declare const createModelServiceSchema: (options: import("#src/schema/creator/index.js").DefinitionSchemaCreatorOptions) => z.ZodObject<{
271
+ export declare const createModelServiceSchema: (context: import("#src/schema/creator/index.js").DefinitionSchemaParserContext) => z.ZodObject<{
200
272
  create: z.ZodDefault<z.ZodObject<{
201
273
  enabled: z.ZodDefault<z.ZodBoolean>;
202
- fields: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
203
- transformerNames: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
274
+ fields: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
275
+ transformerNames: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
204
276
  }, "strip", z.ZodTypeAny, {
205
277
  enabled: boolean;
206
278
  fields?: string[] | undefined;
@@ -212,8 +284,8 @@ export declare const createModelServiceSchema: (options: import("#src/schema/cre
212
284
  }>>;
213
285
  update: z.ZodDefault<z.ZodObject<{
214
286
  enabled: z.ZodDefault<z.ZodBoolean>;
215
- fields: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
216
- transformerNames: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
287
+ fields: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
288
+ transformerNames: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
217
289
  }, "strip", z.ZodTypeAny, {
218
290
  enabled: boolean;
219
291
  fields?: string[] | undefined;
@@ -230,16 +302,22 @@ export declare const createModelServiceSchema: (options: import("#src/schema/cre
230
302
  }, {
231
303
  enabled?: boolean | undefined;
232
304
  }>>;
233
- transformers: z.ZodDefault<z.ZodArray<import("../../index.js").ZodWithPlugins<z.ZodObject<{
234
- type: z.ZodString;
235
- id: z.ZodString;
236
- }, "strip", z.ZodTypeAny, {
237
- type: string;
238
- id: string;
239
- }, {
305
+ transformers: z.ZodDefault<z.ZodArray<z.ZodEffects<z.ZodObject<{
306
+ readonly id: z.ZodString;
307
+ readonly type: z.ZodString;
308
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
309
+ readonly id: z.ZodString;
310
+ readonly type: z.ZodString;
311
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
312
+ readonly id: z.ZodString;
313
+ readonly type: z.ZodString;
314
+ }, z.ZodTypeAny, "passthrough">>, {
240
315
  type: string;
241
316
  id: string;
242
- }>>, "many">>;
317
+ }, z.objectInputType<{
318
+ readonly id: z.ZodString;
319
+ readonly type: z.ZodString;
320
+ }, z.ZodTypeAny, "passthrough">>, "many">>;
243
321
  }, "strip", z.ZodTypeAny, {
244
322
  delete: {
245
323
  enabled: boolean;
@@ -272,27 +350,28 @@ export declare const createModelServiceSchema: (options: import("#src/schema/cre
272
350
  fields?: string[] | undefined;
273
351
  transformerNames?: string[] | undefined;
274
352
  } | undefined;
275
- transformers?: {
276
- type: string;
277
- id: string;
278
- }[] | undefined;
353
+ transformers?: z.objectInputType<{
354
+ readonly id: z.ZodString;
355
+ readonly type: z.ZodString;
356
+ }, z.ZodTypeAny, "passthrough">[] | undefined;
279
357
  }>;
280
358
  export type ModelServiceConfig = def.InferOutput<typeof createModelServiceSchema>;
281
- export declare const createModelBaseSchema: (options: import("#src/schema/creator/index.js").DefinitionSchemaCreatorOptions) => z.ZodObject<{
359
+ export declare const createModelBaseSchema: (context: import("#src/schema/creator/index.js").DefinitionSchemaParserContext) => z.ZodObject<{
282
360
  id: z.ZodString;
283
361
  name: z.ZodString;
284
- featureRef: import("#src/references/index.js").ZodRef<z.ZodString>;
362
+ featureRef: z.ZodEffects<z.ZodString, string, string>;
285
363
  model: z.ZodObject<{
286
- fields: z.ZodArray<z.ZodEffects<z.ZodEffects<import("#src/references/index.js").ZodRef<z.ZodObject<{
364
+ fields: z.ZodArray<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodObject<{
365
+ id: z.ZodString;
287
366
  name: z.ZodString;
288
367
  type: z.ZodEnum<["string", "uuid", "int", "boolean", "dateTime", "float", "decimal", "json", "date", "enum"]>;
289
368
  isOptional: z.ZodDefault<z.ZodBoolean>;
290
- options: import("#src/references/index.js").ZodRef<z.ZodDefault<z.ZodEffects<z.ZodObject<{
369
+ options: z.ZodEffects<z.ZodDefault<z.ZodEffects<z.ZodObject<{
291
370
  default: z.ZodDefault<z.ZodString>;
292
371
  genUuid: z.ZodOptional<z.ZodBoolean>;
293
372
  updatedAt: z.ZodOptional<z.ZodBoolean>;
294
373
  defaultToNow: z.ZodOptional<z.ZodBoolean>;
295
- enumRef: import("#src/references/index.js").ZodRef<z.ZodOptional<z.ZodString>>;
374
+ enumRef: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
296
375
  defaultEnumValueRef: z.ZodOptional<z.ZodString>;
297
376
  }, "strip", z.ZodTypeAny, {
298
377
  default: string;
@@ -322,9 +401,21 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
322
401
  defaultToNow?: boolean | undefined;
323
402
  enumRef?: string | undefined;
324
403
  defaultEnumValueRef?: string | undefined;
325
- }>>>;
326
- } & {
327
- id: z.ZodType<string, z.ZodAnyDef, string>;
404
+ }>>, {
405
+ defaultEnumValueRef?: string | undefined;
406
+ default: string;
407
+ genUuid?: boolean | undefined;
408
+ updatedAt?: boolean | undefined;
409
+ defaultToNow?: boolean | undefined;
410
+ enumRef?: string | undefined;
411
+ }, {
412
+ default?: string | undefined;
413
+ genUuid?: boolean | undefined;
414
+ updatedAt?: boolean | undefined;
415
+ defaultToNow?: boolean | undefined;
416
+ enumRef?: string | undefined;
417
+ defaultEnumValueRef?: string | undefined;
418
+ } | undefined>;
328
419
  }, "strip", z.ZodTypeAny, {
329
420
  options: {
330
421
  defaultEnumValueRef?: string | undefined;
@@ -351,7 +442,33 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
351
442
  defaultEnumValueRef?: string | undefined;
352
443
  } | undefined;
353
444
  isOptional?: boolean | undefined;
354
- }>>, {
445
+ }>, {
446
+ options: {
447
+ defaultEnumValueRef?: string | undefined;
448
+ default: string;
449
+ genUuid?: boolean | undefined;
450
+ updatedAt?: boolean | undefined;
451
+ defaultToNow?: boolean | undefined;
452
+ enumRef?: string | undefined;
453
+ };
454
+ type: "string" | "boolean" | "float" | "date" | "uuid" | "int" | "dateTime" | "decimal" | "json" | "enum";
455
+ name: string;
456
+ id: string;
457
+ isOptional: boolean;
458
+ }, {
459
+ type: "string" | "boolean" | "float" | "date" | "uuid" | "int" | "dateTime" | "decimal" | "json" | "enum";
460
+ name: string;
461
+ id: string;
462
+ options?: {
463
+ default?: string | undefined;
464
+ genUuid?: boolean | undefined;
465
+ updatedAt?: boolean | undefined;
466
+ defaultToNow?: boolean | undefined;
467
+ enumRef?: string | undefined;
468
+ defaultEnumValueRef?: string | undefined;
469
+ } | undefined;
470
+ isOptional?: boolean | undefined;
471
+ }>, {
355
472
  options: {
356
473
  defaultEnumValueRef?: string | undefined;
357
474
  default: string;
@@ -404,13 +521,13 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
404
521
  } | undefined;
405
522
  isOptional?: boolean | undefined;
406
523
  }>, "many">;
407
- relations: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodObject<{
524
+ relations: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodObject<{
408
525
  id: z.ZodString;
409
526
  foreignId: z.ZodDefault<z.ZodString>;
410
527
  name: z.ZodString;
411
528
  references: z.ZodArray<z.ZodObject<{
412
- localRef: import("#src/references/index.js").ZodRef<z.ZodString>;
413
- foreignRef: import("#src/references/index.js").ZodRef<z.ZodString>;
529
+ localRef: z.ZodEffects<z.ZodString, string, string>;
530
+ foreignRef: z.ZodEffects<z.ZodString, string, string>;
414
531
  }, "strip", z.ZodTypeAny, {
415
532
  localRef: string;
416
533
  foreignRef: string;
@@ -446,18 +563,41 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
446
563
  onDelete?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
447
564
  foreignId?: string | undefined;
448
565
  onUpdate?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
449
- }>>, "many">>;
450
- primaryKeyFieldRefs: z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">;
451
- uniqueConstraints: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodObject<{
566
+ }>, {
567
+ name: string;
568
+ id: string;
569
+ onDelete: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault";
570
+ references: {
571
+ localRef: string;
572
+ foreignRef: string;
573
+ }[];
574
+ modelRef: string;
575
+ foreignId: string;
576
+ foreignRelationName: string;
577
+ onUpdate: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault";
578
+ }, {
579
+ name: string;
580
+ id: string;
581
+ references: {
582
+ localRef: string;
583
+ foreignRef: string;
584
+ }[];
585
+ modelRef: string;
586
+ foreignRelationName: string;
587
+ onDelete?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
588
+ foreignId?: string | undefined;
589
+ onUpdate?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
590
+ }>, "many">>;
591
+ primaryKeyFieldRefs: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
592
+ uniqueConstraints: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodObject<{
593
+ id: z.ZodString;
452
594
  fields: z.ZodArray<z.ZodObject<{
453
- fieldRef: import("#src/references/index.js").ZodRef<z.ZodString>;
595
+ fieldRef: z.ZodEffects<z.ZodString, string, string>;
454
596
  }, "strip", z.ZodTypeAny, {
455
597
  fieldRef: string;
456
598
  }, {
457
599
  fieldRef: string;
458
600
  }>, "many">;
459
- } & {
460
- id: z.ZodType<string, z.ZodAnyDef, string>;
461
601
  }, "strip", z.ZodTypeAny, {
462
602
  id: string;
463
603
  fields: {
@@ -468,7 +608,17 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
468
608
  fields: {
469
609
  fieldRef: string;
470
610
  }[];
471
- }>>, "many">>;
611
+ }>, {
612
+ id: string;
613
+ fields: {
614
+ fieldRef: string;
615
+ }[];
616
+ }, {
617
+ id: string;
618
+ fields: {
619
+ fieldRef: string;
620
+ }[];
621
+ }>, "many">>;
472
622
  }, "strip", z.ZodTypeAny, {
473
623
  fields: {
474
624
  options: {
@@ -543,8 +693,8 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
543
693
  service: z.ZodDefault<z.ZodObject<{
544
694
  create: z.ZodDefault<z.ZodObject<{
545
695
  enabled: z.ZodDefault<z.ZodBoolean>;
546
- fields: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
547
- transformerNames: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
696
+ fields: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
697
+ transformerNames: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
548
698
  }, "strip", z.ZodTypeAny, {
549
699
  enabled: boolean;
550
700
  fields?: string[] | undefined;
@@ -556,8 +706,8 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
556
706
  }>>;
557
707
  update: z.ZodDefault<z.ZodObject<{
558
708
  enabled: z.ZodDefault<z.ZodBoolean>;
559
- fields: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
560
- transformerNames: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
709
+ fields: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
710
+ transformerNames: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
561
711
  }, "strip", z.ZodTypeAny, {
562
712
  enabled: boolean;
563
713
  fields?: string[] | undefined;
@@ -574,16 +724,22 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
574
724
  }, {
575
725
  enabled?: boolean | undefined;
576
726
  }>>;
577
- transformers: z.ZodDefault<z.ZodArray<import("../../index.js").ZodWithPlugins<z.ZodObject<{
578
- type: z.ZodString;
579
- id: z.ZodString;
580
- }, "strip", z.ZodTypeAny, {
581
- type: string;
582
- id: string;
583
- }, {
727
+ transformers: z.ZodDefault<z.ZodArray<z.ZodEffects<z.ZodObject<{
728
+ readonly id: z.ZodString;
729
+ readonly type: z.ZodString;
730
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
731
+ readonly id: z.ZodString;
732
+ readonly type: z.ZodString;
733
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
734
+ readonly id: z.ZodString;
735
+ readonly type: z.ZodString;
736
+ }, z.ZodTypeAny, "passthrough">>, {
584
737
  type: string;
585
738
  id: string;
586
- }>>, "many">>;
739
+ }, z.objectInputType<{
740
+ readonly id: z.ZodString;
741
+ readonly type: z.ZodString;
742
+ }, z.ZodTypeAny, "passthrough">>, "many">>;
587
743
  }, "strip", z.ZodTypeAny, {
588
744
  delete: {
589
745
  enabled: boolean;
@@ -616,49 +772,71 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
616
772
  fields?: string[] | undefined;
617
773
  transformerNames?: string[] | undefined;
618
774
  } | undefined;
619
- transformers?: {
620
- type: string;
621
- id: string;
622
- }[] | undefined;
775
+ transformers?: z.objectInputType<{
776
+ readonly id: z.ZodString;
777
+ readonly type: z.ZodString;
778
+ }, z.ZodTypeAny, "passthrough">[] | undefined;
623
779
  }>>;
624
780
  graphql: z.ZodOptional<z.ZodObject<{
625
- objectType: z.ZodDefault<z.ZodObject<{
626
- enabled: z.ZodDefault<z.ZodBoolean>;
627
- fields: z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">;
628
- localRelations: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
629
- foreignRelations: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
781
+ objectType: z.ZodEffects<z.ZodOptional<z.ZodObject<{
782
+ enabled: z.ZodEffects<z.ZodOptional<z.ZodBoolean>, boolean | undefined, boolean | undefined>;
783
+ fields: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
784
+ localRelations: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
785
+ foreignRelations: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
630
786
  }, "strip", z.ZodTypeAny, {
631
- enabled: boolean;
632
- fields: string[];
787
+ enabled?: boolean | undefined;
788
+ fields?: string[] | undefined;
633
789
  localRelations?: string[] | undefined;
634
790
  foreignRelations?: string[] | undefined;
635
791
  }, {
636
- fields: string[];
637
792
  enabled?: boolean | undefined;
793
+ fields?: string[] | undefined;
638
794
  localRelations?: string[] | undefined;
639
795
  foreignRelations?: string[] | undefined;
640
- }>>;
641
- queries: z.ZodDefault<z.ZodObject<{
642
- get: z.ZodOptional<z.ZodObject<{
643
- enabled: z.ZodOptional<z.ZodBoolean>;
644
- roles: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
796
+ }>>, {
797
+ enabled?: boolean | undefined;
798
+ fields?: string[] | undefined;
799
+ localRelations?: string[] | undefined;
800
+ foreignRelations?: string[] | undefined;
801
+ } | undefined, {
802
+ enabled?: boolean | undefined;
803
+ fields?: string[] | undefined;
804
+ localRelations?: string[] | undefined;
805
+ foreignRelations?: string[] | undefined;
806
+ } | undefined>;
807
+ queries: z.ZodEffects<z.ZodOptional<z.ZodObject<{
808
+ get: z.ZodEffects<z.ZodOptional<z.ZodObject<{
809
+ enabled: z.ZodEffects<z.ZodOptional<z.ZodBoolean>, boolean | undefined, boolean | undefined>;
810
+ roles: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
645
811
  }, "strip", z.ZodTypeAny, {
646
812
  enabled?: boolean | undefined;
647
813
  roles?: string[] | undefined;
648
814
  }, {
649
815
  enabled?: boolean | undefined;
650
816
  roles?: string[] | undefined;
651
- }>>;
652
- list: z.ZodOptional<z.ZodObject<{
653
- enabled: z.ZodOptional<z.ZodBoolean>;
654
- roles: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
817
+ }>>, {
818
+ enabled?: boolean | undefined;
819
+ roles?: string[] | undefined;
820
+ } | undefined, {
821
+ enabled?: boolean | undefined;
822
+ roles?: string[] | undefined;
823
+ } | undefined>;
824
+ list: z.ZodEffects<z.ZodOptional<z.ZodObject<{
825
+ enabled: z.ZodEffects<z.ZodOptional<z.ZodBoolean>, boolean | undefined, boolean | undefined>;
826
+ roles: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
655
827
  }, "strip", z.ZodTypeAny, {
656
828
  enabled?: boolean | undefined;
657
829
  roles?: string[] | undefined;
658
830
  }, {
659
831
  enabled?: boolean | undefined;
660
832
  roles?: string[] | undefined;
661
- }>>;
833
+ }>>, {
834
+ enabled?: boolean | undefined;
835
+ roles?: string[] | undefined;
836
+ } | undefined, {
837
+ enabled?: boolean | undefined;
838
+ roles?: string[] | undefined;
839
+ } | undefined>;
662
840
  }, "strip", z.ZodTypeAny, {
663
841
  get?: {
664
842
  enabled?: boolean | undefined;
@@ -677,114 +855,88 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
677
855
  enabled?: boolean | undefined;
678
856
  roles?: string[] | undefined;
679
857
  } | undefined;
680
- }>>;
681
- mutations: z.ZodDefault<z.ZodObject<{
682
- create: z.ZodDefault<z.ZodObject<{
683
- enabled: z.ZodOptional<z.ZodBoolean>;
684
- roles: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
685
- }, "strip", z.ZodTypeAny, {
858
+ }>>, {
859
+ get?: {
686
860
  enabled?: boolean | undefined;
687
861
  roles?: string[] | undefined;
688
- }, {
862
+ } | undefined;
863
+ list?: {
689
864
  enabled?: boolean | undefined;
690
865
  roles?: string[] | undefined;
691
- }>>;
692
- update: z.ZodDefault<z.ZodObject<{
693
- enabled: z.ZodOptional<z.ZodBoolean>;
694
- roles: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
695
- }, "strip", z.ZodTypeAny, {
866
+ } | undefined;
867
+ } | undefined, {
868
+ get?: {
696
869
  enabled?: boolean | undefined;
697
870
  roles?: string[] | undefined;
698
- }, {
871
+ } | undefined;
872
+ list?: {
699
873
  enabled?: boolean | undefined;
700
874
  roles?: string[] | undefined;
701
- }>>;
702
- delete: z.ZodDefault<z.ZodObject<{
703
- enabled: z.ZodOptional<z.ZodBoolean>;
704
- roles: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
875
+ } | undefined;
876
+ } | undefined>;
877
+ mutations: z.ZodEffects<z.ZodOptional<z.ZodObject<{
878
+ create: z.ZodEffects<z.ZodOptional<z.ZodObject<{
879
+ enabled: z.ZodEffects<z.ZodOptional<z.ZodBoolean>, boolean | undefined, boolean | undefined>;
880
+ roles: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
705
881
  }, "strip", z.ZodTypeAny, {
706
882
  enabled?: boolean | undefined;
707
883
  roles?: string[] | undefined;
708
884
  }, {
709
885
  enabled?: boolean | undefined;
710
886
  roles?: string[] | undefined;
711
- }>>;
712
- }, "strip", z.ZodTypeAny, {
713
- delete: {
887
+ }>>, {
714
888
  enabled?: boolean | undefined;
715
889
  roles?: string[] | undefined;
716
- };
717
- create: {
890
+ } | undefined, {
718
891
  enabled?: boolean | undefined;
719
892
  roles?: string[] | undefined;
720
- };
721
- update: {
893
+ } | undefined>;
894
+ update: z.ZodEffects<z.ZodOptional<z.ZodObject<{
895
+ enabled: z.ZodEffects<z.ZodOptional<z.ZodBoolean>, boolean | undefined, boolean | undefined>;
896
+ roles: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
897
+ }, "strip", z.ZodTypeAny, {
722
898
  enabled?: boolean | undefined;
723
899
  roles?: string[] | undefined;
724
- };
725
- }, {
726
- delete?: {
900
+ }, {
727
901
  enabled?: boolean | undefined;
728
902
  roles?: string[] | undefined;
729
- } | undefined;
730
- create?: {
903
+ }>>, {
731
904
  enabled?: boolean | undefined;
732
905
  roles?: string[] | undefined;
733
- } | undefined;
734
- update?: {
906
+ } | undefined, {
735
907
  enabled?: boolean | undefined;
736
908
  roles?: string[] | undefined;
737
- } | undefined;
738
- }>>;
739
- }, "strip", z.ZodTypeAny, {
740
- objectType: {
741
- enabled: boolean;
742
- fields: string[];
743
- localRelations?: string[] | undefined;
744
- foreignRelations?: string[] | undefined;
745
- };
746
- queries: {
747
- get?: {
909
+ } | undefined>;
910
+ delete: z.ZodEffects<z.ZodOptional<z.ZodObject<{
911
+ enabled: z.ZodEffects<z.ZodOptional<z.ZodBoolean>, boolean | undefined, boolean | undefined>;
912
+ roles: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
913
+ }, "strip", z.ZodTypeAny, {
748
914
  enabled?: boolean | undefined;
749
915
  roles?: string[] | undefined;
750
- } | undefined;
751
- list?: {
916
+ }, {
752
917
  enabled?: boolean | undefined;
753
918
  roles?: string[] | undefined;
754
- } | undefined;
755
- };
756
- mutations: {
757
- delete: {
919
+ }>>, {
758
920
  enabled?: boolean | undefined;
759
921
  roles?: string[] | undefined;
760
- };
761
- create: {
922
+ } | undefined, {
762
923
  enabled?: boolean | undefined;
763
924
  roles?: string[] | undefined;
764
- };
765
- update: {
925
+ } | undefined>;
926
+ }, "strip", z.ZodTypeAny, {
927
+ delete?: {
766
928
  enabled?: boolean | undefined;
767
929
  roles?: string[] | undefined;
768
- };
769
- };
770
- }, {
771
- objectType?: {
772
- fields: string[];
773
- enabled?: boolean | undefined;
774
- localRelations?: string[] | undefined;
775
- foreignRelations?: string[] | undefined;
776
- } | undefined;
777
- queries?: {
778
- get?: {
930
+ } | undefined;
931
+ create?: {
779
932
  enabled?: boolean | undefined;
780
933
  roles?: string[] | undefined;
781
934
  } | undefined;
782
- list?: {
935
+ update?: {
783
936
  enabled?: boolean | undefined;
784
937
  roles?: string[] | undefined;
785
938
  } | undefined;
786
- } | undefined;
787
- mutations?: {
939
+ }, {
788
940
  delete?: {
789
941
  enabled?: boolean | undefined;
790
942
  roles?: string[] | undefined;
@@ -797,11 +949,100 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
797
949
  enabled?: boolean | undefined;
798
950
  roles?: string[] | undefined;
799
951
  } | undefined;
800
- } | undefined;
801
- }>>;
802
- }, "strip", z.ZodTypeAny, {
952
+ }>>, {
953
+ delete?: {
954
+ enabled?: boolean | undefined;
955
+ roles?: string[] | undefined;
956
+ } | undefined;
957
+ create?: {
958
+ enabled?: boolean | undefined;
959
+ roles?: string[] | undefined;
960
+ } | undefined;
961
+ update?: {
962
+ enabled?: boolean | undefined;
963
+ roles?: string[] | undefined;
964
+ } | undefined;
965
+ } | undefined, {
966
+ delete?: {
967
+ enabled?: boolean | undefined;
968
+ roles?: string[] | undefined;
969
+ } | undefined;
970
+ create?: {
971
+ enabled?: boolean | undefined;
972
+ roles?: string[] | undefined;
973
+ } | undefined;
974
+ update?: {
975
+ enabled?: boolean | undefined;
976
+ roles?: string[] | undefined;
977
+ } | undefined;
978
+ } | undefined>;
979
+ }, "strip", z.ZodTypeAny, {
980
+ objectType?: {
981
+ enabled?: boolean | undefined;
982
+ fields?: string[] | undefined;
983
+ localRelations?: string[] | undefined;
984
+ foreignRelations?: string[] | undefined;
985
+ } | undefined;
986
+ queries?: {
987
+ get?: {
988
+ enabled?: boolean | undefined;
989
+ roles?: string[] | undefined;
990
+ } | undefined;
991
+ list?: {
992
+ enabled?: boolean | undefined;
993
+ roles?: string[] | undefined;
994
+ } | undefined;
995
+ } | undefined;
996
+ mutations?: {
997
+ delete?: {
998
+ enabled?: boolean | undefined;
999
+ roles?: string[] | undefined;
1000
+ } | undefined;
1001
+ create?: {
1002
+ enabled?: boolean | undefined;
1003
+ roles?: string[] | undefined;
1004
+ } | undefined;
1005
+ update?: {
1006
+ enabled?: boolean | undefined;
1007
+ roles?: string[] | undefined;
1008
+ } | undefined;
1009
+ } | undefined;
1010
+ }, {
1011
+ objectType?: {
1012
+ enabled?: boolean | undefined;
1013
+ fields?: string[] | undefined;
1014
+ localRelations?: string[] | undefined;
1015
+ foreignRelations?: string[] | undefined;
1016
+ } | undefined;
1017
+ queries?: {
1018
+ get?: {
1019
+ enabled?: boolean | undefined;
1020
+ roles?: string[] | undefined;
1021
+ } | undefined;
1022
+ list?: {
1023
+ enabled?: boolean | undefined;
1024
+ roles?: string[] | undefined;
1025
+ } | undefined;
1026
+ } | undefined;
1027
+ mutations?: {
1028
+ delete?: {
1029
+ enabled?: boolean | undefined;
1030
+ roles?: string[] | undefined;
1031
+ } | undefined;
1032
+ create?: {
1033
+ enabled?: boolean | undefined;
1034
+ roles?: string[] | undefined;
1035
+ } | undefined;
1036
+ update?: {
1037
+ enabled?: boolean | undefined;
1038
+ roles?: string[] | undefined;
1039
+ } | undefined;
1040
+ } | undefined;
1041
+ }>>;
1042
+ }, "strip", z.ZodTypeAny, {
803
1043
  name: string;
804
1044
  id: string;
1045
+ featureRef: string;
805
1046
  model: {
806
1047
  fields: {
807
1048
  options: {
@@ -838,7 +1079,6 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
838
1079
  }[];
839
1080
  }[] | undefined;
840
1081
  };
841
- featureRef: string;
842
1082
  service: {
843
1083
  delete: {
844
1084
  enabled: boolean;
@@ -859,13 +1099,13 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
859
1099
  }[];
860
1100
  };
861
1101
  graphql?: {
862
- objectType: {
863
- enabled: boolean;
864
- fields: string[];
1102
+ objectType?: {
1103
+ enabled?: boolean | undefined;
1104
+ fields?: string[] | undefined;
865
1105
  localRelations?: string[] | undefined;
866
1106
  foreignRelations?: string[] | undefined;
867
- };
868
- queries: {
1107
+ } | undefined;
1108
+ queries?: {
869
1109
  get?: {
870
1110
  enabled?: boolean | undefined;
871
1111
  roles?: string[] | undefined;
@@ -874,25 +1114,26 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
874
1114
  enabled?: boolean | undefined;
875
1115
  roles?: string[] | undefined;
876
1116
  } | undefined;
877
- };
878
- mutations: {
879
- delete: {
1117
+ } | undefined;
1118
+ mutations?: {
1119
+ delete?: {
880
1120
  enabled?: boolean | undefined;
881
1121
  roles?: string[] | undefined;
882
- };
883
- create: {
1122
+ } | undefined;
1123
+ create?: {
884
1124
  enabled?: boolean | undefined;
885
1125
  roles?: string[] | undefined;
886
- };
887
- update: {
1126
+ } | undefined;
1127
+ update?: {
888
1128
  enabled?: boolean | undefined;
889
1129
  roles?: string[] | undefined;
890
- };
891
- };
1130
+ } | undefined;
1131
+ } | undefined;
892
1132
  } | undefined;
893
1133
  }, {
894
1134
  name: string;
895
1135
  id: string;
1136
+ featureRef: string;
896
1137
  model: {
897
1138
  fields: {
898
1139
  type: "string" | "boolean" | "float" | "date" | "uuid" | "int" | "dateTime" | "decimal" | "json" | "enum";
@@ -929,7 +1170,6 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
929
1170
  }[];
930
1171
  }[] | undefined;
931
1172
  };
932
- featureRef: string;
933
1173
  service?: {
934
1174
  delete?: {
935
1175
  enabled?: boolean | undefined;
@@ -944,15 +1184,15 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
944
1184
  fields?: string[] | undefined;
945
1185
  transformerNames?: string[] | undefined;
946
1186
  } | undefined;
947
- transformers?: {
948
- type: string;
949
- id: string;
950
- }[] | undefined;
1187
+ transformers?: z.objectInputType<{
1188
+ readonly id: z.ZodString;
1189
+ readonly type: z.ZodString;
1190
+ }, z.ZodTypeAny, "passthrough">[] | undefined;
951
1191
  } | undefined;
952
1192
  graphql?: {
953
1193
  objectType?: {
954
- fields: string[];
955
1194
  enabled?: boolean | undefined;
1195
+ fields?: string[] | undefined;
956
1196
  localRelations?: string[] | undefined;
957
1197
  foreignRelations?: string[] | undefined;
958
1198
  } | undefined;
@@ -982,21 +1222,22 @@ export declare const createModelBaseSchema: (options: import("#src/schema/creato
982
1222
  } | undefined;
983
1223
  } | undefined;
984
1224
  }>;
985
- export declare const createModelSchema: (options: import("#src/schema/creator/index.js").DefinitionSchemaCreatorOptions) => import("#src/references/index.js").ZodRef<z.ZodObject<{
1225
+ export declare const createModelSchema: (context: import("#src/schema/creator/index.js").DefinitionSchemaParserContext) => z.ZodEffects<z.ZodObject<{
986
1226
  id: z.ZodString;
987
1227
  name: z.ZodString;
988
- featureRef: import("#src/references/index.js").ZodRef<z.ZodString>;
1228
+ featureRef: z.ZodEffects<z.ZodString, string, string>;
989
1229
  model: z.ZodObject<{
990
- fields: z.ZodArray<z.ZodEffects<z.ZodEffects<import("#src/references/index.js").ZodRef<z.ZodObject<{
1230
+ fields: z.ZodArray<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodObject<{
1231
+ id: z.ZodString;
991
1232
  name: z.ZodString;
992
1233
  type: z.ZodEnum<["string", "uuid", "int", "boolean", "dateTime", "float", "decimal", "json", "date", "enum"]>;
993
1234
  isOptional: z.ZodDefault<z.ZodBoolean>;
994
- options: import("#src/references/index.js").ZodRef<z.ZodDefault<z.ZodEffects<z.ZodObject<{
1235
+ options: z.ZodEffects<z.ZodDefault<z.ZodEffects<z.ZodObject<{
995
1236
  default: z.ZodDefault<z.ZodString>;
996
1237
  genUuid: z.ZodOptional<z.ZodBoolean>;
997
1238
  updatedAt: z.ZodOptional<z.ZodBoolean>;
998
1239
  defaultToNow: z.ZodOptional<z.ZodBoolean>;
999
- enumRef: import("#src/references/index.js").ZodRef<z.ZodOptional<z.ZodString>>;
1240
+ enumRef: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
1000
1241
  defaultEnumValueRef: z.ZodOptional<z.ZodString>;
1001
1242
  }, "strip", z.ZodTypeAny, {
1002
1243
  default: string;
@@ -1026,9 +1267,21 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1026
1267
  defaultToNow?: boolean | undefined;
1027
1268
  enumRef?: string | undefined;
1028
1269
  defaultEnumValueRef?: string | undefined;
1029
- }>>>;
1030
- } & {
1031
- id: z.ZodType<string, z.ZodAnyDef, string>;
1270
+ }>>, {
1271
+ defaultEnumValueRef?: string | undefined;
1272
+ default: string;
1273
+ genUuid?: boolean | undefined;
1274
+ updatedAt?: boolean | undefined;
1275
+ defaultToNow?: boolean | undefined;
1276
+ enumRef?: string | undefined;
1277
+ }, {
1278
+ default?: string | undefined;
1279
+ genUuid?: boolean | undefined;
1280
+ updatedAt?: boolean | undefined;
1281
+ defaultToNow?: boolean | undefined;
1282
+ enumRef?: string | undefined;
1283
+ defaultEnumValueRef?: string | undefined;
1284
+ } | undefined>;
1032
1285
  }, "strip", z.ZodTypeAny, {
1033
1286
  options: {
1034
1287
  defaultEnumValueRef?: string | undefined;
@@ -1055,7 +1308,33 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1055
1308
  defaultEnumValueRef?: string | undefined;
1056
1309
  } | undefined;
1057
1310
  isOptional?: boolean | undefined;
1058
- }>>, {
1311
+ }>, {
1312
+ options: {
1313
+ defaultEnumValueRef?: string | undefined;
1314
+ default: string;
1315
+ genUuid?: boolean | undefined;
1316
+ updatedAt?: boolean | undefined;
1317
+ defaultToNow?: boolean | undefined;
1318
+ enumRef?: string | undefined;
1319
+ };
1320
+ type: "string" | "boolean" | "float" | "date" | "uuid" | "int" | "dateTime" | "decimal" | "json" | "enum";
1321
+ name: string;
1322
+ id: string;
1323
+ isOptional: boolean;
1324
+ }, {
1325
+ type: "string" | "boolean" | "float" | "date" | "uuid" | "int" | "dateTime" | "decimal" | "json" | "enum";
1326
+ name: string;
1327
+ id: string;
1328
+ options?: {
1329
+ default?: string | undefined;
1330
+ genUuid?: boolean | undefined;
1331
+ updatedAt?: boolean | undefined;
1332
+ defaultToNow?: boolean | undefined;
1333
+ enumRef?: string | undefined;
1334
+ defaultEnumValueRef?: string | undefined;
1335
+ } | undefined;
1336
+ isOptional?: boolean | undefined;
1337
+ }>, {
1059
1338
  options: {
1060
1339
  defaultEnumValueRef?: string | undefined;
1061
1340
  default: string;
@@ -1108,13 +1387,13 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1108
1387
  } | undefined;
1109
1388
  isOptional?: boolean | undefined;
1110
1389
  }>, "many">;
1111
- relations: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodObject<{
1390
+ relations: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodObject<{
1112
1391
  id: z.ZodString;
1113
1392
  foreignId: z.ZodDefault<z.ZodString>;
1114
1393
  name: z.ZodString;
1115
1394
  references: z.ZodArray<z.ZodObject<{
1116
- localRef: import("#src/references/index.js").ZodRef<z.ZodString>;
1117
- foreignRef: import("#src/references/index.js").ZodRef<z.ZodString>;
1395
+ localRef: z.ZodEffects<z.ZodString, string, string>;
1396
+ foreignRef: z.ZodEffects<z.ZodString, string, string>;
1118
1397
  }, "strip", z.ZodTypeAny, {
1119
1398
  localRef: string;
1120
1399
  foreignRef: string;
@@ -1150,18 +1429,41 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1150
1429
  onDelete?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
1151
1430
  foreignId?: string | undefined;
1152
1431
  onUpdate?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
1153
- }>>, "many">>;
1154
- primaryKeyFieldRefs: z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">;
1155
- uniqueConstraints: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodObject<{
1432
+ }>, {
1433
+ name: string;
1434
+ id: string;
1435
+ onDelete: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault";
1436
+ references: {
1437
+ localRef: string;
1438
+ foreignRef: string;
1439
+ }[];
1440
+ modelRef: string;
1441
+ foreignId: string;
1442
+ foreignRelationName: string;
1443
+ onUpdate: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault";
1444
+ }, {
1445
+ name: string;
1446
+ id: string;
1447
+ references: {
1448
+ localRef: string;
1449
+ foreignRef: string;
1450
+ }[];
1451
+ modelRef: string;
1452
+ foreignRelationName: string;
1453
+ onDelete?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
1454
+ foreignId?: string | undefined;
1455
+ onUpdate?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
1456
+ }>, "many">>;
1457
+ primaryKeyFieldRefs: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
1458
+ uniqueConstraints: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodObject<{
1459
+ id: z.ZodString;
1156
1460
  fields: z.ZodArray<z.ZodObject<{
1157
- fieldRef: import("#src/references/index.js").ZodRef<z.ZodString>;
1461
+ fieldRef: z.ZodEffects<z.ZodString, string, string>;
1158
1462
  }, "strip", z.ZodTypeAny, {
1159
1463
  fieldRef: string;
1160
1464
  }, {
1161
1465
  fieldRef: string;
1162
1466
  }>, "many">;
1163
- } & {
1164
- id: z.ZodType<string, z.ZodAnyDef, string>;
1165
1467
  }, "strip", z.ZodTypeAny, {
1166
1468
  id: string;
1167
1469
  fields: {
@@ -1172,7 +1474,17 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1172
1474
  fields: {
1173
1475
  fieldRef: string;
1174
1476
  }[];
1175
- }>>, "many">>;
1477
+ }>, {
1478
+ id: string;
1479
+ fields: {
1480
+ fieldRef: string;
1481
+ }[];
1482
+ }, {
1483
+ id: string;
1484
+ fields: {
1485
+ fieldRef: string;
1486
+ }[];
1487
+ }>, "many">>;
1176
1488
  }, "strip", z.ZodTypeAny, {
1177
1489
  fields: {
1178
1490
  options: {
@@ -1247,8 +1559,8 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1247
1559
  service: z.ZodDefault<z.ZodObject<{
1248
1560
  create: z.ZodDefault<z.ZodObject<{
1249
1561
  enabled: z.ZodDefault<z.ZodBoolean>;
1250
- fields: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
1251
- transformerNames: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
1562
+ fields: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
1563
+ transformerNames: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
1252
1564
  }, "strip", z.ZodTypeAny, {
1253
1565
  enabled: boolean;
1254
1566
  fields?: string[] | undefined;
@@ -1260,8 +1572,8 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1260
1572
  }>>;
1261
1573
  update: z.ZodDefault<z.ZodObject<{
1262
1574
  enabled: z.ZodDefault<z.ZodBoolean>;
1263
- fields: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
1264
- transformerNames: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
1575
+ fields: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
1576
+ transformerNames: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
1265
1577
  }, "strip", z.ZodTypeAny, {
1266
1578
  enabled: boolean;
1267
1579
  fields?: string[] | undefined;
@@ -1278,16 +1590,22 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1278
1590
  }, {
1279
1591
  enabled?: boolean | undefined;
1280
1592
  }>>;
1281
- transformers: z.ZodDefault<z.ZodArray<import("../../index.js").ZodWithPlugins<z.ZodObject<{
1282
- type: z.ZodString;
1283
- id: z.ZodString;
1284
- }, "strip", z.ZodTypeAny, {
1285
- type: string;
1286
- id: string;
1287
- }, {
1593
+ transformers: z.ZodDefault<z.ZodArray<z.ZodEffects<z.ZodObject<{
1594
+ readonly id: z.ZodString;
1595
+ readonly type: z.ZodString;
1596
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
1597
+ readonly id: z.ZodString;
1598
+ readonly type: z.ZodString;
1599
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
1600
+ readonly id: z.ZodString;
1601
+ readonly type: z.ZodString;
1602
+ }, z.ZodTypeAny, "passthrough">>, {
1288
1603
  type: string;
1289
1604
  id: string;
1290
- }>>, "many">>;
1605
+ }, z.objectInputType<{
1606
+ readonly id: z.ZodString;
1607
+ readonly type: z.ZodString;
1608
+ }, z.ZodTypeAny, "passthrough">>, "many">>;
1291
1609
  }, "strip", z.ZodTypeAny, {
1292
1610
  delete: {
1293
1611
  enabled: boolean;
@@ -1320,49 +1638,71 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1320
1638
  fields?: string[] | undefined;
1321
1639
  transformerNames?: string[] | undefined;
1322
1640
  } | undefined;
1323
- transformers?: {
1324
- type: string;
1325
- id: string;
1326
- }[] | undefined;
1641
+ transformers?: z.objectInputType<{
1642
+ readonly id: z.ZodString;
1643
+ readonly type: z.ZodString;
1644
+ }, z.ZodTypeAny, "passthrough">[] | undefined;
1327
1645
  }>>;
1328
1646
  graphql: z.ZodOptional<z.ZodObject<{
1329
- objectType: z.ZodDefault<z.ZodObject<{
1330
- enabled: z.ZodDefault<z.ZodBoolean>;
1331
- fields: z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">;
1332
- localRelations: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
1333
- foreignRelations: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
1647
+ objectType: z.ZodEffects<z.ZodOptional<z.ZodObject<{
1648
+ enabled: z.ZodEffects<z.ZodOptional<z.ZodBoolean>, boolean | undefined, boolean | undefined>;
1649
+ fields: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
1650
+ localRelations: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
1651
+ foreignRelations: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
1334
1652
  }, "strip", z.ZodTypeAny, {
1335
- enabled: boolean;
1336
- fields: string[];
1653
+ enabled?: boolean | undefined;
1654
+ fields?: string[] | undefined;
1337
1655
  localRelations?: string[] | undefined;
1338
1656
  foreignRelations?: string[] | undefined;
1339
1657
  }, {
1340
- fields: string[];
1341
1658
  enabled?: boolean | undefined;
1659
+ fields?: string[] | undefined;
1660
+ localRelations?: string[] | undefined;
1661
+ foreignRelations?: string[] | undefined;
1662
+ }>>, {
1663
+ enabled?: boolean | undefined;
1664
+ fields?: string[] | undefined;
1342
1665
  localRelations?: string[] | undefined;
1343
1666
  foreignRelations?: string[] | undefined;
1344
- }>>;
1345
- queries: z.ZodDefault<z.ZodObject<{
1346
- get: z.ZodOptional<z.ZodObject<{
1347
- enabled: z.ZodOptional<z.ZodBoolean>;
1348
- roles: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
1667
+ } | undefined, {
1668
+ enabled?: boolean | undefined;
1669
+ fields?: string[] | undefined;
1670
+ localRelations?: string[] | undefined;
1671
+ foreignRelations?: string[] | undefined;
1672
+ } | undefined>;
1673
+ queries: z.ZodEffects<z.ZodOptional<z.ZodObject<{
1674
+ get: z.ZodEffects<z.ZodOptional<z.ZodObject<{
1675
+ enabled: z.ZodEffects<z.ZodOptional<z.ZodBoolean>, boolean | undefined, boolean | undefined>;
1676
+ roles: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
1349
1677
  }, "strip", z.ZodTypeAny, {
1350
1678
  enabled?: boolean | undefined;
1351
1679
  roles?: string[] | undefined;
1352
1680
  }, {
1353
1681
  enabled?: boolean | undefined;
1354
1682
  roles?: string[] | undefined;
1355
- }>>;
1356
- list: z.ZodOptional<z.ZodObject<{
1357
- enabled: z.ZodOptional<z.ZodBoolean>;
1358
- roles: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
1683
+ }>>, {
1684
+ enabled?: boolean | undefined;
1685
+ roles?: string[] | undefined;
1686
+ } | undefined, {
1687
+ enabled?: boolean | undefined;
1688
+ roles?: string[] | undefined;
1689
+ } | undefined>;
1690
+ list: z.ZodEffects<z.ZodOptional<z.ZodObject<{
1691
+ enabled: z.ZodEffects<z.ZodOptional<z.ZodBoolean>, boolean | undefined, boolean | undefined>;
1692
+ roles: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
1359
1693
  }, "strip", z.ZodTypeAny, {
1360
1694
  enabled?: boolean | undefined;
1361
1695
  roles?: string[] | undefined;
1362
1696
  }, {
1363
1697
  enabled?: boolean | undefined;
1364
1698
  roles?: string[] | undefined;
1365
- }>>;
1699
+ }>>, {
1700
+ enabled?: boolean | undefined;
1701
+ roles?: string[] | undefined;
1702
+ } | undefined, {
1703
+ enabled?: boolean | undefined;
1704
+ roles?: string[] | undefined;
1705
+ } | undefined>;
1366
1706
  }, "strip", z.ZodTypeAny, {
1367
1707
  get?: {
1368
1708
  enabled?: boolean | undefined;
@@ -1381,73 +1721,135 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1381
1721
  enabled?: boolean | undefined;
1382
1722
  roles?: string[] | undefined;
1383
1723
  } | undefined;
1384
- }>>;
1385
- mutations: z.ZodDefault<z.ZodObject<{
1386
- create: z.ZodDefault<z.ZodObject<{
1387
- enabled: z.ZodOptional<z.ZodBoolean>;
1388
- roles: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
1389
- }, "strip", z.ZodTypeAny, {
1724
+ }>>, {
1725
+ get?: {
1390
1726
  enabled?: boolean | undefined;
1391
1727
  roles?: string[] | undefined;
1392
- }, {
1728
+ } | undefined;
1729
+ list?: {
1393
1730
  enabled?: boolean | undefined;
1394
1731
  roles?: string[] | undefined;
1395
- }>>;
1396
- update: z.ZodDefault<z.ZodObject<{
1397
- enabled: z.ZodOptional<z.ZodBoolean>;
1398
- roles: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
1399
- }, "strip", z.ZodTypeAny, {
1732
+ } | undefined;
1733
+ } | undefined, {
1734
+ get?: {
1400
1735
  enabled?: boolean | undefined;
1401
1736
  roles?: string[] | undefined;
1402
- }, {
1737
+ } | undefined;
1738
+ list?: {
1403
1739
  enabled?: boolean | undefined;
1404
1740
  roles?: string[] | undefined;
1405
- }>>;
1406
- delete: z.ZodDefault<z.ZodObject<{
1407
- enabled: z.ZodOptional<z.ZodBoolean>;
1408
- roles: z.ZodOptional<z.ZodArray<import("#src/references/index.js").ZodRef<z.ZodString>, "many">>;
1741
+ } | undefined;
1742
+ } | undefined>;
1743
+ mutations: z.ZodEffects<z.ZodOptional<z.ZodObject<{
1744
+ create: z.ZodEffects<z.ZodOptional<z.ZodObject<{
1745
+ enabled: z.ZodEffects<z.ZodOptional<z.ZodBoolean>, boolean | undefined, boolean | undefined>;
1746
+ roles: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
1409
1747
  }, "strip", z.ZodTypeAny, {
1410
1748
  enabled?: boolean | undefined;
1411
1749
  roles?: string[] | undefined;
1412
1750
  }, {
1413
1751
  enabled?: boolean | undefined;
1414
1752
  roles?: string[] | undefined;
1415
- }>>;
1416
- }, "strip", z.ZodTypeAny, {
1417
- delete: {
1753
+ }>>, {
1418
1754
  enabled?: boolean | undefined;
1419
1755
  roles?: string[] | undefined;
1420
- };
1421
- create: {
1756
+ } | undefined, {
1422
1757
  enabled?: boolean | undefined;
1423
1758
  roles?: string[] | undefined;
1424
- };
1425
- update: {
1759
+ } | undefined>;
1760
+ update: z.ZodEffects<z.ZodOptional<z.ZodObject<{
1761
+ enabled: z.ZodEffects<z.ZodOptional<z.ZodBoolean>, boolean | undefined, boolean | undefined>;
1762
+ roles: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
1763
+ }, "strip", z.ZodTypeAny, {
1426
1764
  enabled?: boolean | undefined;
1427
1765
  roles?: string[] | undefined;
1428
- };
1429
- }, {
1430
- delete?: {
1766
+ }, {
1431
1767
  enabled?: boolean | undefined;
1432
1768
  roles?: string[] | undefined;
1433
- } | undefined;
1434
- create?: {
1769
+ }>>, {
1435
1770
  enabled?: boolean | undefined;
1436
1771
  roles?: string[] | undefined;
1437
- } | undefined;
1438
- update?: {
1772
+ } | undefined, {
1439
1773
  enabled?: boolean | undefined;
1440
1774
  roles?: string[] | undefined;
1441
- } | undefined;
1442
- }>>;
1443
- }, "strip", z.ZodTypeAny, {
1444
- objectType: {
1445
- enabled: boolean;
1446
- fields: string[];
1775
+ } | undefined>;
1776
+ delete: z.ZodEffects<z.ZodOptional<z.ZodObject<{
1777
+ enabled: z.ZodEffects<z.ZodOptional<z.ZodBoolean>, boolean | undefined, boolean | undefined>;
1778
+ roles: z.ZodEffects<z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>, string[] | undefined, string[] | undefined>;
1779
+ }, "strip", z.ZodTypeAny, {
1780
+ enabled?: boolean | undefined;
1781
+ roles?: string[] | undefined;
1782
+ }, {
1783
+ enabled?: boolean | undefined;
1784
+ roles?: string[] | undefined;
1785
+ }>>, {
1786
+ enabled?: boolean | undefined;
1787
+ roles?: string[] | undefined;
1788
+ } | undefined, {
1789
+ enabled?: boolean | undefined;
1790
+ roles?: string[] | undefined;
1791
+ } | undefined>;
1792
+ }, "strip", z.ZodTypeAny, {
1793
+ delete?: {
1794
+ enabled?: boolean | undefined;
1795
+ roles?: string[] | undefined;
1796
+ } | undefined;
1797
+ create?: {
1798
+ enabled?: boolean | undefined;
1799
+ roles?: string[] | undefined;
1800
+ } | undefined;
1801
+ update?: {
1802
+ enabled?: boolean | undefined;
1803
+ roles?: string[] | undefined;
1804
+ } | undefined;
1805
+ }, {
1806
+ delete?: {
1807
+ enabled?: boolean | undefined;
1808
+ roles?: string[] | undefined;
1809
+ } | undefined;
1810
+ create?: {
1811
+ enabled?: boolean | undefined;
1812
+ roles?: string[] | undefined;
1813
+ } | undefined;
1814
+ update?: {
1815
+ enabled?: boolean | undefined;
1816
+ roles?: string[] | undefined;
1817
+ } | undefined;
1818
+ }>>, {
1819
+ delete?: {
1820
+ enabled?: boolean | undefined;
1821
+ roles?: string[] | undefined;
1822
+ } | undefined;
1823
+ create?: {
1824
+ enabled?: boolean | undefined;
1825
+ roles?: string[] | undefined;
1826
+ } | undefined;
1827
+ update?: {
1828
+ enabled?: boolean | undefined;
1829
+ roles?: string[] | undefined;
1830
+ } | undefined;
1831
+ } | undefined, {
1832
+ delete?: {
1833
+ enabled?: boolean | undefined;
1834
+ roles?: string[] | undefined;
1835
+ } | undefined;
1836
+ create?: {
1837
+ enabled?: boolean | undefined;
1838
+ roles?: string[] | undefined;
1839
+ } | undefined;
1840
+ update?: {
1841
+ enabled?: boolean | undefined;
1842
+ roles?: string[] | undefined;
1843
+ } | undefined;
1844
+ } | undefined>;
1845
+ }, "strip", z.ZodTypeAny, {
1846
+ objectType?: {
1847
+ enabled?: boolean | undefined;
1848
+ fields?: string[] | undefined;
1447
1849
  localRelations?: string[] | undefined;
1448
1850
  foreignRelations?: string[] | undefined;
1449
- };
1450
- queries: {
1851
+ } | undefined;
1852
+ queries?: {
1451
1853
  get?: {
1452
1854
  enabled?: boolean | undefined;
1453
1855
  roles?: string[] | undefined;
@@ -1456,25 +1858,25 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1456
1858
  enabled?: boolean | undefined;
1457
1859
  roles?: string[] | undefined;
1458
1860
  } | undefined;
1459
- };
1460
- mutations: {
1461
- delete: {
1861
+ } | undefined;
1862
+ mutations?: {
1863
+ delete?: {
1462
1864
  enabled?: boolean | undefined;
1463
1865
  roles?: string[] | undefined;
1464
- };
1465
- create: {
1866
+ } | undefined;
1867
+ create?: {
1466
1868
  enabled?: boolean | undefined;
1467
1869
  roles?: string[] | undefined;
1468
- };
1469
- update: {
1870
+ } | undefined;
1871
+ update?: {
1470
1872
  enabled?: boolean | undefined;
1471
1873
  roles?: string[] | undefined;
1472
- };
1473
- };
1874
+ } | undefined;
1875
+ } | undefined;
1474
1876
  }, {
1475
1877
  objectType?: {
1476
- fields: string[];
1477
1878
  enabled?: boolean | undefined;
1879
+ fields?: string[] | undefined;
1478
1880
  localRelations?: string[] | undefined;
1479
1881
  foreignRelations?: string[] | undefined;
1480
1882
  } | undefined;
@@ -1503,11 +1905,10 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1503
1905
  } | undefined;
1504
1906
  } | undefined;
1505
1907
  }>>;
1506
- } & {
1507
- id: z.ZodType<string, z.ZodAnyDef, string>;
1508
1908
  }, "strip", z.ZodTypeAny, {
1509
1909
  name: string;
1510
1910
  id: string;
1911
+ featureRef: string;
1511
1912
  model: {
1512
1913
  fields: {
1513
1914
  options: {
@@ -1544,7 +1945,6 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1544
1945
  }[];
1545
1946
  }[] | undefined;
1546
1947
  };
1547
- featureRef: string;
1548
1948
  service: {
1549
1949
  delete: {
1550
1950
  enabled: boolean;
@@ -1565,13 +1965,13 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1565
1965
  }[];
1566
1966
  };
1567
1967
  graphql?: {
1568
- objectType: {
1569
- enabled: boolean;
1570
- fields: string[];
1968
+ objectType?: {
1969
+ enabled?: boolean | undefined;
1970
+ fields?: string[] | undefined;
1571
1971
  localRelations?: string[] | undefined;
1572
1972
  foreignRelations?: string[] | undefined;
1573
- };
1574
- queries: {
1973
+ } | undefined;
1974
+ queries?: {
1575
1975
  get?: {
1576
1976
  enabled?: boolean | undefined;
1577
1977
  roles?: string[] | undefined;
@@ -1580,25 +1980,26 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1580
1980
  enabled?: boolean | undefined;
1581
1981
  roles?: string[] | undefined;
1582
1982
  } | undefined;
1583
- };
1584
- mutations: {
1585
- delete: {
1983
+ } | undefined;
1984
+ mutations?: {
1985
+ delete?: {
1586
1986
  enabled?: boolean | undefined;
1587
1987
  roles?: string[] | undefined;
1588
- };
1589
- create: {
1988
+ } | undefined;
1989
+ create?: {
1590
1990
  enabled?: boolean | undefined;
1591
1991
  roles?: string[] | undefined;
1592
- };
1593
- update: {
1992
+ } | undefined;
1993
+ update?: {
1594
1994
  enabled?: boolean | undefined;
1595
1995
  roles?: string[] | undefined;
1596
- };
1597
- };
1996
+ } | undefined;
1997
+ } | undefined;
1598
1998
  } | undefined;
1599
1999
  }, {
1600
2000
  name: string;
1601
2001
  id: string;
2002
+ featureRef: string;
1602
2003
  model: {
1603
2004
  fields: {
1604
2005
  type: "string" | "boolean" | "float" | "date" | "uuid" | "int" | "dateTime" | "decimal" | "json" | "enum";
@@ -1635,7 +2036,6 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1635
2036
  }[];
1636
2037
  }[] | undefined;
1637
2038
  };
1638
- featureRef: string;
1639
2039
  service?: {
1640
2040
  delete?: {
1641
2041
  enabled?: boolean | undefined;
@@ -1650,15 +2050,197 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1650
2050
  fields?: string[] | undefined;
1651
2051
  transformerNames?: string[] | undefined;
1652
2052
  } | undefined;
1653
- transformers?: {
2053
+ transformers?: z.objectInputType<{
2054
+ readonly id: z.ZodString;
2055
+ readonly type: z.ZodString;
2056
+ }, z.ZodTypeAny, "passthrough">[] | undefined;
2057
+ } | undefined;
2058
+ graphql?: {
2059
+ objectType?: {
2060
+ enabled?: boolean | undefined;
2061
+ fields?: string[] | undefined;
2062
+ localRelations?: string[] | undefined;
2063
+ foreignRelations?: string[] | undefined;
2064
+ } | undefined;
2065
+ queries?: {
2066
+ get?: {
2067
+ enabled?: boolean | undefined;
2068
+ roles?: string[] | undefined;
2069
+ } | undefined;
2070
+ list?: {
2071
+ enabled?: boolean | undefined;
2072
+ roles?: string[] | undefined;
2073
+ } | undefined;
2074
+ } | undefined;
2075
+ mutations?: {
2076
+ delete?: {
2077
+ enabled?: boolean | undefined;
2078
+ roles?: string[] | undefined;
2079
+ } | undefined;
2080
+ create?: {
2081
+ enabled?: boolean | undefined;
2082
+ roles?: string[] | undefined;
2083
+ } | undefined;
2084
+ update?: {
2085
+ enabled?: boolean | undefined;
2086
+ roles?: string[] | undefined;
2087
+ } | undefined;
2088
+ } | undefined;
2089
+ } | undefined;
2090
+ }>, {
2091
+ name: string;
2092
+ id: string;
2093
+ featureRef: string;
2094
+ model: {
2095
+ fields: {
2096
+ options: {
2097
+ defaultEnumValueRef?: string | undefined;
2098
+ default: string;
2099
+ genUuid?: boolean | undefined;
2100
+ updatedAt?: boolean | undefined;
2101
+ defaultToNow?: boolean | undefined;
2102
+ enumRef?: string | undefined;
2103
+ };
2104
+ type: "string" | "boolean" | "float" | "date" | "uuid" | "int" | "dateTime" | "decimal" | "json" | "enum";
2105
+ name: string;
2106
+ id: string;
2107
+ isOptional: boolean;
2108
+ }[];
2109
+ primaryKeyFieldRefs: string[];
2110
+ relations?: {
2111
+ name: string;
2112
+ id: string;
2113
+ onDelete: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault";
2114
+ references: {
2115
+ localRef: string;
2116
+ foreignRef: string;
2117
+ }[];
2118
+ modelRef: string;
2119
+ foreignId: string;
2120
+ foreignRelationName: string;
2121
+ onUpdate: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault";
2122
+ }[] | undefined;
2123
+ uniqueConstraints?: {
2124
+ id: string;
2125
+ fields: {
2126
+ fieldRef: string;
2127
+ }[];
2128
+ }[] | undefined;
2129
+ };
2130
+ service: {
2131
+ delete: {
2132
+ enabled: boolean;
2133
+ };
2134
+ create: {
2135
+ enabled: boolean;
2136
+ fields?: string[] | undefined;
2137
+ transformerNames?: string[] | undefined;
2138
+ };
2139
+ update: {
2140
+ enabled: boolean;
2141
+ fields?: string[] | undefined;
2142
+ transformerNames?: string[] | undefined;
2143
+ };
2144
+ transformers: {
1654
2145
  type: string;
1655
2146
  id: string;
2147
+ }[];
2148
+ };
2149
+ graphql?: {
2150
+ objectType?: {
2151
+ enabled?: boolean | undefined;
2152
+ fields?: string[] | undefined;
2153
+ localRelations?: string[] | undefined;
2154
+ foreignRelations?: string[] | undefined;
2155
+ } | undefined;
2156
+ queries?: {
2157
+ get?: {
2158
+ enabled?: boolean | undefined;
2159
+ roles?: string[] | undefined;
2160
+ } | undefined;
2161
+ list?: {
2162
+ enabled?: boolean | undefined;
2163
+ roles?: string[] | undefined;
2164
+ } | undefined;
2165
+ } | undefined;
2166
+ mutations?: {
2167
+ delete?: {
2168
+ enabled?: boolean | undefined;
2169
+ roles?: string[] | undefined;
2170
+ } | undefined;
2171
+ create?: {
2172
+ enabled?: boolean | undefined;
2173
+ roles?: string[] | undefined;
2174
+ } | undefined;
2175
+ update?: {
2176
+ enabled?: boolean | undefined;
2177
+ roles?: string[] | undefined;
2178
+ } | undefined;
2179
+ } | undefined;
2180
+ } | undefined;
2181
+ }, {
2182
+ name: string;
2183
+ id: string;
2184
+ featureRef: string;
2185
+ model: {
2186
+ fields: {
2187
+ type: "string" | "boolean" | "float" | "date" | "uuid" | "int" | "dateTime" | "decimal" | "json" | "enum";
2188
+ name: string;
2189
+ id: string;
2190
+ options?: {
2191
+ default?: string | undefined;
2192
+ genUuid?: boolean | undefined;
2193
+ updatedAt?: boolean | undefined;
2194
+ defaultToNow?: boolean | undefined;
2195
+ enumRef?: string | undefined;
2196
+ defaultEnumValueRef?: string | undefined;
2197
+ } | undefined;
2198
+ isOptional?: boolean | undefined;
2199
+ }[];
2200
+ primaryKeyFieldRefs: string[];
2201
+ relations?: {
2202
+ name: string;
2203
+ id: string;
2204
+ references: {
2205
+ localRef: string;
2206
+ foreignRef: string;
2207
+ }[];
2208
+ modelRef: string;
2209
+ foreignRelationName: string;
2210
+ onDelete?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
2211
+ foreignId?: string | undefined;
2212
+ onUpdate?: "Cascade" | "Restrict" | "NoAction" | "SetNull" | "SetDefault" | undefined;
2213
+ }[] | undefined;
2214
+ uniqueConstraints?: {
2215
+ id: string;
2216
+ fields: {
2217
+ fieldRef: string;
2218
+ }[];
1656
2219
  }[] | undefined;
2220
+ };
2221
+ service?: {
2222
+ delete?: {
2223
+ enabled?: boolean | undefined;
2224
+ } | undefined;
2225
+ create?: {
2226
+ enabled?: boolean | undefined;
2227
+ fields?: string[] | undefined;
2228
+ transformerNames?: string[] | undefined;
2229
+ } | undefined;
2230
+ update?: {
2231
+ enabled?: boolean | undefined;
2232
+ fields?: string[] | undefined;
2233
+ transformerNames?: string[] | undefined;
2234
+ } | undefined;
2235
+ transformers?: z.objectInputType<{
2236
+ readonly id: z.ZodString;
2237
+ readonly type: z.ZodString;
2238
+ }, z.ZodTypeAny, "passthrough">[] | undefined;
1657
2239
  } | undefined;
1658
2240
  graphql?: {
1659
2241
  objectType?: {
1660
- fields: string[];
1661
2242
  enabled?: boolean | undefined;
2243
+ fields?: string[] | undefined;
1662
2244
  localRelations?: string[] | undefined;
1663
2245
  foreignRelations?: string[] | undefined;
1664
2246
  } | undefined;
@@ -1687,7 +2269,7 @@ export declare const createModelSchema: (options: import("#src/schema/creator/in
1687
2269
  } | undefined;
1688
2270
  } | undefined;
1689
2271
  } | undefined;
1690
- }>>;
2272
+ }>;
1691
2273
  export type ModelConfig = def.InferOutput<typeof createModelSchema>;
1692
2274
  export type ModelConfigInput = def.InferInput<typeof createModelSchema>;
1693
2275
  //# sourceMappingURL=index.d.ts.map