-
Notifications
You must be signed in to change notification settings - Fork 32
Closed
Labels
Description
Objective
Add the "required": ["on"] field to the main workflow schema to enforce that all workflows must have a trigger.
Context
This addresses Issue #1 from discussion #2969. Currently, all three schemas (main_workflow_schema.json, included_file_schema.json, mcp_config_schema.json) have zero required fields defined, yet 100% of production workflows (67/67) use the on: field. The schema should reflect this implicit requirement.
Approach
- Open
pkg/parser/schemas/main_workflow_schema.json - Add a
"required"array at the root level with"on"as the first entry - Update the schema description to clarify that
on:is mandatory
Files to Modify
pkg/parser/schemas/main_workflow_schema.json- Add required fields array
Example Change
{
"$schema": "(redacted)#",
"title": "Agentic Workflow",
"type": "object",
"required": ["on"],
"properties": {
"on": {
...
}
}
}Acceptance Criteria
- Schema includes
"required": ["on"]at root level - Schema validation rejects workflows without
on:field - Existing workflows continue to pass validation
- Run
make buildandmake testsuccessfully
Related to [Schema Consistency] 🔍 Schema Consistency Check - Required Fields & Error Documentation Gap (Nov 2, 2025) #2969
AI generated by Plan Command for discussion #2969
Copilot