feat(platform): 强化工作流节点 JSON schema 约束并修复 MCP inputSchema 生成

- 将 tasks 从 z.array(z.any()) 改为递归 discriminated union
- 覆盖 webhook/condition/every/stop/http/flow-detail/code/code-js2/ekuaibao-datalink-filter/create/data-convert/flow-create-task 及兜底 unknown
- 使用 Zod v4 内置 toJSONSchema() 替换不兼容的 zod-to-json-schema
- 移除 zod-to-json-schema 依赖
This commit is contained in:
gitea committed 2026-07-17 16:53:46 +08:00
1 parent 58c8a92d8e
commit e583a5faab
4 files changed
+242 -44

No files matched your search

+4 -3
View File
@@ -5,13 +5,14 @@
"type": "module",
"scripts": {
"dev": "bun run --watch src/server.ts",
"start": "bun run src/server.ts"
"start": "bun run src/server.ts",
"typecheck": "tsc --noEmit",
"export:workflow-schema": "bun run scripts/export-workflow-schema.ts"
},
"dependencies": {
"@modelcontextprotocol/sdk": "^1.29.0",
"ky": "^2.0.2",
"zod": "^4.4.3",
"zod-to-json-schema": "^3.25.2"
"zod": "^4.4.3"
},
"devDependencies": {
"@types/bun": "^1.3.14",