owlrunkit 0.18.3 → 0.19.0

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 (59) hide show
  1. package/CHANGELOG.md +80 -0
  2. package/README.md +223 -52
  3. package/docs/architecture/OWLCODA_RUNKIT_0184_EXTERNAL_DELIVERY_INTAKE_PRODUCT_DECISION_20260812.md +209 -0
  4. package/docs/architecture/OWLCODA_RUNKIT_0190_CONSOLIDATED_DAILY_USE_PRODUCT_DECISION_20260812.md +97 -0
  5. package/docs/architecture/OWLCODA_RUNKIT_USAGE_MODE_SELECTION_PRODUCT_DECISION_20260811.md +8 -7
  6. package/docs/architecture/OWLCODA_RUN_KIT_CONTRACT_V0_2.md +57 -0
  7. package/integrations/codex/skills/owlcoda-runkit/SKILL.md +133 -77
  8. package/integrations/codex/skills/owlcoda-runkit/assets/templates/config.json +3 -3
  9. package/integrations/codex/skills/owlcoda-runkit/references/contract-v0.2.md +57 -0
  10. package/package.json +1 -1
  11. package/packages/attest/README.md +9 -5
  12. package/packages/attest/consumer-surface-v2.json +263 -0
  13. package/packages/attest/distribution-manifest-v1.json +14 -1
  14. package/packages/attest/schemas/quick-verification-receipt-v3.schema.json +244 -0
  15. package/packages/attest/schemas/workspace-snapshot-v2.schema.json +114 -0
  16. package/packages/attest/src/dependency-environment.mjs +128 -0
  17. package/packages/attest/src/index.mjs +1 -0
  18. package/packages/attest/src/quick-receipt-contract.mjs +205 -12
  19. package/packages/attest/src/quick.mjs +45 -4
  20. package/packages/attest/src/workspace-snapshot.mjs +143 -7
  21. package/registry-release-policy-v1.json +5 -5
  22. package/sbom.spdx.json +5 -5
  23. package/scripts/runkit-contract/assurance-router.mjs +25 -6
  24. package/scripts/runkit-contract/core-contract.mjs +29 -1
  25. package/scripts/runkit-contract/efficiency-metrics.mjs +559 -0
  26. package/scripts/runkit-contract/evidence-store.mjs +130 -0
  27. package/scripts/runkit-contract/onboarding-bootstrap.mjs +685 -0
  28. package/scripts/runkit-contract/onboarding-doctor.mjs +3 -2
  29. package/scripts/runkit-contract/outcome-presentation.mjs +171 -0
  30. package/scripts/runkit-contract/profile-onboarding.mjs +285 -17
  31. package/scripts/runkit-contract/project-cli-resolver.mjs +29 -5
  32. package/scripts/runkit-contract/project-external-delivery.mjs +707 -0
  33. package/scripts/runkit-contract/quick-evidence-reuse.mjs +590 -0
  34. package/scripts/runkit-contract/quick-isolation.mjs +314 -0
  35. package/scripts/runkit-contract/quick-metrics.mjs +51 -3
  36. package/scripts/runkit-contract/quick-receipt.mjs +31 -1
  37. package/scripts/runkit-contract/quick-verify.mjs +217 -26
  38. package/scripts/runkit-contract/quick-workspace-snapshot.mjs +1 -0
  39. package/scripts/runkit-contract/runkit-bootstrap.mjs +7 -1
  40. package/scripts/runkit-contract/runkit-cli.mjs +602 -152
  41. package/scripts/runkit-contract/runtime-transition.mjs +478 -0
  42. package/scripts/runkit-contract/schemas/assurance-route-v2.schema.json +26 -0
  43. package/scripts/runkit-contract/schemas/efficiency-event-v1.schema.json +56 -0
  44. package/scripts/runkit-contract/schemas/efficiency-metrics-v1.schema.json +220 -0
  45. package/scripts/runkit-contract/schemas/external-runtime-report-v1.schema.json +125 -0
  46. package/scripts/runkit-contract/schemas/onboarding-bootstrap-plan-v1.schema.json +168 -0
  47. package/scripts/runkit-contract/schemas/onboarding-bootstrap-receipt-v1.schema.json +130 -0
  48. package/scripts/runkit-contract/schemas/outcome-summary-v1.schema.json +83 -0
  49. package/scripts/runkit-contract/schemas/profile-detection-v3.schema.json +170 -0
  50. package/scripts/runkit-contract/schemas/quick-evidence-reuse-plan-v1.schema.json +59 -0
  51. package/scripts/runkit-contract/schemas/quick-evidence-reuse-receipt-v1.schema.json +79 -0
  52. package/scripts/runkit-contract/schemas/runtime-transition-receipt-v1.schema.json +185 -0
  53. package/scripts/runkit-contract/schemas/team-project-event-v3.schema.json +146 -0
  54. package/scripts/runkit-contract/schemas/team-project-event-v4.schema.json +142 -0
  55. package/scripts/runkit-contract/schemas/team-project-status-v2.schema.json +85 -0
  56. package/scripts/runkit-contract/schemas/usage-mode-recommendation-v2.schema.json +136 -0
  57. package/scripts/runkit-contract/team-project.mjs +1172 -22
  58. package/scripts/runkit-contract/usage-mode.mjs +28 -7
  59. package/scripts/runkit-contract/verification-envelope.mjs +15 -18
@@ -0,0 +1,220 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://owlcoda.dev/schemas/runkit/efficiency-metrics-v1.json",
4
+ "title": "OwlCoda RunKit Efficiency Metrics V1",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": [
8
+ "schemaVersion",
9
+ "status",
10
+ "exitCode",
11
+ "telemetry",
12
+ "networkRequests",
13
+ "duplicateCommands",
14
+ "confirmedFalseBlocks",
15
+ "manualInterventions",
16
+ "handoffWait",
17
+ "timeToAcceptableResult",
18
+ "issueCodes",
19
+ "issues",
20
+ "authorizationGranted"
21
+ ],
22
+ "properties": {
23
+ "schemaVersion": { "const": "OwlCodaRunKitEfficiencyMetricsV1" },
24
+ "status": { "enum": ["efficiency_metrics", "efficiency_metrics_invalid"] },
25
+ "exitCode": { "enum": [0, 3] },
26
+ "telemetry": { "const": false },
27
+ "networkRequests": { "const": 0 },
28
+ "duplicateCommands": { "$ref": "#/$defs/duplicateCommands" },
29
+ "confirmedFalseBlocks": { "$ref": "#/$defs/explicitCount" },
30
+ "manualInterventions": { "$ref": "#/$defs/explicitCount" },
31
+ "handoffWait": { "$ref": "#/$defs/handoffWait" },
32
+ "timeToAcceptableResult": { "$ref": "#/$defs/timeToAcceptable" },
33
+ "details": {
34
+ "type": "object",
35
+ "additionalProperties": false,
36
+ "required": [
37
+ "duplicateCommandGroups",
38
+ "workflowDurations",
39
+ "handoffSamples",
40
+ "inputRefs"
41
+ ],
42
+ "properties": {
43
+ "duplicateCommandGroups": {
44
+ "type": "array",
45
+ "items": { "$ref": "#/$defs/duplicateCommandGroup" }
46
+ },
47
+ "workflowDurations": {
48
+ "type": "array",
49
+ "items": { "$ref": "#/$defs/workflowDuration" }
50
+ },
51
+ "handoffSamples": {
52
+ "type": "array",
53
+ "items": { "$ref": "#/$defs/handoffSample" }
54
+ },
55
+ "inputRefs": {
56
+ "type": "array",
57
+ "uniqueItems": true,
58
+ "items": { "type": "string", "minLength": 1 }
59
+ }
60
+ }
61
+ },
62
+ "issueCodes": {
63
+ "type": "array",
64
+ "uniqueItems": true,
65
+ "items": {
66
+ "enum": ["invalid_quick_receipts_excluded", "efficiency_input_store_invalid"]
67
+ }
68
+ },
69
+ "issues": {
70
+ "type": "array",
71
+ "uniqueItems": true,
72
+ "items": { "type": "string", "minLength": 1 }
73
+ },
74
+ "authorizationGranted": { "const": false }
75
+ },
76
+ "$defs": {
77
+ "nonNegative": { "type": "integer", "minimum": 0 },
78
+ "hash": { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" },
79
+ "duplicateCommands": {
80
+ "type": "object",
81
+ "additionalProperties": false,
82
+ "required": ["repeatedExecutions", "groupCount", "basis"],
83
+ "properties": {
84
+ "repeatedExecutions": { "$ref": "#/$defs/nonNegative" },
85
+ "groupCount": { "$ref": "#/$defs/nonNegative" },
86
+ "basis": { "const": "quick_receipts_same_command_candidate_input_and_dependency" }
87
+ }
88
+ },
89
+ "explicitCount": {
90
+ "type": "object",
91
+ "additionalProperties": false,
92
+ "required": ["count", "basis"],
93
+ "properties": {
94
+ "count": { "$ref": "#/$defs/nonNegative" },
95
+ "basis": { "const": "explicit_events" }
96
+ }
97
+ },
98
+ "handoffWait": {
99
+ "type": "object",
100
+ "additionalProperties": false,
101
+ "required": [
102
+ "completedHandoffs",
103
+ "unresolvedHandoffs",
104
+ "staleHandoffs",
105
+ "totalMs",
106
+ "averageMs",
107
+ "maxMs"
108
+ ],
109
+ "properties": {
110
+ "completedHandoffs": { "$ref": "#/$defs/nonNegative" },
111
+ "unresolvedHandoffs": { "$ref": "#/$defs/nonNegative" },
112
+ "staleHandoffs": { "$ref": "#/$defs/nonNegative" },
113
+ "totalMs": { "$ref": "#/$defs/nonNegative" },
114
+ "averageMs": { "$ref": "#/$defs/nonNegative" },
115
+ "maxMs": { "$ref": "#/$defs/nonNegative" }
116
+ }
117
+ },
118
+ "timeToAcceptable": {
119
+ "type": "object",
120
+ "additionalProperties": false,
121
+ "required": [
122
+ "status",
123
+ "completedWorkflows",
124
+ "totalMs",
125
+ "averageMs",
126
+ "minMs",
127
+ "maxMs",
128
+ "latestMs"
129
+ ],
130
+ "properties": {
131
+ "status": { "enum": ["observed", "not_observed"] },
132
+ "completedWorkflows": { "$ref": "#/$defs/nonNegative" },
133
+ "totalMs": { "$ref": "#/$defs/nonNegative" },
134
+ "averageMs": { "$ref": "#/$defs/nonNegative" },
135
+ "minMs": { "$ref": "#/$defs/nonNegative" },
136
+ "maxMs": { "$ref": "#/$defs/nonNegative" },
137
+ "latestMs": { "$ref": "#/$defs/nonNegative" }
138
+ }
139
+ },
140
+ "duplicateCommandGroup": {
141
+ "type": "object",
142
+ "additionalProperties": false,
143
+ "required": ["bindingFingerprint", "executions", "inputRefs"],
144
+ "properties": {
145
+ "bindingFingerprint": { "$ref": "#/$defs/hash" },
146
+ "executions": { "$ref": "#/$defs/nonNegative" },
147
+ "inputRefs": {
148
+ "type": "array",
149
+ "minItems": 2,
150
+ "items": { "type": "string", "minLength": 1 }
151
+ }
152
+ }
153
+ },
154
+ "workflowDuration": {
155
+ "type": "object",
156
+ "additionalProperties": false,
157
+ "required": ["workflowId", "startedAt", "acceptableResultAt", "durationMs"],
158
+ "properties": {
159
+ "workflowId": { "type": "string", "minLength": 1 },
160
+ "startedAt": { "type": "string", "format": "date-time" },
161
+ "acceptableResultAt": { "type": "string", "format": "date-time" },
162
+ "durationMs": { "$ref": "#/$defs/nonNegative" }
163
+ }
164
+ },
165
+ "handoffSample": {
166
+ "type": "object",
167
+ "additionalProperties": false,
168
+ "required": [
169
+ "handoffEventId",
170
+ "acceptedEventId",
171
+ "workItemId",
172
+ "durationMs",
173
+ "handoffRef",
174
+ "acceptedRef"
175
+ ],
176
+ "properties": {
177
+ "handoffEventId": { "type": "string", "minLength": 1 },
178
+ "acceptedEventId": { "type": "string", "minLength": 1 },
179
+ "workItemId": { "type": "string", "minLength": 1 },
180
+ "durationMs": { "$ref": "#/$defs/nonNegative" },
181
+ "handoffRef": { "type": "string", "minLength": 1 },
182
+ "acceptedRef": { "type": "string", "minLength": 1 }
183
+ }
184
+ }
185
+ },
186
+ "examples": [{
187
+ "schemaVersion": "OwlCodaRunKitEfficiencyMetricsV1",
188
+ "status": "efficiency_metrics",
189
+ "exitCode": 0,
190
+ "telemetry": false,
191
+ "networkRequests": 0,
192
+ "duplicateCommands": {
193
+ "repeatedExecutions": 0,
194
+ "groupCount": 0,
195
+ "basis": "quick_receipts_same_command_candidate_input_and_dependency"
196
+ },
197
+ "confirmedFalseBlocks": { "count": 0, "basis": "explicit_events" },
198
+ "manualInterventions": { "count": 0, "basis": "explicit_events" },
199
+ "handoffWait": {
200
+ "completedHandoffs": 0,
201
+ "unresolvedHandoffs": 0,
202
+ "staleHandoffs": 0,
203
+ "totalMs": 0,
204
+ "averageMs": 0,
205
+ "maxMs": 0
206
+ },
207
+ "timeToAcceptableResult": {
208
+ "status": "not_observed",
209
+ "completedWorkflows": 0,
210
+ "totalMs": 0,
211
+ "averageMs": 0,
212
+ "minMs": 0,
213
+ "maxMs": 0,
214
+ "latestMs": 0
215
+ },
216
+ "issueCodes": [],
217
+ "issues": [],
218
+ "authorizationGranted": false
219
+ }]
220
+ }
@@ -0,0 +1,125 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://owlcoda.dev/schemas/runkit/external-runtime-report-v1.schema.json",
4
+ "title": "OwlCoda RunKit External Runtime Report V1",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": [
8
+ "schemaVersion",
9
+ "externalMutation",
10
+ "rollbackPerformed",
11
+ "finalExternalState",
12
+ "failedStage",
13
+ "lastPassedStage",
14
+ "rollbackOutcome",
15
+ "stages",
16
+ "recoveryEvidence",
17
+ "authorizationGranted"
18
+ ],
19
+ "properties": {
20
+ "schemaVersion": { "const": "OwlCodaRunKitExternalRuntimeReportV1" },
21
+ "externalMutation": { "enum": ["changed", "unchanged", "unknown"] },
22
+ "rollbackPerformed": { "type": "boolean" },
23
+ "finalExternalState": { "$ref": "#/$defs/finalState" },
24
+ "failedStage": { "$ref": "#/$defs/nullableStageId" },
25
+ "lastPassedStage": { "$ref": "#/$defs/nullableStageId" },
26
+ "rollbackOutcome": { "enum": ["not_required", "succeeded", "failed", "unknown"] },
27
+ "stages": {
28
+ "type": "array",
29
+ "minItems": 1,
30
+ "maxItems": 128,
31
+ "items": { "$ref": "#/$defs/stage" }
32
+ },
33
+ "recoveryEvidence": {
34
+ "type": "array",
35
+ "maxItems": 128,
36
+ "items": { "$ref": "#/$defs/recoveryEvidence" }
37
+ },
38
+ "authorizationGranted": { "const": false }
39
+ },
40
+ "$defs": {
41
+ "hashOrNull": {
42
+ "oneOf": [
43
+ { "type": "null" },
44
+ { "type": "string", "pattern": "^sha256:[0-9a-f]{64}$" }
45
+ ]
46
+ },
47
+ "stageId": {
48
+ "type": "string",
49
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$"
50
+ },
51
+ "nullableStageId": {
52
+ "oneOf": [
53
+ { "type": "null" },
54
+ { "$ref": "#/$defs/stageId" }
55
+ ]
56
+ },
57
+ "reference": {
58
+ "type": "string",
59
+ "minLength": 1,
60
+ "maxLength": 1024,
61
+ "pattern": "^[^\\r\\n\\u0000]+$"
62
+ },
63
+ "summary": {
64
+ "type": "string",
65
+ "minLength": 1,
66
+ "maxLength": 2048,
67
+ "pattern": "^[^\\u0000]+$"
68
+ },
69
+ "finalState": {
70
+ "type": "object",
71
+ "additionalProperties": false,
72
+ "required": ["status", "stateRef", "fingerprint", "summary"],
73
+ "properties": {
74
+ "status": { "enum": ["changed", "unchanged", "restored", "unknown"] },
75
+ "stateRef": { "$ref": "#/$defs/reference" },
76
+ "fingerprint": { "$ref": "#/$defs/hashOrNull" },
77
+ "summary": { "$ref": "#/$defs/summary" }
78
+ }
79
+ },
80
+ "stage": {
81
+ "type": "object",
82
+ "additionalProperties": false,
83
+ "required": ["stageId", "status", "summary", "evidenceRefs"],
84
+ "properties": {
85
+ "stageId": { "$ref": "#/$defs/stageId" },
86
+ "status": { "enum": ["passed", "failed", "skipped"] },
87
+ "summary": { "$ref": "#/$defs/summary" },
88
+ "evidenceRefs": {
89
+ "type": "array",
90
+ "maxItems": 128,
91
+ "items": { "$ref": "#/$defs/reference" }
92
+ }
93
+ }
94
+ },
95
+ "capturedBefore": {
96
+ "type": "object",
97
+ "additionalProperties": false,
98
+ "required": ["stageId", "stateRef", "fingerprint"],
99
+ "properties": {
100
+ "stageId": { "$ref": "#/$defs/stageId" },
101
+ "stateRef": { "$ref": "#/$defs/reference" },
102
+ "fingerprint": { "$ref": "#/$defs/hashOrNull" }
103
+ }
104
+ },
105
+ "restoresTo": {
106
+ "type": "object",
107
+ "additionalProperties": false,
108
+ "required": ["stateRef", "fingerprint"],
109
+ "properties": {
110
+ "stateRef": { "$ref": "#/$defs/reference" },
111
+ "fingerprint": { "$ref": "#/$defs/hashOrNull" }
112
+ }
113
+ },
114
+ "recoveryEvidence": {
115
+ "type": "object",
116
+ "additionalProperties": false,
117
+ "required": ["artifactRef", "capturedBefore", "restoresTo"],
118
+ "properties": {
119
+ "artifactRef": { "$ref": "#/$defs/reference" },
120
+ "capturedBefore": { "$ref": "#/$defs/capturedBefore" },
121
+ "restoresTo": { "$ref": "#/$defs/restoresTo" }
122
+ }
123
+ }
124
+ }
125
+ }
@@ -0,0 +1,168 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://owlcoda.dev/schemas/runkit/onboarding-bootstrap-plan-v1.json",
4
+ "title": "OwlCoda RunKit Onboarding Bootstrap Plan V1",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": [
8
+ "schemaVersion",
9
+ "status",
10
+ "exitCode",
11
+ "dryRun",
12
+ "writesPerformed",
13
+ "workspaceRoot",
14
+ "exactSpec",
15
+ "localBinding",
16
+ "registry",
17
+ "upgradeSafety",
18
+ "profiles",
19
+ "sharedSkill",
20
+ "steps",
21
+ "estimatedAdditionalSteps",
22
+ "estimatedEvidenceObjects",
23
+ "rollbackScope",
24
+ "issueCodes",
25
+ "nextCommand",
26
+ "authorizationGranted",
27
+ "planSha256"
28
+ ],
29
+ "properties": {
30
+ "schemaVersion": { "const": "OwlCodaRunKitOnboardingBootstrapPlanV1" },
31
+ "status": { "enum": ["bootstrap_ready", "bootstrap_blocked"] },
32
+ "exitCode": { "enum": [0, 2] },
33
+ "dryRun": { "const": true },
34
+ "writesPerformed": { "const": 0 },
35
+ "workspaceRoot": { "type": "string", "minLength": 1 },
36
+ "exactSpec": { "$ref": "#/$defs/exactSpec" },
37
+ "localBinding": { "$ref": "#/$defs/localBinding" },
38
+ "registry": { "$ref": "#/$defs/registry" },
39
+ "upgradeSafety": { "enum": ["safe", "unsafe"] },
40
+ "profiles": { "$ref": "#/$defs/profiles" },
41
+ "sharedSkill": { "$ref": "#/$defs/sharedSkill" },
42
+ "steps": {
43
+ "type": "array",
44
+ "minItems": 6,
45
+ "maxItems": 6,
46
+ "items": { "$ref": "#/$defs/step" }
47
+ },
48
+ "estimatedAdditionalSteps": { "type": "integer", "minimum": 0 },
49
+ "estimatedEvidenceObjects": { "type": "integer", "minimum": 0 },
50
+ "rollbackScope": { "$ref": "#/$defs/strings" },
51
+ "issueCodes": { "$ref": "#/$defs/strings" },
52
+ "nextCommand": { "type": "string", "minLength": 1 },
53
+ "authorizationGranted": { "const": false },
54
+ "planSha256": { "$ref": "#/$defs/hashRef" }
55
+ },
56
+ "$defs": {
57
+ "exactSpec": {
58
+ "type": "string",
59
+ "pattern": "^owlrunkit@[0-9]+\\.[0-9]+\\.[0-9]+$"
60
+ },
61
+ "hash": { "type": "string", "pattern": "^[a-f0-9]{64}$" },
62
+ "hashRef": { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" },
63
+ "strings": {
64
+ "type": "array",
65
+ "uniqueItems": true,
66
+ "items": { "type": "string", "minLength": 1 }
67
+ },
68
+ "localBinding": {
69
+ "oneOf": [
70
+ {
71
+ "type": "object",
72
+ "additionalProperties": false,
73
+ "required": ["status", "version", "resolved", "integrity"],
74
+ "properties": {
75
+ "status": { "const": "bound" },
76
+ "version": { "type": "string", "pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$" },
77
+ "resolved": { "type": "string", "minLength": 1 },
78
+ "integrity": { "type": "string", "pattern": "^sha512-" }
79
+ }
80
+ },
81
+ {
82
+ "type": "object",
83
+ "additionalProperties": false,
84
+ "required": ["status"],
85
+ "properties": {
86
+ "status": { "type": "string", "minLength": 1 }
87
+ }
88
+ }
89
+ ]
90
+ },
91
+ "registry": {
92
+ "oneOf": [
93
+ {
94
+ "type": "object",
95
+ "additionalProperties": false,
96
+ "required": ["status", "version", "shasum", "integrity", "tarballUrl"],
97
+ "properties": {
98
+ "status": { "const": "verified" },
99
+ "version": { "type": "string", "pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$" },
100
+ "shasum": { "type": "string", "pattern": "^[a-f0-9]{40}$" },
101
+ "integrity": { "type": "string", "pattern": "^sha512-" },
102
+ "tarballUrl": { "type": "string", "minLength": 1 }
103
+ }
104
+ },
105
+ {
106
+ "type": "object",
107
+ "additionalProperties": false,
108
+ "required": ["status", "issueCodes"],
109
+ "properties": {
110
+ "status": { "type": "string", "minLength": 1 },
111
+ "issueCodes": { "$ref": "#/$defs/strings" }
112
+ }
113
+ }
114
+ ]
115
+ },
116
+ "profiles": {
117
+ "type": "object",
118
+ "additionalProperties": false,
119
+ "required": ["status", "action", "issueCodes", "evidenceRef"],
120
+ "properties": {
121
+ "status": { "enum": ["ready", "blocked"] },
122
+ "action": { "enum": ["detect_then_reconcile", "validate_current", "reconcile"] },
123
+ "issueCodes": { "$ref": "#/$defs/strings" },
124
+ "evidenceRef": {
125
+ "oneOf": [
126
+ { "type": "null" },
127
+ { "$ref": "#/$defs/hash" }
128
+ ]
129
+ }
130
+ }
131
+ },
132
+ "sharedSkill": {
133
+ "type": "object",
134
+ "additionalProperties": false,
135
+ "required": ["status", "blocking", "issueCodes", "nextCommand"],
136
+ "properties": {
137
+ "status": { "enum": ["not_checked", "valid", "version_mismatch", "invalid"] },
138
+ "blocking": { "const": false },
139
+ "issueCodes": { "$ref": "#/$defs/strings" },
140
+ "nextCommand": {
141
+ "oneOf": [
142
+ { "type": "null" },
143
+ { "type": "string", "minLength": 1 }
144
+ ]
145
+ }
146
+ }
147
+ },
148
+ "step": {
149
+ "type": "object",
150
+ "additionalProperties": false,
151
+ "required": ["id", "action", "writes"],
152
+ "properties": {
153
+ "id": {
154
+ "enum": [
155
+ "exact_package_binding",
156
+ "initialize_core",
157
+ "reconcile_profiles",
158
+ "validate_profiles",
159
+ "adopt_registry_release",
160
+ "doctor"
161
+ ]
162
+ },
163
+ "action": { "type": "string", "minLength": 1 },
164
+ "writes": { "type": "integer", "minimum": 0 }
165
+ }
166
+ }
167
+ }
168
+ }
@@ -0,0 +1,130 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://owlcoda.dev/schemas/runkit/onboarding-bootstrap-receipt-v1.json",
4
+ "title": "OwlCoda RunKit Onboarding Bootstrap Receipt V1",
5
+ "oneOf": [
6
+ { "$ref": "#/$defs/success" },
7
+ { "$ref": "#/$defs/failure" }
8
+ ],
9
+ "$defs": {
10
+ "baseProperties": {
11
+ "schemaVersion": { "const": "OwlCodaRunKitOnboardingBootstrapReceiptV1" },
12
+ "exitCode": { "enum": [0, 2] },
13
+ "bootstrapId": {
14
+ "type": "string",
15
+ "pattern": "^bootstrap-[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$"
16
+ },
17
+ "planSha256": { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" },
18
+ "exactSpec": {
19
+ "type": "string",
20
+ "pattern": "^owlrunkit@[0-9]+\\.[0-9]+\\.[0-9]+$"
21
+ },
22
+ "startedAt": { "type": "string", "format": "date-time" },
23
+ "completedAt": { "type": "string", "format": "date-time" },
24
+ "completedSteps": {
25
+ "type": "array",
26
+ "items": {
27
+ "type": "object",
28
+ "additionalProperties": false,
29
+ "required": ["id", "status"],
30
+ "properties": {
31
+ "id": { "type": "string", "minLength": 1 },
32
+ "status": { "type": "string", "minLength": 1 }
33
+ }
34
+ }
35
+ },
36
+ "rollbackPerformed": { "type": "boolean" },
37
+ "rollbackOutcome": { "enum": ["not_required", "restored", "failed"] },
38
+ "authorizationGranted": { "const": false }
39
+ },
40
+ "success": {
41
+ "type": "object",
42
+ "additionalProperties": false,
43
+ "required": [
44
+ "schemaVersion",
45
+ "status",
46
+ "exitCode",
47
+ "bootstrapId",
48
+ "planSha256",
49
+ "exactSpec",
50
+ "startedAt",
51
+ "completedAt",
52
+ "completedSteps",
53
+ "profileStatus",
54
+ "adoptionStatus",
55
+ "doctorStatus",
56
+ "rollbackPerformed",
57
+ "rollbackOutcome",
58
+ "authorizationGranted"
59
+ ],
60
+ "properties": {
61
+ "schemaVersion": { "const": "OwlCodaRunKitOnboardingBootstrapReceiptV1" },
62
+ "status": { "const": "bootstrapped" },
63
+ "exitCode": { "const": 0 },
64
+ "bootstrapId": { "$ref": "#/$defs/baseProperties/bootstrapId" },
65
+ "planSha256": { "$ref": "#/$defs/baseProperties/planSha256" },
66
+ "exactSpec": { "$ref": "#/$defs/baseProperties/exactSpec" },
67
+ "startedAt": { "$ref": "#/$defs/baseProperties/startedAt" },
68
+ "completedAt": { "$ref": "#/$defs/baseProperties/completedAt" },
69
+ "completedSteps": { "$ref": "#/$defs/baseProperties/completedSteps" },
70
+ "profileStatus": { "enum": ["profiles_already_current", "profiles_reconciled"] },
71
+ "adoptionStatus": { "enum": ["adopted", "ok"] },
72
+ "doctorStatus": { "const": "ready" },
73
+ "rollbackPerformed": { "const": false },
74
+ "rollbackOutcome": { "const": "not_required" },
75
+ "authorizationGranted": { "const": false }
76
+ }
77
+ },
78
+ "failure": {
79
+ "type": "object",
80
+ "additionalProperties": false,
81
+ "required": [
82
+ "schemaVersion",
83
+ "status",
84
+ "exitCode",
85
+ "bootstrapId",
86
+ "planSha256",
87
+ "exactSpec",
88
+ "startedAt",
89
+ "completedAt",
90
+ "completedSteps",
91
+ "failedStep",
92
+ "issueCodes",
93
+ "rollbackPerformed",
94
+ "rollbackOutcome",
95
+ "restoredPaths",
96
+ "authorizationGranted"
97
+ ],
98
+ "properties": {
99
+ "schemaVersion": { "const": "OwlCodaRunKitOnboardingBootstrapReceiptV1" },
100
+ "status": { "const": "bootstrap_failed" },
101
+ "exitCode": { "const": 2 },
102
+ "bootstrapId": { "$ref": "#/$defs/baseProperties/bootstrapId" },
103
+ "planSha256": { "$ref": "#/$defs/baseProperties/planSha256" },
104
+ "exactSpec": { "$ref": "#/$defs/baseProperties/exactSpec" },
105
+ "startedAt": { "$ref": "#/$defs/baseProperties/startedAt" },
106
+ "completedAt": { "$ref": "#/$defs/baseProperties/completedAt" },
107
+ "completedSteps": { "$ref": "#/$defs/baseProperties/completedSteps" },
108
+ "failedStep": {
109
+ "oneOf": [
110
+ { "type": "null" },
111
+ { "type": "string", "minLength": 1 }
112
+ ]
113
+ },
114
+ "issueCodes": {
115
+ "type": "array",
116
+ "minItems": 1,
117
+ "items": { "type": "string", "minLength": 1 }
118
+ },
119
+ "rollbackPerformed": { "const": true },
120
+ "rollbackOutcome": { "enum": ["restored", "failed"] },
121
+ "restoredPaths": {
122
+ "type": "array",
123
+ "uniqueItems": true,
124
+ "items": { "type": "string", "minLength": 1 }
125
+ },
126
+ "authorizationGranted": { "const": false }
127
+ }
128
+ }
129
+ }
130
+ }