@opensoftware/contracts 2.3.0 → 2.4.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.
- package/README.md +8 -5
- package/dist/formats.js +4 -0
- package/dist/formats.js.map +1 -1
- package/dist/generated/types.d.ts +489 -8
- package/dist/index.d.ts +9 -0
- package/dist/index.js.map +1 -1
- package/events/asyncapi.yaml +63 -0
- package/events/doctor-ping/doctor-ping.schema.json +62 -0
- package/events/run-blocked/run-blocked.schema.json +138 -0
- package/events/run-completed/run-completed.schema.json +10 -0
- package/events/run-started/run-started.schema.json +6 -0
- package/events/work-retry-requested/work-retry-requested.schema.json +106 -0
- package/factory-definition/factory-definition.schema.json +5 -1
- package/factory-lock/factory-lock.schema.json +111 -0
- package/openapi/openapi.json +844 -12
- package/package.json +2 -2
- package/typespec/events.tsp +58 -0
- package/typespec/factory-definition.tsp +7 -1
- package/typespec/factory-lock.tsp +56 -0
- package/typespec/foreman-api.tsp +32 -3
- package/typespec/foreman.tsp +99 -3
- package/typespec/gatekeeper-api.tsp +14 -0
- package/typespec/gatekeeper.tsp +15 -0
- package/typespec/intake-api.tsp +9 -2
- package/typespec/intake.tsp +4 -0
- package/typespec/main.tsp +1 -0
package/openapi/openapi.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"openapi": "3.1.0",
|
|
3
3
|
"info": {
|
|
4
4
|
"title": "Open Software Factory contracts",
|
|
5
|
-
"version": "2.
|
|
5
|
+
"version": "2.4.0",
|
|
6
6
|
"description": "The shared formats as named models, and the HTTP APIs of the modules. Generated by `pnpm build` in contracts/ from typespec/. Do not edit.",
|
|
7
7
|
"license": {
|
|
8
8
|
"name": "Apache-2.0",
|
|
@@ -10,6 +10,54 @@
|
|
|
10
10
|
}
|
|
11
11
|
},
|
|
12
12
|
"paths": {
|
|
13
|
+
"/v1/doctor/pings/{id}": {
|
|
14
|
+
"get": {
|
|
15
|
+
"operationId": "ForemanApi_getDoctorPing",
|
|
16
|
+
"description": "The `doctor.ping@v1` event with this ID, when the foreman's consumer received it since the server started (ADR\n0120). `console doctor --deep` asks for it after it published the event.",
|
|
17
|
+
"parameters": [
|
|
18
|
+
{
|
|
19
|
+
"name": "id",
|
|
20
|
+
"in": "path",
|
|
21
|
+
"required": true,
|
|
22
|
+
"schema": {
|
|
23
|
+
"type": "string"
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
],
|
|
27
|
+
"responses": {
|
|
28
|
+
"200": {
|
|
29
|
+
"description": "The request has succeeded.",
|
|
30
|
+
"content": {
|
|
31
|
+
"application/json": {
|
|
32
|
+
"schema": {
|
|
33
|
+
"$ref": "#/components/schemas/DoctorPingSeen"
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
},
|
|
38
|
+
"401": {
|
|
39
|
+
"description": "Access is unauthorized.",
|
|
40
|
+
"content": {
|
|
41
|
+
"application/problem+json": {
|
|
42
|
+
"schema": {
|
|
43
|
+
"$ref": "#/components/schemas/ApiProblem"
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"404": {
|
|
49
|
+
"description": "The server cannot find the requested resource.",
|
|
50
|
+
"content": {
|
|
51
|
+
"application/problem+json": {
|
|
52
|
+
"schema": {
|
|
53
|
+
"$ref": "#/components/schemas/ApiProblem"
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
},
|
|
13
61
|
"/v1/gates": {
|
|
14
62
|
"post": {
|
|
15
63
|
"operationId": "GatekeeperApi_requestGate",
|
|
@@ -117,6 +165,94 @@
|
|
|
117
165
|
}
|
|
118
166
|
}
|
|
119
167
|
},
|
|
168
|
+
"/v1/gates/{gateId}/decisions": {
|
|
169
|
+
"post": {
|
|
170
|
+
"operationId": "GatekeeperApi_decideGate",
|
|
171
|
+
"description": "A person decides a pending gate (ADR 0118): 403 when they are in no group the gate waits for, 409 when the gate\nis no longer pending.",
|
|
172
|
+
"parameters": [
|
|
173
|
+
{
|
|
174
|
+
"name": "gateId",
|
|
175
|
+
"in": "path",
|
|
176
|
+
"required": true,
|
|
177
|
+
"schema": {
|
|
178
|
+
"type": "string"
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
],
|
|
182
|
+
"responses": {
|
|
183
|
+
"200": {
|
|
184
|
+
"description": "The request has succeeded.",
|
|
185
|
+
"content": {
|
|
186
|
+
"application/json": {
|
|
187
|
+
"schema": {
|
|
188
|
+
"$ref": "#/components/schemas/GateView"
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
},
|
|
193
|
+
"400": {
|
|
194
|
+
"description": "The server could not understand the request due to invalid syntax.",
|
|
195
|
+
"content": {
|
|
196
|
+
"application/problem+json": {
|
|
197
|
+
"schema": {
|
|
198
|
+
"$ref": "#/components/schemas/ApiProblem"
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
},
|
|
203
|
+
"401": {
|
|
204
|
+
"description": "Access is unauthorized.",
|
|
205
|
+
"content": {
|
|
206
|
+
"application/problem+json": {
|
|
207
|
+
"schema": {
|
|
208
|
+
"$ref": "#/components/schemas/ApiProblem"
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
},
|
|
213
|
+
"403": {
|
|
214
|
+
"description": "Access is forbidden.",
|
|
215
|
+
"content": {
|
|
216
|
+
"application/problem+json": {
|
|
217
|
+
"schema": {
|
|
218
|
+
"$ref": "#/components/schemas/ApiProblem"
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
},
|
|
223
|
+
"404": {
|
|
224
|
+
"description": "The server cannot find the requested resource.",
|
|
225
|
+
"content": {
|
|
226
|
+
"application/problem+json": {
|
|
227
|
+
"schema": {
|
|
228
|
+
"$ref": "#/components/schemas/ApiProblem"
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
},
|
|
233
|
+
"409": {
|
|
234
|
+
"description": "The request conflicts with the current state of the server.",
|
|
235
|
+
"content": {
|
|
236
|
+
"application/problem+json": {
|
|
237
|
+
"schema": {
|
|
238
|
+
"$ref": "#/components/schemas/ApiProblem"
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
}
|
|
243
|
+
},
|
|
244
|
+
"requestBody": {
|
|
245
|
+
"required": true,
|
|
246
|
+
"content": {
|
|
247
|
+
"application/json": {
|
|
248
|
+
"schema": {
|
|
249
|
+
"$ref": "#/components/schemas/GateDecisionRequest"
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
},
|
|
120
256
|
"/v1/health": {
|
|
121
257
|
"get": {
|
|
122
258
|
"operationId": "HealthApi_getHealth",
|
|
@@ -152,7 +288,7 @@
|
|
|
152
288
|
"/v1/inbox": {
|
|
153
289
|
"get": {
|
|
154
290
|
"operationId": "IntakeApi_listWorkItems",
|
|
155
|
-
"description": "
|
|
291
|
+
"description": "A page of the latest work items, the one received last first; with `status`, only the work items in that status.\n`limit` work items at most, 50 by default; `cursor` is the `next` of the page before (ADR 0115).",
|
|
156
292
|
"parameters": [
|
|
157
293
|
{
|
|
158
294
|
"name": "status",
|
|
@@ -162,6 +298,28 @@
|
|
|
162
298
|
"$ref": "#/components/schemas/WorkItemStatus"
|
|
163
299
|
},
|
|
164
300
|
"explode": false
|
|
301
|
+
},
|
|
302
|
+
{
|
|
303
|
+
"name": "limit",
|
|
304
|
+
"in": "query",
|
|
305
|
+
"required": false,
|
|
306
|
+
"schema": {
|
|
307
|
+
"type": "integer",
|
|
308
|
+
"format": "int32",
|
|
309
|
+
"minimum": 1,
|
|
310
|
+
"maximum": 500
|
|
311
|
+
},
|
|
312
|
+
"explode": false
|
|
313
|
+
},
|
|
314
|
+
{
|
|
315
|
+
"name": "cursor",
|
|
316
|
+
"in": "query",
|
|
317
|
+
"required": false,
|
|
318
|
+
"schema": {
|
|
319
|
+
"type": "string",
|
|
320
|
+
"minLength": 1
|
|
321
|
+
},
|
|
322
|
+
"explode": false
|
|
165
323
|
}
|
|
166
324
|
],
|
|
167
325
|
"responses": {
|
|
@@ -201,7 +359,7 @@
|
|
|
201
359
|
"/v1/runs": {
|
|
202
360
|
"post": {
|
|
203
361
|
"operationId": "ForemanApi_startRun",
|
|
204
|
-
"description": "Start a run of the factory's workflow for a work item. The same work item again answers
|
|
362
|
+
"description": "Start a run of the factory's workflow for a work item. The same work item again answers its newest run.",
|
|
205
363
|
"parameters": [],
|
|
206
364
|
"responses": {
|
|
207
365
|
"200": {
|
|
@@ -258,7 +416,7 @@
|
|
|
258
416
|
},
|
|
259
417
|
"get": {
|
|
260
418
|
"operationId": "ForemanApi_listRuns",
|
|
261
|
-
"description": "
|
|
419
|
+
"description": "A page of the runs of the server, running runs first, then the runs that ended, the one that ended last first; with\n`state`, only the runs in that state (ADR 0071). `limit` runs at most, 50 by default; `cursor` is the `next` of the\npage before (ADR 0115). With `state`, a page may hold fewer runs than `limit` and still have a `next`.",
|
|
262
420
|
"parameters": [
|
|
263
421
|
{
|
|
264
422
|
"name": "state",
|
|
@@ -268,6 +426,28 @@
|
|
|
268
426
|
"$ref": "#/components/schemas/RunState"
|
|
269
427
|
},
|
|
270
428
|
"explode": false
|
|
429
|
+
},
|
|
430
|
+
{
|
|
431
|
+
"name": "limit",
|
|
432
|
+
"in": "query",
|
|
433
|
+
"required": false,
|
|
434
|
+
"schema": {
|
|
435
|
+
"type": "integer",
|
|
436
|
+
"format": "int32",
|
|
437
|
+
"minimum": 1,
|
|
438
|
+
"maximum": 500
|
|
439
|
+
},
|
|
440
|
+
"explode": false
|
|
441
|
+
},
|
|
442
|
+
{
|
|
443
|
+
"name": "cursor",
|
|
444
|
+
"in": "query",
|
|
445
|
+
"required": false,
|
|
446
|
+
"schema": {
|
|
447
|
+
"type": "string",
|
|
448
|
+
"minLength": 1
|
|
449
|
+
},
|
|
450
|
+
"explode": false
|
|
271
451
|
}
|
|
272
452
|
],
|
|
273
453
|
"responses": {
|
|
@@ -352,6 +532,84 @@
|
|
|
352
532
|
}
|
|
353
533
|
}
|
|
354
534
|
},
|
|
535
|
+
"/v1/runs/{runId}/retry": {
|
|
536
|
+
"post": {
|
|
537
|
+
"operationId": "ForemanApi_retryRun",
|
|
538
|
+
"description": "Run a run that failed or was cancelled again, as a new run that names it (ADR 0105).",
|
|
539
|
+
"parameters": [
|
|
540
|
+
{
|
|
541
|
+
"name": "runId",
|
|
542
|
+
"in": "path",
|
|
543
|
+
"required": true,
|
|
544
|
+
"schema": {
|
|
545
|
+
"type": "string"
|
|
546
|
+
}
|
|
547
|
+
}
|
|
548
|
+
],
|
|
549
|
+
"responses": {
|
|
550
|
+
"201": {
|
|
551
|
+
"description": "The request has succeeded and a new resource has been created as a result.",
|
|
552
|
+
"content": {
|
|
553
|
+
"application/json": {
|
|
554
|
+
"schema": {
|
|
555
|
+
"$ref": "#/components/schemas/RunView"
|
|
556
|
+
}
|
|
557
|
+
}
|
|
558
|
+
}
|
|
559
|
+
},
|
|
560
|
+
"400": {
|
|
561
|
+
"description": "The server could not understand the request due to invalid syntax.",
|
|
562
|
+
"content": {
|
|
563
|
+
"application/problem+json": {
|
|
564
|
+
"schema": {
|
|
565
|
+
"$ref": "#/components/schemas/ApiProblem"
|
|
566
|
+
}
|
|
567
|
+
}
|
|
568
|
+
}
|
|
569
|
+
},
|
|
570
|
+
"401": {
|
|
571
|
+
"description": "Access is unauthorized.",
|
|
572
|
+
"content": {
|
|
573
|
+
"application/problem+json": {
|
|
574
|
+
"schema": {
|
|
575
|
+
"$ref": "#/components/schemas/ApiProblem"
|
|
576
|
+
}
|
|
577
|
+
}
|
|
578
|
+
}
|
|
579
|
+
},
|
|
580
|
+
"404": {
|
|
581
|
+
"description": "The server cannot find the requested resource.",
|
|
582
|
+
"content": {
|
|
583
|
+
"application/problem+json": {
|
|
584
|
+
"schema": {
|
|
585
|
+
"$ref": "#/components/schemas/ApiProblem"
|
|
586
|
+
}
|
|
587
|
+
}
|
|
588
|
+
}
|
|
589
|
+
},
|
|
590
|
+
"409": {
|
|
591
|
+
"description": "The request conflicts with the current state of the server.",
|
|
592
|
+
"content": {
|
|
593
|
+
"application/problem+json": {
|
|
594
|
+
"schema": {
|
|
595
|
+
"$ref": "#/components/schemas/ApiProblem"
|
|
596
|
+
}
|
|
597
|
+
}
|
|
598
|
+
}
|
|
599
|
+
}
|
|
600
|
+
},
|
|
601
|
+
"requestBody": {
|
|
602
|
+
"required": true,
|
|
603
|
+
"content": {
|
|
604
|
+
"application/json": {
|
|
605
|
+
"schema": {
|
|
606
|
+
"$ref": "#/components/schemas/RunRetry"
|
|
607
|
+
}
|
|
608
|
+
}
|
|
609
|
+
}
|
|
610
|
+
}
|
|
611
|
+
}
|
|
612
|
+
},
|
|
355
613
|
"/v1/runs/{runId}/signals": {
|
|
356
614
|
"post": {
|
|
357
615
|
"operationId": "ForemanApi_signalRun",
|
|
@@ -632,6 +890,58 @@
|
|
|
632
890
|
],
|
|
633
891
|
"description": "Who caused something: a person, or an automated trigger such as a cron rule or an alert."
|
|
634
892
|
},
|
|
893
|
+
"AdapterVersion": {
|
|
894
|
+
"type": "object",
|
|
895
|
+
"properties": {
|
|
896
|
+
"port": {
|
|
897
|
+
"anyOf": [
|
|
898
|
+
{
|
|
899
|
+
"type": "string",
|
|
900
|
+
"const": "harness"
|
|
901
|
+
},
|
|
902
|
+
{
|
|
903
|
+
"type": "string",
|
|
904
|
+
"const": "sandbox"
|
|
905
|
+
},
|
|
906
|
+
{
|
|
907
|
+
"type": "string",
|
|
908
|
+
"const": "forge"
|
|
909
|
+
},
|
|
910
|
+
{
|
|
911
|
+
"type": "string",
|
|
912
|
+
"const": "inference"
|
|
913
|
+
}
|
|
914
|
+
],
|
|
915
|
+
"description": "The port under `providers`: harness, sandbox, forge or inference."
|
|
916
|
+
},
|
|
917
|
+
"name": {
|
|
918
|
+
"type": "string",
|
|
919
|
+
"minLength": 1
|
|
920
|
+
},
|
|
921
|
+
"version": {
|
|
922
|
+
"type": "string",
|
|
923
|
+
"minLength": 1,
|
|
924
|
+
"description": "The exact version that factory.lock pins for the range under `providers.<port>.<name>`, else that range (ADR 0125)."
|
|
925
|
+
},
|
|
926
|
+
"command": {
|
|
927
|
+
"type": "array",
|
|
928
|
+
"items": {
|
|
929
|
+
"type": "string"
|
|
930
|
+
},
|
|
931
|
+
"description": "The command line the foreman builds when no map names the adapter: npx at the version."
|
|
932
|
+
},
|
|
933
|
+
"configured": {
|
|
934
|
+
"type": "string",
|
|
935
|
+
"minLength": 1,
|
|
936
|
+
"description": "The variable whose map gives the adapter's command line instead, for example \"FOREMAN_HARNESSES\"."
|
|
937
|
+
}
|
|
938
|
+
},
|
|
939
|
+
"required": [
|
|
940
|
+
"port",
|
|
941
|
+
"name"
|
|
942
|
+
],
|
|
943
|
+
"description": "foreman: a run of the factory's workflow for one work item, as the HTTP API shows it (ADR 0067).An adapter of the factory's `providers` and the version a run of it asks for (ADR 0110)."
|
|
944
|
+
},
|
|
635
945
|
"Agent": {
|
|
636
946
|
"type": "object",
|
|
637
947
|
"properties": {
|
|
@@ -824,6 +1134,13 @@
|
|
|
824
1134
|
],
|
|
825
1135
|
"additionalProperties": false
|
|
826
1136
|
},
|
|
1137
|
+
"BlockedOn": {
|
|
1138
|
+
"type": "string",
|
|
1139
|
+
"enum": [
|
|
1140
|
+
"checks"
|
|
1141
|
+
],
|
|
1142
|
+
"description": "What a blocked stage waits for: the checks of the run's pull request. A gate has its own `gate.requested@v1`."
|
|
1143
|
+
},
|
|
827
1144
|
"BundlePath": {
|
|
828
1145
|
"type": "string",
|
|
829
1146
|
"pattern": "^(?!/)(?!.*(^|/)\\.\\.(/|$))[^\\\\]+$",
|
|
@@ -865,6 +1182,84 @@
|
|
|
865
1182
|
"pattern": "^[0-9a-f]{7,40}$",
|
|
866
1183
|
"description": "A Git commit hash, abbreviated (7+) or full. The factory version is the commit of the factory definition."
|
|
867
1184
|
},
|
|
1185
|
+
"DoctorPing": {
|
|
1186
|
+
"type": "object",
|
|
1187
|
+
"properties": {
|
|
1188
|
+
"specversion": {
|
|
1189
|
+
"type": "string",
|
|
1190
|
+
"const": "1.0"
|
|
1191
|
+
},
|
|
1192
|
+
"id": {
|
|
1193
|
+
"$ref": "#/components/schemas/Identifier",
|
|
1194
|
+
"description": "Unique per source. A consumer that sees the same source and id twice handles the event once."
|
|
1195
|
+
},
|
|
1196
|
+
"source": {
|
|
1197
|
+
"type": "string",
|
|
1198
|
+
"minLength": 1,
|
|
1199
|
+
"description": "The producing module, for example \"/osf/intake\"."
|
|
1200
|
+
},
|
|
1201
|
+
"type": {
|
|
1202
|
+
"type": "string",
|
|
1203
|
+
"const": "doctor.ping@v1"
|
|
1204
|
+
},
|
|
1205
|
+
"time": {
|
|
1206
|
+
"type": "string",
|
|
1207
|
+
"format": "date-time"
|
|
1208
|
+
},
|
|
1209
|
+
"subject": {
|
|
1210
|
+
"type": "string",
|
|
1211
|
+
"description": "The ID of the thing the event is about: work item, gate, run, score or pull request."
|
|
1212
|
+
},
|
|
1213
|
+
"datacontenttype": {
|
|
1214
|
+
"type": "string",
|
|
1215
|
+
"const": "application/json"
|
|
1216
|
+
},
|
|
1217
|
+
"dataschema": {
|
|
1218
|
+
"type": "string",
|
|
1219
|
+
"format": "uri"
|
|
1220
|
+
},
|
|
1221
|
+
"traceparent": {
|
|
1222
|
+
"type": "string",
|
|
1223
|
+
"description": "W3C trace context (CloudEvents distributed tracing extension)."
|
|
1224
|
+
},
|
|
1225
|
+
"data": {
|
|
1226
|
+
"$ref": "#/components/schemas/DoctorPingData"
|
|
1227
|
+
}
|
|
1228
|
+
},
|
|
1229
|
+
"required": [
|
|
1230
|
+
"specversion",
|
|
1231
|
+
"id",
|
|
1232
|
+
"source",
|
|
1233
|
+
"type",
|
|
1234
|
+
"time",
|
|
1235
|
+
"data"
|
|
1236
|
+
],
|
|
1237
|
+
"description": "console: `console doctor --deep` checks that an event reaches the foreman (ADR 0120). The ID is fresh and random;\nthe foreman shows it on `GET /v1/doctor/pings/{id}` and acts on nothing else."
|
|
1238
|
+
},
|
|
1239
|
+
"DoctorPingData": {
|
|
1240
|
+
"type": "object",
|
|
1241
|
+
"properties": {},
|
|
1242
|
+
"description": "A ping carries nothing but its ID."
|
|
1243
|
+
},
|
|
1244
|
+
"DoctorPingSeen": {
|
|
1245
|
+
"type": "object",
|
|
1246
|
+
"properties": {
|
|
1247
|
+
"id": {
|
|
1248
|
+
"$ref": "#/components/schemas/Identifier",
|
|
1249
|
+
"description": "The event's ID."
|
|
1250
|
+
},
|
|
1251
|
+
"receivedAt": {
|
|
1252
|
+
"type": "string",
|
|
1253
|
+
"format": "date-time",
|
|
1254
|
+
"description": "When the foreman received it."
|
|
1255
|
+
}
|
|
1256
|
+
},
|
|
1257
|
+
"required": [
|
|
1258
|
+
"id",
|
|
1259
|
+
"receivedAt"
|
|
1260
|
+
],
|
|
1261
|
+
"description": "foreman: a `doctor.ping@v1` event that its consumer received (ADR 0120)."
|
|
1262
|
+
},
|
|
868
1263
|
"Effort": {
|
|
869
1264
|
"type": "string",
|
|
870
1265
|
"enum": [
|
|
@@ -1000,7 +1395,7 @@
|
|
|
1000
1395
|
"items": {
|
|
1001
1396
|
"$ref": "#/components/schemas/Stage"
|
|
1002
1397
|
},
|
|
1003
|
-
"description": "Stages in order. Each stage runs one agent
|
|
1398
|
+
"description": "Stages in order. Each stage runs one agent, which defaults to the stage name, or only waits (ADR 0107)."
|
|
1004
1399
|
},
|
|
1005
1400
|
"automations": {
|
|
1006
1401
|
"type": "array",
|
|
@@ -1031,8 +1426,121 @@
|
|
|
1031
1426
|
"factory",
|
|
1032
1427
|
"agents"
|
|
1033
1428
|
],
|
|
1034
|
-
"description": "`factory.yaml`: the desired state of one factory (P3). Paths are relative to the file.\nRealizes SCN-FACTORY-CODE-001: agents and prompts; MCP servers, skills and secrets per agent;\nrepositories; model and runtime; automations; scorers and benchmarks.",
|
|
1035
|
-
"additionalProperties": false
|
|
1429
|
+
"description": "`factory.yaml`: the desired state of one factory (P3). Paths are relative to the file.\nRealizes SCN-FACTORY-CODE-001: agents and prompts; MCP servers, skills and secrets per agent;\nrepositories; model and runtime; automations; scorers and benchmarks.",
|
|
1430
|
+
"additionalProperties": false
|
|
1431
|
+
},
|
|
1432
|
+
"FactoryLock": {
|
|
1433
|
+
"type": "object",
|
|
1434
|
+
"properties": {
|
|
1435
|
+
"version": {
|
|
1436
|
+
"type": "number",
|
|
1437
|
+
"const": 1,
|
|
1438
|
+
"description": "The version of the lock's format."
|
|
1439
|
+
},
|
|
1440
|
+
"mcp": {
|
|
1441
|
+
"type": "object",
|
|
1442
|
+
"properties": {},
|
|
1443
|
+
"unevaluatedProperties": {
|
|
1444
|
+
"$ref": "#/components/schemas/FactoryLockMcpPin"
|
|
1445
|
+
},
|
|
1446
|
+
"description": "The registry MCP servers, by their reference in factory.yaml, for example `registry:io.github.acme/tracker@1.4`."
|
|
1447
|
+
},
|
|
1448
|
+
"adapters": {
|
|
1449
|
+
"type": "object",
|
|
1450
|
+
"properties": {},
|
|
1451
|
+
"unevaluatedProperties": {
|
|
1452
|
+
"type": "object",
|
|
1453
|
+
"properties": {},
|
|
1454
|
+
"unevaluatedProperties": {
|
|
1455
|
+
"$ref": "#/components/schemas/FactoryLockAdapterPin"
|
|
1456
|
+
}
|
|
1457
|
+
},
|
|
1458
|
+
"description": "The adapters under `providers` that `factory plan --adapters` pinned, per port and adapter name (ADR 0125). A pin\ncounts only while its `range` is the range factory.yaml declares."
|
|
1459
|
+
}
|
|
1460
|
+
},
|
|
1461
|
+
"required": [
|
|
1462
|
+
"version",
|
|
1463
|
+
"mcp"
|
|
1464
|
+
],
|
|
1465
|
+
"description": "factory.lock next to factory.yaml (ADR 0020, ADR 0125): the exact versions that `factory plan` pinned. factory-spec\nwrites it; the foreman reads the pins of its adapters."
|
|
1466
|
+
},
|
|
1467
|
+
"FactoryLockAdapterPin": {
|
|
1468
|
+
"type": "object",
|
|
1469
|
+
"properties": {
|
|
1470
|
+
"range": {
|
|
1471
|
+
"type": "string",
|
|
1472
|
+
"minLength": 1,
|
|
1473
|
+
"description": "The range under `providers` that the pin was resolved from, for example \"^2\"."
|
|
1474
|
+
},
|
|
1475
|
+
"version": {
|
|
1476
|
+
"type": "string",
|
|
1477
|
+
"minLength": 1,
|
|
1478
|
+
"description": "The exact version, for example \"2.3.1\"."
|
|
1479
|
+
}
|
|
1480
|
+
},
|
|
1481
|
+
"required": [
|
|
1482
|
+
"range",
|
|
1483
|
+
"version"
|
|
1484
|
+
],
|
|
1485
|
+
"description": "One adapter's npm package `@opensoftware/<port>-<name>` at the newest version inside its range.",
|
|
1486
|
+
"additionalProperties": false
|
|
1487
|
+
},
|
|
1488
|
+
"FactoryLockMcpPin": {
|
|
1489
|
+
"type": "object",
|
|
1490
|
+
"properties": {
|
|
1491
|
+
"name": {
|
|
1492
|
+
"type": "string",
|
|
1493
|
+
"minLength": 1
|
|
1494
|
+
},
|
|
1495
|
+
"version": {
|
|
1496
|
+
"type": "string",
|
|
1497
|
+
"minLength": 1
|
|
1498
|
+
},
|
|
1499
|
+
"package": {
|
|
1500
|
+
"type": "object",
|
|
1501
|
+
"properties": {
|
|
1502
|
+
"registryType": {
|
|
1503
|
+
"type": "string",
|
|
1504
|
+
"const": "npm"
|
|
1505
|
+
},
|
|
1506
|
+
"identifier": {
|
|
1507
|
+
"type": "string",
|
|
1508
|
+
"minLength": 1
|
|
1509
|
+
},
|
|
1510
|
+
"version": {
|
|
1511
|
+
"type": "string",
|
|
1512
|
+
"minLength": 1
|
|
1513
|
+
}
|
|
1514
|
+
},
|
|
1515
|
+
"required": [
|
|
1516
|
+
"registryType",
|
|
1517
|
+
"identifier",
|
|
1518
|
+
"version"
|
|
1519
|
+
]
|
|
1520
|
+
},
|
|
1521
|
+
"remote": {
|
|
1522
|
+
"type": "object",
|
|
1523
|
+
"properties": {
|
|
1524
|
+
"type": {
|
|
1525
|
+
"type": "string",
|
|
1526
|
+
"minLength": 1
|
|
1527
|
+
},
|
|
1528
|
+
"url": {
|
|
1529
|
+
"type": "string",
|
|
1530
|
+
"minLength": 1
|
|
1531
|
+
}
|
|
1532
|
+
},
|
|
1533
|
+
"required": [
|
|
1534
|
+
"type",
|
|
1535
|
+
"url"
|
|
1536
|
+
]
|
|
1537
|
+
}
|
|
1538
|
+
},
|
|
1539
|
+
"required": [
|
|
1540
|
+
"name",
|
|
1541
|
+
"version"
|
|
1542
|
+
],
|
|
1543
|
+
"description": "One registry MCP server at its exact version, with the npm package or the remote it starts."
|
|
1036
1544
|
},
|
|
1037
1545
|
"FormatVersion": {
|
|
1038
1546
|
"type": "integer",
|
|
@@ -1155,6 +1663,37 @@
|
|
|
1155
1663
|
"expired"
|
|
1156
1664
|
]
|
|
1157
1665
|
},
|
|
1666
|
+
"GateDecisionRequest": {
|
|
1667
|
+
"type": "object",
|
|
1668
|
+
"properties": {
|
|
1669
|
+
"decision": {
|
|
1670
|
+
"anyOf": [
|
|
1671
|
+
{
|
|
1672
|
+
"type": "string",
|
|
1673
|
+
"const": "approved"
|
|
1674
|
+
},
|
|
1675
|
+
{
|
|
1676
|
+
"type": "string",
|
|
1677
|
+
"const": "rejected"
|
|
1678
|
+
}
|
|
1679
|
+
]
|
|
1680
|
+
},
|
|
1681
|
+
"by": {
|
|
1682
|
+
"$ref": "#/components/schemas/Actor",
|
|
1683
|
+
"description": "The person who decides; their `id` must be a member of a group in `waitingFor`."
|
|
1684
|
+
},
|
|
1685
|
+
"reason": {
|
|
1686
|
+
"type": "string",
|
|
1687
|
+
"minLength": 1,
|
|
1688
|
+
"description": "The reason of a rejection."
|
|
1689
|
+
}
|
|
1690
|
+
},
|
|
1691
|
+
"required": [
|
|
1692
|
+
"decision",
|
|
1693
|
+
"by"
|
|
1694
|
+
],
|
|
1695
|
+
"description": "gatekeeper: a person's decision of a pending gate through the API, as a member of a group the gate waits for\n(ADR 0118). It decides like a reply \"approve\" or \"reject <reason>\" in the gate's channel."
|
|
1696
|
+
},
|
|
1158
1697
|
"GateRecord": {
|
|
1159
1698
|
"type": "object",
|
|
1160
1699
|
"properties": {
|
|
@@ -2077,6 +2616,132 @@
|
|
|
2077
2616
|
"commented"
|
|
2078
2617
|
]
|
|
2079
2618
|
},
|
|
2619
|
+
"RunAction": {
|
|
2620
|
+
"type": "object",
|
|
2621
|
+
"properties": {
|
|
2622
|
+
"type": {
|
|
2623
|
+
"$ref": "#/components/schemas/RunSignalType"
|
|
2624
|
+
},
|
|
2625
|
+
"by": {
|
|
2626
|
+
"$ref": "#/components/schemas/Actor",
|
|
2627
|
+
"description": "The person who sent it."
|
|
2628
|
+
},
|
|
2629
|
+
"at": {
|
|
2630
|
+
"type": "string",
|
|
2631
|
+
"format": "date-time",
|
|
2632
|
+
"description": "When the foreman took it."
|
|
2633
|
+
},
|
|
2634
|
+
"message": {
|
|
2635
|
+
"type": "string",
|
|
2636
|
+
"minLength": 1,
|
|
2637
|
+
"description": "The steering message of \"steer\"."
|
|
2638
|
+
}
|
|
2639
|
+
},
|
|
2640
|
+
"required": [
|
|
2641
|
+
"type",
|
|
2642
|
+
"by",
|
|
2643
|
+
"at"
|
|
2644
|
+
],
|
|
2645
|
+
"description": "foreman: a signal a person sent a run, as the run records it (ADR 0118)."
|
|
2646
|
+
},
|
|
2647
|
+
"RunBlocked": {
|
|
2648
|
+
"type": "object",
|
|
2649
|
+
"properties": {
|
|
2650
|
+
"specversion": {
|
|
2651
|
+
"type": "string",
|
|
2652
|
+
"const": "1.0"
|
|
2653
|
+
},
|
|
2654
|
+
"id": {
|
|
2655
|
+
"$ref": "#/components/schemas/Identifier",
|
|
2656
|
+
"description": "Unique per source. A consumer that sees the same source and id twice handles the event once."
|
|
2657
|
+
},
|
|
2658
|
+
"source": {
|
|
2659
|
+
"type": "string",
|
|
2660
|
+
"minLength": 1,
|
|
2661
|
+
"description": "The producing module, for example \"/osf/intake\"."
|
|
2662
|
+
},
|
|
2663
|
+
"type": {
|
|
2664
|
+
"type": "string",
|
|
2665
|
+
"const": "run.blocked@v1"
|
|
2666
|
+
},
|
|
2667
|
+
"time": {
|
|
2668
|
+
"type": "string",
|
|
2669
|
+
"format": "date-time"
|
|
2670
|
+
},
|
|
2671
|
+
"subject": {
|
|
2672
|
+
"type": "string",
|
|
2673
|
+
"description": "The ID of the thing the event is about: work item, gate, run, score or pull request."
|
|
2674
|
+
},
|
|
2675
|
+
"datacontenttype": {
|
|
2676
|
+
"type": "string",
|
|
2677
|
+
"const": "application/json"
|
|
2678
|
+
},
|
|
2679
|
+
"dataschema": {
|
|
2680
|
+
"type": "string",
|
|
2681
|
+
"format": "uri"
|
|
2682
|
+
},
|
|
2683
|
+
"traceparent": {
|
|
2684
|
+
"type": "string",
|
|
2685
|
+
"description": "W3C trace context (CloudEvents distributed tracing extension)."
|
|
2686
|
+
},
|
|
2687
|
+
"data": {
|
|
2688
|
+
"$ref": "#/components/schemas/RunBlockedData"
|
|
2689
|
+
}
|
|
2690
|
+
},
|
|
2691
|
+
"required": [
|
|
2692
|
+
"specversion",
|
|
2693
|
+
"id",
|
|
2694
|
+
"source",
|
|
2695
|
+
"type",
|
|
2696
|
+
"time",
|
|
2697
|
+
"data"
|
|
2698
|
+
],
|
|
2699
|
+
"description": "foreman: a stage of a run waits for the checks of its pull request (ADR 0127). The ID is `<run ID>.blocked.<stage>`."
|
|
2700
|
+
},
|
|
2701
|
+
"RunBlockedData": {
|
|
2702
|
+
"type": "object",
|
|
2703
|
+
"properties": {
|
|
2704
|
+
"runId": {
|
|
2705
|
+
"$ref": "#/components/schemas/Identifier"
|
|
2706
|
+
},
|
|
2707
|
+
"workItemId": {
|
|
2708
|
+
"$ref": "#/components/schemas/Identifier"
|
|
2709
|
+
},
|
|
2710
|
+
"stage": {
|
|
2711
|
+
"$ref": "#/components/schemas/Name",
|
|
2712
|
+
"description": "The stage that waits."
|
|
2713
|
+
},
|
|
2714
|
+
"waitsFor": {
|
|
2715
|
+
"$ref": "#/components/schemas/BlockedOn"
|
|
2716
|
+
},
|
|
2717
|
+
"pullRequest": {
|
|
2718
|
+
"type": "string",
|
|
2719
|
+
"format": "uri",
|
|
2720
|
+
"description": "The pull request whose checks the stage waits for."
|
|
2721
|
+
},
|
|
2722
|
+
"checks": {
|
|
2723
|
+
"type": "array",
|
|
2724
|
+
"items": {
|
|
2725
|
+
"type": "string"
|
|
2726
|
+
},
|
|
2727
|
+
"description": "The names of the checks the stage waits for."
|
|
2728
|
+
},
|
|
2729
|
+
"requester": {
|
|
2730
|
+
"$ref": "#/components/schemas/Actor"
|
|
2731
|
+
},
|
|
2732
|
+
"source": {
|
|
2733
|
+
"$ref": "#/components/schemas/Name"
|
|
2734
|
+
}
|
|
2735
|
+
},
|
|
2736
|
+
"required": [
|
|
2737
|
+
"runId",
|
|
2738
|
+
"workItemId",
|
|
2739
|
+
"stage",
|
|
2740
|
+
"waitsFor",
|
|
2741
|
+
"requester",
|
|
2742
|
+
"source"
|
|
2743
|
+
]
|
|
2744
|
+
},
|
|
2080
2745
|
"RunCompleted": {
|
|
2081
2746
|
"type": "object",
|
|
2082
2747
|
"properties": {
|
|
@@ -2180,6 +2845,14 @@
|
|
|
2180
2845
|
"evidenceBundle": {
|
|
2181
2846
|
"type": "string",
|
|
2182
2847
|
"format": "uri"
|
|
2848
|
+
},
|
|
2849
|
+
"retryOf": {
|
|
2850
|
+
"$ref": "#/components/schemas/Identifier",
|
|
2851
|
+
"description": "The run before, when this run runs a work item again (ADR 0105)."
|
|
2852
|
+
},
|
|
2853
|
+
"reason": {
|
|
2854
|
+
"type": "string",
|
|
2855
|
+
"description": "Why the stage the run ended at failed, when the foreman knows it (ADR 0127)."
|
|
2183
2856
|
}
|
|
2184
2857
|
},
|
|
2185
2858
|
"required": [
|
|
@@ -2201,6 +2874,11 @@
|
|
|
2201
2874
|
"items": {
|
|
2202
2875
|
"$ref": "#/components/schemas/RunView"
|
|
2203
2876
|
}
|
|
2877
|
+
},
|
|
2878
|
+
"next": {
|
|
2879
|
+
"type": "string",
|
|
2880
|
+
"minLength": 1,
|
|
2881
|
+
"description": "The cursor of the next page, while more runs follow (ADR 0115)."
|
|
2204
2882
|
}
|
|
2205
2883
|
},
|
|
2206
2884
|
"required": [
|
|
@@ -2286,6 +2964,22 @@
|
|
|
2286
2964
|
],
|
|
2287
2965
|
"description": "Set at launch through OTEL_RESOURCE_ATTRIBUTES, so it is on every span of the run."
|
|
2288
2966
|
},
|
|
2967
|
+
"RunRetry": {
|
|
2968
|
+
"type": "object",
|
|
2969
|
+
"properties": {
|
|
2970
|
+
"by": {
|
|
2971
|
+
"$ref": "#/components/schemas/Actor",
|
|
2972
|
+
"description": "The person who asks."
|
|
2973
|
+
},
|
|
2974
|
+
"from": {
|
|
2975
|
+
"$ref": "#/components/schemas/Name"
|
|
2976
|
+
}
|
|
2977
|
+
},
|
|
2978
|
+
"required": [
|
|
2979
|
+
"by"
|
|
2980
|
+
],
|
|
2981
|
+
"description": "foreman: run a run that failed or was cancelled again, as a new run (ADR 0105). The new run starts at the first stage\nthat did not succeed, or at `from`, a stage at or before it."
|
|
2982
|
+
},
|
|
2289
2983
|
"RunSignal": {
|
|
2290
2984
|
"type": "object",
|
|
2291
2985
|
"properties": {
|
|
@@ -2296,6 +2990,10 @@
|
|
|
2296
2990
|
"type": "string",
|
|
2297
2991
|
"minLength": 1,
|
|
2298
2992
|
"description": "The steering message. Required with \"steer\"."
|
|
2993
|
+
},
|
|
2994
|
+
"by": {
|
|
2995
|
+
"$ref": "#/components/schemas/Actor",
|
|
2996
|
+
"description": "The person who sends the signal; the run then records it in `actions` (ADR 0118)."
|
|
2299
2997
|
}
|
|
2300
2998
|
},
|
|
2301
2999
|
"required": [
|
|
@@ -2489,6 +3187,10 @@
|
|
|
2489
3187
|
},
|
|
2490
3188
|
"source": {
|
|
2491
3189
|
"$ref": "#/components/schemas/Name"
|
|
3190
|
+
},
|
|
3191
|
+
"retryOf": {
|
|
3192
|
+
"$ref": "#/components/schemas/Identifier",
|
|
3193
|
+
"description": "The run before, when this run runs a work item again (ADR 0105)."
|
|
2492
3194
|
}
|
|
2493
3195
|
},
|
|
2494
3196
|
"required": [
|
|
@@ -2519,7 +3221,21 @@
|
|
|
2519
3221
|
"runId": {
|
|
2520
3222
|
"type": "string",
|
|
2521
3223
|
"pattern": "^run_[0-9a-f]{20}$",
|
|
2522
|
-
"description": "\"run_\" and 20 hex digits of the SHA-256 of the work item's ID."
|
|
3224
|
+
"description": "\"run_\" and 20 hex digits of the SHA-256 of the work item's ID; for the n-th run of the work item, n ≥ 2, of \"<work item ID>#<n>\" (ADR 0105)."
|
|
3225
|
+
},
|
|
3226
|
+
"attempt": {
|
|
3227
|
+
"type": "integer",
|
|
3228
|
+
"minimum": 1,
|
|
3229
|
+
"description": "Which run of the work item this is: 1 when absent (ADR 0105)."
|
|
3230
|
+
},
|
|
3231
|
+
"retryOf": {
|
|
3232
|
+
"type": "string",
|
|
3233
|
+
"pattern": "^run_[0-9a-f]{20}$",
|
|
3234
|
+
"description": "The run before this one, which a person ran again (ADR 0105)."
|
|
3235
|
+
},
|
|
3236
|
+
"retriedBy": {
|
|
3237
|
+
"$ref": "#/components/schemas/Actor",
|
|
3238
|
+
"description": "The person who ran the run before again (ADR 0105)."
|
|
2523
3239
|
},
|
|
2524
3240
|
"workItem": {
|
|
2525
3241
|
"$ref": "#/components/schemas/WorkItem"
|
|
@@ -2532,13 +3248,20 @@
|
|
|
2532
3248
|
"$ref": "#/components/schemas/CommitHash",
|
|
2533
3249
|
"description": "The commit of the factory definition the run started with."
|
|
2534
3250
|
},
|
|
3251
|
+
"adapters": {
|
|
3252
|
+
"type": "array",
|
|
3253
|
+
"items": {
|
|
3254
|
+
"$ref": "#/components/schemas/AdapterVersion"
|
|
3255
|
+
},
|
|
3256
|
+
"description": "The adapters of the factory's `providers` and the versions the run asks for (ADR 0110)."
|
|
3257
|
+
},
|
|
2535
3258
|
"state": {
|
|
2536
3259
|
"$ref": "#/components/schemas/RunState"
|
|
2537
3260
|
},
|
|
2538
3261
|
"pullRequest": {
|
|
2539
3262
|
"type": "string",
|
|
2540
3263
|
"format": "uri",
|
|
2541
|
-
"description": "The
|
|
3264
|
+
"description": "The run's pull request: the forge's of the run's branch, the one an agent stated, or else the last link an agent wrote (ADR 0069, ADR 0109)."
|
|
2542
3265
|
},
|
|
2543
3266
|
"folder": {
|
|
2544
3267
|
"type": "string",
|
|
@@ -2563,6 +3286,13 @@
|
|
|
2563
3286
|
"$ref": "#/components/schemas/StageView"
|
|
2564
3287
|
},
|
|
2565
3288
|
"description": "The stages of the workflow, in order."
|
|
3289
|
+
},
|
|
3290
|
+
"actions": {
|
|
3291
|
+
"type": "array",
|
|
3292
|
+
"items": {
|
|
3293
|
+
"$ref": "#/components/schemas/RunAction"
|
|
3294
|
+
},
|
|
3295
|
+
"description": "The signals that named their person, oldest first (ADR 0118)."
|
|
2566
3296
|
}
|
|
2567
3297
|
},
|
|
2568
3298
|
"required": [
|
|
@@ -2573,8 +3303,7 @@
|
|
|
2573
3303
|
"state",
|
|
2574
3304
|
"startedAt",
|
|
2575
3305
|
"stages"
|
|
2576
|
-
]
|
|
2577
|
-
"description": "foreman: a run of the factory's workflow for one work item, as the HTTP API shows it (ADR 0067)."
|
|
3306
|
+
]
|
|
2578
3307
|
},
|
|
2579
3308
|
"Sandbox": {
|
|
2580
3309
|
"type": "object",
|
|
@@ -2945,6 +3674,10 @@
|
|
|
2945
3674
|
"evidence": {
|
|
2946
3675
|
"$ref": "#/components/schemas/EvidenceRequirement",
|
|
2947
3676
|
"description": "Whether the stage must produce an evidence bundle."
|
|
3677
|
+
},
|
|
3678
|
+
"wait": {
|
|
3679
|
+
"type": "boolean",
|
|
3680
|
+
"description": "The stage runs no agent: it only waits for its checks, its evidence and its gate, then succeeds (ADR 0107). It\nnames no agent and at least one of checks, evidence \"required\" or gate."
|
|
2948
3681
|
}
|
|
2949
3682
|
},
|
|
2950
3683
|
"required": [
|
|
@@ -2973,7 +3706,11 @@
|
|
|
2973
3706
|
},
|
|
2974
3707
|
"agent": {
|
|
2975
3708
|
"$ref": "#/components/schemas/Name",
|
|
2976
|
-
"description": "The agent that runs the stage."
|
|
3709
|
+
"description": "The agent that runs the stage; the stage's name for a stage that only waits (ADR 0107)."
|
|
3710
|
+
},
|
|
3711
|
+
"wait": {
|
|
3712
|
+
"type": "boolean",
|
|
3713
|
+
"description": "True for a stage that only waits: it runs no agent and starts no session (ADR 0107)."
|
|
2977
3714
|
},
|
|
2978
3715
|
"state": {
|
|
2979
3716
|
"$ref": "#/components/schemas/StageState"
|
|
@@ -2982,6 +3719,11 @@
|
|
|
2982
3719
|
"type": "string",
|
|
2983
3720
|
"description": "The harness session of the stage's agent, once it started."
|
|
2984
3721
|
},
|
|
3722
|
+
"spanId": {
|
|
3723
|
+
"type": "string",
|
|
3724
|
+
"pattern": "^[0-9a-f]{16}$",
|
|
3725
|
+
"description": "The span of the stage in the run's trace, once it started: the first 16 hex digits of the SHA-256 of\n`<runId>:<stage index>` (ADR 0087, ADR 0121)."
|
|
3726
|
+
},
|
|
2985
3727
|
"gateId": {
|
|
2986
3728
|
"type": "string",
|
|
2987
3729
|
"pattern": "^g[0-9a-f]{16}$",
|
|
@@ -2994,6 +3736,11 @@
|
|
|
2994
3736
|
},
|
|
2995
3737
|
"description": "The checks the stage waits for, once the foreman read them (ADR 0069)."
|
|
2996
3738
|
},
|
|
3739
|
+
"waitingSince": {
|
|
3740
|
+
"type": "string",
|
|
3741
|
+
"format": "date-time",
|
|
3742
|
+
"description": "Since when the stage waits for its checks, its gate or a person, while it is blocked (ADR 0106)."
|
|
3743
|
+
},
|
|
2997
3744
|
"takenOverAt": {
|
|
2998
3745
|
"type": "string",
|
|
2999
3746
|
"format": "date-time",
|
|
@@ -3004,6 +3751,11 @@
|
|
|
3004
3751
|
"minLength": 1,
|
|
3005
3752
|
"description": "Why the stage ended without success, when the foreman knows."
|
|
3006
3753
|
},
|
|
3754
|
+
"note": {
|
|
3755
|
+
"type": "string",
|
|
3756
|
+
"minLength": 1,
|
|
3757
|
+
"description": "Why the stage gave the run no pull request: a refused link, a branch the forge has none of, or the forge adapter's error (ADR 0109)."
|
|
3758
|
+
},
|
|
3007
3759
|
"startedAt": {
|
|
3008
3760
|
"type": "string",
|
|
3009
3761
|
"format": "date-time"
|
|
@@ -3101,6 +3853,11 @@
|
|
|
3101
3853
|
"items": {
|
|
3102
3854
|
"$ref": "#/components/schemas/WorkItemView"
|
|
3103
3855
|
}
|
|
3856
|
+
},
|
|
3857
|
+
"next": {
|
|
3858
|
+
"type": "string",
|
|
3859
|
+
"minLength": 1,
|
|
3860
|
+
"description": "The cursor of the next page, while more work items follow (ADR 0115)."
|
|
3104
3861
|
}
|
|
3105
3862
|
},
|
|
3106
3863
|
"required": [
|
|
@@ -3238,6 +3995,81 @@
|
|
|
3238
3995
|
],
|
|
3239
3996
|
"description": "intake: one submission that asked for a work item."
|
|
3240
3997
|
},
|
|
3998
|
+
"WorkRetryRequested": {
|
|
3999
|
+
"type": "object",
|
|
4000
|
+
"properties": {
|
|
4001
|
+
"specversion": {
|
|
4002
|
+
"type": "string",
|
|
4003
|
+
"const": "1.0"
|
|
4004
|
+
},
|
|
4005
|
+
"id": {
|
|
4006
|
+
"$ref": "#/components/schemas/Identifier",
|
|
4007
|
+
"description": "Unique per source. A consumer that sees the same source and id twice handles the event once."
|
|
4008
|
+
},
|
|
4009
|
+
"source": {
|
|
4010
|
+
"type": "string",
|
|
4011
|
+
"minLength": 1,
|
|
4012
|
+
"description": "The producing module, for example \"/osf/intake\"."
|
|
4013
|
+
},
|
|
4014
|
+
"type": {
|
|
4015
|
+
"type": "string",
|
|
4016
|
+
"const": "work.retry-requested@v1"
|
|
4017
|
+
},
|
|
4018
|
+
"time": {
|
|
4019
|
+
"type": "string",
|
|
4020
|
+
"format": "date-time"
|
|
4021
|
+
},
|
|
4022
|
+
"subject": {
|
|
4023
|
+
"type": "string",
|
|
4024
|
+
"description": "The ID of the thing the event is about: work item, gate, run, score or pull request."
|
|
4025
|
+
},
|
|
4026
|
+
"datacontenttype": {
|
|
4027
|
+
"type": "string",
|
|
4028
|
+
"const": "application/json"
|
|
4029
|
+
},
|
|
4030
|
+
"dataschema": {
|
|
4031
|
+
"type": "string",
|
|
4032
|
+
"format": "uri"
|
|
4033
|
+
},
|
|
4034
|
+
"traceparent": {
|
|
4035
|
+
"type": "string",
|
|
4036
|
+
"description": "W3C trace context (CloudEvents distributed tracing extension)."
|
|
4037
|
+
},
|
|
4038
|
+
"data": {
|
|
4039
|
+
"$ref": "#/components/schemas/WorkRetryRequestedData"
|
|
4040
|
+
}
|
|
4041
|
+
},
|
|
4042
|
+
"required": [
|
|
4043
|
+
"specversion",
|
|
4044
|
+
"id",
|
|
4045
|
+
"source",
|
|
4046
|
+
"type",
|
|
4047
|
+
"time",
|
|
4048
|
+
"data"
|
|
4049
|
+
],
|
|
4050
|
+
"description": "intake: a person asked to run a work item's run again (ADR 0105). The ID is `<run ID>.retry`."
|
|
4051
|
+
},
|
|
4052
|
+
"WorkRetryRequestedData": {
|
|
4053
|
+
"type": "object",
|
|
4054
|
+
"properties": {
|
|
4055
|
+
"workItemId": {
|
|
4056
|
+
"$ref": "#/components/schemas/Identifier"
|
|
4057
|
+
},
|
|
4058
|
+
"runId": {
|
|
4059
|
+
"$ref": "#/components/schemas/Identifier",
|
|
4060
|
+
"description": "The run to run again: the run the work item follows."
|
|
4061
|
+
},
|
|
4062
|
+
"requester": {
|
|
4063
|
+
"$ref": "#/components/schemas/Actor",
|
|
4064
|
+
"description": "The person who asked."
|
|
4065
|
+
}
|
|
4066
|
+
},
|
|
4067
|
+
"required": [
|
|
4068
|
+
"workItemId",
|
|
4069
|
+
"runId",
|
|
4070
|
+
"requester"
|
|
4071
|
+
]
|
|
4072
|
+
},
|
|
3241
4073
|
"WorkSubmission": {
|
|
3242
4074
|
"type": "object",
|
|
3243
4075
|
"properties": {
|