@ixo/topic-protocol 1.0.0-rc.2 → 1.0.0-rc.4

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 (77) hide show
  1. package/README.md +5 -2
  2. package/dist/profiles/releases/1.0.0-rc.3.json +8442 -0
  3. package/dist/schemas/external-project-snapshot.schema.json +121 -0
  4. package/dist/schemas/external-work-state-map.schema.json +1 -1
  5. package/dist/schemas/project-plan.schema.json +75 -0
  6. package/dist/schemas/project-projection.schema.json +187 -0
  7. package/dist/schemas/topic-contract-body.schema.json +1 -0
  8. package/dist/schemas/topic-operation.schema.json +155 -13
  9. package/dist/schemas/topic-recipe.schema.json +53 -3
  10. package/dist/schemas/topic-root.schema.json +1 -1
  11. package/dist/schemas/topic-shape.schema.json +1 -1
  12. package/dist/schemas/topic-state.schema.json +1 -0
  13. package/dist/src/contracts/schemas.d.ts +734 -54
  14. package/dist/src/contracts/schemas.js +6 -0
  15. package/dist/src/contracts/schemas.js.map +1 -1
  16. package/dist/src/contracts/topic-contract.d.ts +4 -2
  17. package/dist/src/contracts/topic-contract.js +6 -1
  18. package/dist/src/contracts/topic-contract.js.map +1 -1
  19. package/dist/src/contracts/validator.js +53 -3
  20. package/dist/src/contracts/validator.js.map +1 -1
  21. package/dist/src/index.d.ts +11 -2
  22. package/dist/src/index.js +9 -0
  23. package/dist/src/index.js.map +1 -1
  24. package/dist/src/projector/payload.d.ts +53 -3
  25. package/dist/src/projector/payload.js +107 -15
  26. package/dist/src/projector/payload.js.map +1 -1
  27. package/dist/src/projector/project.js +3 -3
  28. package/dist/src/projector/project.js.map +1 -1
  29. package/dist/src/projector/state.d.ts +2 -2
  30. package/dist/src/projector/state.js +103 -3
  31. package/dist/src/projector/state.js.map +1 -1
  32. package/dist/src/projector/types.d.ts +10 -4
  33. package/dist/src/projector/types.js +1 -0
  34. package/dist/src/projector/types.js.map +1 -1
  35. package/dist/src/projects/project.d.ts +7 -0
  36. package/dist/src/projects/project.js +294 -0
  37. package/dist/src/projects/project.js.map +1 -0
  38. package/dist/src/projects/types.d.ts +127 -0
  39. package/dist/src/projects/types.js +14 -0
  40. package/dist/src/projects/types.js.map +1 -0
  41. package/dist/src/shapes/availability.d.ts +2 -0
  42. package/dist/src/shapes/availability.js +19 -0
  43. package/dist/src/shapes/availability.js.map +1 -0
  44. package/dist/src/shapes/commands.d.ts +3 -0
  45. package/dist/src/shapes/commands.js +10 -0
  46. package/dist/src/shapes/commands.js.map +1 -0
  47. package/dist/src/shapes/fields.d.ts +9 -0
  48. package/dist/src/shapes/fields.js +41 -0
  49. package/dist/src/shapes/fields.js.map +1 -0
  50. package/dist/src/shapes/now.js +4 -1
  51. package/dist/src/shapes/now.js.map +1 -1
  52. package/dist/src/shapes/progress.d.ts +5 -1
  53. package/dist/src/shapes/progress.js +99 -49
  54. package/dist/src/shapes/progress.js.map +1 -1
  55. package/dist/src/shapes/reachability.d.ts +3 -0
  56. package/dist/src/shapes/reachability.js +29 -0
  57. package/dist/src/shapes/reachability.js.map +1 -0
  58. package/dist/src/shapes/recipes.js +124 -21
  59. package/dist/src/shapes/recipes.js.map +1 -1
  60. package/dist/src/shapes/releases.d.ts +9 -0
  61. package/dist/src/shapes/releases.js +12 -0
  62. package/dist/src/shapes/releases.js.map +1 -0
  63. package/dist/src/shapes/resolver.d.ts +3 -0
  64. package/dist/src/shapes/resolver.js +62 -16
  65. package/dist/src/shapes/resolver.js.map +1 -1
  66. package/dist/src/shapes/types.d.ts +16 -2
  67. package/dist/src/shapes/types.js +2 -0
  68. package/dist/src/shapes/types.js.map +1 -1
  69. package/dist/src/work-bridge/types.d.ts +14 -1
  70. package/package.json +1 -1
  71. package/profiles/releases/1.0.0-rc.3.json +8442 -0
  72. package/recipes/agent-delivery.json +54 -4
  73. package/recipes/blueprint-design.json +613 -0
  74. package/recipes/registry.json +30 -6
  75. package/recipes/research-brief.json +53 -2
  76. package/recipes/software-build.json +566 -0
  77. package/recipes/verified-work-payment.json +56 -5
@@ -0,0 +1,121 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://topic-protocol.ixo.world/schemas/external-project-snapshot.schema.json",
4
+ "title": "External project snapshot v1",
5
+ "type": "object",
6
+ "required": [
7
+ "version",
8
+ "snapshotId",
9
+ "bindingId",
10
+ "topicId",
11
+ "source",
12
+ "title",
13
+ "workflowState",
14
+ "progress",
15
+ "milestones",
16
+ "sourceCreatedAt",
17
+ "sourceUpdatedAt",
18
+ "retrievedAt",
19
+ "digest"
20
+ ],
21
+ "properties": {
22
+ "version": { "const": 1 },
23
+ "snapshotId": { "$ref": "#/$defs/uuidV7" },
24
+ "bindingId": { "$ref": "#/$defs/uuidV7" },
25
+ "topicId": { "$ref": "#/$defs/topicId" },
26
+ "source": {
27
+ "type": "object",
28
+ "required": ["provider", "organizationId", "resourceId", "identifier", "url"],
29
+ "properties": {
30
+ "provider": { "type": "string", "pattern": "^[a-z][a-z0-9.-]{0,63}$" },
31
+ "organizationId": { "type": "string", "minLength": 1 },
32
+ "teamIds": {
33
+ "type": "array",
34
+ "uniqueItems": true,
35
+ "items": { "type": "string", "minLength": 1 }
36
+ },
37
+ "resourceId": { "type": "string", "minLength": 1 },
38
+ "identifier": { "type": "string", "minLength": 1 },
39
+ "url": { "type": "string", "format": "uri" }
40
+ },
41
+ "additionalProperties": false
42
+ },
43
+ "title": { "type": "string", "minLength": 1, "maxLength": 512 },
44
+ "descriptionMarkdown": { "type": "string", "maxLength": 200000 },
45
+ "workflowState": {
46
+ "type": "object",
47
+ "required": ["id", "name", "category", "mappedWorkState", "mappingProfileId", "mappingVersion"],
48
+ "properties": {
49
+ "id": { "type": "string", "minLength": 1 },
50
+ "name": { "type": "string", "minLength": 1 },
51
+ "category": { "enum": ["triage", "backlog", "unstarted", "started", "completed", "canceled"] },
52
+ "mappedWorkState": { "enum": ["planned", "ready", "in_progress", "blocked", "handoff_ready", "handed_off", "cancelled"] },
53
+ "mappingProfileId": { "type": "string", "format": "uri" },
54
+ "mappingVersion": { "type": "integer", "minimum": 1 }
55
+ },
56
+ "additionalProperties": false
57
+ },
58
+ "lead": { "$ref": "#/$defs/externalActor" },
59
+ "planning": {
60
+ "type": "object",
61
+ "required": ["labels"],
62
+ "properties": {
63
+ "startDate": { "type": "string", "format": "date" },
64
+ "targetDate": { "type": "string", "format": "date" },
65
+ "labels": {
66
+ "type": "array",
67
+ "uniqueItems": true,
68
+ "items": { "type": "string", "minLength": 1 }
69
+ }
70
+ },
71
+ "additionalProperties": false
72
+ },
73
+ "progress": {
74
+ "type": "object",
75
+ "required": ["scope", "completed", "total"],
76
+ "properties": {
77
+ "scope": { "enum": ["provider_reported", "work_items", "observed_page"] },
78
+ "completed": { "type": "integer", "minimum": 0 },
79
+ "total": { "type": "integer", "minimum": 0 },
80
+ "hasMore": { "type": "boolean" }
81
+ },
82
+ "additionalProperties": false
83
+ },
84
+ "milestones": {
85
+ "type": "array",
86
+ "items": {
87
+ "type": "object",
88
+ "required": ["id", "name"],
89
+ "properties": {
90
+ "id": { "type": "string", "minLength": 1 },
91
+ "name": { "type": "string", "minLength": 1 },
92
+ "targetDate": { "type": "string", "format": "date" },
93
+ "status": { "type": "string", "minLength": 1 }
94
+ },
95
+ "additionalProperties": false
96
+ }
97
+ },
98
+ "sourceCreatedAt": { "type": "string", "format": "date-time" },
99
+ "sourceUpdatedAt": { "type": "string", "format": "date-time" },
100
+ "retrievedAt": { "type": "string", "format": "date-time" },
101
+ "sourceEventId": { "type": "string", "minLength": 1 },
102
+ "digest": { "$ref": "#/$defs/digest" },
103
+ "extensions": { "type": "object" }
104
+ },
105
+ "$defs": {
106
+ "uuidV7": { "type": "string", "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-7[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$" },
107
+ "topicId": { "type": "string", "pattern": "^ixo:topic:[0-9a-f]{8}-[0-9a-f]{4}-7[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$" },
108
+ "digest": { "type": "string", "pattern": "^sha256:[0-9a-f]{64}$" },
109
+ "externalActor": {
110
+ "type": "object",
111
+ "required": ["id"],
112
+ "properties": {
113
+ "id": { "type": "string", "minLength": 1 },
114
+ "displayName": { "type": "string", "minLength": 1 },
115
+ "did": { "type": "string", "pattern": "^did:[a-z0-9]+:.+" }
116
+ },
117
+ "additionalProperties": false
118
+ }
119
+ },
120
+ "additionalProperties": false
121
+ }
@@ -3,7 +3,7 @@
3
3
  "$id": "https://topic-protocol.ixo.world/schemas/external-work-state-map.schema.json",
4
4
  "title": "External work state mapping profile v1",
5
5
  "type": "object",
6
- "required": ["version", "profileId", "provider", "organizationId", "teamId", "mappings"],
6
+ "required": ["version", "profileId", "provider", "organizationId", "mappings"],
7
7
  "properties": {
8
8
  "version": { "const": 1 },
9
9
  "profileId": { "type": "string", "format": "uri" },
@@ -0,0 +1,75 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://topic-protocol.ixo.world/schemas/project-plan.schema.json",
4
+ "title": "Project plan v1",
5
+ "type": "object",
6
+ "required": ["version"],
7
+ "properties": {
8
+ "version": { "const": 1 },
9
+ "lead": { "$ref": "#/$defs/subject" },
10
+ "closer": { "$ref": "#/$defs/subject" },
11
+ "milestones": { "type": "array", "items": { "$ref": "#/$defs/milestone" }, "uniqueItemProperty": "id" },
12
+ "childObligations": { "type": "array", "items": { "$ref": "#/$defs/childObligation" }, "uniqueItemProperty": "id" },
13
+ "currentBlockingChildObligationId": { "type": "string", "minLength": 1 },
14
+ "methodManifestRef": { "$ref": "#/$defs/digestRef" },
15
+ "trackerBindings": { "type": "array", "items": { "$ref": "#/$defs/trackerBinding" }, "uniqueItemProperty": "id" }
16
+ },
17
+ "additionalProperties": false,
18
+ "$defs": {
19
+ "digest": { "type": "string", "pattern": "^sha256:[0-9a-f]{64}$" },
20
+ "digestRef": {
21
+ "type": "object",
22
+ "required": ["id", "version", "digest"],
23
+ "properties": {
24
+ "id": { "type": "string", "minLength": 1 },
25
+ "version": { "type": "string", "minLength": 1 },
26
+ "digest": { "$ref": "#/$defs/digest" }
27
+ },
28
+ "additionalProperties": false
29
+ },
30
+ "subject": {
31
+ "type": "object",
32
+ "required": ["kind", "id"],
33
+ "properties": {
34
+ "kind": { "enum": ["actor", "role"] },
35
+ "id": { "type": "string", "minLength": 1 }
36
+ },
37
+ "additionalProperties": false
38
+ },
39
+ "milestone": {
40
+ "type": "object",
41
+ "required": ["id", "name"],
42
+ "properties": {
43
+ "id": { "type": "string", "minLength": 1 },
44
+ "name": { "type": "string", "minLength": 1 },
45
+ "evidenceRequired": { "type": "array", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true }
46
+ },
47
+ "additionalProperties": false
48
+ },
49
+ "childObligation": {
50
+ "type": "object",
51
+ "required": ["id", "title"],
52
+ "properties": {
53
+ "id": { "type": "string", "minLength": 1 },
54
+ "title": { "type": "string", "minLength": 1 },
55
+ "kind": { "enum": ["task", "agent_task", "proposal", "evaluation", "claims", "incident", "question", "discussion"] },
56
+ "topicId": { "type": "string", "pattern": "^ixo:topic:[0-9a-f-]{36}$" }
57
+ },
58
+ "additionalProperties": false
59
+ },
60
+ "trackerBinding": {
61
+ "type": "object",
62
+ "required": ["id", "resourceClass", "role"],
63
+ "properties": {
64
+ "id": { "type": "string", "minLength": 1 },
65
+ "resourceClass": { "enum": ["project", "work-item"] },
66
+ "role": { "enum": ["primary", "supporting", "verification", "delivery"] },
67
+ "provider": { "type": "string", "pattern": "^[a-z][a-z0-9.-]{0,63}$" },
68
+ "resourceType": { "type": "string", "minLength": 1, "maxLength": 80 },
69
+ "bindingId": { "type": "string", "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-7[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$" },
70
+ "label": { "type": "string", "minLength": 1, "maxLength": 160 }
71
+ },
72
+ "additionalProperties": false
73
+ }
74
+ }
75
+ }
@@ -0,0 +1,187 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://topic-protocol.ixo.world/schemas/project-projection.schema.json",
4
+ "title": "Projected Project state v1",
5
+ "type": "object",
6
+ "required": [
7
+ "version",
8
+ "lifecycle",
9
+ "milestones",
10
+ "childObligations"
11
+ ],
12
+ "properties": {
13
+ "version": {
14
+ "const": 1
15
+ },
16
+ "lifecycle": {
17
+ "enum": [
18
+ "proposed",
19
+ "effective",
20
+ "closing",
21
+ "closed"
22
+ ]
23
+ },
24
+ "lead": {
25
+ "type": "object",
26
+ "required": [
27
+ "kind",
28
+ "id"
29
+ ],
30
+ "properties": {
31
+ "kind": {
32
+ "enum": [
33
+ "actor",
34
+ "role"
35
+ ]
36
+ },
37
+ "id": {
38
+ "type": "string",
39
+ "minLength": 1
40
+ }
41
+ },
42
+ "additionalProperties": false
43
+ },
44
+ "closer": {
45
+ "type": "object",
46
+ "required": [
47
+ "kind",
48
+ "id"
49
+ ],
50
+ "properties": {
51
+ "kind": {
52
+ "enum": [
53
+ "actor",
54
+ "role"
55
+ ]
56
+ },
57
+ "id": {
58
+ "type": "string",
59
+ "minLength": 1
60
+ }
61
+ },
62
+ "additionalProperties": false
63
+ },
64
+ "milestones": {
65
+ "type": "array",
66
+ "items": {
67
+ "type": "object",
68
+ "required": [
69
+ "id",
70
+ "name",
71
+ "status",
72
+ "evidenceRefs"
73
+ ],
74
+ "properties": {
75
+ "id": {
76
+ "type": "string"
77
+ },
78
+ "name": {
79
+ "type": "string"
80
+ },
81
+ "status": {
82
+ "enum": [
83
+ "pending",
84
+ "in-progress",
85
+ "met",
86
+ "waived"
87
+ ]
88
+ },
89
+ "evidenceRequired": {
90
+ "type": "array",
91
+ "items": {
92
+ "type": "string"
93
+ }
94
+ },
95
+ "evidenceRefs": {
96
+ "type": "array",
97
+ "items": {
98
+ "type": "string"
99
+ }
100
+ },
101
+ "lastOperationId": {
102
+ "type": "string"
103
+ }
104
+ },
105
+ "additionalProperties": false
106
+ },
107
+ "uniqueItemProperty": "id"
108
+ },
109
+ "childObligations": {
110
+ "type": "array",
111
+ "items": {
112
+ "type": "object",
113
+ "required": [
114
+ "id",
115
+ "title",
116
+ "status"
117
+ ],
118
+ "properties": {
119
+ "id": {
120
+ "type": "string"
121
+ },
122
+ "title": {
123
+ "type": "string"
124
+ },
125
+ "kind": {
126
+ "enum": [
127
+ "task",
128
+ "agent_task",
129
+ "proposal",
130
+ "evaluation",
131
+ "claims",
132
+ "incident",
133
+ "question",
134
+ "discussion"
135
+ ]
136
+ },
137
+ "topicId": {
138
+ "type": "string"
139
+ },
140
+ "status": {
141
+ "enum": [
142
+ "unmet",
143
+ "linked",
144
+ "complete",
145
+ "waived"
146
+ ]
147
+ },
148
+ "childRevision": {
149
+ "type": "string"
150
+ },
151
+ "childShapeDigest": {
152
+ "type": "string",
153
+ "pattern": "^sha256:[0-9a-f]{64}$"
154
+ },
155
+ "sourceEventId": {
156
+ "type": "string"
157
+ },
158
+ "lastOperationId": {
159
+ "type": "string"
160
+ },
161
+ "waiverReason": {
162
+ "type": "string",
163
+ "minLength": 1
164
+ }
165
+ },
166
+ "additionalProperties": false
167
+ },
168
+ "uniqueItemProperty": "id"
169
+ },
170
+ "currentBlockingChildObligationId": {
171
+ "type": "string"
172
+ },
173
+ "methodManifestRef": {
174
+ "type": "object"
175
+ },
176
+ "closeRequest": {
177
+ "type": "object"
178
+ },
179
+ "closeAcceptance": {
180
+ "type": "object"
181
+ },
182
+ "sourceContractRevision": {
183
+ "type": "string"
184
+ }
185
+ },
186
+ "additionalProperties": false
187
+ }
@@ -29,6 +29,7 @@
29
29
  "outcome": { "type": "object" },
30
30
  "completion": { "type": "object" },
31
31
  "ownerId": { "type": "string" },
32
+ "project": { "$ref": "https://topic-protocol.ixo.world/schemas/project-plan.schema.json" },
32
33
  "scope": { "type": "object" },
33
34
  "constraints": { "type": "array", "items": { "type": "object" } },
34
35
  "assumptions": { "type": "array", "items": { "type": "object" } },
@@ -3,28 +3,170 @@
3
3
  "$id": "https://topic-protocol.ixo.world/schemas/topic-operation.schema.json",
4
4
  "title": "Topic operation",
5
5
  "type": "object",
6
- "required": ["version", "operationId", "topicId", "type", "previousRevision", "actor", "createdAt", "payload"],
6
+ "required": [
7
+ "version",
8
+ "operationId",
9
+ "topicId",
10
+ "type",
11
+ "previousRevision",
12
+ "actor",
13
+ "createdAt",
14
+ "payload"
15
+ ],
7
16
  "properties": {
8
- "version": { "enum": [1, 2] },
9
- "operationId": { "type": "string", "minLength": 1 },
10
- "topicId": { "type": "string", "pattern": "^ixo:topic:[0-9a-f]{8}-[0-9a-f]{4}-7[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$" },
11
- "type": { "type": "string", "enum": ["rename", "change-status", "update-overview", "link-context", "unlink-context", "attach-files", "detach-files", "record-decision", "record-outcome", "propose-contract", "update-contract", "accept-contract", "confirm-setup", "withdraw-setup-confirmation", "record-assent", "withdraw-assent", "raise-dispute", "resolve-dispute", "supersede-contract", "bind-automation", "update-automation", "pause-automation", "remove-automation", "bind-flow", "update-flow-binding", "unbind-flow", "request-action", "cancel-action", "record-action-receipt", "bind-external-work", "sync-external-work", "unlink-external-work", "submit-delivery", "record-delivery-decision", "record-evaluation", "record-approval", "record-claim", "record-settlement", "redirect", "branch", "merge", "resolve-conflict"] },
12
- "previousRevision": { "type": "string", "minLength": 1 },
13
- "actor": { "type": "string", "minLength": 1 },
14
- "createdAt": { "type": "string", "format": "date-time" },
15
- "payload": { "type": "object" },
16
- "capability": { "type": "string" }
17
+ "version": {
18
+ "enum": [
19
+ 1,
20
+ 2
21
+ ]
22
+ },
23
+ "operationId": {
24
+ "type": "string",
25
+ "minLength": 1
26
+ },
27
+ "topicId": {
28
+ "type": "string",
29
+ "pattern": "^ixo:topic:[0-9a-f]{8}-[0-9a-f]{4}-7[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
30
+ },
31
+ "type": {
32
+ "type": "string",
33
+ "enum": [
34
+ "rename",
35
+ "change-status",
36
+ "change-progress",
37
+ "answer-question",
38
+ "change-due-date",
39
+ "unblock-topic",
40
+ "complete-topic",
41
+ "update-overview",
42
+ "link-context",
43
+ "unlink-context",
44
+ "attach-files",
45
+ "detach-files",
46
+ "record-decision",
47
+ "record-outcome",
48
+ "propose-contract",
49
+ "update-contract",
50
+ "accept-contract",
51
+ "confirm-setup",
52
+ "withdraw-setup-confirmation",
53
+ "record-assent",
54
+ "withdraw-assent",
55
+ "raise-dispute",
56
+ "resolve-dispute",
57
+ "supersede-contract",
58
+ "bind-automation",
59
+ "update-automation",
60
+ "pause-automation",
61
+ "remove-automation",
62
+ "bind-flow",
63
+ "update-flow-binding",
64
+ "unbind-flow",
65
+ "request-action",
66
+ "cancel-action",
67
+ "record-action-receipt",
68
+ "bind-external-work",
69
+ "sync-external-work",
70
+ "unlink-external-work",
71
+ "submit-delivery",
72
+ "record-delivery-decision",
73
+ "record-evaluation",
74
+ "record-approval",
75
+ "record-claim",
76
+ "record-settlement",
77
+ "record-project-milestone",
78
+ "link-project-child",
79
+ "unlink-project-child",
80
+ "record-project-child-status",
81
+ "waive-project-child",
82
+ "set-project-blocker",
83
+ "request-project-close",
84
+ "close-project",
85
+ "redirect",
86
+ "branch",
87
+ "merge",
88
+ "resolve-conflict",
89
+ "record-review"
90
+ ]
91
+ },
92
+ "previousRevision": {
93
+ "type": "string",
94
+ "minLength": 1
95
+ },
96
+ "actor": {
97
+ "type": "string",
98
+ "minLength": 1
99
+ },
100
+ "createdAt": {
101
+ "type": "string",
102
+ "format": "date-time"
103
+ },
104
+ "payload": {
105
+ "type": "object"
106
+ },
107
+ "capability": {
108
+ "type": "string"
109
+ }
17
110
  },
18
111
  "additionalProperties": true,
19
112
  "allOf": [
20
113
  {
21
114
  "if": {
22
115
  "properties": {
23
- "type": { "enum": ["record-outcome", "propose-contract", "update-contract", "accept-contract", "confirm-setup", "withdraw-setup-confirmation", "record-assent", "withdraw-assent", "raise-dispute", "resolve-dispute", "supersede-contract", "bind-automation", "update-automation", "pause-automation", "remove-automation", "bind-flow", "update-flow-binding", "unbind-flow", "request-action", "cancel-action", "record-action-receipt", "bind-external-work", "sync-external-work", "unlink-external-work", "submit-delivery", "record-delivery-decision", "record-evaluation", "record-approval", "record-claim", "record-settlement"] }
116
+ "type": {
117
+ "enum": [
118
+ "record-outcome",
119
+ "propose-contract",
120
+ "update-contract",
121
+ "accept-contract",
122
+ "confirm-setup",
123
+ "withdraw-setup-confirmation",
124
+ "record-assent",
125
+ "withdraw-assent",
126
+ "raise-dispute",
127
+ "resolve-dispute",
128
+ "supersede-contract",
129
+ "bind-automation",
130
+ "update-automation",
131
+ "pause-automation",
132
+ "remove-automation",
133
+ "bind-flow",
134
+ "update-flow-binding",
135
+ "unbind-flow",
136
+ "request-action",
137
+ "cancel-action",
138
+ "record-action-receipt",
139
+ "bind-external-work",
140
+ "sync-external-work",
141
+ "unlink-external-work",
142
+ "submit-delivery",
143
+ "record-delivery-decision",
144
+ "record-evaluation",
145
+ "record-approval",
146
+ "record-claim",
147
+ "record-settlement",
148
+ "record-project-milestone",
149
+ "link-project-child",
150
+ "unlink-project-child",
151
+ "record-project-child-status",
152
+ "waive-project-child",
153
+ "set-project-blocker",
154
+ "request-project-close",
155
+ "close-project"
156
+ ]
157
+ }
24
158
  },
25
- "required": ["type"]
159
+ "required": [
160
+ "type"
161
+ ]
26
162
  },
27
- "then": { "properties": { "version": { "const": 2 } } }
163
+ "then": {
164
+ "properties": {
165
+ "version": {
166
+ "const": 2
167
+ }
168
+ }
169
+ }
28
170
  }
29
171
  ]
30
172
  }
@@ -6,14 +6,64 @@
6
6
  "required": ["version", "code", "id", "recipeVersion", "label", "description", "baseRecipe", "creates", "shape"],
7
7
  "properties": {
8
8
  "version": { "const": 1 },
9
- "code": { "enum": ["research-brief", "agent-delivery", "verified-work-payment"] },
9
+ "code": { "enum": ["research-brief", "agent-delivery", "verified-work-payment", "software-build", "blueprint-design"] },
10
10
  "id": { "type": "string", "format": "uri" },
11
11
  "recipeVersion": { "type": "string", "minLength": 1 },
12
12
  "label": { "type": "string", "minLength": 1 },
13
13
  "description": { "type": "string", "minLength": 1 },
14
14
  "baseRecipe": { "enum": ["project", "flow", "proposal", "evaluation", "claims", "research", "discussion", "incident"] },
15
15
  "creates": { "const": "draft" },
16
- "shape": { "$ref": "https://topic-protocol.ixo.world/schemas/topic-shape.schema.json" }
16
+ "shape": { "$ref": "https://topic-protocol.ixo.world/schemas/topic-shape.schema.json" },
17
+ "project": { "$ref": "#/$defs/projectRecipe" }
17
18
  },
18
- "additionalProperties": false
19
+ "additionalProperties": false,
20
+ "allOf": [
21
+ {
22
+ "if": { "properties": { "code": { "enum": ["software-build", "blueprint-design"] } }, "required": ["code"] },
23
+ "then": { "properties": { "baseRecipe": { "const": "project" }, "project": true }, "required": ["project"] }
24
+ }
25
+ ],
26
+ "$defs": {
27
+ "childKind": { "enum": ["task", "agent_task", "proposal", "evaluation", "claims", "incident", "question", "discussion"] },
28
+ "digestRef": { "type": "object", "required": ["id", "version", "digest"], "properties": { "id": { "type": "string", "minLength": 1 }, "version": { "type": "string", "minLength": 1 }, "digest": { "type": "string", "pattern": "^sha256:[0-9a-f]{64}$" } }, "additionalProperties": false },
29
+ "entryPoint": {
30
+ "type": "object",
31
+ "required": ["code", "label", "kind", "target", "suggestedChildKinds", "requiresReview"],
32
+ "properties": {
33
+ "code": { "type": "string", "minLength": 1 },
34
+ "label": { "type": "string", "minLength": 1 },
35
+ "kind": { "enum": ["action", "flow"] },
36
+ "target": { "type": "string", "minLength": 1 },
37
+ "suggestedChildKinds": { "type": "array", "items": { "$ref": "#/$defs/childKind" }, "uniqueItems": true },
38
+ "requiresReview": { "const": true }
39
+ },
40
+ "additionalProperties": false
41
+ },
42
+ "milestoneSuggestion": {
43
+ "type": "object",
44
+ "required": ["code", "label", "provenance", "requiresAcceptance"],
45
+ "properties": {
46
+ "code": { "type": "string", "minLength": 1 },
47
+ "label": { "type": "string", "minLength": 1 },
48
+ "provenance": { "const": "recipe" },
49
+ "requiresAcceptance": { "const": true }
50
+ },
51
+ "additionalProperties": false
52
+ },
53
+ "projectRecipe": {
54
+ "type": "object",
55
+ "required": ["version", "compatibleKind", "compatibleShapeVersion", "allowedChildKinds", "entryPoints", "milestoneSuggestions"],
56
+ "properties": {
57
+ "version": { "const": 1 },
58
+ "compatibleKind": { "const": "project" },
59
+ "compatibleShapeVersion": { "const": 1 },
60
+ "methodManifestRef": { "$ref": "#/$defs/digestRef" },
61
+ "allowedChildKinds": { "type": "array", "items": { "$ref": "#/$defs/childKind" }, "uniqueItems": true },
62
+ "entryPoints": { "type": "array", "items": { "$ref": "#/$defs/entryPoint" } },
63
+ "milestoneSuggestions": { "type": "array", "items": { "$ref": "#/$defs/milestoneSuggestion" } },
64
+ "requiredCloseEvidenceTypes": { "type": "array", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true }
65
+ },
66
+ "additionalProperties": false
67
+ }
68
+ }
19
69
  }