@cxtms/cx-schema 1.9.7 → 1.9.8

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cxtms/cx-schema",
3
- "version": "1.9.7",
3
+ "version": "1.9.8",
4
4
  "description": "Schema validation package for CargoXplorer YAML modules",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -68,13 +68,52 @@
68
68
  "properties": {
69
69
  "foreach": {
70
70
  "type": "string",
71
- "description": "Collection to iterate"
71
+ "description": "Expression evaluating to array collection to iterate (e.g., 'stepName.result?.items?')"
72
+ },
73
+ "item": {
74
+ "type": "string",
75
+ "description": "Variable name for current item (default: 'item')"
76
+ },
77
+ "index": {
78
+ "type": "string",
79
+ "description": "Variable name for current index"
80
+ },
81
+ "conditions": {
82
+ "oneOf": [
83
+ {
84
+ "type": "string",
85
+ "description": "Single NCalc filter expression (e.g., '[item.isActive] = true')"
86
+ },
87
+ {
88
+ "type": "array",
89
+ "items": {
90
+ "oneOf": [
91
+ { "type": "string" },
92
+ {
93
+ "type": "object",
94
+ "properties": {
95
+ "expression": { "type": "string" }
96
+ }
97
+ }
98
+ ]
99
+ },
100
+ "description": "Array of condition expressions (all must be true)"
101
+ }
102
+ ],
103
+ "description": "Filter conditions — only items matching all conditions are included"
104
+ },
105
+ "continueOnError": {
106
+ "type": "boolean",
107
+ "description": "Skip items that cause errors and continue"
72
108
  },
73
109
  "mapping": {
74
110
  "type": "object",
111
+ "description": "Object defining the output shape — each key maps to a template expression or nested value directive",
75
112
  "additionalProperties": true
76
113
  }
77
- }
114
+ },
115
+ "required": ["foreach", "mapping"],
116
+ "additionalProperties": false
78
117
  },
79
118
  {
80
119
  "type": "object",