Flows YAML — Zod → JSON Schema build pipeline #1069
Labels
No labels
area:agents
area:dashboard
area:database
area:design
area:design-review
area:flows
area:infra
area:meta
area:security
area:sessions
area:webhook
area:workdir
security
type:bug
type:chore
type:meta
type:user-story
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
charles/claude-hooks#1069
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
User story
As the editor, I need a single JSON Schema that drives both server validation and Monaco autocomplete, so that adding a new op or trigger automatically extends what the UI offers.
Acceptance criteria
Source of truth
apps/server/src/domain/flows-yaml/schema.tscoverFlowFile,TriggerKind, every op'sargsSchema(discriminated onuses), and built-in expression types..describe()string used as JSON Schemadescription(and Monaco hover text).Generation
apps/server/scripts/generate-flow-schema.tsrunszod-to-json-schema.apps/web/public/schemas/flows.schema.json(committed) andapps/server/src/domain/flows-yaml/flows.schema.json.format: "flow-expression"on every expression-string field for downstream linting.CI integration
just qaregenerates the schema and fails if the committed file is out of date.Server consumption
POST /flowsandPUT /flows/:namere-parse with Zod (authoritative); JSON Schema mismatch is a 422.Tests
*.ymldefault validates against the generated schema.Out of scope
flow-expressiontag.References
docs/specs/flows-yaml.md§10.3.2.