@fungi.computer/braid 0.0.0-stage → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (83) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +260 -2
  3. package/dist/cloudflare/graph-engine.d.ts +25 -0
  4. package/dist/cloudflare/graph-engine.js +46 -0
  5. package/dist/cloudflare/graph-program.d.ts +6 -0
  6. package/dist/cloudflare/graph-program.js +550 -0
  7. package/dist/cloudflare/index.d.ts +1 -0
  8. package/dist/cloudflare/index.js +1 -0
  9. package/dist/code-execution.d.ts +16 -0
  10. package/dist/code-execution.js +50 -0
  11. package/dist/code-result.d.ts +11 -0
  12. package/dist/code-result.js +19 -0
  13. package/dist/code-sandbox.d.ts +9 -0
  14. package/dist/code-sandbox.js +13 -0
  15. package/dist/compile.d.ts +43 -0
  16. package/dist/compile.js +248 -0
  17. package/dist/execution.d.ts +194 -0
  18. package/dist/execution.js +130 -0
  19. package/dist/expressions.d.ts +16 -0
  20. package/dist/expressions.js +322 -0
  21. package/dist/git-access.d.ts +59 -0
  22. package/dist/git-access.js +106 -0
  23. package/dist/index.d.ts +9 -0
  24. package/dist/index.js +9 -0
  25. package/dist/ports.d.ts +58 -0
  26. package/dist/ports.js +256 -0
  27. package/dist/review-text.d.ts +15 -0
  28. package/dist/review-text.js +40 -0
  29. package/dist/runtime/arming-authority.d.ts +83 -0
  30. package/dist/runtime/arming-authority.js +90 -0
  31. package/dist/runtime/bindings.d.ts +25 -0
  32. package/dist/runtime/bindings.js +41 -0
  33. package/dist/runtime/capture.d.ts +18 -0
  34. package/dist/runtime/capture.js +99 -0
  35. package/dist/runtime/git-pass-contract.d.ts +63 -0
  36. package/dist/runtime/git-pass-contract.js +36 -0
  37. package/dist/runtime/git-pass-store.d.ts +32 -0
  38. package/dist/runtime/git-pass-store.js +82 -0
  39. package/dist/runtime/git-pass.d.ts +41 -0
  40. package/dist/runtime/git-pass.js +72 -0
  41. package/dist/runtime/graph-contract.d.ts +788 -0
  42. package/dist/runtime/graph-contract.js +122 -0
  43. package/dist/runtime/graph-dispatch.d.ts +31 -0
  44. package/dist/runtime/graph-dispatch.js +111 -0
  45. package/dist/runtime/graph-run-store.d.ts +79 -0
  46. package/dist/runtime/graph-run-store.js +267 -0
  47. package/dist/runtime/graph-start.d.ts +90 -0
  48. package/dist/runtime/graph-start.js +124 -0
  49. package/dist/runtime/index.d.ts +20 -0
  50. package/dist/runtime/index.js +20 -0
  51. package/dist/runtime/ports.d.ts +156 -0
  52. package/dist/runtime/ports.js +1 -0
  53. package/dist/runtime/run-authority.d.ts +60 -0
  54. package/dist/runtime/run-authority.js +145 -0
  55. package/dist/runtime/run-ceiling.d.ts +106 -0
  56. package/dist/runtime/run-ceiling.js +23 -0
  57. package/dist/runtime/run-member.d.ts +3 -0
  58. package/dist/runtime/run-member.js +12 -0
  59. package/dist/runtime/run-owner.d.ts +1650 -0
  60. package/dist/runtime/run-owner.js +513 -0
  61. package/dist/runtime/run-report.d.ts +14 -0
  62. package/dist/runtime/run-report.js +23 -0
  63. package/dist/runtime/schedules.d.ts +39 -0
  64. package/dist/runtime/schedules.js +149 -0
  65. package/dist/runtime/stored-trigger-rows.d.ts +12 -0
  66. package/dist/runtime/stored-trigger-rows.js +17 -0
  67. package/dist/runtime/trigger-owner.d.ts +594 -0
  68. package/dist/runtime/trigger-owner.js +280 -0
  69. package/dist/runtime/trigger-plans.d.ts +774 -0
  70. package/dist/runtime/trigger-plans.js +62 -0
  71. package/dist/runtime/trigger-router.d.ts +34 -0
  72. package/dist/runtime/trigger-router.js +143 -0
  73. package/dist/runtime/trigger-run-reservations.d.ts +28 -0
  74. package/dist/runtime/trigger-run-reservations.js +114 -0
  75. package/dist/schema.d.ts +1183 -0
  76. package/dist/schema.js +239 -0
  77. package/dist/triggers.d.ts +46 -0
  78. package/dist/triggers.js +75 -0
  79. package/dist/validate.d.ts +25 -0
  80. package/dist/validate.js +686 -0
  81. package/dist/workflow-id.d.ts +3 -0
  82. package/dist/workflow-id.js +3 -0
  83. package/package.json +96 -3
@@ -0,0 +1,594 @@
1
+ import { z } from "zod";
2
+ import * as S from "effect/Schema";
3
+ import { type GitBinding, type RepositoryRef } from "@fungi.computer/agar/git";
4
+ import { type TriggerEvent } from "../index.js";
5
+ import { type WorkflowArmingAuthorityPorts, type WorkflowArmingReceipt } from "./arming-authority.js";
6
+ import type { PublishedDefinitionPort, WorkflowPublicationContext, WorkflowTriggerRunPorts, WorkflowErrorPort } from "./ports.js";
7
+ export declare const workflowTriggerTargetSchema: z.ZodObject<{
8
+ installationId: z.ZodString;
9
+ workflowId: z.ZodString;
10
+ commit: z.ZodString;
11
+ digest: z.ZodString & z.ZodType<string & {
12
+ readonly appReleaseKind: "Sha256Digest";
13
+ }, string, z.core.$ZodTypeInternals<string & {
14
+ readonly appReleaseKind: "Sha256Digest";
15
+ }, string>>;
16
+ triggerId: z.ZodString;
17
+ bindings: z.ZodRecord<z.ZodLazy<z.ZodString>, z.ZodUnion<readonly [z.ZodString, z.ZodLazy<z.ZodObject<{
18
+ kind: z.ZodLiteral<"team-source">;
19
+ }, z.core.$strict>>]>>;
20
+ delivery: z.ZodOptional<z.ZodCustom<{
21
+ readonly agentId: string;
22
+ readonly sessionId: string;
23
+ }, {
24
+ readonly agentId: string;
25
+ readonly sessionId: string;
26
+ }>>;
27
+ }, z.core.$strict>;
28
+ /** The host frame's installation selection and verified artifact, pinned at arm time. */
29
+ export declare const workflowInstallationAuthoritySchema: z.ZodObject<{
30
+ selection: z.ZodObject<{
31
+ instanceId: z.ZodString;
32
+ owner: z.ZodObject<{
33
+ kind: z.ZodEnum<{
34
+ installation: "installation";
35
+ deployment: "deployment";
36
+ }>;
37
+ id: z.ZodString;
38
+ }, z.core.$strict>;
39
+ appId: z.ZodString & z.ZodType<string & {
40
+ readonly appReleaseKind: "AppId";
41
+ }, string, z.core.$ZodTypeInternals<string & {
42
+ readonly appReleaseKind: "AppId";
43
+ }, string>>;
44
+ releaseId: z.ZodString & z.ZodType<string & {
45
+ readonly appReleaseKind: "ReleaseId";
46
+ }, string, z.core.$ZodTypeInternals<string & {
47
+ readonly appReleaseKind: "ReleaseId";
48
+ }, string>>;
49
+ authorityVersion: z.ZodNumber;
50
+ }, z.core.$strict>;
51
+ artifactDigest: z.ZodString & z.ZodType<string & {
52
+ readonly appReleaseKind: "Sha256Digest";
53
+ }, string, z.core.$ZodTypeInternals<string & {
54
+ readonly appReleaseKind: "Sha256Digest";
55
+ }, string>>;
56
+ }, z.core.$strict>;
57
+ export type WorkflowInstallationAuthority = z.infer<typeof workflowInstallationAuthoritySchema>;
58
+ export declare const armedWorkflowTriggerSchema: z.ZodObject<{
59
+ installationId: z.ZodString;
60
+ workflowId: z.ZodString;
61
+ commit: z.ZodString;
62
+ digest: z.ZodString & z.ZodType<string & {
63
+ readonly appReleaseKind: "Sha256Digest";
64
+ }, string, z.core.$ZodTypeInternals<string & {
65
+ readonly appReleaseKind: "Sha256Digest";
66
+ }, string>>;
67
+ triggerId: z.ZodString;
68
+ bindings: z.ZodRecord<z.ZodLazy<z.ZodString>, z.ZodUnion<readonly [z.ZodString, z.ZodLazy<z.ZodObject<{
69
+ kind: z.ZodLiteral<"team-source">;
70
+ }, z.core.$strict>>]>>;
71
+ delivery: z.ZodOptional<z.ZodCustom<{
72
+ readonly agentId: string;
73
+ readonly sessionId: string;
74
+ }, {
75
+ readonly agentId: string;
76
+ readonly sessionId: string;
77
+ }>>;
78
+ armedBy: z.ZodString;
79
+ armedVia: z.ZodNullable<z.ZodDiscriminatedUnion<[z.ZodObject<{
80
+ kind: z.ZodLiteral<"connector">;
81
+ agentId: z.ZodString;
82
+ attachmentId: z.ZodString;
83
+ attachmentVersion: z.ZodNumber;
84
+ }, z.core.$strict>, z.ZodObject<{
85
+ kind: z.ZodLiteral<"policy">;
86
+ agentId: z.ZodString;
87
+ policyRevision: z.ZodString;
88
+ grantorMemberId: z.ZodString;
89
+ }, z.core.$strict>], "kind">>;
90
+ grantorMembershipVersion: z.ZodNumber;
91
+ installationAuthority: z.ZodObject<{
92
+ selection: z.ZodObject<{
93
+ instanceId: z.ZodString;
94
+ owner: z.ZodObject<{
95
+ kind: z.ZodEnum<{
96
+ installation: "installation";
97
+ deployment: "deployment";
98
+ }>;
99
+ id: z.ZodString;
100
+ }, z.core.$strict>;
101
+ appId: z.ZodString & z.ZodType<string & {
102
+ readonly appReleaseKind: "AppId";
103
+ }, string, z.core.$ZodTypeInternals<string & {
104
+ readonly appReleaseKind: "AppId";
105
+ }, string>>;
106
+ releaseId: z.ZodString & z.ZodType<string & {
107
+ readonly appReleaseKind: "ReleaseId";
108
+ }, string, z.core.$ZodTypeInternals<string & {
109
+ readonly appReleaseKind: "ReleaseId";
110
+ }, string>>;
111
+ authorityVersion: z.ZodNumber;
112
+ }, z.core.$strict>;
113
+ artifactDigest: z.ZodString & z.ZodType<string & {
114
+ readonly appReleaseKind: "Sha256Digest";
115
+ }, string, z.core.$ZodTypeInternals<string & {
116
+ readonly appReleaseKind: "Sha256Digest";
117
+ }, string>>;
118
+ }, z.core.$strict>;
119
+ computerId: z.ZodString;
120
+ nodeGitAccess: z.ZodOptional<z.ZodCustom<readonly {
121
+ readonly nodeId: string;
122
+ readonly gitAccess: {
123
+ repository: {
124
+ kind: "installation";
125
+ installationId: string;
126
+ repository: string;
127
+ } | {
128
+ kind: "team-source";
129
+ repository: string;
130
+ };
131
+ branches: string[];
132
+ } | {
133
+ repository: {
134
+ kind: "installation";
135
+ installationId: string;
136
+ repository: string;
137
+ } | {
138
+ kind: "team-source";
139
+ repository: string;
140
+ };
141
+ access: "read";
142
+ };
143
+ readonly graphId?: string;
144
+ }[], readonly {
145
+ readonly nodeId: string;
146
+ readonly gitAccess: {
147
+ repository: {
148
+ kind: "installation";
149
+ installationId: string;
150
+ repository: string;
151
+ } | {
152
+ kind: "team-source";
153
+ repository: string;
154
+ };
155
+ branches: string[];
156
+ } | {
157
+ repository: {
158
+ kind: "installation";
159
+ installationId: string;
160
+ repository: string;
161
+ } | {
162
+ kind: "team-source";
163
+ repository: string;
164
+ };
165
+ access: "read";
166
+ };
167
+ readonly graphId?: string;
168
+ }[]>>;
169
+ }, z.core.$strict>;
170
+ export type WorkflowTriggerTarget = z.infer<typeof workflowTriggerTargetSchema>;
171
+ export type ArmedWorkflowTrigger = z.infer<typeof armedWorkflowTriggerSchema>;
172
+ /** Host-attested arming principal: the grantor member and, for an Agent, its live source. */
173
+ export type WorkflowArmer = Pick<WorkflowArmingReceipt, "armedBy" | "armedVia">;
174
+ /** Host-attested control principal for listing and disarming stored triggers. */
175
+ export type WorkflowTriggerPrincipal = Readonly<{
176
+ kind: "member";
177
+ memberId: string;
178
+ }> | Readonly<{
179
+ kind: "agent";
180
+ agentId: string;
181
+ grantorMemberId: string;
182
+ }>;
183
+ /** The member whose installation grant authorizes this principal's control. */
184
+ export declare const workflowTriggerPrincipalMember: (principal: WorkflowTriggerPrincipal) => string;
185
+ /** A member controls every decodable trigger; an Agent controls only its own arms. */
186
+ export declare const workflowTriggerControlledBy: (principal: WorkflowTriggerPrincipal, binding: Pick<ArmedWorkflowTrigger, "armedVia">) => boolean;
187
+ /** Separate arming principals keep separate stored triggers. */
188
+ export declare const workflowArmerKey: (armer: WorkflowArmer) => (string | null)[];
189
+ /** Published provenance and current member authority shared by every trigger kind. */
190
+ export declare function createTeamWorkflowTriggers(options: {
191
+ runs: WorkflowTriggerRunPorts;
192
+ published: PublishedDefinitionPort<WorkflowPublicationContext>;
193
+ errors: WorkflowErrorPort;
194
+ /** Host-resolved installation GIT; rechecks membership and workflow.run on every call. */
195
+ source: (memberId: string, installationId: string, computerId: string) => Promise<GitBinding>;
196
+ /**
197
+ * Live installation authority only (workflow.run, workflow.arm, Git and the
198
+ * Computer); never opens Git or Artifact bytes. Returns the current pin.
199
+ */
200
+ admit: (memberId: string, installationId: string, computerId: string) => Promise<WorkflowInstallationAuthority>;
201
+ /** The current Agent source owner; the member reader is the run owner's. */
202
+ readAgentAccess: WorkflowArmingAuthorityPorts["readAgentAccess"];
203
+ /** The member's current Team Git policy; this never mints a pass. */
204
+ admitGitAccess: (memberId: string, repository: RepositoryRef, scope: "read" | "write") => Promise<void>;
205
+ /** Idempotently ensure the recorded run has an engine instance, including on replay. */
206
+ launch: (run: Readonly<{
207
+ runId: string;
208
+ planDigest: string;
209
+ }>) => Promise<void>;
210
+ }): {
211
+ arm: (armer: WorkflowArmer, raw: WorkflowTriggerTarget, computerId: string, rawAuthority: WorkflowInstallationAuthority) => Promise<{
212
+ kind: "refused";
213
+ reason: string;
214
+ } | {
215
+ kind: "refused";
216
+ reason: string;
217
+ issues: readonly import("../validate.js").Issue[];
218
+ binding?: never;
219
+ trigger?: never;
220
+ definition?: never;
221
+ } | {
222
+ kind: "armed";
223
+ binding: {
224
+ installationId: string;
225
+ workflowId: string;
226
+ commit: string;
227
+ digest: string & {
228
+ readonly appReleaseKind: "Sha256Digest";
229
+ };
230
+ triggerId: string;
231
+ bindings: Record<string, string | {
232
+ kind: "team-source";
233
+ }>;
234
+ armedBy: string;
235
+ armedVia: {
236
+ kind: "connector";
237
+ agentId: string;
238
+ attachmentId: string;
239
+ attachmentVersion: number;
240
+ } | {
241
+ kind: "policy";
242
+ agentId: string;
243
+ policyRevision: string;
244
+ grantorMemberId: string;
245
+ } | null;
246
+ grantorMembershipVersion: number;
247
+ installationAuthority: {
248
+ selection: {
249
+ instanceId: string;
250
+ owner: {
251
+ kind: "installation" | "deployment";
252
+ id: string;
253
+ };
254
+ appId: string & {
255
+ readonly appReleaseKind: "AppId";
256
+ };
257
+ releaseId: string & {
258
+ readonly appReleaseKind: "ReleaseId";
259
+ };
260
+ authorityVersion: number;
261
+ };
262
+ artifactDigest: string & {
263
+ readonly appReleaseKind: "Sha256Digest";
264
+ };
265
+ };
266
+ computerId: string;
267
+ delivery?: {
268
+ readonly agentId: string;
269
+ readonly sessionId: string;
270
+ } | undefined;
271
+ nodeGitAccess?: readonly {
272
+ readonly nodeId: string;
273
+ readonly gitAccess: {
274
+ repository: {
275
+ kind: "installation";
276
+ installationId: string;
277
+ repository: string;
278
+ } | {
279
+ kind: "team-source";
280
+ repository: string;
281
+ };
282
+ branches: string[];
283
+ } | {
284
+ repository: {
285
+ kind: "installation";
286
+ installationId: string;
287
+ repository: string;
288
+ } | {
289
+ kind: "team-source";
290
+ repository: string;
291
+ };
292
+ access: "read";
293
+ };
294
+ readonly graphId?: string;
295
+ }[] | undefined;
296
+ };
297
+ trigger: {
298
+ readonly id: string;
299
+ readonly on: "webhook";
300
+ readonly input?: {
301
+ readonly [x: string]: import("../schema.js").Mapping;
302
+ };
303
+ readonly title?: string;
304
+ readonly when?: import("../schema.js").Predicate;
305
+ } | {
306
+ readonly id: string;
307
+ readonly on: "schedule";
308
+ readonly cron: {
309
+ readonly expression: string;
310
+ readonly timeZone: string;
311
+ };
312
+ readonly input?: {
313
+ readonly [x: string]: import("../schema.js").Mapping;
314
+ };
315
+ readonly title?: string;
316
+ } | {
317
+ readonly id: string;
318
+ readonly on: "event";
319
+ readonly event: string;
320
+ readonly app: string;
321
+ readonly eventDigest: string;
322
+ readonly input?: {
323
+ readonly [x: string]: import("../schema.js").Mapping;
324
+ };
325
+ readonly title?: string;
326
+ readonly when?: import("../schema.js").Predicate;
327
+ readonly repository?: import("../schema.js").Mapping;
328
+ };
329
+ definition: {
330
+ readonly input: {
331
+ readonly [x: string]: S.Json;
332
+ };
333
+ readonly output: {
334
+ readonly [x: string]: {
335
+ readonly node: string;
336
+ readonly port: string;
337
+ };
338
+ };
339
+ readonly title: string;
340
+ readonly format: "fungi.workflow/v1";
341
+ readonly nodes: readonly ({
342
+ readonly id: string;
343
+ readonly kind: "code";
344
+ readonly source: string;
345
+ readonly input: {
346
+ readonly [x: string]: S.Json;
347
+ };
348
+ readonly output: {
349
+ readonly [x: string]: S.Json;
350
+ };
351
+ readonly values: {
352
+ readonly [x: string]: import("../schema.js").Mapping;
353
+ };
354
+ } | {
355
+ readonly values: {
356
+ readonly [x: string]: import("../schema.js").Mapping;
357
+ };
358
+ readonly id: string;
359
+ readonly method: string;
360
+ readonly kind: "app";
361
+ readonly app: string;
362
+ readonly methodDigest: string;
363
+ readonly gitAccess?: {
364
+ binding: string;
365
+ repository: string;
366
+ branches: string[];
367
+ } | {
368
+ binding: string;
369
+ repository: string;
370
+ access: "read";
371
+ };
372
+ readonly retry?: {
373
+ readonly attempts: number;
374
+ };
375
+ } | {
376
+ readonly show: readonly {
377
+ readonly node: string;
378
+ readonly port: string;
379
+ }[];
380
+ readonly id: string;
381
+ readonly title: string;
382
+ readonly timeout: number;
383
+ readonly kind: "review";
384
+ readonly reviewers: "runner" | "owners";
385
+ readonly detail?: string;
386
+ readonly choices?: readonly {
387
+ readonly id: string;
388
+ readonly label: string;
389
+ readonly description?: string;
390
+ }[];
391
+ } | {
392
+ readonly id: string;
393
+ readonly kind: "condition";
394
+ readonly test: import("../schema.js").Predicate;
395
+ } | {
396
+ readonly id: string;
397
+ readonly kind: "map";
398
+ readonly over: {
399
+ readonly node: string;
400
+ readonly port: string;
401
+ };
402
+ readonly body: string;
403
+ readonly concurrency: number;
404
+ readonly maxItems: number;
405
+ } | {
406
+ readonly id: string;
407
+ readonly kind: "repeat";
408
+ readonly body: string;
409
+ readonly maxRounds: number;
410
+ readonly until: import("../schema.js").Predicate;
411
+ } | {
412
+ readonly id: string;
413
+ readonly kind: "wait";
414
+ readonly for: number;
415
+ } | {
416
+ readonly id: string;
417
+ readonly kind: "transform";
418
+ readonly fields: {
419
+ readonly [x: string]: import("../schema.js").Mapping;
420
+ };
421
+ })[];
422
+ readonly edges: readonly {
423
+ readonly from: {
424
+ readonly node: string;
425
+ readonly port: string;
426
+ };
427
+ readonly to: {
428
+ readonly node: string;
429
+ readonly port: string;
430
+ };
431
+ }[];
432
+ readonly apps: {
433
+ readonly [x: string]: {
434
+ readonly appId: string;
435
+ readonly role?: string;
436
+ };
437
+ };
438
+ readonly description?: string;
439
+ readonly subgraphs?: {
440
+ readonly [x: string]: {
441
+ readonly input: {
442
+ readonly [x: string]: S.Json;
443
+ };
444
+ readonly nodes: readonly ({
445
+ readonly id: string;
446
+ readonly kind: "code";
447
+ readonly source: string;
448
+ readonly input: {
449
+ readonly [x: string]: S.Json;
450
+ };
451
+ readonly output: {
452
+ readonly [x: string]: S.Json;
453
+ };
454
+ readonly values: {
455
+ readonly [x: string]: import("../schema.js").Mapping;
456
+ };
457
+ } | {
458
+ readonly values: {
459
+ readonly [x: string]: import("../schema.js").Mapping;
460
+ };
461
+ readonly id: string;
462
+ readonly method: string;
463
+ readonly kind: "app";
464
+ readonly app: string;
465
+ readonly methodDigest: string;
466
+ readonly gitAccess?: {
467
+ binding: string;
468
+ repository: string;
469
+ branches: string[];
470
+ } | {
471
+ binding: string;
472
+ repository: string;
473
+ access: "read";
474
+ };
475
+ readonly retry?: {
476
+ readonly attempts: number;
477
+ };
478
+ } | {
479
+ readonly show: readonly {
480
+ readonly node: string;
481
+ readonly port: string;
482
+ }[];
483
+ readonly id: string;
484
+ readonly title: string;
485
+ readonly timeout: number;
486
+ readonly kind: "review";
487
+ readonly reviewers: "runner" | "owners";
488
+ readonly detail?: string;
489
+ readonly choices?: readonly {
490
+ readonly id: string;
491
+ readonly label: string;
492
+ readonly description?: string;
493
+ }[];
494
+ } | {
495
+ readonly id: string;
496
+ readonly kind: "condition";
497
+ readonly test: import("../schema.js").Predicate;
498
+ } | {
499
+ readonly id: string;
500
+ readonly kind: "map";
501
+ readonly over: {
502
+ readonly node: string;
503
+ readonly port: string;
504
+ };
505
+ readonly body: string;
506
+ readonly concurrency: number;
507
+ readonly maxItems: number;
508
+ } | {
509
+ readonly id: string;
510
+ readonly kind: "repeat";
511
+ readonly body: string;
512
+ readonly maxRounds: number;
513
+ readonly until: import("../schema.js").Predicate;
514
+ } | {
515
+ readonly id: string;
516
+ readonly kind: "wait";
517
+ readonly for: number;
518
+ } | {
519
+ readonly id: string;
520
+ readonly kind: "transform";
521
+ readonly fields: {
522
+ readonly [x: string]: import("../schema.js").Mapping;
523
+ };
524
+ })[];
525
+ readonly edges: readonly {
526
+ readonly from: {
527
+ readonly node: string;
528
+ readonly port: string;
529
+ };
530
+ readonly to: {
531
+ readonly node: string;
532
+ readonly port: string;
533
+ };
534
+ }[];
535
+ readonly output: {
536
+ readonly [x: string]: {
537
+ readonly node: string;
538
+ readonly port: string;
539
+ };
540
+ };
541
+ };
542
+ };
543
+ readonly triggers?: readonly ({
544
+ readonly id: string;
545
+ readonly on: "webhook";
546
+ readonly input?: {
547
+ readonly [x: string]: import("../schema.js").Mapping;
548
+ };
549
+ readonly title?: string;
550
+ readonly when?: import("../schema.js").Predicate;
551
+ } | {
552
+ readonly id: string;
553
+ readonly on: "schedule";
554
+ readonly cron: {
555
+ readonly expression: string;
556
+ readonly timeZone: string;
557
+ };
558
+ readonly input?: {
559
+ readonly [x: string]: import("../schema.js").Mapping;
560
+ };
561
+ readonly title?: string;
562
+ } | {
563
+ readonly id: string;
564
+ readonly on: "event";
565
+ readonly event: string;
566
+ readonly app: string;
567
+ readonly eventDigest: string;
568
+ readonly input?: {
569
+ readonly [x: string]: import("../schema.js").Mapping;
570
+ };
571
+ readonly title?: string;
572
+ readonly when?: import("../schema.js").Predicate;
573
+ readonly repository?: import("../schema.js").Mapping;
574
+ })[];
575
+ };
576
+ reason?: never;
577
+ issues?: never;
578
+ }>;
579
+ disarm: (binding: ArmedWorkflowTrigger) => void;
580
+ refusal: (binding: ArmedWorkflowTrigger) => string | null;
581
+ invalidateInstallation: (installationId: string) => void;
582
+ /** The single native push owner supplies host-issued Git, never a fire caller. */
583
+ revalidatePublished(installationId: string, git: GitBinding): Promise<void>;
584
+ fire(raw: ArmedWorkflowTrigger, scope: string, event: TriggerEvent): Promise<Readonly<{
585
+ kind: "ignored";
586
+ }> | Readonly<{
587
+ kind: "started" | "replay" | "conflict";
588
+ runId: string;
589
+ planDigest: string;
590
+ }> | Readonly<{
591
+ kind: "refused";
592
+ reason: string;
593
+ }>>;
594
+ };