@loopstack/contracts 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +43 -0
- package/README.md +7 -0
- package/dist/enums/index.d.ts +3 -0
- package/dist/enums/index.d.ts.map +1 -0
- package/dist/enums/index.js +19 -0
- package/dist/enums/pipeline-state.d.ts +8 -0
- package/dist/enums/pipeline-state.d.ts.map +1 -0
- package/dist/enums/pipeline-state.js +12 -0
- package/dist/enums/user-type.enum.d.ts +4 -0
- package/dist/enums/user-type.enum.d.ts.map +1 -0
- package/dist/enums/user-type.enum.js +8 -0
- package/dist/enums/workflow-state.enum.d.ts +8 -0
- package/dist/enums/workflow-state.enum.d.ts.map +1 -0
- package/dist/enums/workflow-state.enum.js +12 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +19 -0
- package/dist/schemas/assignment.schema.d.ts +3 -0
- package/dist/schemas/assignment.schema.d.ts.map +1 -0
- package/dist/schemas/assignment.schema.js +20 -0
- package/dist/schemas/block.schema.d.ts +2 -0
- package/dist/schemas/block.schema.d.ts.map +1 -0
- package/dist/schemas/block.schema.js +5 -0
- package/dist/schemas/document.schema.d.ts +826 -0
- package/dist/schemas/document.schema.d.ts.map +1 -0
- package/dist/schemas/document.schema.js +91 -0
- package/dist/schemas/index.d.ts +16 -0
- package/dist/schemas/index.d.ts.map +1 -0
- package/dist/schemas/index.js +32 -0
- package/dist/schemas/json-schema.schema.d.ts +2 -0
- package/dist/schemas/json-schema.schema.d.ts.map +1 -0
- package/dist/schemas/json-schema.schema.js +58 -0
- package/dist/schemas/main.schema.d.ts +1126 -0
- package/dist/schemas/main.schema.d.ts.map +1 -0
- package/dist/schemas/main.schema.js +17 -0
- package/dist/schemas/pipeline.schema.d.ts +932 -0
- package/dist/schemas/pipeline.schema.d.ts.map +1 -0
- package/dist/schemas/pipeline.schema.js +57 -0
- package/dist/schemas/startup.schema.d.ts +637 -0
- package/dist/schemas/startup.schema.d.ts.map +1 -0
- package/dist/schemas/startup.schema.js +78 -0
- package/dist/schemas/template-expression.schema.d.ts +2 -0
- package/dist/schemas/template-expression.schema.d.ts.map +1 -0
- package/dist/schemas/template-expression.schema.js +5 -0
- package/dist/schemas/tool-call.schema.d.ts +17 -0
- package/dist/schemas/tool-call.schema.d.ts.map +1 -0
- package/dist/schemas/tool-call.schema.js +11 -0
- package/dist/schemas/tool-config.schema.d.ts +178 -0
- package/dist/schemas/tool-config.schema.d.ts.map +1 -0
- package/dist/schemas/tool-config.schema.js +11 -0
- package/dist/schemas/transition-payload.schema.d.ts +17 -0
- package/dist/schemas/transition-payload.schema.d.ts.map +1 -0
- package/dist/schemas/transition-payload.schema.js +10 -0
- package/dist/schemas/ui-form-element.schema.d.ts +89 -0
- package/dist/schemas/ui-form-element.schema.d.ts.map +1 -0
- package/dist/schemas/ui-form-element.schema.js +38 -0
- package/dist/schemas/ui-form.schema.d.ts +300 -0
- package/dist/schemas/ui-form.schema.d.ts.map +1 -0
- package/dist/schemas/ui-form.schema.js +39 -0
- package/dist/schemas/ui-properties-schema.d.ts +2 -0
- package/dist/schemas/ui-properties-schema.d.ts.map +1 -0
- package/dist/schemas/ui-properties-schema.js +9 -0
- package/dist/schemas/workflow-transition.schema.d.ts +48 -0
- package/dist/schemas/workflow-transition.schema.d.ts.map +1 -0
- package/dist/schemas/workflow-transition.schema.js +17 -0
- package/dist/schemas/workflow.schema.d.ts +439 -0
- package/dist/schemas/workflow.schema.d.ts.map +1 -0
- package/dist/schemas/workflow.schema.js +19 -0
- package/dist/schemas/workspace.schema.d.ts +14 -0
- package/dist/schemas/workspace.schema.d.ts.map +1 -0
- package/dist/schemas/workspace.schema.js +10 -0
- package/dist/types/index.d.ts +2 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +18 -0
- package/dist/types/interfaces/client-message.interface.d.ts +10 -0
- package/dist/types/interfaces/client-message.interface.d.ts.map +1 -0
- package/dist/types/interfaces/client-message.interface.js +2 -0
- package/dist/types/interfaces/document-item.interface.d.ts +25 -0
- package/dist/types/interfaces/document-item.interface.d.ts.map +1 -0
- package/dist/types/interfaces/document-item.interface.js +2 -0
- package/dist/types/interfaces/history-transition.interface.d.ts +5 -0
- package/dist/types/interfaces/history-transition.interface.d.ts.map +1 -0
- package/dist/types/interfaces/history-transition.interface.js +2 -0
- package/dist/types/interfaces/index.d.ts +9 -0
- package/dist/types/interfaces/index.d.ts.map +1 -0
- package/dist/types/interfaces/index.js +25 -0
- package/dist/types/interfaces/namespace-create.interface.d.ts +8 -0
- package/dist/types/interfaces/namespace-create.interface.d.ts.map +1 -0
- package/dist/types/interfaces/namespace-create.interface.js +2 -0
- package/dist/types/interfaces/pipeline-config.interface.d.ts +8 -0
- package/dist/types/interfaces/pipeline-config.interface.d.ts.map +1 -0
- package/dist/types/interfaces/pipeline-config.interface.js +2 -0
- package/dist/types/interfaces/transition-info.interface.d.ts +6 -0
- package/dist/types/interfaces/transition-info.interface.d.ts.map +1 -0
- package/dist/types/interfaces/transition-info.interface.js +2 -0
- package/dist/types/interfaces/transition-metadata.interface.d.ts +4 -0
- package/dist/types/interfaces/transition-metadata.interface.d.ts.map +1 -0
- package/dist/types/interfaces/transition-metadata.interface.js +2 -0
- package/dist/types/interfaces/transition-payload.interface.d.ts +2 -0
- package/dist/types/interfaces/transition-payload.interface.d.ts.map +1 -0
- package/dist/types/interfaces/transition-payload.interface.js +2 -0
- package/dist/types/interfaces/workflow.interface.d.ts +26 -0
- package/dist/types/interfaces/workflow.interface.d.ts.map +1 -0
- package/dist/types/interfaces/workflow.interface.js +2 -0
- package/dist/types/types/assignment.type.d.ts +4 -0
- package/dist/types/types/assignment.type.d.ts.map +1 -0
- package/dist/types/types/assignment.type.js +2 -0
- package/dist/types/types/document.type.d.ts +6 -0
- package/dist/types/types/document.type.d.ts.map +1 -0
- package/dist/types/types/document.type.js +2 -0
- package/dist/types/types/index.d.ts +17 -0
- package/dist/types/types/index.d.ts.map +1 -0
- package/dist/types/types/index.js +33 -0
- package/dist/types/types/json-schema-config.type.d.ts +4 -0
- package/dist/types/types/json-schema-config.type.d.ts.map +1 -0
- package/dist/types/types/json-schema-config.type.js +2 -0
- package/dist/types/types/main.type.d.ts +9 -0
- package/dist/types/types/main.type.d.ts.map +1 -0
- package/dist/types/types/main.type.js +2 -0
- package/dist/types/types/pipeline-state.type.d.ts +1 -0
- package/dist/types/types/pipeline-state.type.d.ts.map +1 -0
- package/dist/types/types/pipeline-state.type.js +2 -0
- package/dist/types/types/pipeline.type.d.ts +9 -0
- package/dist/types/types/pipeline.type.d.ts.map +1 -0
- package/dist/types/types/pipeline.type.js +2 -0
- package/dist/types/types/startup.type.d.ts +4 -0
- package/dist/types/types/startup.type.d.ts.map +1 -0
- package/dist/types/types/startup.type.js +2 -0
- package/dist/types/types/tool-call.type.d.ts +3 -0
- package/dist/types/types/tool-call.type.d.ts.map +1 -0
- package/dist/types/types/tool-call.type.js +2 -0
- package/dist/types/types/tool-config.type.d.ts +3 -0
- package/dist/types/types/tool-config.type.d.ts.map +1 -0
- package/dist/types/types/tool-config.type.js +2 -0
- package/dist/types/types/transition-payload.type.d.ts +3 -0
- package/dist/types/types/transition-payload.type.d.ts.map +1 -0
- package/dist/types/types/transition-payload.type.js +2 -0
- package/dist/types/types/ui-element.type.d.ts +3 -0
- package/dist/types/types/ui-element.type.d.ts.map +1 -0
- package/dist/types/types/ui-element.type.js +2 -0
- package/dist/types/types/ui-form.type.d.ts +6 -0
- package/dist/types/types/ui-form.type.d.ts.map +1 -0
- package/dist/types/types/ui-form.type.js +2 -0
- package/dist/types/types/ui-properties.type.d.ts +4 -0
- package/dist/types/types/ui-properties.type.d.ts.map +1 -0
- package/dist/types/types/ui-properties.type.js +2 -0
- package/dist/types/types/workflow-state.type.d.ts +1 -0
- package/dist/types/types/workflow-state.type.d.ts.map +1 -0
- package/dist/types/types/workflow-state.type.js +2 -0
- package/dist/types/types/workflow-transition.type.d.ts +3 -0
- package/dist/types/types/workflow-transition.type.d.ts.map +1 -0
- package/dist/types/types/workflow-transition.type.js +2 -0
- package/dist/types/types/workflow.type.d.ts +4 -0
- package/dist/types/types/workflow.type.d.ts.map +1 -0
- package/dist/types/types/workflow.type.js +2 -0
- package/dist/types/types/workspace.type.d.ts +3 -0
- package/dist/types/types/workspace.type.d.ts.map +1 -0
- package/dist/types/types/workspace.type.js +2 -0
- package/package.json +48 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"document.schema.d.ts","sourceRoot":"","sources":["../../src/schemas/document.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,eAAO,MAAM,cAAc,gMAWzB,CAAC;AAEH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAiC/B,CAAA;AAEF,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAoBzB,CAAA;AAEF,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAavC,CAAC;AAEH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAEhC,CAAC"}
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DocumentMessageSchema = exports.DocumentMessageContentSchema = exports.DocumentSchema = exports.DocumentConfigSchema = exports.MimeTypeSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const template_expression_schema_1 = require("./template-expression.schema");
|
|
6
|
+
const block_schema_1 = require("./block.schema");
|
|
7
|
+
const ui_form_schema_1 = require("./ui-form.schema");
|
|
8
|
+
exports.MimeTypeSchema = zod_1.z.enum([
|
|
9
|
+
"text/plain",
|
|
10
|
+
"text/html",
|
|
11
|
+
"text/css",
|
|
12
|
+
"text/xml",
|
|
13
|
+
"text/markdown",
|
|
14
|
+
"application/javascript",
|
|
15
|
+
"application/typescript",
|
|
16
|
+
"application/json",
|
|
17
|
+
"application/xml",
|
|
18
|
+
"application/yaml",
|
|
19
|
+
]);
|
|
20
|
+
exports.DocumentConfigSchema = block_schema_1.BlockSchema.extend({
|
|
21
|
+
type: zod_1.z.literal('document').default('document').optional(),
|
|
22
|
+
description: zod_1.z.string().optional(),
|
|
23
|
+
content: zod_1.z.any().optional(),
|
|
24
|
+
ui: ui_form_schema_1.UiFormSchema.optional(),
|
|
25
|
+
tags: zod_1.z.union([
|
|
26
|
+
template_expression_schema_1.TemplateExpression,
|
|
27
|
+
zod_1.z.array(zod_1.z.string()),
|
|
28
|
+
]).optional(),
|
|
29
|
+
meta: zod_1.z.object({
|
|
30
|
+
hidden: zod_1.z.union([
|
|
31
|
+
zod_1.z.boolean(),
|
|
32
|
+
template_expression_schema_1.TemplateExpression,
|
|
33
|
+
]).optional(),
|
|
34
|
+
mimeType: zod_1.z.union([
|
|
35
|
+
exports.MimeTypeSchema,
|
|
36
|
+
template_expression_schema_1.TemplateExpression,
|
|
37
|
+
]).optional(),
|
|
38
|
+
invalidate: zod_1.z.union([
|
|
39
|
+
zod_1.z.boolean(),
|
|
40
|
+
template_expression_schema_1.TemplateExpression,
|
|
41
|
+
]).optional(),
|
|
42
|
+
level: zod_1.z.union([
|
|
43
|
+
template_expression_schema_1.TemplateExpression,
|
|
44
|
+
zod_1.z.literal('debug'),
|
|
45
|
+
zod_1.z.literal('info'),
|
|
46
|
+
zod_1.z.literal('warning'),
|
|
47
|
+
zod_1.z.literal('error'),
|
|
48
|
+
]).optional(),
|
|
49
|
+
enableAtPlaces: zod_1.z.array(zod_1.z.string()).optional(),
|
|
50
|
+
hideAtPlaces: zod_1.z.array(zod_1.z.string()).optional(),
|
|
51
|
+
data: zod_1.z.any().optional(),
|
|
52
|
+
}).optional(),
|
|
53
|
+
});
|
|
54
|
+
exports.DocumentSchema = zod_1.z.object({
|
|
55
|
+
type: zod_1.z.literal('document').default('document').optional(),
|
|
56
|
+
description: zod_1.z.string().optional(),
|
|
57
|
+
content: zod_1.z.any().optional(),
|
|
58
|
+
ui: ui_form_schema_1.UiFormSchema.optional(),
|
|
59
|
+
tags: zod_1.z.array(zod_1.z.string()).optional(),
|
|
60
|
+
meta: zod_1.z.object({
|
|
61
|
+
hidden: zod_1.z.boolean().optional(),
|
|
62
|
+
mimeType: exports.MimeTypeSchema.optional(),
|
|
63
|
+
invalidate: zod_1.z.boolean().optional(),
|
|
64
|
+
level: zod_1.z.union([
|
|
65
|
+
zod_1.z.literal('debug'),
|
|
66
|
+
zod_1.z.literal('info'),
|
|
67
|
+
zod_1.z.literal('warning'),
|
|
68
|
+
zod_1.z.literal('error'),
|
|
69
|
+
]).optional(),
|
|
70
|
+
enableAtPlaces: zod_1.z.array(zod_1.z.string()).optional(),
|
|
71
|
+
hideAtPlaces: zod_1.z.array(zod_1.z.string()).optional(),
|
|
72
|
+
data: zod_1.z.any().optional(),
|
|
73
|
+
}).optional(),
|
|
74
|
+
});
|
|
75
|
+
exports.DocumentMessageContentSchema = zod_1.z.object({
|
|
76
|
+
role: zod_1.z.enum(["user", "assistant", "system"]),
|
|
77
|
+
content: zod_1.z.string().optional(),
|
|
78
|
+
tool_calls: zod_1.z.array(zod_1.z.object({
|
|
79
|
+
id: zod_1.z.string(),
|
|
80
|
+
type: zod_1.z.string(),
|
|
81
|
+
function: zod_1.z.object({
|
|
82
|
+
name: zod_1.z.string(),
|
|
83
|
+
arguments: zod_1.z.string().optional(),
|
|
84
|
+
})
|
|
85
|
+
})).optional(),
|
|
86
|
+
animation: zod_1.z.string().optional(),
|
|
87
|
+
icon: zod_1.z.string().optional(),
|
|
88
|
+
});
|
|
89
|
+
exports.DocumentMessageSchema = exports.DocumentSchema.extend({
|
|
90
|
+
content: exports.DocumentMessageContentSchema,
|
|
91
|
+
});
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export * from './document.schema.js';
|
|
2
|
+
export * from './json-schema.schema.js';
|
|
3
|
+
export * from './main.schema.js';
|
|
4
|
+
export * from './pipeline.schema.js';
|
|
5
|
+
export * from './tool-config.schema';
|
|
6
|
+
export * from './workflow-transition.schema.js';
|
|
7
|
+
export * from './workflow.schema.js';
|
|
8
|
+
export * from './workspace.schema.js';
|
|
9
|
+
export * from './template-expression.schema.js';
|
|
10
|
+
export * from './tool-call.schema.js';
|
|
11
|
+
export * from './ui-form.schema.js';
|
|
12
|
+
export * from './ui-form-element.schema.js';
|
|
13
|
+
export * from './ui-properties-schema.js';
|
|
14
|
+
export * from './startup.schema.js';
|
|
15
|
+
export * from './transition-payload.schema.js';
|
|
16
|
+
export * from './assignment.schema';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/schemas/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAA;AACpC,cAAc,yBAAyB,CAAA;AACvC,cAAc,kBAAkB,CAAA;AAChC,cAAc,sBAAsB,CAAA;AACpC,cAAc,sBAAsB,CAAA;AACpC,cAAc,iCAAiC,CAAA;AAC/C,cAAc,sBAAsB,CAAA;AACpC,cAAc,uBAAuB,CAAA;AACrC,cAAc,iCAAiC,CAAA;AAC/C,cAAc,uBAAuB,CAAA;AACrC,cAAc,qBAAqB,CAAA;AACnC,cAAc,6BAA6B,CAAA;AAC3C,cAAc,2BAA2B,CAAA;AACzC,cAAc,qBAAqB,CAAA;AACnC,cAAc,gCAAgC,CAAA;AAC9C,cAAc,qBAAqB,CAAA"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./document.schema.js"), exports);
|
|
18
|
+
__exportStar(require("./json-schema.schema.js"), exports);
|
|
19
|
+
__exportStar(require("./main.schema.js"), exports);
|
|
20
|
+
__exportStar(require("./pipeline.schema.js"), exports);
|
|
21
|
+
__exportStar(require("./tool-config.schema"), exports);
|
|
22
|
+
__exportStar(require("./workflow-transition.schema.js"), exports);
|
|
23
|
+
__exportStar(require("./workflow.schema.js"), exports);
|
|
24
|
+
__exportStar(require("./workspace.schema.js"), exports);
|
|
25
|
+
__exportStar(require("./template-expression.schema.js"), exports);
|
|
26
|
+
__exportStar(require("./tool-call.schema.js"), exports);
|
|
27
|
+
__exportStar(require("./ui-form.schema.js"), exports);
|
|
28
|
+
__exportStar(require("./ui-form-element.schema.js"), exports);
|
|
29
|
+
__exportStar(require("./ui-properties-schema.js"), exports);
|
|
30
|
+
__exportStar(require("./startup.schema.js"), exports);
|
|
31
|
+
__exportStar(require("./transition-payload.schema.js"), exports);
|
|
32
|
+
__exportStar(require("./assignment.schema"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"json-schema.schema.d.ts","sourceRoot":"","sources":["../../src/schemas/json-schema.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,cAAc,EAAE,CAAC,CAAC,OAAO,CAAC,GAAG,CAgEzC,CAAC"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.JSONSchemaType = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
exports.JSONSchemaType = zod_1.z.lazy(() => zod_1.z.object({
|
|
6
|
+
// Type validators
|
|
7
|
+
type: zod_1.z.union([
|
|
8
|
+
zod_1.z.enum(["string", "number", "integer", "boolean", "array", "object", "null", "any"]),
|
|
9
|
+
zod_1.z.array(zod_1.z.enum(["string", "number", "integer", "boolean", "array", "object", "null"]))
|
|
10
|
+
]).optional(),
|
|
11
|
+
// Core schema metadata
|
|
12
|
+
$id: zod_1.z.string().optional(),
|
|
13
|
+
$schema: zod_1.z.string().optional(),
|
|
14
|
+
title: zod_1.z.string().optional(),
|
|
15
|
+
description: zod_1.z.string().optional(),
|
|
16
|
+
default: zod_1.z.any().optional(),
|
|
17
|
+
// String validators
|
|
18
|
+
minLength: zod_1.z.number().int().optional(),
|
|
19
|
+
maxLength: zod_1.z.number().int().optional(),
|
|
20
|
+
pattern: zod_1.z.string().optional(),
|
|
21
|
+
format: zod_1.z.string().optional(),
|
|
22
|
+
// Number validators
|
|
23
|
+
multipleOf: zod_1.z.number().positive().optional(),
|
|
24
|
+
minimum: zod_1.z.number().optional(),
|
|
25
|
+
maximum: zod_1.z.number().optional(),
|
|
26
|
+
exclusiveMinimum: zod_1.z.union([zod_1.z.boolean(), zod_1.z.number()]).optional(),
|
|
27
|
+
exclusiveMaximum: zod_1.z.union([zod_1.z.boolean(), zod_1.z.number()]).optional(),
|
|
28
|
+
// Array validators
|
|
29
|
+
items: zod_1.z.union([exports.JSONSchemaType, zod_1.z.array(exports.JSONSchemaType)]).optional(),
|
|
30
|
+
additionalItems: zod_1.z.union([zod_1.z.boolean(), exports.JSONSchemaType]).optional(),
|
|
31
|
+
minItems: zod_1.z.number().int().nonnegative().optional(),
|
|
32
|
+
maxItems: zod_1.z.number().int().nonnegative().optional(),
|
|
33
|
+
uniqueItems: zod_1.z.boolean().optional(),
|
|
34
|
+
contains: exports.JSONSchemaType.optional(),
|
|
35
|
+
// Object validators
|
|
36
|
+
properties: zod_1.z.record(exports.JSONSchemaType).optional(),
|
|
37
|
+
patternProperties: zod_1.z.record(exports.JSONSchemaType).optional(),
|
|
38
|
+
additionalProperties: zod_1.z.union([zod_1.z.boolean(), exports.JSONSchemaType]).optional(),
|
|
39
|
+
required: zod_1.z.array(zod_1.z.string()).optional(),
|
|
40
|
+
propertyNames: exports.JSONSchemaType.optional(),
|
|
41
|
+
minProperties: zod_1.z.number().int().nonnegative().optional(),
|
|
42
|
+
maxProperties: zod_1.z.number().int().nonnegative().optional(),
|
|
43
|
+
// Logic validators
|
|
44
|
+
allOf: zod_1.z.array(exports.JSONSchemaType).optional(),
|
|
45
|
+
anyOf: zod_1.z.array(exports.JSONSchemaType).optional(),
|
|
46
|
+
oneOf: zod_1.z.array(exports.JSONSchemaType).optional(),
|
|
47
|
+
not: exports.JSONSchemaType.optional(),
|
|
48
|
+
// Conditional validators
|
|
49
|
+
if: exports.JSONSchemaType.optional(),
|
|
50
|
+
then: exports.JSONSchemaType.optional(),
|
|
51
|
+
else: exports.JSONSchemaType.optional(),
|
|
52
|
+
// Other validators
|
|
53
|
+
enum: zod_1.z.array(zod_1.z.any()).optional(),
|
|
54
|
+
const: zod_1.z.any().optional(),
|
|
55
|
+
// Schema composition
|
|
56
|
+
definitions: zod_1.z.record(exports.JSONSchemaType).optional(),
|
|
57
|
+
$ref: zod_1.z.string().optional(),
|
|
58
|
+
}));
|