@openframe-org/criteria-set-protocol 2.0.4 → 2.0.5

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 (32) hide show
  1. package/dist/v1/schemas/certification.d.ts +80 -80
  2. package/dist/v1/schemas/certification.js +7 -6
  3. package/dist/v1/schemas/common.d.ts +144 -75
  4. package/dist/v1/schemas/common.js +15 -14
  5. package/dist/v1/schemas/criteria-tree.d.ts +4265 -2446
  6. package/dist/v1/schemas/criteria-tree.js +2 -1
  7. package/dist/v1/schemas/criterion.d.ts +786 -445
  8. package/dist/v1/schemas/criterion.js +4 -3
  9. package/dist/v1/schemas/data-map.d.ts +2 -2
  10. package/dist/v1/schemas/data-map.js +2 -1
  11. package/dist/v1/schemas/metadata.d.ts +28 -19
  12. package/dist/v1/schemas/metadata.js +7 -6
  13. package/dist/v1/schemas/request/matrix-body-schema.d.ts +7 -7
  14. package/dist/v1/schemas/request/matrix-body-schema.js +5 -4
  15. package/dist/v1/schemas/request/matrix-request-body-schema.d.ts +7 -7
  16. package/dist/v1/schemas/request/matrix-request-body-schema.js +5 -4
  17. package/dist/v1/schemas/request/tree-and-data-body-schema.d.ts +6 -6
  18. package/dist/v1/schemas/request/tree-and-data-body-schema.js +4 -3
  19. package/dist/v1/schemas/request/tree-and-data-request-body-schema.d.ts +6 -6
  20. package/dist/v1/schemas/request/tree-and-data-request-body-schema.js +4 -3
  21. package/dist/v1/schemas/response.d.ts +24 -15
  22. package/dist/v1/schemas/task-group.d.ts +584 -321
  23. package/dist/v1/schemas/task-group.js +5 -4
  24. package/dist/v1/schemas/task-item.d.ts +303 -193
  25. package/dist/v1/schemas/task-item.js +14 -13
  26. package/dist/v1/schemas/task.d.ts +395 -210
  27. package/dist/v1/schemas/task.js +4 -3
  28. package/dist/v1/schemas/theme.d.ts +1036 -603
  29. package/dist/v1/schemas/theme.js +4 -3
  30. package/dist/v1/schemas/utils.d.ts +6 -0
  31. package/dist/v1/schemas/utils.js +12 -0
  32. package/package.json +1 -1
@@ -4,12 +4,13 @@ exports.criterionSchema = exports.criterionOptionsSchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const task_group_1 = require("./task-group");
6
6
  const common_1 = require("./common");
7
+ const utils_1 = require("./utils");
7
8
  exports.criterionOptionsSchema = zod_1.z.object({
8
- hideCode: zod_1.z.boolean().optional(),
9
- hideFromHierarchy: zod_1.z.boolean().optional(),
9
+ hideCode: (0, utils_1.optional)(zod_1.z.boolean()),
10
+ hideFromHierarchy: (0, utils_1.optional)(zod_1.z.boolean()),
10
11
  });
11
12
  exports.criterionSchema = common_1.abstractElementSchema.extend({
12
13
  type: zod_1.z.literal("criterion"),
13
14
  items: zod_1.z.array(zod_1.z.lazy(() => task_group_1.taskGroupSchema)),
14
- options: exports.criterionOptionsSchema.optional(),
15
+ options: (0, utils_1.optional)(exports.criterionOptionsSchema),
15
16
  });
@@ -3,7 +3,7 @@ export declare const dataMapSchema: z.ZodObject<{
3
3
  version: z.ZodString;
4
4
  elements: z.ZodRecord<z.ZodString, z.ZodAny>;
5
5
  result: z.ZodAny;
6
- certifications: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
6
+ certifications: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<string[], z.ZodTypeDef, string[]>>>, string[] | undefined, string[] | null | undefined>, z.ZodOptional<z.ZodType<string[], z.ZodTypeDef, string[]>>>;
7
7
  }, "strip", z.ZodTypeAny, {
8
8
  elements: Record<string, any>;
9
9
  version: string;
@@ -13,5 +13,5 @@ export declare const dataMapSchema: z.ZodObject<{
13
13
  elements: Record<string, any>;
14
14
  version: string;
15
15
  result?: any;
16
- certifications?: string[] | undefined;
16
+ certifications?: string[] | null | undefined;
17
17
  }>;
@@ -2,9 +2,10 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.dataMapSchema = void 0;
4
4
  const zod_1 = require("zod");
5
+ const utils_1 = require("./utils");
5
6
  exports.dataMapSchema = zod_1.z.object({
6
7
  version: zod_1.z.string(),
7
8
  elements: zod_1.z.record(zod_1.z.string(), zod_1.z.any()),
8
9
  result: zod_1.z.any(),
9
- certifications: zod_1.z.array(zod_1.z.string()).optional(),
10
+ certifications: (0, utils_1.optional)(zod_1.z.array(zod_1.z.string())),
10
11
  });
@@ -1,14 +1,14 @@
1
1
  import { z } from "zod";
2
2
  export declare const schemaDefinitionSchema: z.ZodRecord<z.ZodString, z.ZodAny>;
3
3
  export declare const schemaDefinitionsSchema: z.ZodObject<{
4
- parameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
5
- result: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
4
+ parameters: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<Record<string, any>, z.ZodTypeDef, Record<string, any>>>>, Record<string, any> | undefined, Record<string, any> | null | undefined>, z.ZodOptional<z.ZodType<Record<string, any>, z.ZodTypeDef, Record<string, any>>>>;
5
+ result: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<Record<string, any>, z.ZodTypeDef, Record<string, any>>>>, Record<string, any> | undefined, Record<string, any> | null | undefined>, z.ZodOptional<z.ZodType<Record<string, any>, z.ZodTypeDef, Record<string, any>>>>;
6
6
  }, "strip", z.ZodTypeAny, {
7
7
  parameters?: Record<string, any> | undefined;
8
8
  result?: Record<string, any> | undefined;
9
9
  }, {
10
- parameters?: Record<string, any> | undefined;
11
- result?: Record<string, any> | undefined;
10
+ parameters?: Record<string, any> | null | undefined;
11
+ result?: Record<string, any> | null | undefined;
12
12
  }>;
13
13
  export declare const metadataSchema: z.ZodObject<{
14
14
  id: z.ZodString;
@@ -16,19 +16,28 @@ export declare const metadataSchema: z.ZodObject<{
16
16
  date: z.ZodDate;
17
17
  name: z.ZodString;
18
18
  description: z.ZodString;
19
- documentation: z.ZodOptional<z.ZodString>;
20
- locales: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
21
- defaultLocale: z.ZodOptional<z.ZodString>;
22
- schemas: z.ZodOptional<z.ZodObject<{
23
- parameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
24
- result: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
25
- }, "strip", z.ZodTypeAny, {
19
+ documentation: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<string, z.ZodTypeDef, string>>>, string | undefined, string | null | undefined>, z.ZodOptional<z.ZodType<string, z.ZodTypeDef, string>>>;
20
+ locales: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<string[], z.ZodTypeDef, string[]>>>, string[] | undefined, string[] | null | undefined>, z.ZodOptional<z.ZodType<string[], z.ZodTypeDef, string[]>>>;
21
+ defaultLocale: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<string, z.ZodTypeDef, string>>>, string | undefined, string | null | undefined>, z.ZodOptional<z.ZodType<string, z.ZodTypeDef, string>>>;
22
+ schemas: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<{
26
23
  parameters?: Record<string, any> | undefined;
27
24
  result?: Record<string, any> | undefined;
28
- }, {
25
+ }, z.ZodTypeDef, {
26
+ parameters?: Record<string, any> | null | undefined;
27
+ result?: Record<string, any> | null | undefined;
28
+ }>>>, {
29
29
  parameters?: Record<string, any> | undefined;
30
30
  result?: Record<string, any> | undefined;
31
- }>>;
31
+ } | undefined, {
32
+ parameters?: Record<string, any> | null | undefined;
33
+ result?: Record<string, any> | null | undefined;
34
+ } | null | undefined>, z.ZodOptional<z.ZodType<{
35
+ parameters?: Record<string, any> | undefined;
36
+ result?: Record<string, any> | undefined;
37
+ }, z.ZodTypeDef, {
38
+ parameters?: Record<string, any> | null | undefined;
39
+ result?: Record<string, any> | null | undefined;
40
+ }>>>;
32
41
  }, "strip", z.ZodTypeAny, {
33
42
  id: string;
34
43
  name: string;
@@ -48,11 +57,11 @@ export declare const metadataSchema: z.ZodObject<{
48
57
  description: string;
49
58
  date: Date;
50
59
  version: string;
51
- documentation?: string | undefined;
52
- locales?: string[] | undefined;
53
- defaultLocale?: string | undefined;
60
+ documentation?: string | null | undefined;
61
+ locales?: string[] | null | undefined;
62
+ defaultLocale?: string | null | undefined;
54
63
  schemas?: {
55
- parameters?: Record<string, any> | undefined;
56
- result?: Record<string, any> | undefined;
57
- } | undefined;
64
+ parameters?: Record<string, any> | null | undefined;
65
+ result?: Record<string, any> | null | undefined;
66
+ } | null | undefined;
58
67
  }>;
@@ -2,10 +2,11 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.metadataSchema = exports.schemaDefinitionsSchema = exports.schemaDefinitionSchema = void 0;
4
4
  const zod_1 = require("zod");
5
+ const utils_1 = require("./utils");
5
6
  exports.schemaDefinitionSchema = zod_1.z.record(zod_1.z.string(), zod_1.z.any());
6
7
  exports.schemaDefinitionsSchema = zod_1.z.object({
7
- parameters: exports.schemaDefinitionSchema.optional(),
8
- result: exports.schemaDefinitionSchema.optional(),
8
+ parameters: (0, utils_1.optional)(exports.schemaDefinitionSchema),
9
+ result: (0, utils_1.optional)(exports.schemaDefinitionSchema),
9
10
  });
10
11
  exports.metadataSchema = zod_1.z.object({
11
12
  id: zod_1.z.string(),
@@ -13,8 +14,8 @@ exports.metadataSchema = zod_1.z.object({
13
14
  date: zod_1.z.date(),
14
15
  name: zod_1.z.string(),
15
16
  description: zod_1.z.string(),
16
- documentation: zod_1.z.string().optional(),
17
- locales: zod_1.z.array(zod_1.z.string()).optional(),
18
- defaultLocale: zod_1.z.string().optional(),
19
- schemas: exports.schemaDefinitionsSchema.optional(),
17
+ documentation: (0, utils_1.optional)(zod_1.z.string()),
18
+ locales: (0, utils_1.optional)(zod_1.z.array(zod_1.z.string())),
19
+ defaultLocale: (0, utils_1.optional)(zod_1.z.string()),
20
+ schemas: (0, utils_1.optional)(exports.schemaDefinitionsSchema),
20
21
  });
@@ -3,18 +3,18 @@ import { z } from "zod";
3
3
  * Validates the request body for the matrix endpoints
4
4
  */
5
5
  export declare const matrixBodySchema: z.ZodOptional<z.ZodObject<{
6
- locale: z.ZodOptional<z.ZodString>;
7
- parameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
8
- values: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>, z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>, "many">]>>>;
9
- additional: z.ZodOptional<z.ZodAny>;
6
+ locale: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<string, z.ZodTypeDef, string>>>, string | undefined, string | null | undefined>, z.ZodOptional<z.ZodType<string, z.ZodTypeDef, string>>>;
7
+ parameters: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<Record<string, any>, z.ZodTypeDef, Record<string, any>>>>, Record<string, any> | undefined, Record<string, any> | null | undefined>, z.ZodOptional<z.ZodType<Record<string, any>, z.ZodTypeDef, Record<string, any>>>>;
8
+ values: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<Record<string, string | number | boolean | (string | number | boolean | null)[] | null>, z.ZodTypeDef, Record<string, string | number | boolean | (string | number | boolean | null)[] | null>>>>, Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | undefined, Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | null | undefined>, z.ZodOptional<z.ZodType<Record<string, string | number | boolean | (string | number | boolean | null)[] | null>, z.ZodTypeDef, Record<string, string | number | boolean | (string | number | boolean | null)[] | null>>>>;
9
+ additional: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<any, z.ZodTypeDef, any>>>, any, any>, z.ZodOptional<z.ZodType<any, z.ZodTypeDef, any>>>;
10
10
  }, "strip", z.ZodTypeAny, {
11
11
  values?: Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | undefined;
12
12
  locale?: string | undefined;
13
13
  parameters?: Record<string, any> | undefined;
14
14
  additional?: any;
15
15
  }, {
16
- values?: Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | undefined;
17
- locale?: string | undefined;
18
- parameters?: Record<string, any> | undefined;
16
+ values?: Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | null | undefined;
17
+ locale?: string | null | undefined;
18
+ parameters?: Record<string, any> | null | undefined;
19
19
  additional?: any;
20
20
  }>>;
@@ -3,14 +3,15 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.matrixBodySchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const task_item_1 = require("../task-item");
6
+ const utils_1 = require("../utils");
6
7
  /**
7
8
  * Validates the request body for the matrix endpoints
8
9
  */
9
10
  exports.matrixBodySchema = zod_1.z
10
11
  .object({
11
- locale: zod_1.z.string().optional(),
12
- parameters: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
13
- values: task_item_1.taskItemValueMapSchema.optional(),
14
- additional: zod_1.z.any().optional(),
12
+ locale: (0, utils_1.optional)(zod_1.z.string()),
13
+ parameters: (0, utils_1.optional)(zod_1.z.record(zod_1.z.string(), zod_1.z.any())),
14
+ values: (0, utils_1.optional)(task_item_1.taskItemValueMapSchema),
15
+ additional: (0, utils_1.optional)(zod_1.z.any()),
15
16
  })
16
17
  .optional();
@@ -3,18 +3,18 @@ import { z } from "zod";
3
3
  * Validates the request body for the matrix endpoints
4
4
  */
5
5
  export declare const matrixRequestBodySchema: z.ZodOptional<z.ZodObject<{
6
- locale: z.ZodOptional<z.ZodString>;
7
- parameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
8
- values: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>, z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>, "many">]>>>;
9
- additional: z.ZodOptional<z.ZodAny>;
6
+ locale: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<string, z.ZodTypeDef, string>>>, string | undefined, string | null | undefined>, z.ZodOptional<z.ZodType<string, z.ZodTypeDef, string>>>;
7
+ parameters: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<Record<string, any>, z.ZodTypeDef, Record<string, any>>>>, Record<string, any> | undefined, Record<string, any> | null | undefined>, z.ZodOptional<z.ZodType<Record<string, any>, z.ZodTypeDef, Record<string, any>>>>;
8
+ values: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<Record<string, string | number | boolean | (string | number | boolean | null)[] | null>, z.ZodTypeDef, Record<string, string | number | boolean | (string | number | boolean | null)[] | null>>>>, Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | undefined, Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | null | undefined>, z.ZodOptional<z.ZodType<Record<string, string | number | boolean | (string | number | boolean | null)[] | null>, z.ZodTypeDef, Record<string, string | number | boolean | (string | number | boolean | null)[] | null>>>>;
9
+ additional: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<any, z.ZodTypeDef, any>>>, any, any>, z.ZodOptional<z.ZodType<any, z.ZodTypeDef, any>>>;
10
10
  }, "strip", z.ZodTypeAny, {
11
11
  values?: Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | undefined;
12
12
  locale?: string | undefined;
13
13
  parameters?: Record<string, any> | undefined;
14
14
  additional?: any;
15
15
  }, {
16
- values?: Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | undefined;
17
- locale?: string | undefined;
18
- parameters?: Record<string, any> | undefined;
16
+ values?: Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | null | undefined;
17
+ locale?: string | null | undefined;
18
+ parameters?: Record<string, any> | null | undefined;
19
19
  additional?: any;
20
20
  }>>;
@@ -3,14 +3,15 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.matrixRequestBodySchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const task_item_1 = require("../task-item");
6
+ const utils_1 = require("../utils");
6
7
  /**
7
8
  * Validates the request body for the matrix endpoints
8
9
  */
9
10
  exports.matrixRequestBodySchema = zod_1.z
10
11
  .object({
11
- locale: zod_1.z.string().optional(),
12
- parameters: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
13
- values: task_item_1.taskItemValueMapSchema.optional(),
14
- additional: zod_1.z.any().optional(),
12
+ locale: (0, utils_1.optional)(zod_1.z.string()),
13
+ parameters: (0, utils_1.optional)(zod_1.z.record(zod_1.z.string(), zod_1.z.any())),
14
+ values: (0, utils_1.optional)(task_item_1.taskItemValueMapSchema),
15
+ additional: (0, utils_1.optional)(zod_1.z.any()),
15
16
  })
16
17
  .optional();
@@ -3,15 +3,15 @@ import { z } from "zod";
3
3
  * Validates the request body for the tree and data endpoints
4
4
  */
5
5
  export declare const treeAndDataBodySchema: z.ZodOptional<z.ZodObject<{
6
- locale: z.ZodOptional<z.ZodString>;
7
- parameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
8
- values: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>, z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>, "many">]>>>;
6
+ locale: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<string, z.ZodTypeDef, string>>>, string | undefined, string | null | undefined>, z.ZodOptional<z.ZodType<string, z.ZodTypeDef, string>>>;
7
+ parameters: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<Record<string, any>, z.ZodTypeDef, Record<string, any>>>>, Record<string, any> | undefined, Record<string, any> | null | undefined>, z.ZodOptional<z.ZodType<Record<string, any>, z.ZodTypeDef, Record<string, any>>>>;
8
+ values: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<Record<string, string | number | boolean | (string | number | boolean | null)[] | null>, z.ZodTypeDef, Record<string, string | number | boolean | (string | number | boolean | null)[] | null>>>>, Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | undefined, Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | null | undefined>, z.ZodOptional<z.ZodType<Record<string, string | number | boolean | (string | number | boolean | null)[] | null>, z.ZodTypeDef, Record<string, string | number | boolean | (string | number | boolean | null)[] | null>>>>;
9
9
  }, "strip", z.ZodTypeAny, {
10
10
  values?: Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | undefined;
11
11
  locale?: string | undefined;
12
12
  parameters?: Record<string, any> | undefined;
13
13
  }, {
14
- values?: Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | undefined;
15
- locale?: string | undefined;
16
- parameters?: Record<string, any> | undefined;
14
+ values?: Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | null | undefined;
15
+ locale?: string | null | undefined;
16
+ parameters?: Record<string, any> | null | undefined;
17
17
  }>>;
@@ -3,13 +3,14 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.treeAndDataBodySchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const task_item_1 = require("../task-item");
6
+ const utils_1 = require("../utils");
6
7
  /**
7
8
  * Validates the request body for the tree and data endpoints
8
9
  */
9
10
  exports.treeAndDataBodySchema = zod_1.z
10
11
  .object({
11
- locale: zod_1.z.string().optional(),
12
- parameters: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
13
- values: task_item_1.taskItemValueMapSchema.optional(),
12
+ locale: (0, utils_1.optional)(zod_1.z.string()),
13
+ parameters: (0, utils_1.optional)(zod_1.z.record(zod_1.z.string(), zod_1.z.any())),
14
+ values: (0, utils_1.optional)(task_item_1.taskItemValueMapSchema),
14
15
  })
15
16
  .optional();
@@ -3,15 +3,15 @@ import { z } from "zod";
3
3
  * Validates the request body for the tree and data endpoints
4
4
  */
5
5
  export declare const treeAndDataRequestBodySchema: z.ZodOptional<z.ZodObject<{
6
- locale: z.ZodOptional<z.ZodString>;
7
- parameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
8
- values: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>, z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>, "many">]>>>;
6
+ locale: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<string, z.ZodTypeDef, string>>>, string | undefined, string | null | undefined>, z.ZodOptional<z.ZodType<string, z.ZodTypeDef, string>>>;
7
+ parameters: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<Record<string, any>, z.ZodTypeDef, Record<string, any>>>>, Record<string, any> | undefined, Record<string, any> | null | undefined>, z.ZodOptional<z.ZodType<Record<string, any>, z.ZodTypeDef, Record<string, any>>>>;
8
+ values: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<Record<string, string | number | boolean | (string | number | boolean | null)[] | null>, z.ZodTypeDef, Record<string, string | number | boolean | (string | number | boolean | null)[] | null>>>>, Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | undefined, Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | null | undefined>, z.ZodOptional<z.ZodType<Record<string, string | number | boolean | (string | number | boolean | null)[] | null>, z.ZodTypeDef, Record<string, string | number | boolean | (string | number | boolean | null)[] | null>>>>;
9
9
  }, "strip", z.ZodTypeAny, {
10
10
  values?: Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | undefined;
11
11
  locale?: string | undefined;
12
12
  parameters?: Record<string, any> | undefined;
13
13
  }, {
14
- values?: Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | undefined;
15
- locale?: string | undefined;
16
- parameters?: Record<string, any> | undefined;
14
+ values?: Record<string, string | number | boolean | (string | number | boolean | null)[] | null> | null | undefined;
15
+ locale?: string | null | undefined;
16
+ parameters?: Record<string, any> | null | undefined;
17
17
  }>>;
@@ -3,13 +3,14 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.treeAndDataRequestBodySchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const task_item_1 = require("../task-item");
6
+ const utils_1 = require("../utils");
6
7
  /**
7
8
  * Validates the request body for the tree and data endpoints
8
9
  */
9
10
  exports.treeAndDataRequestBodySchema = zod_1.z
10
11
  .object({
11
- locale: zod_1.z.string().optional(),
12
- parameters: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
13
- values: task_item_1.taskItemValueMapSchema.optional(),
12
+ locale: (0, utils_1.optional)(zod_1.z.string()),
13
+ parameters: (0, utils_1.optional)(zod_1.z.record(zod_1.z.string(), zod_1.z.any())),
14
+ values: (0, utils_1.optional)(task_item_1.taskItemValueMapSchema),
14
15
  })
15
16
  .optional();
@@ -5,19 +5,28 @@ export declare const criteriaSetsAndVersionsSchema: z.ZodRecord<z.ZodString, z.Z
5
5
  date: z.ZodDate;
6
6
  name: z.ZodString;
7
7
  description: z.ZodString;
8
- documentation: z.ZodOptional<z.ZodString>;
9
- locales: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
10
- defaultLocale: z.ZodOptional<z.ZodString>;
11
- schemas: z.ZodOptional<z.ZodObject<{
12
- parameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
13
- result: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
14
- }, "strip", z.ZodTypeAny, {
8
+ documentation: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<string, z.ZodTypeDef, string>>>, string | undefined, string | null | undefined>, z.ZodOptional<z.ZodType<string, z.ZodTypeDef, string>>>;
9
+ locales: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<string[], z.ZodTypeDef, string[]>>>, string[] | undefined, string[] | null | undefined>, z.ZodOptional<z.ZodType<string[], z.ZodTypeDef, string[]>>>;
10
+ defaultLocale: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<string, z.ZodTypeDef, string>>>, string | undefined, string | null | undefined>, z.ZodOptional<z.ZodType<string, z.ZodTypeDef, string>>>;
11
+ schemas: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodType<{
15
12
  parameters?: Record<string, any> | undefined;
16
13
  result?: Record<string, any> | undefined;
17
- }, {
14
+ }, z.ZodTypeDef, {
15
+ parameters?: Record<string, any> | null | undefined;
16
+ result?: Record<string, any> | null | undefined;
17
+ }>>>, {
18
18
  parameters?: Record<string, any> | undefined;
19
19
  result?: Record<string, any> | undefined;
20
- }>>;
20
+ } | undefined, {
21
+ parameters?: Record<string, any> | null | undefined;
22
+ result?: Record<string, any> | null | undefined;
23
+ } | null | undefined>, z.ZodOptional<z.ZodType<{
24
+ parameters?: Record<string, any> | undefined;
25
+ result?: Record<string, any> | undefined;
26
+ }, z.ZodTypeDef, {
27
+ parameters?: Record<string, any> | null | undefined;
28
+ result?: Record<string, any> | null | undefined;
29
+ }>>>;
21
30
  }, "strip", z.ZodTypeAny, {
22
31
  id: string;
23
32
  name: string;
@@ -37,13 +46,13 @@ export declare const criteriaSetsAndVersionsSchema: z.ZodRecord<z.ZodString, z.Z
37
46
  description: string;
38
47
  date: Date;
39
48
  version: string;
40
- documentation?: string | undefined;
41
- locales?: string[] | undefined;
42
- defaultLocale?: string | undefined;
49
+ documentation?: string | null | undefined;
50
+ locales?: string[] | null | undefined;
51
+ defaultLocale?: string | null | undefined;
43
52
  schemas?: {
44
- parameters?: Record<string, any> | undefined;
45
- result?: Record<string, any> | undefined;
46
- } | undefined;
53
+ parameters?: Record<string, any> | null | undefined;
54
+ result?: Record<string, any> | null | undefined;
55
+ } | null | undefined;
47
56
  }>, "many">>;
48
57
  export declare const streamMatrixResponseSchema: z.ZodObject<{
49
58
  filename: z.ZodString;