@toolproof-npm/schema 0.1.44 → 0.1.46

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.
Files changed (28) hide show
  1. package/dist/_lib/test.js +38 -31
  2. package/dist/genesis/generated/resources/Genesis.json +742 -452
  3. package/dist/genesis/generated/schemas/Genesis.json +441 -166
  4. package/dist/genesis/generated/schemas/Job.json +26 -26
  5. package/dist/genesis/generated/schemas/ResourceFormat.json +9 -9
  6. package/dist/genesis/generated/schemas/ResourceType.json +317 -42
  7. package/dist/genesis/generated/schemas/StatefulStrategy.json +76 -76
  8. package/dist/genesis/generated/schemas/StatelessStrategy.json +40 -40
  9. package/dist/{_lib → genesis/generated}/types/Resource_Job.d.ts +16 -16
  10. package/dist/{_lib → genesis/generated}/types/Resource_ResourceFormat.d.ts +10 -10
  11. package/dist/{_lib → genesis/generated}/types/Resource_ResourceType.d.ts +15 -15
  12. package/dist/{_lib → genesis/generated}/types/Resource_StatelessStrategy.d.ts +16 -16
  13. package/dist/{_lib → genesis/generated}/types/types.d.ts +289 -261
  14. package/dist/genesis/resourceTypes/Genesis.json +530 -250
  15. package/dist/index.d.ts +6 -6
  16. package/dist/index.js +2 -2
  17. package/dist/scripts/_lib/config.js +2 -2
  18. package/dist/scripts/brandFactories.d.ts +37 -23
  19. package/dist/scripts/brandFactories.js +26 -29
  20. package/dist/scripts/extractSchemas.js +1 -1
  21. package/dist/scripts/generateResourceEnvelopes.js +6 -6
  22. package/dist/scripts/generateTypes.js +38 -26
  23. package/package.json +1 -1
  24. /package/dist/{_lib → genesis/generated}/types/Resource_Job.js +0 -0
  25. /package/dist/{_lib → genesis/generated}/types/Resource_ResourceFormat.js +0 -0
  26. /package/dist/{_lib → genesis/generated}/types/Resource_ResourceType.js +0 -0
  27. /package/dist/{_lib → genesis/generated}/types/Resource_StatelessStrategy.js +0 -0
  28. /package/dist/{_lib → genesis/generated}/types/types.js +0 -0
@@ -15,13 +15,13 @@
15
15
  "cases": {
16
16
  "type": "array",
17
17
  "items": {
18
- "$ref": "#/$defs/ConditionalWrapper"
18
+ "$ref": "#/$defs/Conditional"
19
19
  },
20
20
  "minItems": 1,
21
21
  "uniqueItems": true
22
22
  },
23
23
  "identity": {
24
- "$ref": "#/$defs/BranchStepId"
24
+ "$ref": "#/$defs/BranchStepIdentity"
25
25
  },
26
26
  "kind": {
27
27
  "const": "branch"
@@ -36,13 +36,13 @@
36
36
  ],
37
37
  "$anchor": "BranchStep"
38
38
  },
39
- "BranchStepId": {
39
+ "BranchStepIdentity": {
40
40
  "$schema": "https://json-schema.org/draft/2020-12/schema",
41
41
  "type": "string",
42
- "$anchor": "BranchStepId",
42
+ "$anchor": "BranchStepIdentity",
43
43
  "pattern": "^BRANCHSTEP-.+$"
44
44
  },
45
- "ConditionalWrapper": {
45
+ "Conditional": {
46
46
  "$schema": "https://json-schema.org/draft/2020-12/schema",
47
47
  "type": "object",
48
48
  "properties": {
@@ -58,39 +58,39 @@
58
58
  "what"
59
59
  ],
60
60
  "unevaluatedProperties": false,
61
- "$anchor": "ConditionalWrapper"
61
+ "$anchor": "Conditional"
62
62
  },
63
63
  "CreationContext": {
64
64
  "$schema": "https://json-schema.org/draft/2020-12/schema",
65
65
  "type": "object",
66
66
  "properties": {
67
- "creationContext": {
68
- "$ref": "#/$defs/CreationContextValue"
67
+ "executionRef": {
68
+ "$ref": "#/$defs/ExecutionIdentity"
69
+ },
70
+ "resourceRoleRef": {
71
+ "$ref": "#/$defs/ResourceRoleIdentity"
69
72
  }
70
73
  },
71
74
  "required": [
72
- "creationContext"
75
+ "resourceRoleRef",
76
+ "executionRef"
73
77
  ],
74
78
  "$anchor": "CreationContext"
75
79
  },
76
- "CreationContextValue": {
80
+ "CreationContextWrapper": {
77
81
  "$schema": "https://json-schema.org/draft/2020-12/schema",
78
82
  "type": "object",
79
83
  "properties": {
80
- "executionId": {
81
- "$ref": "#/$defs/ExecutionId"
82
- },
83
- "resourceRoleId": {
84
- "$ref": "#/$defs/ResourceRoleId"
84
+ "creationContext": {
85
+ "$ref": "#/$defs/CreationContext"
85
86
  }
86
87
  },
87
88
  "required": [
88
- "resourceRoleId",
89
- "executionId"
89
+ "creationContext"
90
90
  ],
91
- "$anchor": "CreationContextValue"
91
+ "$anchor": "CreationContextWrapper"
92
92
  },
93
- "Description": {
93
+ "Described": {
94
94
  "$schema": "https://json-schema.org/draft/2020-12/schema",
95
95
  "type": "object",
96
96
  "properties": {
@@ -104,17 +104,17 @@
104
104
  "required": [
105
105
  "description"
106
106
  ],
107
- "$anchor": "Description"
107
+ "$anchor": "Described"
108
108
  },
109
109
  "Documented": {
110
110
  "$schema": "https://json-schema.org/draft/2020-12/schema",
111
111
  "type": "object",
112
112
  "allOf": [
113
113
  {
114
- "$ref": "#/$defs/Name"
114
+ "$ref": "#/$defs/Named"
115
115
  },
116
116
  {
117
- "$ref": "#/$defs/Description"
117
+ "$ref": "#/$defs/Described"
118
118
  }
119
119
  ],
120
120
  "$anchor": "Documented"
@@ -127,44 +127,31 @@
127
127
  "type": "object",
128
128
  "properties": {
129
129
  "identity": {
130
- "$ref": "#/$defs/ExecutionId"
130
+ "$ref": "#/$defs/ExecutionIdentity"
131
131
  },
132
- "jobId": {
133
- "$ref": "#/$defs/JobId"
132
+ "jobRef": {
133
+ "$ref": "#/$defs/JobIdentity"
134
134
  }
135
135
  },
136
136
  "required": [
137
137
  "identity",
138
- "jobId"
138
+ "jobRef"
139
139
  ]
140
140
  },
141
141
  {
142
142
  "$comment": "This will be overlayed at runtime to specify roleBindings corresponding to the roles of the underlying job.",
143
- "$ref": "#/$defs/RoleBindingsOuter"
143
+ "$ref": "#/$defs/RoleBindingsWrapper"
144
144
  }
145
145
  ],
146
146
  "$anchor": "Execution"
147
147
  },
148
- "ExecutionId": {
148
+ "ExecutionIdentity": {
149
149
  "$schema": "https://json-schema.org/draft/2020-12/schema",
150
150
  "type": "string",
151
- "$anchor": "ExecutionId",
151
+ "$anchor": "ExecutionIdentity",
152
152
  "pattern": "^EXECUTION-.+$"
153
153
  },
154
154
  "ExtractionSchema": {
155
- "$schema": "https://json-schema.org/draft/2020-12/schema",
156
- "type": "object",
157
- "properties": {
158
- "extractionSchema": {
159
- "$ref": "#/$defs/ExtractionSchemaValue"
160
- }
161
- },
162
- "required": [
163
- "extractionSchema"
164
- ],
165
- "$anchor": "ExtractionSchema"
166
- },
167
- "ExtractionSchemaValue": {
168
155
  "$schema": "https://json-schema.org/draft/2020-12/schema",
169
156
  "type": "object",
170
157
  "allOf": [
@@ -199,14 +186,28 @@
199
186
  },
200
187
  {
201
188
  "if": {
202
- "properties": {
203
- "properties": {
204
- "type": "object",
189
+ "anyOf": [
190
+ {
205
191
  "properties": {
206
- "merit": {}
192
+ "properties": {
193
+ "type": "object",
194
+ "properties": {
195
+ "merit": {}
196
+ }
197
+ }
198
+ }
199
+ },
200
+ {
201
+ "properties": {
202
+ "required": {
203
+ "type": "array",
204
+ "contains": {
205
+ "const": "merit"
206
+ }
207
+ }
207
208
  }
208
209
  }
209
- }
210
+ ]
210
211
  },
211
212
  "then": {
212
213
  "$ref": "#/$defs/MeritProp"
@@ -271,7 +272,20 @@
271
272
  "type"
272
273
  ],
273
274
  "unevaluatedProperties": false,
274
- "$anchor": "ExtractionSchemaValue"
275
+ "$anchor": "ExtractionSchema"
276
+ },
277
+ "ExtractionSchemaWrapper": {
278
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
279
+ "type": "object",
280
+ "properties": {
281
+ "extractionSchema": {
282
+ "$ref": "#/$defs/ExtractionSchema"
283
+ }
284
+ },
285
+ "required": [
286
+ "extractionSchema"
287
+ ],
288
+ "$anchor": "ExtractionSchemaWrapper"
275
289
  },
276
290
  "ForStep": {
277
291
  "$schema": "https://json-schema.org/draft/2020-12/schema",
@@ -284,10 +298,10 @@
284
298
  "type": "object",
285
299
  "properties": {
286
300
  "case": {
287
- "$ref": "#/$defs/ConditionalWrapper"
301
+ "$ref": "#/$defs/Conditional"
288
302
  },
289
303
  "identity": {
290
- "$ref": "#/$defs/ForStepId"
304
+ "$ref": "#/$defs/ForStepIdentity"
291
305
  },
292
306
  "kind": {
293
307
  "const": "for"
@@ -302,30 +316,12 @@
302
316
  ],
303
317
  "$anchor": "ForStep"
304
318
  },
305
- "ForStepId": {
319
+ "ForStepIdentity": {
306
320
  "$schema": "https://json-schema.org/draft/2020-12/schema",
307
321
  "type": "string",
308
- "$anchor": "ForStepId",
322
+ "$anchor": "ForStepIdentity",
309
323
  "pattern": "^FORSTEP-.+$"
310
324
  },
311
- "IdSchemaValue": {
312
- "$schema": "https://json-schema.org/draft/2020-12/schema",
313
- "type": "object",
314
- "properties": {
315
- "type": {
316
- "enum": [
317
- "string",
318
- "number",
319
- "integer",
320
- "boolean"
321
- ]
322
- }
323
- },
324
- "required": [
325
- "type"
326
- ],
327
- "$anchor": "IdSchemaValue"
328
- },
329
325
  "IdentityProp": {
330
326
  "$schema": "https://json-schema.org/draft/2020-12/schema",
331
327
  "type": "object",
@@ -333,22 +329,22 @@
333
329
  "$defs": {
334
330
  "type": "object",
335
331
  "additionalProperties": true,
336
- "$comment": "Ajv-specific: patternRequired enforces at least one Id-like key in this $defs block when identity is present.",
332
+ "$comment": "Ajv-specific: patternRequired enforces at least one Identity-like key in this $defs block when identity is present.",
337
333
  "minProperties": 1,
338
334
  "patternProperties": {
339
- "^[A-Za-z][A-Za-z0-9._-]*Id$": {
340
- "$ref": "#/$defs/IdSchemaValue"
335
+ "^[A-Za-z][A-Za-z0-9._-]*Identity$": {
336
+ "$ref": "#/$defs/IdentitySchema"
341
337
  }
342
338
  },
343
339
  "patternRequired": [
344
- "^[A-Za-z][A-Za-z0-9._-]*Id$"
340
+ "^[A-Za-z][A-Za-z0-9._-]*Identity$"
345
341
  ]
346
342
  },
347
343
  "properties": {
348
344
  "type": "object",
349
345
  "properties": {
350
346
  "identity": {
351
- "$ref": "#/$defs/IdentityValue"
347
+ "$ref": "#/$defs/IdentitySchemaRef"
352
348
  }
353
349
  },
354
350
  "required": [
@@ -373,21 +369,169 @@
373
369
  ],
374
370
  "$anchor": "IdentityProp"
375
371
  },
376
- "IdentityValue": {
372
+ "IdentitySchema": {
373
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
374
+ "type": "object",
375
+ "allOf": [
376
+ {
377
+ "if": {
378
+ "properties": {
379
+ "type": {
380
+ "const": "string"
381
+ }
382
+ }
383
+ },
384
+ "then": {
385
+ "properties": {
386
+ "enum": {
387
+ "items": {
388
+ "type": "string"
389
+ }
390
+ }
391
+ }
392
+ },
393
+ "else": {
394
+ "not": {
395
+ "anyOf": [
396
+ {
397
+ "required": [
398
+ "pattern"
399
+ ]
400
+ },
401
+ {
402
+ "required": [
403
+ "format"
404
+ ]
405
+ },
406
+ {
407
+ "required": [
408
+ "minLength"
409
+ ]
410
+ },
411
+ {
412
+ "required": [
413
+ "maxLength"
414
+ ]
415
+ }
416
+ ]
417
+ }
418
+ }
419
+ },
420
+ {
421
+ "if": {
422
+ "properties": {
423
+ "type": {
424
+ "const": "number"
425
+ }
426
+ }
427
+ },
428
+ "then": {
429
+ "properties": {
430
+ "enum": {
431
+ "items": {
432
+ "type": "number"
433
+ }
434
+ }
435
+ }
436
+ }
437
+ },
438
+ {
439
+ "if": {
440
+ "properties": {
441
+ "type": {
442
+ "const": "integer"
443
+ }
444
+ }
445
+ },
446
+ "then": {
447
+ "properties": {
448
+ "enum": {
449
+ "items": {
450
+ "type": "integer"
451
+ }
452
+ }
453
+ }
454
+ }
455
+ },
456
+ {
457
+ "if": {
458
+ "properties": {
459
+ "type": {
460
+ "const": "boolean"
461
+ }
462
+ }
463
+ },
464
+ "then": {
465
+ "properties": {
466
+ "enum": {
467
+ "items": {
468
+ "type": "boolean"
469
+ }
470
+ }
471
+ }
472
+ }
473
+ }
474
+ ],
475
+ "properties": {
476
+ "$schema": {
477
+ "const": "https://json-schema.org/draft/2020-12/schema"
478
+ },
479
+ "type": {
480
+ "enum": [
481
+ "string",
482
+ "number",
483
+ "integer",
484
+ "boolean"
485
+ ]
486
+ },
487
+ "$anchor": {
488
+ "type": "string",
489
+ "pattern": "^[A-Za-z][A-Za-z0-9._-]*Identity$"
490
+ },
491
+ "$comment": {
492
+ "type": "string"
493
+ },
494
+ "enum": {
495
+ "type": "array",
496
+ "minItems": 1,
497
+ "uniqueItems": true
498
+ },
499
+ "format": {
500
+ "type": "string"
501
+ },
502
+ "maxLength": {
503
+ "type": "integer",
504
+ "minimum": 0
505
+ },
506
+ "minLength": {
507
+ "type": "integer",
508
+ "minimum": 0
509
+ },
510
+ "pattern": {
511
+ "type": "string"
512
+ }
513
+ },
514
+ "required": [
515
+ "type"
516
+ ],
517
+ "additionalProperties": false,
518
+ "$anchor": "IdentitySchema"
519
+ },
520
+ "IdentitySchemaRef": {
377
521
  "$schema": "https://json-schema.org/draft/2020-12/schema",
378
522
  "type": "object",
379
523
  "properties": {
380
524
  "$ref": {
381
525
  "type": "string",
382
- "$comment": "Supports both anchor syntax (#<Name>Id) and JSON Pointer syntax (#/path/to/definition). Anchors use #<Name>Id for identity refs. Top-level and nested $defs should expose an $anchor matching <Name>Id.",
383
- "pattern": "^#([A-Za-z][A-Za-z0-9._-]*Id|/.*)$"
526
+ "$comment": "Supports both anchor syntax (#<Name>Identity) and JSON Pointer syntax (#/path/to/definition). Anchors use #<Name>Identity for identity refs. Top-level and nested $defs should expose an $anchor matching <Name>Identity.",
527
+ "pattern": "^#([A-Za-z][A-Za-z0-9._-]*Identity|/.*)$"
384
528
  }
385
529
  },
386
530
  "required": [
387
531
  "$ref"
388
532
  ],
389
533
  "additionalProperties": false,
390
- "$anchor": "IdentityValue"
534
+ "$anchor": "IdentitySchemaRef"
391
535
  },
392
536
  "Job": {
393
537
  "$schema": "https://json-schema.org/draft/2020-12/schema",
@@ -396,36 +540,36 @@
396
540
  {
397
541
  "properties": {
398
542
  "identity": {
399
- "$ref": "#/$defs/JobId"
543
+ "$ref": "#/$defs/JobIdentity"
400
544
  },
401
- "implementation": {
545
+ "implementationUri": {
402
546
  "type": "string",
403
547
  "format": "uri"
404
548
  }
405
549
  },
406
550
  "required": [
407
551
  "identity",
408
- "implementation"
552
+ "implementationUri"
409
553
  ]
410
554
  },
411
555
  {
412
556
  "$ref": "#/$defs/Documented"
413
557
  },
414
558
  {
415
- "$ref": "#/$defs/RolesOuter"
559
+ "$ref": "#/$defs/RolesWrapper"
416
560
  }
417
561
  ],
418
562
  "unevaluatedProperties": false,
419
563
  "$anchor": "Job"
420
564
  },
421
- "JobId": {
565
+ "JobIdentity": {
422
566
  "$schema": "https://json-schema.org/draft/2020-12/schema",
423
567
  "type": "string",
424
- "$anchor": "JobId",
568
+ "$anchor": "JobIdentity",
425
569
  "$comment": "",
426
570
  "pattern": "^JOB-.+$"
427
571
  },
428
- "JsonValue": {
572
+ "JsonData": {
429
573
  "$schema": "https://json-schema.org/draft/2020-12/schema",
430
574
  "oneOf": [
431
575
  {
@@ -443,36 +587,108 @@
443
587
  {
444
588
  "type": "array",
445
589
  "items": {
446
- "$ref": "#/$defs/JsonValue"
590
+ "$ref": "#/$defs/JsonData"
447
591
  }
448
592
  },
449
593
  {
450
594
  "type": "object",
451
595
  "additionalProperties": {
452
- "$ref": "#/$defs/JsonValue"
596
+ "$ref": "#/$defs/JsonData"
453
597
  }
454
598
  }
455
599
  ],
456
- "$anchor": "JsonValue"
600
+ "$anchor": "JsonData"
457
601
  },
458
602
  "MeritProp": {
459
603
  "$schema": "https://json-schema.org/draft/2020-12/schema",
460
604
  "type": "object",
461
605
  "properties": {
606
+ "$defs": {
607
+ "type": "object",
608
+ "additionalProperties": true,
609
+ "$comment": "Ajv-specific: patternRequired enforces at least one Merit-like key in this $defs block when merit is present.",
610
+ "minProperties": 1,
611
+ "patternProperties": {
612
+ "^[A-Za-z][A-Za-z0-9._-]*Merit$": {
613
+ "$ref": "#/$defs/MeritSchema"
614
+ }
615
+ },
616
+ "patternRequired": [
617
+ "^[A-Za-z][A-Za-z0-9._-]*Merit$"
618
+ ]
619
+ },
462
620
  "properties": {
463
621
  "type": "object",
464
622
  "properties": {
465
623
  "merit": {
466
- "$ref": "#/$defs/MeritValue"
624
+ "$ref": "#/$defs/MeritSchemaRef"
467
625
  }
468
- }
626
+ },
627
+ "required": [
628
+ "merit"
629
+ ]
630
+ },
631
+ "required": {
632
+ "type": "array",
633
+ "items": {
634
+ "type": "string"
635
+ },
636
+ "uniqueItems": true
469
637
  }
470
638
  },
639
+ "required": [
640
+ "$defs",
641
+ "required",
642
+ "properties"
643
+ ],
644
+ "additionalProperties": false,
471
645
  "$anchor": "MeritProp"
472
646
  },
473
- "MeritValue": {
647
+ "MeritSchema": {
474
648
  "$schema": "https://json-schema.org/draft/2020-12/schema",
475
649
  "type": "object",
650
+ "allOf": [
651
+ {
652
+ "if": {
653
+ "required": [
654
+ "type"
655
+ ]
656
+ },
657
+ "then": {},
658
+ "else": {
659
+ "not": {
660
+ "anyOf": [
661
+ {
662
+ "required": [
663
+ "minimum"
664
+ ]
665
+ },
666
+ {
667
+ "required": [
668
+ "maximum"
669
+ ]
670
+ },
671
+ {
672
+ "required": [
673
+ "exclusiveMinimum"
674
+ ]
675
+ },
676
+ {
677
+ "required": [
678
+ "exclusiveMaximum"
679
+ ]
680
+ },
681
+ {
682
+ "required": [
683
+ "multipleOf"
684
+ ]
685
+ }
686
+ ]
687
+ }
688
+ },
689
+ "$comment": "Numeric constraints (minimum/maximum/etc) only make sense when using the explicit type form; the enum-only form is allowed for simple enumerations."
690
+ }
691
+ ],
476
692
  "oneOf": [
477
693
  {
478
694
  "properties": {
@@ -502,9 +718,68 @@
502
718
  ]
503
719
  }
504
720
  ],
505
- "$anchor": "MeritValue"
721
+ "properties": {
722
+ "$schema": {
723
+ "const": "https://json-schema.org/draft/2020-12/schema"
724
+ },
725
+ "type": {
726
+ "enum": [
727
+ "number",
728
+ "integer"
729
+ ]
730
+ },
731
+ "$anchor": {
732
+ "type": "string",
733
+ "pattern": "^[A-Za-z][A-Za-z0-9._-]*Merit$"
734
+ },
735
+ "$comment": {
736
+ "type": "string"
737
+ },
738
+ "enum": {
739
+ "type": "array",
740
+ "items": {
741
+ "type": "number"
742
+ },
743
+ "minItems": 1,
744
+ "uniqueItems": true
745
+ },
746
+ "exclusiveMaximum": {
747
+ "type": "number"
748
+ },
749
+ "exclusiveMinimum": {
750
+ "type": "number"
751
+ },
752
+ "maximum": {
753
+ "type": "number"
754
+ },
755
+ "minimum": {
756
+ "type": "number"
757
+ },
758
+ "multipleOf": {
759
+ "type": "number",
760
+ "exclusiveMinimum": 0
761
+ }
762
+ },
763
+ "additionalProperties": false,
764
+ "$anchor": "MeritSchema"
765
+ },
766
+ "MeritSchemaRef": {
767
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
768
+ "type": "object",
769
+ "properties": {
770
+ "$ref": {
771
+ "type": "string",
772
+ "$comment": "Supports both anchor syntax (#<Name>Merit) and JSON Pointer syntax (#/path/to/definition). Anchors use #<Name>Merit for merit refs. Top-level and nested $defs should expose an $anchor matching <Name>Merit.",
773
+ "pattern": "^#([A-Za-z][A-Za-z0-9._-]*Merit|/.*)$"
774
+ }
775
+ },
776
+ "required": [
777
+ "$ref"
778
+ ],
779
+ "additionalProperties": false,
780
+ "$anchor": "MeritSchemaRef"
506
781
  },
507
- "Name": {
782
+ "Named": {
508
783
  "$schema": "https://json-schema.org/draft/2020-12/schema",
509
784
  "type": "object",
510
785
  "properties": {
@@ -519,7 +794,7 @@
519
794
  "required": [
520
795
  "name"
521
796
  ],
522
- "$anchor": "Name"
797
+ "$anchor": "Named"
523
798
  },
524
799
  "Path": {
525
800
  "$schema": "https://json-schema.org/draft/2020-12/schema",
@@ -546,7 +821,7 @@
546
821
  "extractedData": {
547
822
  "type": "object",
548
823
  "additionalProperties": {
549
- "$ref": "#/$defs/JsonValue"
824
+ "$ref": "#/$defs/JsonData"
550
825
  },
551
826
  "$comment": "This will be overlayed at runtime to match the data structure of the underlying type's extractionSchema. At compile time, we guarantee it has an identity property."
552
827
  }
@@ -566,15 +841,15 @@
566
841
  {
567
842
  "properties": {
568
843
  "identity": {
569
- "$ref": "#/$defs/ResourceId"
844
+ "$ref": "#/$defs/ResourceIdentity"
570
845
  },
571
- "resourceTypeId": {
572
- "$ref": "#/$defs/ResourceTypeId"
846
+ "resourceTypeRef": {
847
+ "$ref": "#/$defs/ResourceTypeIdentity"
573
848
  }
574
849
  },
575
850
  "required": [
576
851
  "identity",
577
- "resourceTypeId"
852
+ "resourceTypeRef"
578
853
  ]
579
854
  }
580
855
  ],
@@ -587,7 +862,7 @@
587
862
  {
588
863
  "properties": {
589
864
  "identity": {
590
- "$ref": "#/$defs/ResourceFormatId"
865
+ "$ref": "#/$defs/ResourceFormatIdentity"
591
866
  }
592
867
  },
593
868
  "required": [
@@ -600,16 +875,16 @@
600
875
  ],
601
876
  "$anchor": "ResourceFormat"
602
877
  },
603
- "ResourceFormatId": {
878
+ "ResourceFormatIdentity": {
604
879
  "$schema": "https://json-schema.org/draft/2020-12/schema",
605
880
  "type": "string",
606
- "$anchor": "ResourceFormatId",
881
+ "$anchor": "ResourceFormatIdentity",
607
882
  "pattern": "^FORMAT-.+$"
608
883
  },
609
- "ResourceId": {
884
+ "ResourceIdentity": {
610
885
  "$schema": "https://json-schema.org/draft/2020-12/schema",
611
886
  "type": "string",
612
- "$anchor": "ResourceId",
887
+ "$anchor": "ResourceIdentity",
613
888
  "$comment": "",
614
889
  "pattern": "^RESOURCE-.+$"
615
890
  },
@@ -646,7 +921,7 @@
646
921
  "$ref": "#/$defs/ResourceBase"
647
922
  },
648
923
  {
649
- "$ref": "#/$defs/CreationContext"
924
+ "$ref": "#/$defs/CreationContextWrapper"
650
925
  },
651
926
  {
652
927
  "$ref": "#/$defs/ResourceKind"
@@ -702,7 +977,7 @@
702
977
  "$ref": "#/$defs/ResourceBase"
703
978
  },
704
979
  {
705
- "$ref": "#/$defs/CreationContext"
980
+ "$ref": "#/$defs/CreationContextWrapper"
706
981
  },
707
982
  {
708
983
  "$ref": "#/$defs/ResourceKind"
@@ -729,7 +1004,7 @@
729
1004
  "$ref": "#/$defs/ResourceBase"
730
1005
  },
731
1006
  {
732
- "$ref": "#/$defs/CreationContext"
1007
+ "$ref": "#/$defs/CreationContextWrapper"
733
1008
  },
734
1009
  {
735
1010
  "$ref": "#/$defs/ResourceKind"
@@ -748,10 +1023,10 @@
748
1023
  "unevaluatedProperties": false,
749
1024
  "$anchor": "ResourcePotentialOutput"
750
1025
  },
751
- "ResourceRoleId": {
1026
+ "ResourceRoleIdentity": {
752
1027
  "$schema": "https://json-schema.org/draft/2020-12/schema",
753
1028
  "type": "string",
754
- "$anchor": "ResourceRoleId",
1029
+ "$anchor": "ResourceRoleIdentity",
755
1030
  "pattern": "^ROLE-.+$"
756
1031
  },
757
1032
  "ResourceRoleValue": {
@@ -760,14 +1035,14 @@
760
1035
  "allOf": [
761
1036
  {
762
1037
  "properties": {
763
- "resourceTypeId": {
764
- "$ref": "#/$defs/ResourceTypeId"
1038
+ "resourceTypeRef": {
1039
+ "$ref": "#/$defs/ResourceTypeIdentity"
765
1040
  }
766
1041
  },
767
1042
  "required": [
768
- "resourceTypeId"
1043
+ "resourceTypeRef"
769
1044
  ],
770
- "$comment": "A ResourceRole does not have a self-contained identity, as it is always defined in the context of a RoleMap."
1045
+ "$comment": "A ResourceRole does not have a self-contained identity, as it is always defined in the context of a RoleMap. ResourceRoleValue uses the Value suffix to mean 'the value stored in this map' (RoleMap.additionalProperties)."
771
1046
  },
772
1047
  {
773
1048
  "$ref": "#/$defs/Documented"
@@ -782,31 +1057,31 @@
782
1057
  {
783
1058
  "properties": {
784
1059
  "identity": {
785
- "$ref": "#/$defs/ResourceTypeId"
1060
+ "$ref": "#/$defs/ResourceTypeIdentity"
786
1061
  },
787
- "resourceFormatId": {
788
- "$ref": "#/$defs/ResourceFormatId"
1062
+ "resourceFormatRef": {
1063
+ "$ref": "#/$defs/ResourceFormatIdentity"
789
1064
  }
790
1065
  },
791
1066
  "required": [
792
1067
  "identity",
793
- "resourceFormatId"
1068
+ "resourceFormatRef"
794
1069
  ]
795
1070
  },
796
1071
  {
797
1072
  "$ref": "#/$defs/Documented"
798
1073
  },
799
1074
  {
800
- "$ref": "#/$defs/ExtractionSchema"
1075
+ "$ref": "#/$defs/ExtractionSchemaWrapper"
801
1076
  },
802
1077
  {
803
1078
  "if": {
804
1079
  "properties": {
805
- "resourceFormatId": {
1080
+ "resourceFormatRef": {
806
1081
  "const": "FORMAT-ApplicationJson"
807
1082
  }
808
1083
  },
809
- "$comment": "If resourceFormatId is FORMAT-ApplicationJson, then extractor must not be present, but if resourceFormatId is not FORMAT-ApplicationJson, then extractor must be present. This is because resources of types with format FORMAT-ApplicationJson are self-contained and do not need an extractor."
1084
+ "$comment": "If resourceFormatRef is FORMAT-ApplicationJson, then extractor must not be present, but if resourceFormatRef is not FORMAT-ApplicationJson, then extractor must be present. This is because resources of types with format FORMAT-ApplicationJson are self-contained and do not need an extractor."
810
1085
  },
811
1086
  "then": {
812
1087
  "not": {
@@ -831,24 +1106,24 @@
831
1106
  ],
832
1107
  "$anchor": "ResourceType"
833
1108
  },
834
- "ResourceTypeId": {
1109
+ "ResourceTypeIdentity": {
835
1110
  "$schema": "https://json-schema.org/draft/2020-12/schema",
836
1111
  "type": "string",
837
- "$anchor": "ResourceTypeId",
1112
+ "$anchor": "ResourceTypeIdentity",
838
1113
  "pattern": "^TYPE-.+$"
839
1114
  },
840
1115
  "RoleBindingMap": {
841
1116
  "$schema": "https://json-schema.org/draft/2020-12/schema",
842
1117
  "type": "object",
843
1118
  "additionalProperties": {
844
- "$ref": "#/$defs/ResourceId"
1119
+ "$ref": "#/$defs/ResourceIdentity"
845
1120
  },
846
1121
  "$anchor": "RoleBindingMap",
847
1122
  "propertyNames": {
848
- "$ref": "#/$defs/ResourceRoleId"
1123
+ "$ref": "#/$defs/ResourceRoleIdentity"
849
1124
  }
850
1125
  },
851
- "RoleBindingsInner": {
1126
+ "RoleBindings": {
852
1127
  "$schema": "https://json-schema.org/draft/2020-12/schema",
853
1128
  "type": "object",
854
1129
  "properties": {
@@ -864,20 +1139,20 @@
864
1139
  "outputBindingMap"
865
1140
  ],
866
1141
  "unevaluatedProperties": false,
867
- "$anchor": "RoleBindingsInner"
1142
+ "$anchor": "RoleBindings"
868
1143
  },
869
- "RoleBindingsOuter": {
1144
+ "RoleBindingsWrapper": {
870
1145
  "$schema": "https://json-schema.org/draft/2020-12/schema",
871
1146
  "type": "object",
872
1147
  "properties": {
873
1148
  "roleBindings": {
874
- "$ref": "#/$defs/RoleBindingsInner"
1149
+ "$ref": "#/$defs/RoleBindings"
875
1150
  }
876
1151
  },
877
1152
  "required": [
878
1153
  "roleBindings"
879
1154
  ],
880
- "$anchor": "RoleBindingsOuter"
1155
+ "$anchor": "RoleBindingsWrapper"
881
1156
  },
882
1157
  "RoleMap": {
883
1158
  "$schema": "https://json-schema.org/draft/2020-12/schema",
@@ -887,10 +1162,10 @@
887
1162
  },
888
1163
  "$anchor": "RoleMap",
889
1164
  "propertyNames": {
890
- "$ref": "#/$defs/ResourceRoleId"
1165
+ "$ref": "#/$defs/ResourceRoleIdentity"
891
1166
  }
892
1167
  },
893
- "RolesInner": {
1168
+ "Roles": {
894
1169
  "$schema": "https://json-schema.org/draft/2020-12/schema",
895
1170
  "type": "object",
896
1171
  "properties": {
@@ -906,20 +1181,20 @@
906
1181
  "outputMap"
907
1182
  ],
908
1183
  "unevaluatedProperties": false,
909
- "$anchor": "RolesInner"
1184
+ "$anchor": "Roles"
910
1185
  },
911
- "RolesOuter": {
1186
+ "RolesWrapper": {
912
1187
  "$schema": "https://json-schema.org/draft/2020-12/schema",
913
1188
  "type": "object",
914
1189
  "properties": {
915
1190
  "roles": {
916
- "$ref": "#/$defs/RolesInner"
1191
+ "$ref": "#/$defs/Roles"
917
1192
  }
918
1193
  },
919
1194
  "required": [
920
1195
  "roles"
921
1196
  ],
922
- "$anchor": "RolesOuter"
1197
+ "$anchor": "RolesWrapper"
923
1198
  },
924
1199
  "StatefulStrategy": {
925
1200
  "$schema": "https://json-schema.org/draft/2020-12/schema",
@@ -928,7 +1203,7 @@
928
1203
  {
929
1204
  "properties": {
930
1205
  "identity": {
931
- "$ref": "#/$defs/StatefulStrategyId"
1206
+ "$ref": "#/$defs/StatefulStrategyIdentity"
932
1207
  },
933
1208
  "statelessStrategy": {
934
1209
  "$ref": "#/$defs/StatelessStrategy"
@@ -940,15 +1215,15 @@
940
1215
  ]
941
1216
  },
942
1217
  {
943
- "$ref": "#/$defs/StrategyState"
1218
+ "$ref": "#/$defs/StrategyStateWrapper"
944
1219
  }
945
1220
  ],
946
1221
  "$anchor": "StatefulStrategy"
947
1222
  },
948
- "StatefulStrategyId": {
1223
+ "StatefulStrategyIdentity": {
949
1224
  "$schema": "https://json-schema.org/draft/2020-12/schema",
950
1225
  "type": "string",
951
- "$anchor": "StatefulStrategyId",
1226
+ "$anchor": "StatefulStrategyIdentity",
952
1227
  "pattern": "^STATEFUL_STRATEGY-.+$"
953
1228
  },
954
1229
  "StatelessStrategy": {
@@ -959,7 +1234,7 @@
959
1234
  "type": "object",
960
1235
  "properties": {
961
1236
  "identity": {
962
- "$ref": "#/$defs/StatelessStrategyId"
1237
+ "$ref": "#/$defs/StatelessStrategyIdentity"
963
1238
  },
964
1239
  "steps": {
965
1240
  "type": "array",
@@ -978,10 +1253,10 @@
978
1253
  "unevaluatedProperties": false,
979
1254
  "$anchor": "StatelessStrategy"
980
1255
  },
981
- "StatelessStrategyId": {
1256
+ "StatelessStrategyIdentity": {
982
1257
  "$schema": "https://json-schema.org/draft/2020-12/schema",
983
1258
  "type": "string",
984
- "$anchor": "StatelessStrategyId",
1259
+ "$anchor": "StatelessStrategyIdentity",
985
1260
  "pattern": "^STATELESS_STRATEGY-.+$"
986
1261
  },
987
1262
  "Step": {
@@ -1024,19 +1299,6 @@
1024
1299
  "$anchor": "StepKind"
1025
1300
  },
1026
1301
  "StrategyState": {
1027
- "$schema": "https://json-schema.org/draft/2020-12/schema",
1028
- "type": "object",
1029
- "properties": {
1030
- "strategyState": {
1031
- "$ref": "#/$defs/StrategyStateValue"
1032
- }
1033
- },
1034
- "required": [
1035
- "strategyState"
1036
- ],
1037
- "$anchor": "StrategyState"
1038
- },
1039
- "StrategyStateValue": {
1040
1302
  "$schema": "https://json-schema.org/draft/2020-12/schema",
1041
1303
  "type": "object",
1042
1304
  "additionalProperties": {
@@ -1058,14 +1320,27 @@
1058
1320
  ]
1059
1321
  },
1060
1322
  "propertyNames": {
1061
- "$ref": "#/$defs/ResourceRoleId"
1323
+ "$ref": "#/$defs/ResourceRoleIdentity"
1062
1324
  }
1063
1325
  },
1064
- "$anchor": "StrategyStateValue",
1326
+ "$anchor": "StrategyState",
1065
1327
  "propertyNames": {
1066
- "$ref": "#/$defs/ExecutionId"
1328
+ "$ref": "#/$defs/ExecutionIdentity"
1067
1329
  }
1068
1330
  },
1331
+ "StrategyStateWrapper": {
1332
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1333
+ "type": "object",
1334
+ "properties": {
1335
+ "strategyState": {
1336
+ "$ref": "#/$defs/StrategyState"
1337
+ }
1338
+ },
1339
+ "required": [
1340
+ "strategyState"
1341
+ ],
1342
+ "$anchor": "StrategyStateWrapper"
1343
+ },
1069
1344
  "Timestamp": {
1070
1345
  "$schema": "https://json-schema.org/draft/2020-12/schema",
1071
1346
  "type": "object",
@@ -1091,10 +1366,10 @@
1091
1366
  "type": "object",
1092
1367
  "properties": {
1093
1368
  "case": {
1094
- "$ref": "#/$defs/ConditionalWrapper"
1369
+ "$ref": "#/$defs/Conditional"
1095
1370
  },
1096
1371
  "identity": {
1097
- "$ref": "#/$defs/WhileStepId"
1372
+ "$ref": "#/$defs/WhileStepIdentity"
1098
1373
  },
1099
1374
  "kind": {
1100
1375
  "const": "while"
@@ -1109,10 +1384,10 @@
1109
1384
  ],
1110
1385
  "$anchor": "WhileStep"
1111
1386
  },
1112
- "WhileStepId": {
1387
+ "WhileStepIdentity": {
1113
1388
  "$schema": "https://json-schema.org/draft/2020-12/schema",
1114
1389
  "type": "string",
1115
- "$anchor": "WhileStepId",
1390
+ "$anchor": "WhileStepIdentity",
1116
1391
  "pattern": "^WHILESTEP-.+$"
1117
1392
  },
1118
1393
  "WorkStep": {
@@ -1129,7 +1404,7 @@
1129
1404
  "$ref": "#/$defs/Execution"
1130
1405
  },
1131
1406
  "identity": {
1132
- "$ref": "#/$defs/WorkStepId"
1407
+ "$ref": "#/$defs/WorkStepIdentity"
1133
1408
  },
1134
1409
  "kind": {
1135
1410
  "const": "work"
@@ -1144,10 +1419,10 @@
1144
1419
  ],
1145
1420
  "$anchor": "WorkStep"
1146
1421
  },
1147
- "WorkStepId": {
1422
+ "WorkStepIdentity": {
1148
1423
  "$schema": "https://json-schema.org/draft/2020-12/schema",
1149
1424
  "type": "string",
1150
- "$anchor": "WorkStepId",
1425
+ "$anchor": "WorkStepIdentity",
1151
1426
  "pattern": "^WORKSTEP-.+$"
1152
1427
  }
1153
1428
  },