@opensoftware/contracts 0.0.0-stage → 1.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/LICENSE +202 -0
- package/README.md +112 -2
- package/dist/breaking.d.ts +27 -0
- package/dist/breaking.js +157 -0
- package/dist/breaking.js.map +1 -0
- package/dist/cli.d.ts +2 -0
- package/dist/cli.js +69 -0
- package/dist/cli.js.map +1 -0
- package/dist/formats.d.ts +10 -0
- package/dist/formats.js +21 -0
- package/dist/formats.js.map +1 -0
- package/dist/generated/types.d.ts +636 -0
- package/dist/generated/types.js +2 -0
- package/dist/generated/types.js.map +1 -0
- package/dist/index.d.ts +31 -0
- package/dist/index.js +75 -0
- package/dist/index.js.map +1 -0
- package/dist/roundtrip.d.ts +3 -0
- package/dist/roundtrip.js +90 -0
- package/dist/roundtrip.js.map +1 -0
- package/dist/run-record.d.ts +18 -0
- package/dist/run-record.js +27 -0
- package/dist/run-record.js.map +1 -0
- package/events/asyncapi.yaml +186 -0
- package/events/gate-decided/gate-decided.schema.json +122 -0
- package/events/gate-requested/gate-requested.schema.json +135 -0
- package/events/pr-closed/pr-closed.schema.json +80 -0
- package/events/pr-opened/pr-opened.schema.json +138 -0
- package/events/pr-reviewed/pr-reviewed.schema.json +111 -0
- package/events/run-completed/run-completed.schema.json +163 -0
- package/events/score-recorded/score-recorded.schema.json +163 -0
- package/events/work-received/work-received.schema.json +182 -0
- package/evidence-bundle/evidence-bundle.schema.json +180 -0
- package/factory-definition/factory-definition.schema.json +371 -0
- package/openapi/openapi.json +1715 -0
- package/package.json +50 -3
- package/run-record/run-record.schema.json +179 -0
- package/score/score.schema.json +110 -0
- package/typespec/common.tsp +62 -0
- package/typespec/events.tsp +168 -0
- package/typespec/evidence-bundle.tsp +99 -0
- package/typespec/factory-definition.tsp +193 -0
- package/typespec/main.tsp +10 -0
- package/typespec/run-record.tsp +88 -0
- package/typespec/score.tsp +68 -0
- package/typespec/work-item.tsp +65 -0
- package/work-item/work-item.schema.json +129 -0
|
@@ -0,0 +1,1715 @@
|
|
|
1
|
+
{
|
|
2
|
+
"openapi": "3.1.0",
|
|
3
|
+
"info": {
|
|
4
|
+
"title": "Open Software Factory contracts",
|
|
5
|
+
"version": "1.4.0",
|
|
6
|
+
"description": "The shared formats as named models. No operations: module APIs are added per module. Generated by `pnpm build` in contracts/ from typespec/. Do not edit.",
|
|
7
|
+
"license": {
|
|
8
|
+
"name": "Apache-2.0",
|
|
9
|
+
"identifier": "Apache-2.0"
|
|
10
|
+
}
|
|
11
|
+
},
|
|
12
|
+
"paths": {},
|
|
13
|
+
"components": {
|
|
14
|
+
"schemas": {
|
|
15
|
+
"Actor": {
|
|
16
|
+
"type": "object",
|
|
17
|
+
"properties": {
|
|
18
|
+
"kind": {
|
|
19
|
+
"$ref": "#/components/schemas/ActorKind"
|
|
20
|
+
},
|
|
21
|
+
"id": {
|
|
22
|
+
"type": "string",
|
|
23
|
+
"minLength": 1,
|
|
24
|
+
"description": "Stable ID in the source system, prefixed with the source, for example \"slack:U024BE7LH\"."
|
|
25
|
+
},
|
|
26
|
+
"displayName": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"description": "Shown to people, for example \"Varun\"."
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
"required": [
|
|
32
|
+
"kind",
|
|
33
|
+
"id"
|
|
34
|
+
],
|
|
35
|
+
"description": "A person or trigger. RUNTIME-008: every run is attributed to one."
|
|
36
|
+
},
|
|
37
|
+
"ActorKind": {
|
|
38
|
+
"type": "string",
|
|
39
|
+
"enum": [
|
|
40
|
+
"person",
|
|
41
|
+
"trigger"
|
|
42
|
+
],
|
|
43
|
+
"description": "Who caused something: a person, or an automated trigger such as a cron rule or an alert."
|
|
44
|
+
},
|
|
45
|
+
"Agent": {
|
|
46
|
+
"type": "object",
|
|
47
|
+
"properties": {
|
|
48
|
+
"description": {
|
|
49
|
+
"type": "string"
|
|
50
|
+
},
|
|
51
|
+
"harness": {
|
|
52
|
+
"$ref": "#/components/schemas/Name",
|
|
53
|
+
"description": "Harness adapter, declared under `providers.harness`, for example \"claude-code\"."
|
|
54
|
+
},
|
|
55
|
+
"model": {
|
|
56
|
+
"type": "string",
|
|
57
|
+
"minLength": 1,
|
|
58
|
+
"description": "A model ID or a routing alias of the inference gateway, for example \"routes/triage\"."
|
|
59
|
+
},
|
|
60
|
+
"prompt": {
|
|
61
|
+
"type": "string",
|
|
62
|
+
"minLength": 1,
|
|
63
|
+
"description": "Path to the Markdown prompt."
|
|
64
|
+
},
|
|
65
|
+
"repositories": {
|
|
66
|
+
"type": "array",
|
|
67
|
+
"items": {
|
|
68
|
+
"type": "string"
|
|
69
|
+
},
|
|
70
|
+
"description": "Repositories the agent operates on, as clone URLs or \"<owner>/<name>\"."
|
|
71
|
+
},
|
|
72
|
+
"mcp": {
|
|
73
|
+
"type": "array",
|
|
74
|
+
"items": {
|
|
75
|
+
"type": "string"
|
|
76
|
+
},
|
|
77
|
+
"description": "MCP servers: `registry:<name>@<version>` or `<name>@<version>`."
|
|
78
|
+
},
|
|
79
|
+
"skills": {
|
|
80
|
+
"type": "array",
|
|
81
|
+
"items": {
|
|
82
|
+
"type": "string"
|
|
83
|
+
},
|
|
84
|
+
"description": "Paths to skill folders."
|
|
85
|
+
},
|
|
86
|
+
"secrets": {
|
|
87
|
+
"type": "array",
|
|
88
|
+
"items": {
|
|
89
|
+
"$ref": "#/components/schemas/SecretReference"
|
|
90
|
+
}
|
|
91
|
+
},
|
|
92
|
+
"sandbox": {
|
|
93
|
+
"$ref": "#/components/schemas/Sandbox",
|
|
94
|
+
"description": "Runtime of the agent."
|
|
95
|
+
}
|
|
96
|
+
},
|
|
97
|
+
"required": [
|
|
98
|
+
"harness",
|
|
99
|
+
"model",
|
|
100
|
+
"prompt"
|
|
101
|
+
],
|
|
102
|
+
"additionalProperties": false
|
|
103
|
+
},
|
|
104
|
+
"Artifact": {
|
|
105
|
+
"type": "object",
|
|
106
|
+
"properties": {
|
|
107
|
+
"path": {
|
|
108
|
+
"$ref": "#/components/schemas/BundlePath"
|
|
109
|
+
},
|
|
110
|
+
"kind": {
|
|
111
|
+
"$ref": "#/components/schemas/ArtifactKind"
|
|
112
|
+
},
|
|
113
|
+
"mediaType": {
|
|
114
|
+
"type": "string",
|
|
115
|
+
"minLength": 1,
|
|
116
|
+
"description": "IANA media type, for example \"image/png\"."
|
|
117
|
+
},
|
|
118
|
+
"sha256": {
|
|
119
|
+
"$ref": "#/components/schemas/Sha256"
|
|
120
|
+
},
|
|
121
|
+
"bytes": {
|
|
122
|
+
"type": "integer",
|
|
123
|
+
"minimum": 0
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
"required": [
|
|
127
|
+
"path",
|
|
128
|
+
"kind",
|
|
129
|
+
"mediaType",
|
|
130
|
+
"sha256"
|
|
131
|
+
]
|
|
132
|
+
},
|
|
133
|
+
"ArtifactKind": {
|
|
134
|
+
"type": "string",
|
|
135
|
+
"enum": [
|
|
136
|
+
"screenshot",
|
|
137
|
+
"video",
|
|
138
|
+
"playwright-trace",
|
|
139
|
+
"junit",
|
|
140
|
+
"log",
|
|
141
|
+
"report",
|
|
142
|
+
"other"
|
|
143
|
+
]
|
|
144
|
+
},
|
|
145
|
+
"Automation": {
|
|
146
|
+
"type": "object",
|
|
147
|
+
"properties": {
|
|
148
|
+
"on": {
|
|
149
|
+
"type": "string",
|
|
150
|
+
"minLength": 1,
|
|
151
|
+
"description": "Event filter, for example \"github.issue.labeled(auto-implement)\" or \"sentry.fatal\"."
|
|
152
|
+
},
|
|
153
|
+
"cron": {
|
|
154
|
+
"type": "string",
|
|
155
|
+
"minLength": 1,
|
|
156
|
+
"description": "Five-field cron expression in UTC."
|
|
157
|
+
},
|
|
158
|
+
"run": {
|
|
159
|
+
"$ref": "#/components/schemas/Name",
|
|
160
|
+
"description": "Job to run. Required with `cron`; without it an event starts the workflow."
|
|
161
|
+
}
|
|
162
|
+
},
|
|
163
|
+
"description": "Starts the workflow, or the named job, on an event (`on`) or a schedule (`cron`). Exactly one of the two; a\nschedule names its job. One model rather than a union, so every generated client reads it without guessing.",
|
|
164
|
+
"oneOf": [
|
|
165
|
+
{
|
|
166
|
+
"required": [
|
|
167
|
+
"on"
|
|
168
|
+
],
|
|
169
|
+
"not": {
|
|
170
|
+
"required": [
|
|
171
|
+
"cron"
|
|
172
|
+
]
|
|
173
|
+
}
|
|
174
|
+
},
|
|
175
|
+
{
|
|
176
|
+
"required": [
|
|
177
|
+
"cron",
|
|
178
|
+
"run"
|
|
179
|
+
],
|
|
180
|
+
"not": {
|
|
181
|
+
"required": [
|
|
182
|
+
"on"
|
|
183
|
+
]
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
],
|
|
187
|
+
"additionalProperties": false
|
|
188
|
+
},
|
|
189
|
+
"Benchmark": {
|
|
190
|
+
"type": "object",
|
|
191
|
+
"properties": {
|
|
192
|
+
"suite": {
|
|
193
|
+
"type": "string",
|
|
194
|
+
"minLength": 1,
|
|
195
|
+
"description": "Path to the Harbor task suite."
|
|
196
|
+
},
|
|
197
|
+
"schedule": {
|
|
198
|
+
"type": "string",
|
|
199
|
+
"description": "Five-field cron expression in UTC. Without it the suite runs on request."
|
|
200
|
+
}
|
|
201
|
+
},
|
|
202
|
+
"required": [
|
|
203
|
+
"suite"
|
|
204
|
+
],
|
|
205
|
+
"additionalProperties": false
|
|
206
|
+
},
|
|
207
|
+
"BundlePath": {
|
|
208
|
+
"type": "string",
|
|
209
|
+
"pattern": "^(?!/)(?!.*(^|/)\\.\\.(/|$))[^\\\\]+$",
|
|
210
|
+
"description": "A path inside the bundle: relative, forward slashes, no \"..\"."
|
|
211
|
+
},
|
|
212
|
+
"CommitHash": {
|
|
213
|
+
"type": "string",
|
|
214
|
+
"pattern": "^[0-9a-f]{7,40}$",
|
|
215
|
+
"description": "A Git commit hash, abbreviated (7+) or full. The factory version is the commit of the factory definition."
|
|
216
|
+
},
|
|
217
|
+
"EvidenceManifest": {
|
|
218
|
+
"type": "object",
|
|
219
|
+
"properties": {
|
|
220
|
+
"manifestVersion": {
|
|
221
|
+
"$ref": "#/components/schemas/FormatVersion",
|
|
222
|
+
"description": "Version of this format."
|
|
223
|
+
},
|
|
224
|
+
"id": {
|
|
225
|
+
"$ref": "#/components/schemas/Identifier"
|
|
226
|
+
},
|
|
227
|
+
"createdAt": {
|
|
228
|
+
"type": "string",
|
|
229
|
+
"format": "date-time"
|
|
230
|
+
},
|
|
231
|
+
"subject": {
|
|
232
|
+
"$ref": "#/components/schemas/EvidenceSubject",
|
|
233
|
+
"description": "The change that was verified."
|
|
234
|
+
},
|
|
235
|
+
"runId": {
|
|
236
|
+
"$ref": "#/components/schemas/Identifier"
|
|
237
|
+
},
|
|
238
|
+
"workItemId": {
|
|
239
|
+
"$ref": "#/components/schemas/Identifier"
|
|
240
|
+
},
|
|
241
|
+
"producer": {
|
|
242
|
+
"$ref": "#/components/schemas/Producer",
|
|
243
|
+
"description": "The tool that wrote the bundle, for example proof 1.2.0."
|
|
244
|
+
},
|
|
245
|
+
"result": {
|
|
246
|
+
"$ref": "#/components/schemas/VerificationResult",
|
|
247
|
+
"description": "Passed only when every scenario passed."
|
|
248
|
+
},
|
|
249
|
+
"scenarios": {
|
|
250
|
+
"type": "array",
|
|
251
|
+
"items": {
|
|
252
|
+
"$ref": "#/components/schemas/ScenarioEvidence"
|
|
253
|
+
}
|
|
254
|
+
},
|
|
255
|
+
"artifacts": {
|
|
256
|
+
"type": "array",
|
|
257
|
+
"items": {
|
|
258
|
+
"$ref": "#/components/schemas/Artifact"
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
},
|
|
262
|
+
"required": [
|
|
263
|
+
"manifestVersion",
|
|
264
|
+
"id",
|
|
265
|
+
"createdAt",
|
|
266
|
+
"subject",
|
|
267
|
+
"producer",
|
|
268
|
+
"result",
|
|
269
|
+
"scenarios",
|
|
270
|
+
"artifacts"
|
|
271
|
+
],
|
|
272
|
+
"description": "`evidence.json` at the root of an evidence bundle: what was verified, against which scenario IDs, with which\nartifacts and result (P10)."
|
|
273
|
+
},
|
|
274
|
+
"EvidenceRequirement": {
|
|
275
|
+
"type": "string",
|
|
276
|
+
"enum": [
|
|
277
|
+
"required",
|
|
278
|
+
"optional"
|
|
279
|
+
]
|
|
280
|
+
},
|
|
281
|
+
"EvidenceSubject": {
|
|
282
|
+
"type": "object",
|
|
283
|
+
"properties": {
|
|
284
|
+
"repository": {
|
|
285
|
+
"type": "string",
|
|
286
|
+
"format": "uri"
|
|
287
|
+
},
|
|
288
|
+
"commit": {
|
|
289
|
+
"$ref": "#/components/schemas/CommitHash"
|
|
290
|
+
},
|
|
291
|
+
"pullRequest": {
|
|
292
|
+
"type": "string",
|
|
293
|
+
"format": "uri"
|
|
294
|
+
}
|
|
295
|
+
},
|
|
296
|
+
"required": [
|
|
297
|
+
"repository",
|
|
298
|
+
"commit"
|
|
299
|
+
]
|
|
300
|
+
},
|
|
301
|
+
"FactoryDefinition": {
|
|
302
|
+
"type": "object",
|
|
303
|
+
"properties": {
|
|
304
|
+
"$schema": {
|
|
305
|
+
"type": "string",
|
|
306
|
+
"description": "Editors may point at this schema. Ignored by every tool."
|
|
307
|
+
},
|
|
308
|
+
"version": {
|
|
309
|
+
"$ref": "#/components/schemas/FormatVersion",
|
|
310
|
+
"description": "Version of this format. A new major version of the format gets a new value."
|
|
311
|
+
},
|
|
312
|
+
"factory": {
|
|
313
|
+
"$ref": "#/components/schemas/Name",
|
|
314
|
+
"description": "Name of the factory."
|
|
315
|
+
},
|
|
316
|
+
"description": {
|
|
317
|
+
"type": "string"
|
|
318
|
+
},
|
|
319
|
+
"providers": {
|
|
320
|
+
"$ref": "#/components/schemas/Providers",
|
|
321
|
+
"description": "Adapters per port with a version range, pinned in `factory.lock` by `factory plan`."
|
|
322
|
+
},
|
|
323
|
+
"agents": {
|
|
324
|
+
"type": "object",
|
|
325
|
+
"properties": {},
|
|
326
|
+
"unevaluatedProperties": {
|
|
327
|
+
"$ref": "#/components/schemas/Agent"
|
|
328
|
+
},
|
|
329
|
+
"minProperties": 1,
|
|
330
|
+
"description": "Agents by name."
|
|
331
|
+
},
|
|
332
|
+
"workflow": {
|
|
333
|
+
"type": "array",
|
|
334
|
+
"items": {
|
|
335
|
+
"$ref": "#/components/schemas/Stage"
|
|
336
|
+
},
|
|
337
|
+
"description": "Stages in order. Each stage runs one agent; the agent defaults to the stage name."
|
|
338
|
+
},
|
|
339
|
+
"automations": {
|
|
340
|
+
"type": "array",
|
|
341
|
+
"items": {
|
|
342
|
+
"$ref": "#/components/schemas/Automation"
|
|
343
|
+
},
|
|
344
|
+
"description": "What starts work without a person asking."
|
|
345
|
+
},
|
|
346
|
+
"scorers": {
|
|
347
|
+
"type": "object",
|
|
348
|
+
"properties": {},
|
|
349
|
+
"unevaluatedProperties": {
|
|
350
|
+
"$ref": "#/components/schemas/Scorer"
|
|
351
|
+
},
|
|
352
|
+
"description": "Scorers by name."
|
|
353
|
+
},
|
|
354
|
+
"benchmarks": {
|
|
355
|
+
"type": "object",
|
|
356
|
+
"properties": {},
|
|
357
|
+
"unevaluatedProperties": {
|
|
358
|
+
"$ref": "#/components/schemas/Benchmark"
|
|
359
|
+
},
|
|
360
|
+
"description": "Benchmark suites by name."
|
|
361
|
+
}
|
|
362
|
+
},
|
|
363
|
+
"required": [
|
|
364
|
+
"version",
|
|
365
|
+
"factory",
|
|
366
|
+
"agents"
|
|
367
|
+
],
|
|
368
|
+
"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.",
|
|
369
|
+
"additionalProperties": false
|
|
370
|
+
},
|
|
371
|
+
"FormatVersion": {
|
|
372
|
+
"type": "integer",
|
|
373
|
+
"minimum": 1,
|
|
374
|
+
"maximum": 2147483647,
|
|
375
|
+
"description": "The version of a format inside its documents. Only 1 exists; a new major version of a format adds the next.",
|
|
376
|
+
"const": 1
|
|
377
|
+
},
|
|
378
|
+
"Gate": {
|
|
379
|
+
"type": "object",
|
|
380
|
+
"properties": {
|
|
381
|
+
"policy": {
|
|
382
|
+
"type": "string",
|
|
383
|
+
"minLength": 1,
|
|
384
|
+
"description": "Path to the Rego policy that decides or picks the approvers."
|
|
385
|
+
},
|
|
386
|
+
"approvers": {
|
|
387
|
+
"type": "array",
|
|
388
|
+
"items": {
|
|
389
|
+
"$ref": "#/components/schemas/Name"
|
|
390
|
+
},
|
|
391
|
+
"description": "Approver groups. The policy may narrow them."
|
|
392
|
+
}
|
|
393
|
+
},
|
|
394
|
+
"required": [
|
|
395
|
+
"policy"
|
|
396
|
+
],
|
|
397
|
+
"additionalProperties": false
|
|
398
|
+
},
|
|
399
|
+
"GateDecided": {
|
|
400
|
+
"type": "object",
|
|
401
|
+
"properties": {
|
|
402
|
+
"specversion": {
|
|
403
|
+
"type": "string",
|
|
404
|
+
"const": "1.0"
|
|
405
|
+
},
|
|
406
|
+
"id": {
|
|
407
|
+
"$ref": "#/components/schemas/Identifier",
|
|
408
|
+
"description": "Unique per source. A consumer that sees the same source and id twice handles the event once."
|
|
409
|
+
},
|
|
410
|
+
"source": {
|
|
411
|
+
"type": "string",
|
|
412
|
+
"minLength": 1,
|
|
413
|
+
"description": "The producing module, for example \"/osf/intake\"."
|
|
414
|
+
},
|
|
415
|
+
"type": {
|
|
416
|
+
"type": "string",
|
|
417
|
+
"const": "gate.decided@v1"
|
|
418
|
+
},
|
|
419
|
+
"time": {
|
|
420
|
+
"type": "string",
|
|
421
|
+
"format": "date-time"
|
|
422
|
+
},
|
|
423
|
+
"subject": {
|
|
424
|
+
"type": "string",
|
|
425
|
+
"description": "The ID of the thing the event is about: work item, gate, run, score or pull request."
|
|
426
|
+
},
|
|
427
|
+
"datacontenttype": {
|
|
428
|
+
"type": "string",
|
|
429
|
+
"const": "application/json"
|
|
430
|
+
},
|
|
431
|
+
"dataschema": {
|
|
432
|
+
"type": "string",
|
|
433
|
+
"format": "uri"
|
|
434
|
+
},
|
|
435
|
+
"traceparent": {
|
|
436
|
+
"type": "string",
|
|
437
|
+
"description": "W3C trace context (CloudEvents distributed tracing extension)."
|
|
438
|
+
},
|
|
439
|
+
"data": {
|
|
440
|
+
"$ref": "#/components/schemas/GateDecidedData"
|
|
441
|
+
}
|
|
442
|
+
},
|
|
443
|
+
"required": [
|
|
444
|
+
"specversion",
|
|
445
|
+
"id",
|
|
446
|
+
"source",
|
|
447
|
+
"type",
|
|
448
|
+
"time",
|
|
449
|
+
"data"
|
|
450
|
+
],
|
|
451
|
+
"description": "gatekeeper: a gate was decided."
|
|
452
|
+
},
|
|
453
|
+
"GateDecidedData": {
|
|
454
|
+
"type": "object",
|
|
455
|
+
"properties": {
|
|
456
|
+
"gateId": {
|
|
457
|
+
"$ref": "#/components/schemas/Identifier"
|
|
458
|
+
},
|
|
459
|
+
"workItemId": {
|
|
460
|
+
"$ref": "#/components/schemas/Identifier"
|
|
461
|
+
},
|
|
462
|
+
"decision": {
|
|
463
|
+
"$ref": "#/components/schemas/GateDecision"
|
|
464
|
+
},
|
|
465
|
+
"decidedBy": {
|
|
466
|
+
"$ref": "#/components/schemas/Actor",
|
|
467
|
+
"description": "The person who decided. Absent only when the gate expired."
|
|
468
|
+
},
|
|
469
|
+
"decidedAt": {
|
|
470
|
+
"type": "string",
|
|
471
|
+
"format": "date-time"
|
|
472
|
+
},
|
|
473
|
+
"reason": {
|
|
474
|
+
"type": "string"
|
|
475
|
+
}
|
|
476
|
+
},
|
|
477
|
+
"required": [
|
|
478
|
+
"gateId",
|
|
479
|
+
"workItemId",
|
|
480
|
+
"decision",
|
|
481
|
+
"decidedAt"
|
|
482
|
+
]
|
|
483
|
+
},
|
|
484
|
+
"GateDecision": {
|
|
485
|
+
"type": "string",
|
|
486
|
+
"enum": [
|
|
487
|
+
"approved",
|
|
488
|
+
"rejected",
|
|
489
|
+
"expired"
|
|
490
|
+
]
|
|
491
|
+
},
|
|
492
|
+
"GateRequested": {
|
|
493
|
+
"type": "object",
|
|
494
|
+
"properties": {
|
|
495
|
+
"specversion": {
|
|
496
|
+
"type": "string",
|
|
497
|
+
"const": "1.0"
|
|
498
|
+
},
|
|
499
|
+
"id": {
|
|
500
|
+
"$ref": "#/components/schemas/Identifier",
|
|
501
|
+
"description": "Unique per source. A consumer that sees the same source and id twice handles the event once."
|
|
502
|
+
},
|
|
503
|
+
"source": {
|
|
504
|
+
"type": "string",
|
|
505
|
+
"minLength": 1,
|
|
506
|
+
"description": "The producing module, for example \"/osf/intake\"."
|
|
507
|
+
},
|
|
508
|
+
"type": {
|
|
509
|
+
"type": "string",
|
|
510
|
+
"const": "gate.requested@v1"
|
|
511
|
+
},
|
|
512
|
+
"time": {
|
|
513
|
+
"type": "string",
|
|
514
|
+
"format": "date-time"
|
|
515
|
+
},
|
|
516
|
+
"subject": {
|
|
517
|
+
"type": "string",
|
|
518
|
+
"description": "The ID of the thing the event is about: work item, gate, run, score or pull request."
|
|
519
|
+
},
|
|
520
|
+
"datacontenttype": {
|
|
521
|
+
"type": "string",
|
|
522
|
+
"const": "application/json"
|
|
523
|
+
},
|
|
524
|
+
"dataschema": {
|
|
525
|
+
"type": "string",
|
|
526
|
+
"format": "uri"
|
|
527
|
+
},
|
|
528
|
+
"traceparent": {
|
|
529
|
+
"type": "string",
|
|
530
|
+
"description": "W3C trace context (CloudEvents distributed tracing extension)."
|
|
531
|
+
},
|
|
532
|
+
"data": {
|
|
533
|
+
"$ref": "#/components/schemas/GateRequestedData"
|
|
534
|
+
}
|
|
535
|
+
},
|
|
536
|
+
"required": [
|
|
537
|
+
"specversion",
|
|
538
|
+
"id",
|
|
539
|
+
"source",
|
|
540
|
+
"type",
|
|
541
|
+
"time",
|
|
542
|
+
"data"
|
|
543
|
+
],
|
|
544
|
+
"description": "gatekeeper: a decision is needed before a stage starts."
|
|
545
|
+
},
|
|
546
|
+
"GateRequestedData": {
|
|
547
|
+
"type": "object",
|
|
548
|
+
"properties": {
|
|
549
|
+
"gateId": {
|
|
550
|
+
"$ref": "#/components/schemas/Identifier"
|
|
551
|
+
},
|
|
552
|
+
"workItemId": {
|
|
553
|
+
"$ref": "#/components/schemas/Identifier"
|
|
554
|
+
},
|
|
555
|
+
"runId": {
|
|
556
|
+
"$ref": "#/components/schemas/Identifier"
|
|
557
|
+
},
|
|
558
|
+
"stage": {
|
|
559
|
+
"$ref": "#/components/schemas/Name",
|
|
560
|
+
"description": "The stage that waits."
|
|
561
|
+
},
|
|
562
|
+
"policy": {
|
|
563
|
+
"type": "string",
|
|
564
|
+
"minLength": 1,
|
|
565
|
+
"description": "Path to the policy in the factory definition."
|
|
566
|
+
},
|
|
567
|
+
"approvers": {
|
|
568
|
+
"type": "array",
|
|
569
|
+
"items": {
|
|
570
|
+
"$ref": "#/components/schemas/Name"
|
|
571
|
+
},
|
|
572
|
+
"minItems": 1,
|
|
573
|
+
"description": "Approver groups picked by the policy."
|
|
574
|
+
},
|
|
575
|
+
"summary": {
|
|
576
|
+
"type": "string",
|
|
577
|
+
"minLength": 1,
|
|
578
|
+
"description": "What the approver is asked to decide, shown in the channel."
|
|
579
|
+
},
|
|
580
|
+
"links": {
|
|
581
|
+
"type": "array",
|
|
582
|
+
"items": {
|
|
583
|
+
"$ref": "#/components/schemas/Link"
|
|
584
|
+
}
|
|
585
|
+
},
|
|
586
|
+
"expiresAt": {
|
|
587
|
+
"type": "string",
|
|
588
|
+
"format": "date-time"
|
|
589
|
+
}
|
|
590
|
+
},
|
|
591
|
+
"required": [
|
|
592
|
+
"gateId",
|
|
593
|
+
"workItemId",
|
|
594
|
+
"stage",
|
|
595
|
+
"policy",
|
|
596
|
+
"approvers",
|
|
597
|
+
"summary"
|
|
598
|
+
]
|
|
599
|
+
},
|
|
600
|
+
"Identifier": {
|
|
601
|
+
"type": "string",
|
|
602
|
+
"minLength": 1,
|
|
603
|
+
"maxLength": 128,
|
|
604
|
+
"description": "An identifier chosen by the producer. ULIDs are recommended; consumers treat it as opaque."
|
|
605
|
+
},
|
|
606
|
+
"Link": {
|
|
607
|
+
"type": "object",
|
|
608
|
+
"properties": {
|
|
609
|
+
"url": {
|
|
610
|
+
"type": "string",
|
|
611
|
+
"format": "uri"
|
|
612
|
+
},
|
|
613
|
+
"title": {
|
|
614
|
+
"type": "string"
|
|
615
|
+
}
|
|
616
|
+
},
|
|
617
|
+
"required": [
|
|
618
|
+
"url"
|
|
619
|
+
]
|
|
620
|
+
},
|
|
621
|
+
"Name": {
|
|
622
|
+
"type": "string",
|
|
623
|
+
"pattern": "^[a-z][a-z0-9-]{0,62}$",
|
|
624
|
+
"description": "A lowercase name: letters, digits and hyphens, starting with a letter. Agents, stages, adapters, sources."
|
|
625
|
+
},
|
|
626
|
+
"Origin": {
|
|
627
|
+
"type": "object",
|
|
628
|
+
"properties": {
|
|
629
|
+
"source": {
|
|
630
|
+
"$ref": "#/components/schemas/Name",
|
|
631
|
+
"description": "The channel or system, for example \"slack\", \"github\", \"sentry\", \"cron\", \"mcp\"."
|
|
632
|
+
},
|
|
633
|
+
"url": {
|
|
634
|
+
"type": "string",
|
|
635
|
+
"format": "uri",
|
|
636
|
+
"description": "Link back to the origin, for example the Slack thread. Absent for a schedule."
|
|
637
|
+
},
|
|
638
|
+
"externalId": {
|
|
639
|
+
"type": "string",
|
|
640
|
+
"description": "ID in the source system."
|
|
641
|
+
}
|
|
642
|
+
},
|
|
643
|
+
"required": [
|
|
644
|
+
"source"
|
|
645
|
+
]
|
|
646
|
+
},
|
|
647
|
+
"PrClosed": {
|
|
648
|
+
"type": "object",
|
|
649
|
+
"properties": {
|
|
650
|
+
"specversion": {
|
|
651
|
+
"type": "string",
|
|
652
|
+
"const": "1.0"
|
|
653
|
+
},
|
|
654
|
+
"id": {
|
|
655
|
+
"$ref": "#/components/schemas/Identifier",
|
|
656
|
+
"description": "Unique per source. A consumer that sees the same source and id twice handles the event once."
|
|
657
|
+
},
|
|
658
|
+
"source": {
|
|
659
|
+
"type": "string",
|
|
660
|
+
"minLength": 1,
|
|
661
|
+
"description": "The producing module, for example \"/osf/intake\"."
|
|
662
|
+
},
|
|
663
|
+
"type": {
|
|
664
|
+
"type": "string",
|
|
665
|
+
"const": "pr.closed@v1"
|
|
666
|
+
},
|
|
667
|
+
"time": {
|
|
668
|
+
"type": "string",
|
|
669
|
+
"format": "date-time"
|
|
670
|
+
},
|
|
671
|
+
"subject": {
|
|
672
|
+
"type": "string",
|
|
673
|
+
"description": "The ID of the thing the event is about: work item, gate, run, score or pull request."
|
|
674
|
+
},
|
|
675
|
+
"datacontenttype": {
|
|
676
|
+
"type": "string",
|
|
677
|
+
"const": "application/json"
|
|
678
|
+
},
|
|
679
|
+
"dataschema": {
|
|
680
|
+
"type": "string",
|
|
681
|
+
"format": "uri"
|
|
682
|
+
},
|
|
683
|
+
"traceparent": {
|
|
684
|
+
"type": "string",
|
|
685
|
+
"description": "W3C trace context (CloudEvents distributed tracing extension)."
|
|
686
|
+
},
|
|
687
|
+
"data": {
|
|
688
|
+
"$ref": "#/components/schemas/PrClosedData"
|
|
689
|
+
}
|
|
690
|
+
},
|
|
691
|
+
"required": [
|
|
692
|
+
"specversion",
|
|
693
|
+
"id",
|
|
694
|
+
"source",
|
|
695
|
+
"type",
|
|
696
|
+
"time",
|
|
697
|
+
"data"
|
|
698
|
+
],
|
|
699
|
+
"description": "forge adapters: a pull request was merged or closed without a merge."
|
|
700
|
+
},
|
|
701
|
+
"PrClosedData": {
|
|
702
|
+
"type": "object",
|
|
703
|
+
"properties": {
|
|
704
|
+
"url": {
|
|
705
|
+
"type": "string",
|
|
706
|
+
"format": "uri",
|
|
707
|
+
"description": "The pull request."
|
|
708
|
+
},
|
|
709
|
+
"merged": {
|
|
710
|
+
"type": "boolean",
|
|
711
|
+
"description": "True when the pull request was merged, false when it was closed without a merge."
|
|
712
|
+
},
|
|
713
|
+
"mergeCommit": {
|
|
714
|
+
"$ref": "#/components/schemas/CommitHash"
|
|
715
|
+
}
|
|
716
|
+
},
|
|
717
|
+
"required": [
|
|
718
|
+
"url",
|
|
719
|
+
"merged"
|
|
720
|
+
]
|
|
721
|
+
},
|
|
722
|
+
"PrOpened": {
|
|
723
|
+
"type": "object",
|
|
724
|
+
"properties": {
|
|
725
|
+
"specversion": {
|
|
726
|
+
"type": "string",
|
|
727
|
+
"const": "1.0"
|
|
728
|
+
},
|
|
729
|
+
"id": {
|
|
730
|
+
"$ref": "#/components/schemas/Identifier",
|
|
731
|
+
"description": "Unique per source. A consumer that sees the same source and id twice handles the event once."
|
|
732
|
+
},
|
|
733
|
+
"source": {
|
|
734
|
+
"type": "string",
|
|
735
|
+
"minLength": 1,
|
|
736
|
+
"description": "The producing module, for example \"/osf/intake\"."
|
|
737
|
+
},
|
|
738
|
+
"type": {
|
|
739
|
+
"type": "string",
|
|
740
|
+
"const": "pr.opened@v1"
|
|
741
|
+
},
|
|
742
|
+
"time": {
|
|
743
|
+
"type": "string",
|
|
744
|
+
"format": "date-time"
|
|
745
|
+
},
|
|
746
|
+
"subject": {
|
|
747
|
+
"type": "string",
|
|
748
|
+
"description": "The ID of the thing the event is about: work item, gate, run, score or pull request."
|
|
749
|
+
},
|
|
750
|
+
"datacontenttype": {
|
|
751
|
+
"type": "string",
|
|
752
|
+
"const": "application/json"
|
|
753
|
+
},
|
|
754
|
+
"dataschema": {
|
|
755
|
+
"type": "string",
|
|
756
|
+
"format": "uri"
|
|
757
|
+
},
|
|
758
|
+
"traceparent": {
|
|
759
|
+
"type": "string",
|
|
760
|
+
"description": "W3C trace context (CloudEvents distributed tracing extension)."
|
|
761
|
+
},
|
|
762
|
+
"data": {
|
|
763
|
+
"$ref": "#/components/schemas/PrOpenedData"
|
|
764
|
+
}
|
|
765
|
+
},
|
|
766
|
+
"required": [
|
|
767
|
+
"specversion",
|
|
768
|
+
"id",
|
|
769
|
+
"source",
|
|
770
|
+
"type",
|
|
771
|
+
"time",
|
|
772
|
+
"data"
|
|
773
|
+
],
|
|
774
|
+
"description": "forge adapters: the factory opened a pull request."
|
|
775
|
+
},
|
|
776
|
+
"PrOpenedData": {
|
|
777
|
+
"type": "object",
|
|
778
|
+
"properties": {
|
|
779
|
+
"url": {
|
|
780
|
+
"type": "string",
|
|
781
|
+
"format": "uri"
|
|
782
|
+
},
|
|
783
|
+
"repository": {
|
|
784
|
+
"type": "string",
|
|
785
|
+
"format": "uri"
|
|
786
|
+
},
|
|
787
|
+
"number": {
|
|
788
|
+
"type": "integer",
|
|
789
|
+
"minimum": 1
|
|
790
|
+
},
|
|
791
|
+
"title": {
|
|
792
|
+
"type": "string",
|
|
793
|
+
"minLength": 1
|
|
794
|
+
},
|
|
795
|
+
"headBranch": {
|
|
796
|
+
"type": "string"
|
|
797
|
+
},
|
|
798
|
+
"baseBranch": {
|
|
799
|
+
"type": "string"
|
|
800
|
+
},
|
|
801
|
+
"headCommit": {
|
|
802
|
+
"$ref": "#/components/schemas/CommitHash"
|
|
803
|
+
},
|
|
804
|
+
"author": {
|
|
805
|
+
"$ref": "#/components/schemas/Actor"
|
|
806
|
+
},
|
|
807
|
+
"workItemId": {
|
|
808
|
+
"$ref": "#/components/schemas/Identifier"
|
|
809
|
+
},
|
|
810
|
+
"runId": {
|
|
811
|
+
"$ref": "#/components/schemas/Identifier"
|
|
812
|
+
}
|
|
813
|
+
},
|
|
814
|
+
"required": [
|
|
815
|
+
"url",
|
|
816
|
+
"repository",
|
|
817
|
+
"number",
|
|
818
|
+
"title",
|
|
819
|
+
"headBranch",
|
|
820
|
+
"baseBranch",
|
|
821
|
+
"headCommit",
|
|
822
|
+
"author"
|
|
823
|
+
]
|
|
824
|
+
},
|
|
825
|
+
"PrReviewed": {
|
|
826
|
+
"type": "object",
|
|
827
|
+
"properties": {
|
|
828
|
+
"specversion": {
|
|
829
|
+
"type": "string",
|
|
830
|
+
"const": "1.0"
|
|
831
|
+
},
|
|
832
|
+
"id": {
|
|
833
|
+
"$ref": "#/components/schemas/Identifier",
|
|
834
|
+
"description": "Unique per source. A consumer that sees the same source and id twice handles the event once."
|
|
835
|
+
},
|
|
836
|
+
"source": {
|
|
837
|
+
"type": "string",
|
|
838
|
+
"minLength": 1,
|
|
839
|
+
"description": "The producing module, for example \"/osf/intake\"."
|
|
840
|
+
},
|
|
841
|
+
"type": {
|
|
842
|
+
"type": "string",
|
|
843
|
+
"const": "pr.reviewed@v1"
|
|
844
|
+
},
|
|
845
|
+
"time": {
|
|
846
|
+
"type": "string",
|
|
847
|
+
"format": "date-time"
|
|
848
|
+
},
|
|
849
|
+
"subject": {
|
|
850
|
+
"type": "string",
|
|
851
|
+
"description": "The ID of the thing the event is about: work item, gate, run, score or pull request."
|
|
852
|
+
},
|
|
853
|
+
"datacontenttype": {
|
|
854
|
+
"type": "string",
|
|
855
|
+
"const": "application/json"
|
|
856
|
+
},
|
|
857
|
+
"dataschema": {
|
|
858
|
+
"type": "string",
|
|
859
|
+
"format": "uri"
|
|
860
|
+
},
|
|
861
|
+
"traceparent": {
|
|
862
|
+
"type": "string",
|
|
863
|
+
"description": "W3C trace context (CloudEvents distributed tracing extension)."
|
|
864
|
+
},
|
|
865
|
+
"data": {
|
|
866
|
+
"$ref": "#/components/schemas/PrReviewedData"
|
|
867
|
+
}
|
|
868
|
+
},
|
|
869
|
+
"required": [
|
|
870
|
+
"specversion",
|
|
871
|
+
"id",
|
|
872
|
+
"source",
|
|
873
|
+
"type",
|
|
874
|
+
"time",
|
|
875
|
+
"data"
|
|
876
|
+
],
|
|
877
|
+
"description": "forge adapters: a person, an agent or a bot reviewed or commented on a pull request."
|
|
878
|
+
},
|
|
879
|
+
"PrReviewedData": {
|
|
880
|
+
"type": "object",
|
|
881
|
+
"properties": {
|
|
882
|
+
"url": {
|
|
883
|
+
"type": "string",
|
|
884
|
+
"format": "uri",
|
|
885
|
+
"description": "The pull request."
|
|
886
|
+
},
|
|
887
|
+
"reviewer": {
|
|
888
|
+
"$ref": "#/components/schemas/Actor"
|
|
889
|
+
},
|
|
890
|
+
"automated": {
|
|
891
|
+
"type": "boolean",
|
|
892
|
+
"description": "True when an agent or a bot wrote the review, not a person."
|
|
893
|
+
},
|
|
894
|
+
"state": {
|
|
895
|
+
"$ref": "#/components/schemas/ReviewState"
|
|
896
|
+
}
|
|
897
|
+
},
|
|
898
|
+
"required": [
|
|
899
|
+
"url",
|
|
900
|
+
"reviewer",
|
|
901
|
+
"state"
|
|
902
|
+
]
|
|
903
|
+
},
|
|
904
|
+
"Priority": {
|
|
905
|
+
"type": "string",
|
|
906
|
+
"enum": [
|
|
907
|
+
"urgent",
|
|
908
|
+
"high",
|
|
909
|
+
"normal",
|
|
910
|
+
"low"
|
|
911
|
+
]
|
|
912
|
+
},
|
|
913
|
+
"Producer": {
|
|
914
|
+
"type": "object",
|
|
915
|
+
"properties": {
|
|
916
|
+
"name": {
|
|
917
|
+
"type": "string",
|
|
918
|
+
"minLength": 1
|
|
919
|
+
},
|
|
920
|
+
"version": {
|
|
921
|
+
"type": "string",
|
|
922
|
+
"minLength": 1
|
|
923
|
+
}
|
|
924
|
+
},
|
|
925
|
+
"required": [
|
|
926
|
+
"name",
|
|
927
|
+
"version"
|
|
928
|
+
]
|
|
929
|
+
},
|
|
930
|
+
"Providers": {
|
|
931
|
+
"type": "object",
|
|
932
|
+
"properties": {
|
|
933
|
+
"harness": {
|
|
934
|
+
"type": "object",
|
|
935
|
+
"properties": {},
|
|
936
|
+
"unevaluatedProperties": {
|
|
937
|
+
"$ref": "#/components/schemas/VersionRange"
|
|
938
|
+
}
|
|
939
|
+
},
|
|
940
|
+
"sandbox": {
|
|
941
|
+
"type": "object",
|
|
942
|
+
"properties": {},
|
|
943
|
+
"unevaluatedProperties": {
|
|
944
|
+
"$ref": "#/components/schemas/VersionRange"
|
|
945
|
+
}
|
|
946
|
+
},
|
|
947
|
+
"channel": {
|
|
948
|
+
"type": "object",
|
|
949
|
+
"properties": {},
|
|
950
|
+
"unevaluatedProperties": {
|
|
951
|
+
"$ref": "#/components/schemas/VersionRange"
|
|
952
|
+
}
|
|
953
|
+
},
|
|
954
|
+
"tracker": {
|
|
955
|
+
"type": "object",
|
|
956
|
+
"properties": {},
|
|
957
|
+
"unevaluatedProperties": {
|
|
958
|
+
"$ref": "#/components/schemas/VersionRange"
|
|
959
|
+
}
|
|
960
|
+
},
|
|
961
|
+
"forge": {
|
|
962
|
+
"type": "object",
|
|
963
|
+
"properties": {},
|
|
964
|
+
"unevaluatedProperties": {
|
|
965
|
+
"$ref": "#/components/schemas/VersionRange"
|
|
966
|
+
}
|
|
967
|
+
},
|
|
968
|
+
"inference": {
|
|
969
|
+
"type": "object",
|
|
970
|
+
"properties": {},
|
|
971
|
+
"unevaluatedProperties": {
|
|
972
|
+
"$ref": "#/components/schemas/VersionRange"
|
|
973
|
+
}
|
|
974
|
+
},
|
|
975
|
+
"secrets": {
|
|
976
|
+
"type": "object",
|
|
977
|
+
"properties": {},
|
|
978
|
+
"unevaluatedProperties": {
|
|
979
|
+
"$ref": "#/components/schemas/VersionRange"
|
|
980
|
+
}
|
|
981
|
+
},
|
|
982
|
+
"telemetry": {
|
|
983
|
+
"type": "object",
|
|
984
|
+
"properties": {},
|
|
985
|
+
"unevaluatedProperties": {
|
|
986
|
+
"$ref": "#/components/schemas/VersionRange"
|
|
987
|
+
}
|
|
988
|
+
},
|
|
989
|
+
"policy": {
|
|
990
|
+
"type": "object",
|
|
991
|
+
"properties": {},
|
|
992
|
+
"unevaluatedProperties": {
|
|
993
|
+
"$ref": "#/components/schemas/VersionRange"
|
|
994
|
+
}
|
|
995
|
+
}
|
|
996
|
+
},
|
|
997
|
+
"description": "The adapters a factory uses, per port (docs/architecture/internals.md). Keys are adapter names.",
|
|
998
|
+
"additionalProperties": false
|
|
999
|
+
},
|
|
1000
|
+
"ReviewState": {
|
|
1001
|
+
"type": "string",
|
|
1002
|
+
"enum": [
|
|
1003
|
+
"approved",
|
|
1004
|
+
"changes_requested",
|
|
1005
|
+
"commented"
|
|
1006
|
+
]
|
|
1007
|
+
},
|
|
1008
|
+
"RunCompleted": {
|
|
1009
|
+
"type": "object",
|
|
1010
|
+
"properties": {
|
|
1011
|
+
"specversion": {
|
|
1012
|
+
"type": "string",
|
|
1013
|
+
"const": "1.0"
|
|
1014
|
+
},
|
|
1015
|
+
"id": {
|
|
1016
|
+
"$ref": "#/components/schemas/Identifier",
|
|
1017
|
+
"description": "Unique per source. A consumer that sees the same source and id twice handles the event once."
|
|
1018
|
+
},
|
|
1019
|
+
"source": {
|
|
1020
|
+
"type": "string",
|
|
1021
|
+
"minLength": 1,
|
|
1022
|
+
"description": "The producing module, for example \"/osf/intake\"."
|
|
1023
|
+
},
|
|
1024
|
+
"type": {
|
|
1025
|
+
"type": "string",
|
|
1026
|
+
"const": "run.completed@v1"
|
|
1027
|
+
},
|
|
1028
|
+
"time": {
|
|
1029
|
+
"type": "string",
|
|
1030
|
+
"format": "date-time"
|
|
1031
|
+
},
|
|
1032
|
+
"subject": {
|
|
1033
|
+
"type": "string",
|
|
1034
|
+
"description": "The ID of the thing the event is about: work item, gate, run, score or pull request."
|
|
1035
|
+
},
|
|
1036
|
+
"datacontenttype": {
|
|
1037
|
+
"type": "string",
|
|
1038
|
+
"const": "application/json"
|
|
1039
|
+
},
|
|
1040
|
+
"dataschema": {
|
|
1041
|
+
"type": "string",
|
|
1042
|
+
"format": "uri"
|
|
1043
|
+
},
|
|
1044
|
+
"traceparent": {
|
|
1045
|
+
"type": "string",
|
|
1046
|
+
"description": "W3C trace context (CloudEvents distributed tracing extension)."
|
|
1047
|
+
},
|
|
1048
|
+
"data": {
|
|
1049
|
+
"$ref": "#/components/schemas/RunCompletedData"
|
|
1050
|
+
}
|
|
1051
|
+
},
|
|
1052
|
+
"required": [
|
|
1053
|
+
"specversion",
|
|
1054
|
+
"id",
|
|
1055
|
+
"source",
|
|
1056
|
+
"type",
|
|
1057
|
+
"time",
|
|
1058
|
+
"data"
|
|
1059
|
+
],
|
|
1060
|
+
"description": "foreman: a run ended."
|
|
1061
|
+
},
|
|
1062
|
+
"RunCompletedData": {
|
|
1063
|
+
"type": "object",
|
|
1064
|
+
"properties": {
|
|
1065
|
+
"runId": {
|
|
1066
|
+
"$ref": "#/components/schemas/Identifier"
|
|
1067
|
+
},
|
|
1068
|
+
"workItemId": {
|
|
1069
|
+
"$ref": "#/components/schemas/Identifier"
|
|
1070
|
+
},
|
|
1071
|
+
"stage": {
|
|
1072
|
+
"$ref": "#/components/schemas/Name"
|
|
1073
|
+
},
|
|
1074
|
+
"factoryVersion": {
|
|
1075
|
+
"$ref": "#/components/schemas/CommitHash"
|
|
1076
|
+
},
|
|
1077
|
+
"outcome": {
|
|
1078
|
+
"$ref": "#/components/schemas/RunOutcome"
|
|
1079
|
+
},
|
|
1080
|
+
"startedAt": {
|
|
1081
|
+
"type": "string",
|
|
1082
|
+
"format": "date-time"
|
|
1083
|
+
},
|
|
1084
|
+
"endedAt": {
|
|
1085
|
+
"type": "string",
|
|
1086
|
+
"format": "date-time"
|
|
1087
|
+
},
|
|
1088
|
+
"requester": {
|
|
1089
|
+
"$ref": "#/components/schemas/Actor"
|
|
1090
|
+
},
|
|
1091
|
+
"source": {
|
|
1092
|
+
"$ref": "#/components/schemas/Name"
|
|
1093
|
+
},
|
|
1094
|
+
"costUsd": {
|
|
1095
|
+
"type": "number",
|
|
1096
|
+
"minimum": 0
|
|
1097
|
+
},
|
|
1098
|
+
"traceId": {
|
|
1099
|
+
"$ref": "#/components/schemas/TraceId"
|
|
1100
|
+
},
|
|
1101
|
+
"pullRequests": {
|
|
1102
|
+
"type": "array",
|
|
1103
|
+
"items": {
|
|
1104
|
+
"type": "string",
|
|
1105
|
+
"format": "uri"
|
|
1106
|
+
}
|
|
1107
|
+
},
|
|
1108
|
+
"evidenceBundle": {
|
|
1109
|
+
"type": "string",
|
|
1110
|
+
"format": "uri"
|
|
1111
|
+
}
|
|
1112
|
+
},
|
|
1113
|
+
"required": [
|
|
1114
|
+
"runId",
|
|
1115
|
+
"workItemId",
|
|
1116
|
+
"factoryVersion",
|
|
1117
|
+
"outcome",
|
|
1118
|
+
"startedAt",
|
|
1119
|
+
"endedAt",
|
|
1120
|
+
"requester",
|
|
1121
|
+
"source"
|
|
1122
|
+
]
|
|
1123
|
+
},
|
|
1124
|
+
"RunOutcome": {
|
|
1125
|
+
"type": "string",
|
|
1126
|
+
"enum": [
|
|
1127
|
+
"succeeded",
|
|
1128
|
+
"failed",
|
|
1129
|
+
"cancelled"
|
|
1130
|
+
],
|
|
1131
|
+
"description": "How a run ended."
|
|
1132
|
+
},
|
|
1133
|
+
"RunRecord": {
|
|
1134
|
+
"type": "object",
|
|
1135
|
+
"properties": {
|
|
1136
|
+
"resource": {
|
|
1137
|
+
"$ref": "#/components/schemas/RunResource"
|
|
1138
|
+
},
|
|
1139
|
+
"span": {
|
|
1140
|
+
"$ref": "#/components/schemas/RunSpan"
|
|
1141
|
+
}
|
|
1142
|
+
},
|
|
1143
|
+
"required": [
|
|
1144
|
+
"resource",
|
|
1145
|
+
"span"
|
|
1146
|
+
],
|
|
1147
|
+
"description": "The attributes of one run: the OTel resource of every span of the run, and the attributes of its root\n`invoke_agent` span. The run record travels as OTLP; this schema fixes the attribute names and types.\nRealizes SCN-FACTORY-DATA-001 (record shape) and SCN-FACTORY-RUNTIME-008 (attribution)."
|
|
1148
|
+
},
|
|
1149
|
+
"RunResource": {
|
|
1150
|
+
"type": "object",
|
|
1151
|
+
"properties": {
|
|
1152
|
+
"service.name": {
|
|
1153
|
+
"type": "string"
|
|
1154
|
+
},
|
|
1155
|
+
"osf.run.id": {
|
|
1156
|
+
"$ref": "#/components/schemas/Identifier"
|
|
1157
|
+
},
|
|
1158
|
+
"osf.work_item.id": {
|
|
1159
|
+
"$ref": "#/components/schemas/Identifier"
|
|
1160
|
+
},
|
|
1161
|
+
"osf.factory.version": {
|
|
1162
|
+
"$ref": "#/components/schemas/CommitHash",
|
|
1163
|
+
"description": "Commit of the factory definition the run used."
|
|
1164
|
+
},
|
|
1165
|
+
"osf.stage": {
|
|
1166
|
+
"$ref": "#/components/schemas/Name"
|
|
1167
|
+
},
|
|
1168
|
+
"osf.requester.kind": {
|
|
1169
|
+
"$ref": "#/components/schemas/ActorKind"
|
|
1170
|
+
},
|
|
1171
|
+
"osf.requester.id": {
|
|
1172
|
+
"type": "string"
|
|
1173
|
+
},
|
|
1174
|
+
"osf.source": {
|
|
1175
|
+
"$ref": "#/components/schemas/Name",
|
|
1176
|
+
"description": "Where the run was started from, for example \"slack\", \"github\", \"cli\"."
|
|
1177
|
+
},
|
|
1178
|
+
"osf.origin.url": {
|
|
1179
|
+
"type": "string",
|
|
1180
|
+
"format": "uri"
|
|
1181
|
+
},
|
|
1182
|
+
"osf.harness.name": {
|
|
1183
|
+
"$ref": "#/components/schemas/Name",
|
|
1184
|
+
"description": "Harness adapter, for example \"claude-code\"."
|
|
1185
|
+
},
|
|
1186
|
+
"osf.harness.version": {
|
|
1187
|
+
"type": "string"
|
|
1188
|
+
}
|
|
1189
|
+
},
|
|
1190
|
+
"required": [
|
|
1191
|
+
"service.name",
|
|
1192
|
+
"osf.run.id",
|
|
1193
|
+
"osf.work_item.id",
|
|
1194
|
+
"osf.factory.version",
|
|
1195
|
+
"osf.requester.kind",
|
|
1196
|
+
"osf.requester.id",
|
|
1197
|
+
"osf.source",
|
|
1198
|
+
"osf.harness.name"
|
|
1199
|
+
],
|
|
1200
|
+
"description": "Set at launch through OTEL_RESOURCE_ATTRIBUTES, so it is on every span of the run."
|
|
1201
|
+
},
|
|
1202
|
+
"RunSpan": {
|
|
1203
|
+
"type": "object",
|
|
1204
|
+
"properties": {
|
|
1205
|
+
"gen_ai.operation.name": {
|
|
1206
|
+
"type": "string",
|
|
1207
|
+
"const": "invoke_agent"
|
|
1208
|
+
},
|
|
1209
|
+
"gen_ai.provider.name": {
|
|
1210
|
+
"type": "string"
|
|
1211
|
+
},
|
|
1212
|
+
"gen_ai.agent.name": {
|
|
1213
|
+
"type": "string"
|
|
1214
|
+
},
|
|
1215
|
+
"gen_ai.conversation.id": {
|
|
1216
|
+
"type": "string",
|
|
1217
|
+
"description": "The harness session ID."
|
|
1218
|
+
},
|
|
1219
|
+
"gen_ai.request.model": {
|
|
1220
|
+
"type": "string"
|
|
1221
|
+
},
|
|
1222
|
+
"gen_ai.response.model": {
|
|
1223
|
+
"type": "string"
|
|
1224
|
+
},
|
|
1225
|
+
"gen_ai.usage.input_tokens": {
|
|
1226
|
+
"type": "integer",
|
|
1227
|
+
"minimum": 0
|
|
1228
|
+
},
|
|
1229
|
+
"gen_ai.usage.output_tokens": {
|
|
1230
|
+
"type": "integer",
|
|
1231
|
+
"minimum": 0
|
|
1232
|
+
},
|
|
1233
|
+
"gen_ai.usage.cache_read.input_tokens": {
|
|
1234
|
+
"type": "integer",
|
|
1235
|
+
"minimum": 0
|
|
1236
|
+
},
|
|
1237
|
+
"gen_ai.usage.cache_write.input_tokens": {
|
|
1238
|
+
"type": "integer",
|
|
1239
|
+
"minimum": 0
|
|
1240
|
+
},
|
|
1241
|
+
"osf.outcome": {
|
|
1242
|
+
"$ref": "#/components/schemas/RunOutcome"
|
|
1243
|
+
},
|
|
1244
|
+
"osf.cost.usd": {
|
|
1245
|
+
"type": "number",
|
|
1246
|
+
"minimum": 0,
|
|
1247
|
+
"description": "Cost of all model calls of the run, from the inference gateway."
|
|
1248
|
+
},
|
|
1249
|
+
"osf.transcript.uri": {
|
|
1250
|
+
"type": "string",
|
|
1251
|
+
"format": "uri",
|
|
1252
|
+
"description": "Full transcript, stored when the run ends."
|
|
1253
|
+
},
|
|
1254
|
+
"osf.artifact.uris": {
|
|
1255
|
+
"type": "array",
|
|
1256
|
+
"items": {
|
|
1257
|
+
"type": "string",
|
|
1258
|
+
"format": "uri"
|
|
1259
|
+
},
|
|
1260
|
+
"description": "Artifacts of the run: reports, screenshots, videos."
|
|
1261
|
+
},
|
|
1262
|
+
"osf.pull_request.urls": {
|
|
1263
|
+
"type": "array",
|
|
1264
|
+
"items": {
|
|
1265
|
+
"type": "string",
|
|
1266
|
+
"format": "uri"
|
|
1267
|
+
}
|
|
1268
|
+
},
|
|
1269
|
+
"osf.issue.urls": {
|
|
1270
|
+
"type": "array",
|
|
1271
|
+
"items": {
|
|
1272
|
+
"type": "string",
|
|
1273
|
+
"format": "uri"
|
|
1274
|
+
}
|
|
1275
|
+
},
|
|
1276
|
+
"osf.evidence_bundle.uri": {
|
|
1277
|
+
"type": "string",
|
|
1278
|
+
"format": "uri"
|
|
1279
|
+
},
|
|
1280
|
+
"osf.agent_trace.uri": {
|
|
1281
|
+
"type": "string",
|
|
1282
|
+
"format": "uri",
|
|
1283
|
+
"description": "Agent Trace record with line attribution of the run's changes."
|
|
1284
|
+
}
|
|
1285
|
+
},
|
|
1286
|
+
"required": [
|
|
1287
|
+
"gen_ai.operation.name",
|
|
1288
|
+
"osf.outcome"
|
|
1289
|
+
],
|
|
1290
|
+
"description": "Attributes of the root span of the run. GenAI names where a convention exists."
|
|
1291
|
+
},
|
|
1292
|
+
"Sandbox": {
|
|
1293
|
+
"type": "object",
|
|
1294
|
+
"properties": {
|
|
1295
|
+
"template": {
|
|
1296
|
+
"type": "string",
|
|
1297
|
+
"minLength": 1,
|
|
1298
|
+
"description": "Sandbox template name, for example \"node-24\"."
|
|
1299
|
+
},
|
|
1300
|
+
"cpu": {
|
|
1301
|
+
"type": "number",
|
|
1302
|
+
"minimum": 0.001,
|
|
1303
|
+
"description": "CPU cores. The smallest unit is 0.001 (one millicore)."
|
|
1304
|
+
},
|
|
1305
|
+
"memory": {
|
|
1306
|
+
"type": "string",
|
|
1307
|
+
"pattern": "^[0-9]+(Ki|Mi|Gi|Ti)?$",
|
|
1308
|
+
"description": "Kubernetes quantity, for example \"8Gi\"."
|
|
1309
|
+
},
|
|
1310
|
+
"egress": {
|
|
1311
|
+
"type": "array",
|
|
1312
|
+
"items": {
|
|
1313
|
+
"type": "string"
|
|
1314
|
+
},
|
|
1315
|
+
"description": "Hostnames the sandbox may reach. Everything else is blocked."
|
|
1316
|
+
}
|
|
1317
|
+
},
|
|
1318
|
+
"required": [
|
|
1319
|
+
"template"
|
|
1320
|
+
],
|
|
1321
|
+
"additionalProperties": false
|
|
1322
|
+
},
|
|
1323
|
+
"ScenarioEvidence": {
|
|
1324
|
+
"type": "object",
|
|
1325
|
+
"properties": {
|
|
1326
|
+
"id": {
|
|
1327
|
+
"$ref": "#/components/schemas/ScenarioId"
|
|
1328
|
+
},
|
|
1329
|
+
"result": {
|
|
1330
|
+
"$ref": "#/components/schemas/ScenarioResult"
|
|
1331
|
+
},
|
|
1332
|
+
"artifacts": {
|
|
1333
|
+
"type": "array",
|
|
1334
|
+
"items": {
|
|
1335
|
+
"$ref": "#/components/schemas/BundlePath"
|
|
1336
|
+
},
|
|
1337
|
+
"description": "Paths of the artifacts in this bundle that prove the scenario."
|
|
1338
|
+
},
|
|
1339
|
+
"summary": {
|
|
1340
|
+
"type": "string"
|
|
1341
|
+
}
|
|
1342
|
+
},
|
|
1343
|
+
"required": [
|
|
1344
|
+
"id",
|
|
1345
|
+
"result",
|
|
1346
|
+
"artifacts"
|
|
1347
|
+
]
|
|
1348
|
+
},
|
|
1349
|
+
"ScenarioId": {
|
|
1350
|
+
"type": "string",
|
|
1351
|
+
"pattern": "^SCN-[A-Z][A-Z0-9]*(-[A-Z][A-Z0-9]*)*-[0-9]{3}$",
|
|
1352
|
+
"description": "A scenario ID as checked by SPEC, for example SCN-PROOF-004."
|
|
1353
|
+
},
|
|
1354
|
+
"ScenarioResult": {
|
|
1355
|
+
"type": "string",
|
|
1356
|
+
"enum": [
|
|
1357
|
+
"passed",
|
|
1358
|
+
"failed",
|
|
1359
|
+
"skipped"
|
|
1360
|
+
]
|
|
1361
|
+
},
|
|
1362
|
+
"Score": {
|
|
1363
|
+
"type": "object",
|
|
1364
|
+
"properties": {
|
|
1365
|
+
"id": {
|
|
1366
|
+
"$ref": "#/components/schemas/Identifier"
|
|
1367
|
+
},
|
|
1368
|
+
"name": {
|
|
1369
|
+
"type": "string",
|
|
1370
|
+
"minLength": 1,
|
|
1371
|
+
"description": "Scorer name, for example \"redundant-tests\"."
|
|
1372
|
+
},
|
|
1373
|
+
"value": {
|
|
1374
|
+
"anyOf": [
|
|
1375
|
+
{
|
|
1376
|
+
"type": "number"
|
|
1377
|
+
},
|
|
1378
|
+
{
|
|
1379
|
+
"type": "string"
|
|
1380
|
+
}
|
|
1381
|
+
],
|
|
1382
|
+
"description": "A number for NUMERIC, 0 or 1 for BOOLEAN, a string for CATEGORICAL."
|
|
1383
|
+
},
|
|
1384
|
+
"dataType": {
|
|
1385
|
+
"$ref": "#/components/schemas/ScoreDataType"
|
|
1386
|
+
},
|
|
1387
|
+
"traceId": {
|
|
1388
|
+
"$ref": "#/components/schemas/TraceId",
|
|
1389
|
+
"description": "Trace of the run (the OTel trace ID)."
|
|
1390
|
+
},
|
|
1391
|
+
"observationId": {
|
|
1392
|
+
"type": "string",
|
|
1393
|
+
"description": "Span the score is about, when it is not the whole run."
|
|
1394
|
+
},
|
|
1395
|
+
"sessionId": {
|
|
1396
|
+
"type": "string"
|
|
1397
|
+
},
|
|
1398
|
+
"comment": {
|
|
1399
|
+
"type": "string",
|
|
1400
|
+
"description": "The reason."
|
|
1401
|
+
},
|
|
1402
|
+
"timestamp": {
|
|
1403
|
+
"type": "string",
|
|
1404
|
+
"format": "date-time"
|
|
1405
|
+
},
|
|
1406
|
+
"source": {
|
|
1407
|
+
"$ref": "#/components/schemas/ScoreSource",
|
|
1408
|
+
"description": "API for scorers, ANNOTATION for scores a person reviews."
|
|
1409
|
+
},
|
|
1410
|
+
"configId": {
|
|
1411
|
+
"type": "string"
|
|
1412
|
+
},
|
|
1413
|
+
"environment": {
|
|
1414
|
+
"type": "string"
|
|
1415
|
+
},
|
|
1416
|
+
"metadata": {
|
|
1417
|
+
"$ref": "#/components/schemas/ScoreMetadata"
|
|
1418
|
+
}
|
|
1419
|
+
},
|
|
1420
|
+
"required": [
|
|
1421
|
+
"id",
|
|
1422
|
+
"name",
|
|
1423
|
+
"value",
|
|
1424
|
+
"dataType",
|
|
1425
|
+
"traceId",
|
|
1426
|
+
"timestamp",
|
|
1427
|
+
"metadata"
|
|
1428
|
+
],
|
|
1429
|
+
"description": "The result of one scorer on one run. The fields are a subset of Langfuse's create-score request\n(POST /api/public/scores), so a score can be sent to Langfuse as is. Factory fields live in `metadata`."
|
|
1430
|
+
},
|
|
1431
|
+
"ScoreDataType": {
|
|
1432
|
+
"type": "string",
|
|
1433
|
+
"enum": [
|
|
1434
|
+
"NUMERIC",
|
|
1435
|
+
"BOOLEAN",
|
|
1436
|
+
"CATEGORICAL"
|
|
1437
|
+
]
|
|
1438
|
+
},
|
|
1439
|
+
"ScoreMetadata": {
|
|
1440
|
+
"type": "object",
|
|
1441
|
+
"properties": {
|
|
1442
|
+
"osf.run.id": {
|
|
1443
|
+
"$ref": "#/components/schemas/Identifier"
|
|
1444
|
+
},
|
|
1445
|
+
"osf.scorer.version": {
|
|
1446
|
+
"type": "string"
|
|
1447
|
+
},
|
|
1448
|
+
"osf.judge.model": {
|
|
1449
|
+
"type": "string",
|
|
1450
|
+
"description": "Judge model of an LLM scorer."
|
|
1451
|
+
},
|
|
1452
|
+
"osf.judge.cost.usd": {
|
|
1453
|
+
"type": "number",
|
|
1454
|
+
"minimum": 0,
|
|
1455
|
+
"description": "Cost of the judge call."
|
|
1456
|
+
}
|
|
1457
|
+
},
|
|
1458
|
+
"required": [
|
|
1459
|
+
"osf.run.id"
|
|
1460
|
+
],
|
|
1461
|
+
"unevaluatedProperties": {}
|
|
1462
|
+
},
|
|
1463
|
+
"ScoreRecorded": {
|
|
1464
|
+
"type": "object",
|
|
1465
|
+
"properties": {
|
|
1466
|
+
"specversion": {
|
|
1467
|
+
"type": "string",
|
|
1468
|
+
"const": "1.0"
|
|
1469
|
+
},
|
|
1470
|
+
"id": {
|
|
1471
|
+
"$ref": "#/components/schemas/Identifier",
|
|
1472
|
+
"description": "Unique per source. A consumer that sees the same source and id twice handles the event once."
|
|
1473
|
+
},
|
|
1474
|
+
"source": {
|
|
1475
|
+
"type": "string",
|
|
1476
|
+
"minLength": 1,
|
|
1477
|
+
"description": "The producing module, for example \"/osf/intake\"."
|
|
1478
|
+
},
|
|
1479
|
+
"type": {
|
|
1480
|
+
"type": "string",
|
|
1481
|
+
"const": "score.recorded@v1"
|
|
1482
|
+
},
|
|
1483
|
+
"time": {
|
|
1484
|
+
"type": "string",
|
|
1485
|
+
"format": "date-time"
|
|
1486
|
+
},
|
|
1487
|
+
"subject": {
|
|
1488
|
+
"type": "string",
|
|
1489
|
+
"description": "The ID of the thing the event is about: work item, gate, run, score or pull request."
|
|
1490
|
+
},
|
|
1491
|
+
"datacontenttype": {
|
|
1492
|
+
"type": "string",
|
|
1493
|
+
"const": "application/json"
|
|
1494
|
+
},
|
|
1495
|
+
"dataschema": {
|
|
1496
|
+
"type": "string",
|
|
1497
|
+
"format": "uri"
|
|
1498
|
+
},
|
|
1499
|
+
"traceparent": {
|
|
1500
|
+
"type": "string",
|
|
1501
|
+
"description": "W3C trace context (CloudEvents distributed tracing extension)."
|
|
1502
|
+
},
|
|
1503
|
+
"data": {
|
|
1504
|
+
"$ref": "#/components/schemas/Score"
|
|
1505
|
+
}
|
|
1506
|
+
},
|
|
1507
|
+
"required": [
|
|
1508
|
+
"specversion",
|
|
1509
|
+
"id",
|
|
1510
|
+
"source",
|
|
1511
|
+
"type",
|
|
1512
|
+
"time",
|
|
1513
|
+
"data"
|
|
1514
|
+
],
|
|
1515
|
+
"description": "scorekit: a scorer scored a run."
|
|
1516
|
+
},
|
|
1517
|
+
"ScoreSource": {
|
|
1518
|
+
"type": "string",
|
|
1519
|
+
"enum": [
|
|
1520
|
+
"API",
|
|
1521
|
+
"ANNOTATION"
|
|
1522
|
+
]
|
|
1523
|
+
},
|
|
1524
|
+
"Scorer": {
|
|
1525
|
+
"type": "object",
|
|
1526
|
+
"properties": {
|
|
1527
|
+
"judge": {
|
|
1528
|
+
"type": "string",
|
|
1529
|
+
"minLength": 1,
|
|
1530
|
+
"description": "Path to the Markdown judge prompt."
|
|
1531
|
+
},
|
|
1532
|
+
"sample": {
|
|
1533
|
+
"type": "number",
|
|
1534
|
+
"minimum": 0,
|
|
1535
|
+
"maximum": 1,
|
|
1536
|
+
"description": "Share of runs to score, 0 to 1. Default 1."
|
|
1537
|
+
}
|
|
1538
|
+
},
|
|
1539
|
+
"required": [
|
|
1540
|
+
"judge"
|
|
1541
|
+
],
|
|
1542
|
+
"additionalProperties": false
|
|
1543
|
+
},
|
|
1544
|
+
"SecretReference": {
|
|
1545
|
+
"type": "string",
|
|
1546
|
+
"pattern": "^ref:[a-z][a-z0-9-]*/[A-Za-z0-9_./-]+$",
|
|
1547
|
+
"description": "A reference to a secret, resolved at the egress proxy, never in the sandbox: \"ref:<provider>/<name>\"."
|
|
1548
|
+
},
|
|
1549
|
+
"Sha256": {
|
|
1550
|
+
"type": "string",
|
|
1551
|
+
"pattern": "^[0-9a-f]{64}$"
|
|
1552
|
+
},
|
|
1553
|
+
"Stage": {
|
|
1554
|
+
"type": "object",
|
|
1555
|
+
"properties": {
|
|
1556
|
+
"stage": {
|
|
1557
|
+
"$ref": "#/components/schemas/Name"
|
|
1558
|
+
},
|
|
1559
|
+
"agent": {
|
|
1560
|
+
"$ref": "#/components/schemas/Name",
|
|
1561
|
+
"description": "Agent that runs the stage. Defaults to the agent with the stage's name."
|
|
1562
|
+
},
|
|
1563
|
+
"gate": {
|
|
1564
|
+
"$ref": "#/components/schemas/Gate",
|
|
1565
|
+
"description": "The stage waits for a decision before it starts."
|
|
1566
|
+
},
|
|
1567
|
+
"evidence": {
|
|
1568
|
+
"$ref": "#/components/schemas/EvidenceRequirement",
|
|
1569
|
+
"description": "Whether the stage must produce an evidence bundle."
|
|
1570
|
+
}
|
|
1571
|
+
},
|
|
1572
|
+
"required": [
|
|
1573
|
+
"stage"
|
|
1574
|
+
],
|
|
1575
|
+
"additionalProperties": false
|
|
1576
|
+
},
|
|
1577
|
+
"TraceId": {
|
|
1578
|
+
"type": "string",
|
|
1579
|
+
"pattern": "^[0-9a-f]{32}$",
|
|
1580
|
+
"description": "An OpenTelemetry trace ID: 32 lowercase hex characters."
|
|
1581
|
+
},
|
|
1582
|
+
"VerificationResult": {
|
|
1583
|
+
"type": "string",
|
|
1584
|
+
"enum": [
|
|
1585
|
+
"passed",
|
|
1586
|
+
"failed"
|
|
1587
|
+
]
|
|
1588
|
+
},
|
|
1589
|
+
"VersionRange": {
|
|
1590
|
+
"type": "string",
|
|
1591
|
+
"minLength": 1,
|
|
1592
|
+
"description": "A semver range of an adapter, for example \"^2\"."
|
|
1593
|
+
},
|
|
1594
|
+
"WorkItem": {
|
|
1595
|
+
"type": "object",
|
|
1596
|
+
"properties": {
|
|
1597
|
+
"id": {
|
|
1598
|
+
"$ref": "#/components/schemas/Identifier"
|
|
1599
|
+
},
|
|
1600
|
+
"type": {
|
|
1601
|
+
"$ref": "#/components/schemas/WorkItemType"
|
|
1602
|
+
},
|
|
1603
|
+
"title": {
|
|
1604
|
+
"type": "string",
|
|
1605
|
+
"minLength": 1,
|
|
1606
|
+
"maxLength": 300
|
|
1607
|
+
},
|
|
1608
|
+
"description": {
|
|
1609
|
+
"type": "string"
|
|
1610
|
+
},
|
|
1611
|
+
"requester": {
|
|
1612
|
+
"$ref": "#/components/schemas/Actor",
|
|
1613
|
+
"description": "The person or trigger that asked for the work."
|
|
1614
|
+
},
|
|
1615
|
+
"origin": {
|
|
1616
|
+
"$ref": "#/components/schemas/Origin",
|
|
1617
|
+
"description": "Where the work came from."
|
|
1618
|
+
},
|
|
1619
|
+
"dedupeKey": {
|
|
1620
|
+
"type": "string",
|
|
1621
|
+
"minLength": 1,
|
|
1622
|
+
"description": "Requests with the same key become one work item, for example \"github:acme/web#42\"."
|
|
1623
|
+
},
|
|
1624
|
+
"surface": {
|
|
1625
|
+
"type": "string",
|
|
1626
|
+
"description": "Product surface the work is about, for example \"checkout\"."
|
|
1627
|
+
},
|
|
1628
|
+
"priority": {
|
|
1629
|
+
"$ref": "#/components/schemas/Priority",
|
|
1630
|
+
"description": "Set by triage."
|
|
1631
|
+
},
|
|
1632
|
+
"links": {
|
|
1633
|
+
"type": "array",
|
|
1634
|
+
"items": {
|
|
1635
|
+
"$ref": "#/components/schemas/Link"
|
|
1636
|
+
},
|
|
1637
|
+
"description": "Related material: an error report, a change, a document."
|
|
1638
|
+
}
|
|
1639
|
+
},
|
|
1640
|
+
"required": [
|
|
1641
|
+
"id",
|
|
1642
|
+
"type",
|
|
1643
|
+
"title",
|
|
1644
|
+
"requester",
|
|
1645
|
+
"origin",
|
|
1646
|
+
"dedupeKey"
|
|
1647
|
+
],
|
|
1648
|
+
"description": "One unit of requested work: the `data` of a `work.received@v1` CloudEvent."
|
|
1649
|
+
},
|
|
1650
|
+
"WorkItemType": {
|
|
1651
|
+
"type": "string",
|
|
1652
|
+
"enum": [
|
|
1653
|
+
"idea",
|
|
1654
|
+
"bug",
|
|
1655
|
+
"task",
|
|
1656
|
+
"automation"
|
|
1657
|
+
]
|
|
1658
|
+
},
|
|
1659
|
+
"WorkReceived": {
|
|
1660
|
+
"type": "object",
|
|
1661
|
+
"properties": {
|
|
1662
|
+
"specversion": {
|
|
1663
|
+
"type": "string",
|
|
1664
|
+
"const": "1.0"
|
|
1665
|
+
},
|
|
1666
|
+
"id": {
|
|
1667
|
+
"$ref": "#/components/schemas/Identifier",
|
|
1668
|
+
"description": "Unique per source. A consumer that sees the same source and id twice handles the event once."
|
|
1669
|
+
},
|
|
1670
|
+
"source": {
|
|
1671
|
+
"type": "string",
|
|
1672
|
+
"minLength": 1,
|
|
1673
|
+
"description": "The producing module, for example \"/osf/intake\"."
|
|
1674
|
+
},
|
|
1675
|
+
"type": {
|
|
1676
|
+
"type": "string",
|
|
1677
|
+
"const": "work.received@v1"
|
|
1678
|
+
},
|
|
1679
|
+
"time": {
|
|
1680
|
+
"type": "string",
|
|
1681
|
+
"format": "date-time"
|
|
1682
|
+
},
|
|
1683
|
+
"subject": {
|
|
1684
|
+
"type": "string",
|
|
1685
|
+
"description": "The ID of the thing the event is about: work item, gate, run, score or pull request."
|
|
1686
|
+
},
|
|
1687
|
+
"datacontenttype": {
|
|
1688
|
+
"type": "string",
|
|
1689
|
+
"const": "application/json"
|
|
1690
|
+
},
|
|
1691
|
+
"dataschema": {
|
|
1692
|
+
"type": "string",
|
|
1693
|
+
"format": "uri"
|
|
1694
|
+
},
|
|
1695
|
+
"traceparent": {
|
|
1696
|
+
"type": "string",
|
|
1697
|
+
"description": "W3C trace context (CloudEvents distributed tracing extension)."
|
|
1698
|
+
},
|
|
1699
|
+
"data": {
|
|
1700
|
+
"$ref": "#/components/schemas/WorkItem"
|
|
1701
|
+
}
|
|
1702
|
+
},
|
|
1703
|
+
"required": [
|
|
1704
|
+
"specversion",
|
|
1705
|
+
"id",
|
|
1706
|
+
"source",
|
|
1707
|
+
"type",
|
|
1708
|
+
"time",
|
|
1709
|
+
"data"
|
|
1710
|
+
],
|
|
1711
|
+
"description": "intake: a work item was accepted."
|
|
1712
|
+
}
|
|
1713
|
+
}
|
|
1714
|
+
}
|
|
1715
|
+
}
|