@oh-my-pi/pi-coding-agent 17.2.0 → 17.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (87) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/dist/{CHANGELOG-be1f2t8h.md → CHANGELOG-dj46zzrm.md} +18 -0
  3. package/dist/cli.js +3340 -3195
  4. package/dist/types/config/model-discovery.d.ts +12 -0
  5. package/dist/types/config/settings-schema.d.ts +10 -0
  6. package/dist/types/extensibility/legacy-pi-coding-agent-shim.d.ts +23 -0
  7. package/dist/types/internal-urls/index.d.ts +1 -0
  8. package/dist/types/internal-urls/security-protocol.d.ts +15 -0
  9. package/dist/types/internal-urls/types.d.ts +1 -1
  10. package/dist/types/sdk.d.ts +17 -0
  11. package/dist/types/security/auth.d.ts +30 -0
  12. package/dist/types/security/cloud.d.ts +79 -0
  13. package/dist/types/security/comparison.d.ts +49 -0
  14. package/dist/types/security/contracts/ids.d.ts +15 -0
  15. package/dist/types/security/contracts/index.d.ts +4 -0
  16. package/dist/types/security/contracts/schemas.d.ts +660 -0
  17. package/dist/types/security/contracts/types.d.ts +234 -0
  18. package/dist/types/security/contracts/validation.d.ts +5 -0
  19. package/dist/types/security/coordinator.d.ts +100 -0
  20. package/dist/types/security/importers/codex-security.d.ts +7 -0
  21. package/dist/types/security/importers/index.d.ts +2 -0
  22. package/dist/types/security/importers/sarif.d.ts +9 -0
  23. package/dist/types/security/index.d.ts +13 -0
  24. package/dist/types/security/preflight.d.ts +61 -0
  25. package/dist/types/security/provenance.d.ts +24 -0
  26. package/dist/types/security/publication.d.ts +78 -0
  27. package/dist/types/security/remediation.d.ts +27 -0
  28. package/dist/types/security/resource-output.d.ts +8 -0
  29. package/dist/types/security/sarif.d.ts +2 -0
  30. package/dist/types/security/store.d.ts +40 -0
  31. package/dist/types/slash-commands/helpers/security.d.ts +2 -0
  32. package/dist/types/system-prompt.d.ts +2 -0
  33. package/dist/types/task/executor.d.ts +3 -0
  34. package/dist/types/tools/builtin-names.d.ts +1 -1
  35. package/dist/types/tools/index.d.ts +6 -1
  36. package/dist/types/tools/security-scan.d.ts +96 -0
  37. package/package.json +12 -12
  38. package/scripts/security-compare.ts +40 -0
  39. package/src/config/model-discovery.ts +32 -5
  40. package/src/config/model-registry.ts +4 -0
  41. package/src/config/settings-schema.ts +12 -0
  42. package/src/eval/py/prelude.py +7 -3
  43. package/src/extensibility/legacy-pi-coding-agent-shim.ts +53 -0
  44. package/src/internal-urls/index.ts +1 -0
  45. package/src/internal-urls/router.ts +4 -1
  46. package/src/internal-urls/security-protocol.ts +261 -0
  47. package/src/internal-urls/types.ts +1 -1
  48. package/src/lsp/index.ts +3 -0
  49. package/src/modes/rpc/host-uris.ts +6 -0
  50. package/src/prompts/agents/security-reviewer.md +75 -0
  51. package/src/prompts/security/scan-coordinator.md +7 -0
  52. package/src/prompts/security/scan-request.md +21 -0
  53. package/src/prompts/security/validate-request.md +8 -0
  54. package/src/prompts/system/system-prompt.md +3 -0
  55. package/src/prompts/tools/security-publish.md +1 -0
  56. package/src/prompts/tools/security-scan.md +1 -0
  57. package/src/sdk.ts +34 -6
  58. package/src/security/auth.ts +98 -0
  59. package/src/security/cloud.ts +686 -0
  60. package/src/security/comparison.ts +255 -0
  61. package/src/security/contracts/ids.ts +111 -0
  62. package/src/security/contracts/index.ts +4 -0
  63. package/src/security/contracts/schemas.ts +201 -0
  64. package/src/security/contracts/types.ts +254 -0
  65. package/src/security/contracts/validation.ts +65 -0
  66. package/src/security/coordinator.ts +708 -0
  67. package/src/security/importers/codex-security.ts +387 -0
  68. package/src/security/importers/index.ts +2 -0
  69. package/src/security/importers/sarif.ts +357 -0
  70. package/src/security/index.ts +13 -0
  71. package/src/security/preflight.ts +405 -0
  72. package/src/security/provenance.ts +106 -0
  73. package/src/security/publication.ts +326 -0
  74. package/src/security/remediation.ts +93 -0
  75. package/src/security/resource-output.ts +50 -0
  76. package/src/security/sarif.ts +78 -0
  77. package/src/security/store.ts +430 -0
  78. package/src/slash-commands/builtin-registry.ts +21 -0
  79. package/src/slash-commands/helpers/security.ts +451 -0
  80. package/src/system-prompt.ts +4 -0
  81. package/src/task/agents.ts +2 -0
  82. package/src/task/executor.ts +3 -0
  83. package/src/task/structured-subagent.ts +6 -4
  84. package/src/tools/builtin-names.ts +1 -0
  85. package/src/tools/index.ts +9 -1
  86. package/src/tools/path-utils.ts +3 -0
  87. package/src/tools/security-scan.ts +287 -0
@@ -0,0 +1,660 @@
1
+ export declare const securityProducerSchema: import("arktype/internal/variants/object.ts").ObjectType<{
2
+ kind: "codex-security-bundle" | "codex-security-cloud" | "omp-native" | "sarif-import";
3
+ name: string;
4
+ version?: string | undefined;
5
+ vendor?: string | undefined;
6
+ revision?: string | undefined;
7
+ pluginVersion?: string | undefined;
8
+ }, {}>;
9
+ export declare const securityProvenanceSchema: import("arktype/internal/variants/object.ts").ObjectType<{
10
+ producer: {
11
+ kind: "codex-security-bundle" | "codex-security-cloud" | "omp-native" | "sarif-import";
12
+ name: string;
13
+ version?: string | undefined;
14
+ vendor?: string | undefined;
15
+ revision?: string | undefined;
16
+ pluginVersion?: string | undefined;
17
+ };
18
+ createdAt: string;
19
+ importedAt?: string | undefined;
20
+ sourceIds?: {
21
+ [x: string]: string;
22
+ } | undefined;
23
+ vendorFingerprints?: {
24
+ [x: string]: string;
25
+ } | undefined;
26
+ upstream?: {
27
+ repository?: string | undefined;
28
+ revision?: string | undefined;
29
+ packageVersion?: string | undefined;
30
+ pluginVersion?: string | undefined;
31
+ archiveSha256?: string | undefined;
32
+ } | undefined;
33
+ metadata?: {
34
+ [x: string]: unknown;
35
+ } | undefined;
36
+ }, {}>;
37
+ export declare const securityLocationSchema: import("arktype/internal/variants/object.ts").ObjectType<{
38
+ path: string;
39
+ startLine: number;
40
+ endLine?: number | undefined;
41
+ startColumn?: number | undefined;
42
+ endColumn?: number | undefined;
43
+ role?: string | undefined;
44
+ }, {}>;
45
+ export declare const securityEvidenceSchema: import("arktype/internal/variants/object.ts").ObjectType<{
46
+ id: string;
47
+ kind: "code" | "note" | "trace" | "validation";
48
+ label: string;
49
+ explanation: string;
50
+ location?: {
51
+ path: string;
52
+ startLine: number;
53
+ endLine?: number | undefined;
54
+ startColumn?: number | undefined;
55
+ endColumn?: number | undefined;
56
+ role?: string | undefined;
57
+ } | undefined;
58
+ excerpt?: string | undefined;
59
+ }, {}>;
60
+ export declare const securityOccurrenceSchema: import("arktype/internal/variants/object.ts").ObjectType<{
61
+ id: string;
62
+ locations: {
63
+ path: string;
64
+ startLine: number;
65
+ endLine?: number | undefined;
66
+ startColumn?: number | undefined;
67
+ endColumn?: number | undefined;
68
+ role?: string | undefined;
69
+ }[];
70
+ evidenceIds: string[];
71
+ }, {}>;
72
+ export declare const securityFindingSchema: import("arktype/internal/variants/object.ts").ObjectType<{
73
+ id: string;
74
+ scanId: string;
75
+ fingerprint: string;
76
+ ruleId: string;
77
+ anchor?: string | undefined;
78
+ title: string;
79
+ summary: string;
80
+ severity: {
81
+ level: "critical" | "high" | "informational" | "low" | "medium";
82
+ score?: number | undefined;
83
+ scoringSystem?: string | undefined;
84
+ vector?: string | undefined;
85
+ rationale?: string | undefined;
86
+ };
87
+ confidence: {
88
+ level: "high" | "low" | "medium";
89
+ rationale?: string | undefined;
90
+ };
91
+ taxonomy: {
92
+ category: string;
93
+ cwe: string[];
94
+ tags?: string[] | undefined;
95
+ };
96
+ occurrences: {
97
+ id: string;
98
+ locations: {
99
+ path: string;
100
+ startLine: number;
101
+ endLine?: number | undefined;
102
+ startColumn?: number | undefined;
103
+ endColumn?: number | undefined;
104
+ role?: string | undefined;
105
+ }[];
106
+ evidenceIds: string[];
107
+ }[];
108
+ evidence: {
109
+ id: string;
110
+ kind: "code" | "note" | "trace" | "validation";
111
+ label: string;
112
+ explanation: string;
113
+ location?: {
114
+ path: string;
115
+ startLine: number;
116
+ endLine?: number | undefined;
117
+ startColumn?: number | undefined;
118
+ endColumn?: number | undefined;
119
+ role?: string | undefined;
120
+ } | undefined;
121
+ excerpt?: string | undefined;
122
+ }[];
123
+ remediation?: string | undefined;
124
+ validation: {
125
+ status: "error" | "partial" | "rejected" | "unvalidated" | "validated";
126
+ summary?: string | undefined;
127
+ evidenceIds: string[];
128
+ validatedAt?: string | undefined;
129
+ };
130
+ disposition: {
131
+ status: "accepted_risk" | "false_positive" | "fixed" | "open" | "wont_fix";
132
+ rationale?: string | undefined;
133
+ updatedAt?: string | undefined;
134
+ actor?: string | undefined;
135
+ };
136
+ provenance: {
137
+ producer: {
138
+ kind: "codex-security-bundle" | "codex-security-cloud" | "omp-native" | "sarif-import";
139
+ name: string;
140
+ version?: string | undefined;
141
+ vendor?: string | undefined;
142
+ revision?: string | undefined;
143
+ pluginVersion?: string | undefined;
144
+ };
145
+ createdAt: string;
146
+ importedAt?: string | undefined;
147
+ sourceIds?: {
148
+ [x: string]: string;
149
+ } | undefined;
150
+ vendorFingerprints?: {
151
+ [x: string]: string;
152
+ } | undefined;
153
+ upstream?: {
154
+ repository?: string | undefined;
155
+ revision?: string | undefined;
156
+ packageVersion?: string | undefined;
157
+ pluginVersion?: string | undefined;
158
+ archiveSha256?: string | undefined;
159
+ } | undefined;
160
+ metadata?: {
161
+ [x: string]: unknown;
162
+ } | undefined;
163
+ };
164
+ extensions?: {
165
+ [x: string]: unknown;
166
+ } | undefined;
167
+ }, {}>;
168
+ export declare const securityCoverageSchema: import("arktype/internal/variants/object.ts").ObjectType<{
169
+ mode: "deep_repository" | "diff" | "imported" | "repository" | "scoped_path" | "working_tree";
170
+ completeness: "complete" | "partial" | "unknown";
171
+ inventoryStrategy: "custom" | "diff" | "directory" | "imported" | "repository" | "scoped_path";
172
+ includePaths: string[];
173
+ excludePaths: string[];
174
+ surfaces: {
175
+ id: string;
176
+ label: string;
177
+ disposition: "needs_follow_up" | "no_issue_found" | "not_applicable" | "rejected" | "reported";
178
+ receiptRefs: string[];
179
+ riskArea?: string | undefined;
180
+ notes?: string | undefined;
181
+ }[];
182
+ explicitExclusions: {
183
+ pattern: string;
184
+ reason: string;
185
+ }[];
186
+ deferred: {
187
+ id: string;
188
+ reason: string;
189
+ paths?: string[] | undefined;
190
+ surfaceIds?: string[] | undefined;
191
+ }[];
192
+ openQuestions?: {
193
+ question: string;
194
+ followUpPrompt?: string | undefined;
195
+ }[] | undefined;
196
+ }, {}>;
197
+ export declare const securityTargetSchema: import("arktype/internal/variants/object.ts").ObjectType<{
198
+ kind: "imported" | "ref_diff" | "repository" | "scoped_path" | "working_tree";
199
+ repositoryRoot: string;
200
+ displayName: string;
201
+ revision?: string | undefined;
202
+ baseRevision?: string | undefined;
203
+ headRevision?: string | undefined;
204
+ includePaths: string[];
205
+ excludePaths: string[];
206
+ treeDigest: string;
207
+ }, {}>;
208
+ export declare const securityScanPlanSchema: import("arktype/internal/variants/object.ts").ObjectType<{
209
+ documentType: "omp-security.scan-plan";
210
+ schemaVersion: "1.0";
211
+ id: string;
212
+ createdAt: string;
213
+ repositoryRoot: string;
214
+ target: {
215
+ kind: "imported" | "ref_diff" | "repository" | "scoped_path" | "working_tree";
216
+ repositoryRoot: string;
217
+ displayName: string;
218
+ revision?: string | undefined;
219
+ baseRevision?: string | undefined;
220
+ headRevision?: string | undefined;
221
+ includePaths: string[];
222
+ excludePaths: string[];
223
+ treeDigest: string;
224
+ };
225
+ knowledgeBases: {
226
+ path: string;
227
+ sha256: string;
228
+ size: number;
229
+ }[];
230
+ output: {
231
+ root: string;
232
+ archiveExisting: boolean;
233
+ existingState: "absent" | "archivable" | "empty";
234
+ };
235
+ model: {
236
+ provider: string;
237
+ modelId: string;
238
+ thinkingLevel?: string | undefined;
239
+ };
240
+ account: {
241
+ provider: string;
242
+ credentialId: number;
243
+ accountId?: string | undefined;
244
+ email?: string | undefined;
245
+ organizationId?: string | undefined;
246
+ organizationName?: string | undefined;
247
+ };
248
+ configFingerprint: string;
249
+ workflowFingerprint: string;
250
+ fingerprint: string;
251
+ }, {}>;
252
+ export declare const securityScanMetricsSchema: import("arktype/internal/variants/object.ts").ObjectType<{
253
+ runtimeMs?: number | undefined;
254
+ tokenUsage?: {
255
+ input: number;
256
+ output: number;
257
+ reasoning: number;
258
+ cacheRead: number;
259
+ cacheWrite: number;
260
+ total: number;
261
+ } | undefined;
262
+ cost?: number | undefined;
263
+ premiumRequests?: number | undefined;
264
+ }, {}>;
265
+ export declare const securityScanSchema: import("arktype/internal/variants/object.ts").ObjectType<{
266
+ documentType: "omp-security.scan";
267
+ schemaVersion: "1.0";
268
+ id: string;
269
+ projectKey: string;
270
+ status: "cancelled" | "completed" | "failed" | "partial" | "planned" | "running";
271
+ createdAt: string;
272
+ startedAt?: string | undefined;
273
+ completedAt?: string | undefined;
274
+ plan?: {
275
+ documentType: "omp-security.scan-plan";
276
+ schemaVersion: "1.0";
277
+ id: string;
278
+ createdAt: string;
279
+ repositoryRoot: string;
280
+ target: {
281
+ kind: "imported" | "ref_diff" | "repository" | "scoped_path" | "working_tree";
282
+ repositoryRoot: string;
283
+ displayName: string;
284
+ revision?: string | undefined;
285
+ baseRevision?: string | undefined;
286
+ headRevision?: string | undefined;
287
+ includePaths: string[];
288
+ excludePaths: string[];
289
+ treeDigest: string;
290
+ };
291
+ knowledgeBases: {
292
+ path: string;
293
+ sha256: string;
294
+ size: number;
295
+ }[];
296
+ output: {
297
+ root: string;
298
+ archiveExisting: boolean;
299
+ existingState: "absent" | "archivable" | "empty";
300
+ };
301
+ model: {
302
+ provider: string;
303
+ modelId: string;
304
+ thinkingLevel?: string | undefined;
305
+ };
306
+ account: {
307
+ provider: string;
308
+ credentialId: number;
309
+ accountId?: string | undefined;
310
+ email?: string | undefined;
311
+ organizationId?: string | undefined;
312
+ organizationName?: string | undefined;
313
+ };
314
+ configFingerprint: string;
315
+ workflowFingerprint: string;
316
+ fingerprint: string;
317
+ } | undefined;
318
+ target: {
319
+ kind: "imported" | "ref_diff" | "repository" | "scoped_path" | "working_tree";
320
+ repositoryRoot: string;
321
+ displayName: string;
322
+ revision?: string | undefined;
323
+ baseRevision?: string | undefined;
324
+ headRevision?: string | undefined;
325
+ includePaths: string[];
326
+ excludePaths: string[];
327
+ treeDigest: string;
328
+ };
329
+ producer: {
330
+ kind: "codex-security-bundle" | "codex-security-cloud" | "omp-native" | "sarif-import";
331
+ name: string;
332
+ version?: string | undefined;
333
+ vendor?: string | undefined;
334
+ revision?: string | undefined;
335
+ pluginVersion?: string | undefined;
336
+ };
337
+ provenance: {
338
+ producer: {
339
+ kind: "codex-security-bundle" | "codex-security-cloud" | "omp-native" | "sarif-import";
340
+ name: string;
341
+ version?: string | undefined;
342
+ vendor?: string | undefined;
343
+ revision?: string | undefined;
344
+ pluginVersion?: string | undefined;
345
+ };
346
+ createdAt: string;
347
+ importedAt?: string | undefined;
348
+ sourceIds?: {
349
+ [x: string]: string;
350
+ } | undefined;
351
+ vendorFingerprints?: {
352
+ [x: string]: string;
353
+ } | undefined;
354
+ upstream?: {
355
+ repository?: string | undefined;
356
+ revision?: string | undefined;
357
+ packageVersion?: string | undefined;
358
+ pluginVersion?: string | undefined;
359
+ archiveSha256?: string | undefined;
360
+ } | undefined;
361
+ metadata?: {
362
+ [x: string]: unknown;
363
+ } | undefined;
364
+ };
365
+ findingIds: string[];
366
+ coverage: {
367
+ mode: "deep_repository" | "diff" | "imported" | "repository" | "scoped_path" | "working_tree";
368
+ completeness: "complete" | "partial" | "unknown";
369
+ inventoryStrategy: "custom" | "diff" | "directory" | "imported" | "repository" | "scoped_path";
370
+ includePaths: string[];
371
+ excludePaths: string[];
372
+ surfaces: {
373
+ id: string;
374
+ label: string;
375
+ disposition: "needs_follow_up" | "no_issue_found" | "not_applicable" | "rejected" | "reported";
376
+ receiptRefs: string[];
377
+ riskArea?: string | undefined;
378
+ notes?: string | undefined;
379
+ }[];
380
+ explicitExclusions: {
381
+ pattern: string;
382
+ reason: string;
383
+ }[];
384
+ deferred: {
385
+ id: string;
386
+ reason: string;
387
+ paths?: string[] | undefined;
388
+ surfaceIds?: string[] | undefined;
389
+ }[];
390
+ openQuestions?: {
391
+ question: string;
392
+ followUpPrompt?: string | undefined;
393
+ }[] | undefined;
394
+ };
395
+ reportRef?: string | undefined;
396
+ sarifRef?: string | undefined;
397
+ error?: string | undefined;
398
+ metrics?: {
399
+ runtimeMs?: number | undefined;
400
+ tokenUsage?: {
401
+ input: number;
402
+ output: number;
403
+ reasoning: number;
404
+ cacheRead: number;
405
+ cacheWrite: number;
406
+ total: number;
407
+ } | undefined;
408
+ cost?: number | undefined;
409
+ premiumRequests?: number | undefined;
410
+ } | undefined;
411
+ }, {}>;
412
+ export declare const securityScanBundleSchema: import("arktype/internal/variants/object.ts").ObjectType<{
413
+ scan: {
414
+ documentType: "omp-security.scan";
415
+ schemaVersion: "1.0";
416
+ id: string;
417
+ projectKey: string;
418
+ status: "cancelled" | "completed" | "failed" | "partial" | "planned" | "running";
419
+ createdAt: string;
420
+ startedAt?: string | undefined;
421
+ completedAt?: string | undefined;
422
+ plan?: {
423
+ documentType: "omp-security.scan-plan";
424
+ schemaVersion: "1.0";
425
+ id: string;
426
+ createdAt: string;
427
+ repositoryRoot: string;
428
+ target: {
429
+ kind: "imported" | "ref_diff" | "repository" | "scoped_path" | "working_tree";
430
+ repositoryRoot: string;
431
+ displayName: string;
432
+ revision?: string | undefined;
433
+ baseRevision?: string | undefined;
434
+ headRevision?: string | undefined;
435
+ includePaths: string[];
436
+ excludePaths: string[];
437
+ treeDigest: string;
438
+ };
439
+ knowledgeBases: {
440
+ path: string;
441
+ sha256: string;
442
+ size: number;
443
+ }[];
444
+ output: {
445
+ root: string;
446
+ archiveExisting: boolean;
447
+ existingState: "absent" | "archivable" | "empty";
448
+ };
449
+ model: {
450
+ provider: string;
451
+ modelId: string;
452
+ thinkingLevel?: string | undefined;
453
+ };
454
+ account: {
455
+ provider: string;
456
+ credentialId: number;
457
+ accountId?: string | undefined;
458
+ email?: string | undefined;
459
+ organizationId?: string | undefined;
460
+ organizationName?: string | undefined;
461
+ };
462
+ configFingerprint: string;
463
+ workflowFingerprint: string;
464
+ fingerprint: string;
465
+ } | undefined;
466
+ target: {
467
+ kind: "imported" | "ref_diff" | "repository" | "scoped_path" | "working_tree";
468
+ repositoryRoot: string;
469
+ displayName: string;
470
+ revision?: string | undefined;
471
+ baseRevision?: string | undefined;
472
+ headRevision?: string | undefined;
473
+ includePaths: string[];
474
+ excludePaths: string[];
475
+ treeDigest: string;
476
+ };
477
+ producer: {
478
+ kind: "codex-security-bundle" | "codex-security-cloud" | "omp-native" | "sarif-import";
479
+ name: string;
480
+ version?: string | undefined;
481
+ vendor?: string | undefined;
482
+ revision?: string | undefined;
483
+ pluginVersion?: string | undefined;
484
+ };
485
+ provenance: {
486
+ producer: {
487
+ kind: "codex-security-bundle" | "codex-security-cloud" | "omp-native" | "sarif-import";
488
+ name: string;
489
+ version?: string | undefined;
490
+ vendor?: string | undefined;
491
+ revision?: string | undefined;
492
+ pluginVersion?: string | undefined;
493
+ };
494
+ createdAt: string;
495
+ importedAt?: string | undefined;
496
+ sourceIds?: {
497
+ [x: string]: string;
498
+ } | undefined;
499
+ vendorFingerprints?: {
500
+ [x: string]: string;
501
+ } | undefined;
502
+ upstream?: {
503
+ repository?: string | undefined;
504
+ revision?: string | undefined;
505
+ packageVersion?: string | undefined;
506
+ pluginVersion?: string | undefined;
507
+ archiveSha256?: string | undefined;
508
+ } | undefined;
509
+ metadata?: {
510
+ [x: string]: unknown;
511
+ } | undefined;
512
+ };
513
+ findingIds: string[];
514
+ coverage: {
515
+ mode: "deep_repository" | "diff" | "imported" | "repository" | "scoped_path" | "working_tree";
516
+ completeness: "complete" | "partial" | "unknown";
517
+ inventoryStrategy: "custom" | "diff" | "directory" | "imported" | "repository" | "scoped_path";
518
+ includePaths: string[];
519
+ excludePaths: string[];
520
+ surfaces: {
521
+ id: string;
522
+ label: string;
523
+ disposition: "needs_follow_up" | "no_issue_found" | "not_applicable" | "rejected" | "reported";
524
+ receiptRefs: string[];
525
+ riskArea?: string | undefined;
526
+ notes?: string | undefined;
527
+ }[];
528
+ explicitExclusions: {
529
+ pattern: string;
530
+ reason: string;
531
+ }[];
532
+ deferred: {
533
+ id: string;
534
+ reason: string;
535
+ paths?: string[] | undefined;
536
+ surfaceIds?: string[] | undefined;
537
+ }[];
538
+ openQuestions?: {
539
+ question: string;
540
+ followUpPrompt?: string | undefined;
541
+ }[] | undefined;
542
+ };
543
+ reportRef?: string | undefined;
544
+ sarifRef?: string | undefined;
545
+ error?: string | undefined;
546
+ metrics?: {
547
+ runtimeMs?: number | undefined;
548
+ tokenUsage?: {
549
+ input: number;
550
+ output: number;
551
+ reasoning: number;
552
+ cacheRead: number;
553
+ cacheWrite: number;
554
+ total: number;
555
+ } | undefined;
556
+ cost?: number | undefined;
557
+ premiumRequests?: number | undefined;
558
+ } | undefined;
559
+ };
560
+ findings: {
561
+ id: string;
562
+ scanId: string;
563
+ fingerprint: string;
564
+ ruleId: string;
565
+ anchor?: string | undefined;
566
+ title: string;
567
+ summary: string;
568
+ severity: {
569
+ level: "critical" | "high" | "informational" | "low" | "medium";
570
+ score?: number | undefined;
571
+ scoringSystem?: string | undefined;
572
+ vector?: string | undefined;
573
+ rationale?: string | undefined;
574
+ };
575
+ confidence: {
576
+ level: "high" | "low" | "medium";
577
+ rationale?: string | undefined;
578
+ };
579
+ taxonomy: {
580
+ category: string;
581
+ cwe: string[];
582
+ tags?: string[] | undefined;
583
+ };
584
+ occurrences: {
585
+ id: string;
586
+ locations: {
587
+ path: string;
588
+ startLine: number;
589
+ endLine?: number | undefined;
590
+ startColumn?: number | undefined;
591
+ endColumn?: number | undefined;
592
+ role?: string | undefined;
593
+ }[];
594
+ evidenceIds: string[];
595
+ }[];
596
+ evidence: {
597
+ id: string;
598
+ kind: "code" | "note" | "trace" | "validation";
599
+ label: string;
600
+ explanation: string;
601
+ location?: {
602
+ path: string;
603
+ startLine: number;
604
+ endLine?: number | undefined;
605
+ startColumn?: number | undefined;
606
+ endColumn?: number | undefined;
607
+ role?: string | undefined;
608
+ } | undefined;
609
+ excerpt?: string | undefined;
610
+ }[];
611
+ remediation?: string | undefined;
612
+ validation: {
613
+ status: "error" | "partial" | "rejected" | "unvalidated" | "validated";
614
+ summary?: string | undefined;
615
+ evidenceIds: string[];
616
+ validatedAt?: string | undefined;
617
+ };
618
+ disposition: {
619
+ status: "accepted_risk" | "false_positive" | "fixed" | "open" | "wont_fix";
620
+ rationale?: string | undefined;
621
+ updatedAt?: string | undefined;
622
+ actor?: string | undefined;
623
+ };
624
+ provenance: {
625
+ producer: {
626
+ kind: "codex-security-bundle" | "codex-security-cloud" | "omp-native" | "sarif-import";
627
+ name: string;
628
+ version?: string | undefined;
629
+ vendor?: string | undefined;
630
+ revision?: string | undefined;
631
+ pluginVersion?: string | undefined;
632
+ };
633
+ createdAt: string;
634
+ importedAt?: string | undefined;
635
+ sourceIds?: {
636
+ [x: string]: string;
637
+ } | undefined;
638
+ vendorFingerprints?: {
639
+ [x: string]: string;
640
+ } | undefined;
641
+ upstream?: {
642
+ repository?: string | undefined;
643
+ revision?: string | undefined;
644
+ packageVersion?: string | undefined;
645
+ pluginVersion?: string | undefined;
646
+ archiveSha256?: string | undefined;
647
+ } | undefined;
648
+ metadata?: {
649
+ [x: string]: unknown;
650
+ } | undefined;
651
+ };
652
+ extensions?: {
653
+ [x: string]: unknown;
654
+ } | undefined;
655
+ }[];
656
+ report?: string | undefined;
657
+ sarif?: {
658
+ [x: string]: unknown;
659
+ } | undefined;
660
+ }, {}>;