@fungi.computer/oyster 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 (339) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +1134 -2
  3. package/dist/agents.d.ts +114 -0
  4. package/dist/agents.js +322 -0
  5. package/dist/app-builds.d.ts +210 -0
  6. package/dist/app-builds.js +499 -0
  7. package/dist/app-sandbox.d.ts +2 -0
  8. package/dist/app-sandbox.js +2 -0
  9. package/dist/app-sources.d.ts +31 -0
  10. package/dist/app-sources.js +370 -0
  11. package/dist/app-storage.d.ts +141 -0
  12. package/dist/app-storage.js +281 -0
  13. package/dist/apps/gate.d.ts +105 -0
  14. package/dist/apps/gate.js +273 -0
  15. package/dist/apps/index.d.ts +5 -0
  16. package/dist/apps/index.js +5 -0
  17. package/dist/apps/installation.d.ts +248 -0
  18. package/dist/apps/installation.js +307 -0
  19. package/dist/apps/operations.d.ts +8 -0
  20. package/dist/apps/operations.js +98 -0
  21. package/dist/apps/tools.d.ts +33 -0
  22. package/dist/apps/tools.js +17 -0
  23. package/dist/auth.d.ts +11 -0
  24. package/dist/auth.js +93 -0
  25. package/dist/backend-request.d.ts +3 -0
  26. package/dist/backend-request.js +53 -0
  27. package/dist/build/artifact-writer.d.ts +40 -0
  28. package/dist/build/artifact-writer.js +181 -0
  29. package/dist/build/build-jobs.d.ts +128 -0
  30. package/dist/build/build-jobs.js +203 -0
  31. package/dist/build/build-policy.d.ts +10 -0
  32. package/dist/build/build-policy.js +10 -0
  33. package/dist/build/build-step.d.ts +37 -0
  34. package/dist/build/build-step.js +28 -0
  35. package/dist/build/bundled-html.d.ts +7 -0
  36. package/dist/build/bundled-html.js +64 -0
  37. package/dist/build/candidate-builder.d.ts +68 -0
  38. package/dist/build/candidate-builder.js +91 -0
  39. package/dist/build/candidate-cli.d.ts +1 -0
  40. package/dist/build/candidate-cli.js +119 -0
  41. package/dist/build/candidate-cli.mjs +28170 -0
  42. package/dist/build/content-objects.d.ts +37 -0
  43. package/dist/build/content-objects.js +53 -0
  44. package/dist/build/definition-emission.d.ts +34 -0
  45. package/dist/build/definition-emission.js +201 -0
  46. package/dist/build/effect.d.ts +249 -0
  47. package/dist/build/effect.js +436 -0
  48. package/dist/build/git-environment.d.ts +9 -0
  49. package/dist/build/git-environment.js +60 -0
  50. package/dist/build/html-recipe.d.ts +20 -0
  51. package/dist/build/html-recipe.js +51 -0
  52. package/dist/build/local-build.d.ts +67 -0
  53. package/dist/build/local-build.js +1128 -0
  54. package/dist/build/snapshot-package-store.d.ts +12 -0
  55. package/dist/build/snapshot-package-store.js +36 -0
  56. package/dist/build/snapshot-program-scripts.d.ts +6 -0
  57. package/dist/build/snapshot-program-scripts.js +2 -0
  58. package/dist/build/snapshot-programs/snapshot-path.d.ts +2 -0
  59. package/dist/build/snapshot-programs/snapshot-path.js +6 -0
  60. package/dist/build/submission-contract.d.ts +828 -0
  61. package/dist/build/submission-contract.js +180 -0
  62. package/dist/build/workspace-build.d.ts +55 -0
  63. package/dist/build/workspace-build.js +200 -0
  64. package/dist/build-contract.d.ts +7 -0
  65. package/dist/build-contract.js +7 -0
  66. package/dist/build-egress.d.ts +62 -0
  67. package/dist/build-egress.js +148 -0
  68. package/dist/build-jobs.d.ts +2 -0
  69. package/dist/build-jobs.js +2 -0
  70. package/dist/build.d.ts +12 -0
  71. package/dist/build.js +14 -0
  72. package/dist/capability-descriptor.d.ts +46 -0
  73. package/dist/capability-descriptor.js +51 -0
  74. package/dist/catalog-frame.d.ts +39 -0
  75. package/dist/catalog-frame.js +72 -0
  76. package/dist/cause-class.d.ts +19 -0
  77. package/dist/cause-class.js +54 -0
  78. package/dist/cloudflare.d.ts +123 -0
  79. package/dist/cloudflare.js +391 -0
  80. package/dist/computer-terminal.d.ts +38 -0
  81. package/dist/computer-terminal.js +410 -0
  82. package/dist/computer.d.ts +60 -0
  83. package/dist/computer.js +33 -0
  84. package/dist/event-recipients.d.ts +57 -0
  85. package/dist/event-recipients.js +144 -0
  86. package/dist/facet-invocation.d.ts +4 -0
  87. package/dist/facet-invocation.js +45 -0
  88. package/dist/files.d.ts +42 -0
  89. package/dist/files.js +123 -0
  90. package/dist/frame-binding-wire-script.d.ts +2 -0
  91. package/dist/frame-binding-wire-script.js +1 -0
  92. package/dist/frame-binding-wire.d.ts +28 -0
  93. package/dist/frame-binding-wire.js +54 -0
  94. package/dist/git-admission.d.ts +52 -0
  95. package/dist/git-admission.js +188 -0
  96. package/dist/git-auth.d.ts +11 -0
  97. package/dist/git-auth.js +27 -0
  98. package/dist/git-door.d.ts +35 -0
  99. package/dist/git-door.js +108 -0
  100. package/dist/git-journal.d.ts +31 -0
  101. package/dist/git-journal.js +188 -0
  102. package/dist/git.d.ts +31 -0
  103. package/dist/git.js +64 -0
  104. package/dist/guest-policy.d.ts +9 -0
  105. package/dist/guest-policy.js +13 -0
  106. package/dist/host.d.ts +244 -0
  107. package/dist/host.js +1043 -0
  108. package/dist/index.d.ts +166 -0
  109. package/dist/index.js +320 -0
  110. package/dist/installation-consent.d.ts +79 -0
  111. package/dist/installation-consent.js +82 -0
  112. package/dist/internal/background-origins.d.ts +3 -0
  113. package/dist/internal/background-origins.js +8 -0
  114. package/dist/internal/delivery.d.ts +12 -0
  115. package/dist/internal/delivery.js +167 -0
  116. package/dist/internal/host-gate.d.ts +14 -0
  117. package/dist/internal/host-gate.js +62 -0
  118. package/dist/internal/registry-installations.d.ts +6 -0
  119. package/dist/internal/registry-installations.js +12 -0
  120. package/dist/invocation.d.ts +251 -0
  121. package/dist/invocation.js +377 -0
  122. package/dist/keys.d.ts +48 -0
  123. package/dist/keys.js +52 -0
  124. package/dist/mcp-owner.d.ts +27 -0
  125. package/dist/mcp-owner.js +155 -0
  126. package/dist/mcp.d.ts +89 -0
  127. package/dist/mcp.js +429 -0
  128. package/dist/media.d.ts +23 -0
  129. package/dist/media.js +12 -0
  130. package/dist/pack.d.ts +79 -0
  131. package/dist/pack.js +151 -0
  132. package/dist/page/capabilities.d.ts +23 -0
  133. package/dist/page/capabilities.js +256 -0
  134. package/dist/page/computer-handles.d.ts +79 -0
  135. package/dist/page/computer-handles.js +44 -0
  136. package/dist/page/gill-observation.d.ts +4 -0
  137. package/dist/page/gill-observation.js +31 -0
  138. package/dist/page/lifetime.d.ts +6 -0
  139. package/dist/page/lifetime.js +19 -0
  140. package/dist/page/mount.d.ts +163 -0
  141. package/dist/page/mount.js +390 -0
  142. package/dist/page/storage.d.ts +3 -0
  143. package/dist/page/storage.js +82 -0
  144. package/dist/page/terminal.d.ts +5 -0
  145. package/dist/page/terminal.js +7 -0
  146. package/dist/page/window-launch.d.ts +18 -0
  147. package/dist/page/window-launch.js +11 -0
  148. package/dist/page-script.d.ts +14 -0
  149. package/dist/page-script.js +5 -0
  150. package/dist/r2-files.d.ts +3 -0
  151. package/dist/r2-files.js +79 -0
  152. package/dist/release.d.ts +83 -0
  153. package/dist/release.js +167 -0
  154. package/dist/root-data.d.ts +86 -0
  155. package/dist/root-data.js +69 -0
  156. package/dist/shell/app-directory.d.ts +542 -0
  157. package/dist/shell/app-directory.js +199 -0
  158. package/dist/shell/browser-actions.d.ts +7 -0
  159. package/dist/shell/browser-actions.js +56 -0
  160. package/dist/shell/command-host.d.ts +112 -0
  161. package/dist/shell/command-host.js +502 -0
  162. package/dist/shell/commands.d.ts +25 -0
  163. package/dist/shell/commands.js +78 -0
  164. package/dist/shell/index.d.ts +8 -0
  165. package/dist/shell/index.js +8 -0
  166. package/dist/shell/keys.d.ts +41 -0
  167. package/dist/shell/keys.js +134 -0
  168. package/dist/shell/shell-module.d.ts +55 -0
  169. package/dist/shell/shell-module.js +86 -0
  170. package/dist/shell/window-manager.d.ts +124 -0
  171. package/dist/shell/window-manager.js +711 -0
  172. package/dist/shell/workbench-contract.d.ts +68 -0
  173. package/dist/shell/workbench-contract.js +1 -0
  174. package/dist/shell/workbench-directory.d.ts +332 -0
  175. package/dist/shell/workbench-directory.js +35 -0
  176. package/dist/shell/workbench-host-types.d.ts +96 -0
  177. package/dist/shell/workbench-host-types.js +1 -0
  178. package/dist/shell/workbench-host.d.ts +34 -0
  179. package/dist/shell/workbench-host.js +347 -0
  180. package/dist/shell/workbench-model.d.ts +192 -0
  181. package/dist/shell/workbench-model.js +53 -0
  182. package/dist/shell/workbench.d.ts +4 -0
  183. package/dist/shell/workbench.js +2 -0
  184. package/dist/source/fork.d.ts +27 -0
  185. package/dist/source/fork.js +46 -0
  186. package/dist/source/index.d.ts +10 -0
  187. package/dist/source/index.js +10 -0
  188. package/dist/source/seed-receipt.d.ts +53 -0
  189. package/dist/source/seed-receipt.js +18 -0
  190. package/dist/source/team-source.d.ts +32 -0
  191. package/dist/source/team-source.js +42 -0
  192. package/dist/source/template-push.d.ts +33 -0
  193. package/dist/source/template-push.js +223 -0
  194. package/dist/source/template-repository.d.ts +4 -0
  195. package/dist/source/template-repository.js +21 -0
  196. package/dist/source/template-seed.d.ts +68 -0
  197. package/dist/source/template-seed.js +80 -0
  198. package/dist/standalone/agent-directory.d.ts +4 -0
  199. package/dist/standalone/agent-directory.js +4 -0
  200. package/dist/standalone/agents.d.ts +220 -0
  201. package/dist/standalone/agents.js +795 -0
  202. package/dist/standalone/app-builds-binding.d.ts +36 -0
  203. package/dist/standalone/app-builds-binding.js +119 -0
  204. package/dist/standalone/app-set.d.ts +91 -0
  205. package/dist/standalone/app-set.js +395 -0
  206. package/dist/standalone/app-source.d.ts +41 -0
  207. package/dist/standalone/app-source.js +59 -0
  208. package/dist/standalone/builds.d.ts +18 -0
  209. package/dist/standalone/builds.js +101 -0
  210. package/dist/standalone/computer-egress.d.ts +37 -0
  211. package/dist/standalone/computer-egress.js +111 -0
  212. package/dist/standalone/computer.d.ts +122 -0
  213. package/dist/standalone/computer.js +714 -0
  214. package/dist/standalone/install-apps-cli.d.ts +2 -0
  215. package/dist/standalone/install-apps-cli.js +126 -0
  216. package/dist/standalone/instance.d.ts +35 -0
  217. package/dist/standalone/instance.js +74 -0
  218. package/dist/standalone/media.d.ts +76 -0
  219. package/dist/standalone/media.js +227 -0
  220. package/dist/standalone/preview.d.ts +51 -0
  221. package/dist/standalone/preview.js +167 -0
  222. package/dist/standalone/registry.d.ts +102 -0
  223. package/dist/standalone/registry.js +193 -0
  224. package/dist/standalone/tenancy.d.ts +42 -0
  225. package/dist/standalone/tenancy.js +241 -0
  226. package/dist/standalone/worker.d.ts +55 -0
  227. package/dist/standalone/worker.js +147 -0
  228. package/dist/standalone/workflow-authority-readers.d.ts +16 -0
  229. package/dist/standalone/workflow-authority-readers.js +35 -0
  230. package/dist/standalone/workflow-binding.d.ts +216 -0
  231. package/dist/standalone/workflow-binding.js +217 -0
  232. package/dist/standalone/workflow-events.d.ts +46 -0
  233. package/dist/standalone/workflow-events.js +39 -0
  234. package/dist/standalone/workflow-git-capture.d.ts +7 -0
  235. package/dist/standalone/workflow-git-capture.js +62 -0
  236. package/dist/standalone/workflow-host.d.ts +931 -0
  237. package/dist/standalone/workflow-host.js +751 -0
  238. package/dist/standalone/workflow-node-capture.d.ts +13 -0
  239. package/dist/standalone/workflow-node-capture.js +72 -0
  240. package/dist/standalone/workflow-root-authority.d.ts +27 -0
  241. package/dist/standalone/workflow-root-authority.js +87 -0
  242. package/dist/standalone/workflow-schedules.d.ts +52 -0
  243. package/dist/standalone/workflow-schedules.js +40 -0
  244. package/dist/standalone/workflow-trigger-host.d.ts +1694 -0
  245. package/dist/standalone/workflow-trigger-host.js +52 -0
  246. package/dist/standalone/workflows.d.ts +657 -0
  247. package/dist/standalone/workflows.js +554 -0
  248. package/dist/storage-frame.d.ts +64 -0
  249. package/dist/storage-frame.js +28 -0
  250. package/dist/tenancy/auth0.d.ts +64 -0
  251. package/dist/tenancy/auth0.js +198 -0
  252. package/dist/tenancy/cloudflare/rate-limit.d.ts +8 -0
  253. package/dist/tenancy/cloudflare/rate-limit.js +19 -0
  254. package/dist/tenancy/cloudflare/registry.d.ts +50 -0
  255. package/dist/tenancy/cloudflare/registry.js +301 -0
  256. package/dist/tenancy/cloudflare.d.ts +2 -0
  257. package/dist/tenancy/cloudflare.js +2 -0
  258. package/dist/tenancy/cold-directory.d.ts +13 -0
  259. package/dist/tenancy/cold-directory.js +43 -0
  260. package/dist/tenancy/contracts.d.ts +195 -0
  261. package/dist/tenancy/contracts.js +1 -0
  262. package/dist/tenancy/index.d.ts +19 -0
  263. package/dist/tenancy/index.js +156 -0
  264. package/dist/tenancy/owner-key.d.ts +26 -0
  265. package/dist/tenancy/owner-key.js +63 -0
  266. package/dist/tenancy/oyster.d.ts +4 -0
  267. package/dist/tenancy/oyster.js +25 -0
  268. package/dist/tenancy/registry-record.d.ts +7 -0
  269. package/dist/tenancy/registry-record.js +44 -0
  270. package/dist/tenancy/registry.d.ts +27 -0
  271. package/dist/tenancy/registry.js +138 -0
  272. package/dist/tenancy/resolve.d.ts +7 -0
  273. package/dist/tenancy/resolve.js +64 -0
  274. package/dist/tenant.d.ts +81 -0
  275. package/dist/tenant.js +71 -0
  276. package/dist/testing/capabilities.d.ts +29 -0
  277. package/dist/testing/capabilities.js +130 -0
  278. package/dist/testing/catalog.d.ts +3 -0
  279. package/dist/testing/catalog.js +53 -0
  280. package/dist/testing/index.d.ts +10 -0
  281. package/dist/testing/index.js +10 -0
  282. package/dist/testing/installation.d.ts +11 -0
  283. package/dist/testing/installation.js +25 -0
  284. package/dist/testing/native-worker.d.ts +21 -0
  285. package/dist/testing/native-worker.js +106 -0
  286. package/dist/testing/worker.d.ts +18 -0
  287. package/dist/testing/worker.js +67 -0
  288. package/dist/testing/workers-runtime.d.ts +24 -0
  289. package/dist/testing/workers-runtime.js +33 -0
  290. package/dist/webhook-delivery.d.ts +14 -0
  291. package/dist/webhook-delivery.js +17 -0
  292. package/dist/workers-git.d.ts +285 -0
  293. package/dist/workers-git.js +1174 -0
  294. package/dist/workers.d.ts +352 -0
  295. package/dist/workers.js +868 -0
  296. package/docs/api/README.md +82 -0
  297. package/docs/api/agents.md +332 -0
  298. package/docs/api/app-storage.md +209 -0
  299. package/docs/api/apps.md +1375 -0
  300. package/docs/api/auth.md +63 -0
  301. package/docs/api/build-contract.md +1304 -0
  302. package/docs/api/build.md +1712 -0
  303. package/docs/api/cloudflare.md +421 -0
  304. package/docs/api/computer.md +203 -0
  305. package/docs/api/files.md +117 -0
  306. package/docs/api/git.md +470 -0
  307. package/docs/api/host.md +1328 -0
  308. package/docs/api/index.md +430 -0
  309. package/docs/api/invocation.md +738 -0
  310. package/docs/api/keys.md +175 -0
  311. package/docs/api/mcp.md +301 -0
  312. package/docs/api/media.md +40 -0
  313. package/docs/api/modules.md +50 -0
  314. package/docs/api/pack.md +141 -0
  315. package/docs/api/page/mount.md +298 -0
  316. package/docs/api/root-data.md +111 -0
  317. package/docs/api/shell/app-directory.md +599 -0
  318. package/docs/api/shell/command-host.md +224 -0
  319. package/docs/api/shell/commands.md +197 -0
  320. package/docs/api/shell/keys.md +183 -0
  321. package/docs/api/shell/shell-module.md +204 -0
  322. package/docs/api/shell/window-manager.md +267 -0
  323. package/docs/api/shell/workbench-directory.md +119 -0
  324. package/docs/api/shell/workbench.md +205 -0
  325. package/docs/api/shell.md +1915 -0
  326. package/docs/api/tenancy/auth0.md +110 -0
  327. package/docs/api/tenancy/cloudflare.md +221 -0
  328. package/docs/api/tenancy/cold-directory.md +46 -0
  329. package/docs/api/tenancy/owner-key.md +63 -0
  330. package/docs/api/tenancy/registry.md +77 -0
  331. package/docs/api/tenancy/resolve.md +69 -0
  332. package/docs/api/tenancy.md +430 -0
  333. package/docs/api/tenant.md +194 -0
  334. package/docs/api/workers-git.md +1646 -0
  335. package/docs/api/workers.md +1691 -0
  336. package/docs/site/agent-quickstart.mdx +346 -0
  337. package/examples/standalone/worker.ts +7 -0
  338. package/examples/standalone/wrangler.jsonc +82 -0
  339. package/package.json +300 -3
@@ -0,0 +1,1646 @@
1
+ <!-- Generated by Botanical API docs (TypeDoc + typedoc-plugin-markdown). Do not edit. -->
2
+
3
+ [**@fungi.computer/oyster**](README.md)
4
+
5
+ ---
6
+
7
+ [@fungi.computer/oyster](modules.md) / workers-git
8
+
9
+ # workers-git
10
+
11
+ ## Classes
12
+
13
+ ### OysterKeys
14
+
15
+ Named keys an owner issues directly: an Ear Tag key store scoped to this tenant.
16
+ A key's id is the name the owner chose for it, so forks and other name-derived
17
+ identities (`service.ts:95`) stay stable across a reissue. Plaintext keys are
18
+ never stored.
19
+
20
+ #### Extends
21
+
22
+ - `DurableObject`\<[`OysterKeysEnv`](#oysterkeysenv)\>
23
+
24
+ #### Constructors
25
+
26
+ ##### Constructor
27
+
28
+ ```ts
29
+ new OysterKeys(ctx, env): OysterKeys;
30
+ ```
31
+
32
+ ###### Parameters
33
+
34
+ | Parameter | Type |
35
+ | --------- | --------------------------------- |
36
+ | `ctx` | `DurableObjectState` |
37
+ | `env` | [`OysterKeysEnv`](#oysterkeysenv) |
38
+
39
+ ###### Returns
40
+
41
+ [`OysterKeys`](#oysterkeys)
42
+
43
+ ###### Overrides
44
+
45
+ ```ts
46
+ DurableObject<OysterKeysEnv>.constructor
47
+ ```
48
+
49
+ #### Methods
50
+
51
+ ##### issue()
52
+
53
+ ```ts
54
+ issue(owner, input): Promise<KeyOutcome<Readonly<{
55
+ key: string;
56
+ record: KeyRecord<Capability>;
57
+ }>>>;
58
+ ```
59
+
60
+ Issue a key named `name`, its id too. Refuses `conflict` once a name has been
61
+ used, including by a now-revoked key: a name is never reused.
62
+
63
+ ###### Parameters
64
+
65
+ | Parameter | Type |
66
+ | --------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
67
+ | `owner` | `string` |
68
+ | `input` | `Readonly`\<\{ `name`: `string`; `grants`: readonly `Grant`\<[`OysterKeyCapability`](keys.md#oysterkeycapability)\>[]; `expiresAt?`: `number`; \}\> |
69
+
70
+ ###### Returns
71
+
72
+ `Promise`\<`KeyOutcome`\<`Readonly`\<\{ `key`: `string`; `record`:
73
+ `KeyRecord`\<`Capability`\>; \}\>\>\>
74
+
75
+ ##### revoke()
76
+
77
+ ```ts
78
+ revoke(
79
+ owner,
80
+ requestId,
81
+ keyId
82
+ ): Promise<KeyOutcome<Readonly<{
83
+ keyId: string;
84
+ owner: string;
85
+ name: string;
86
+ scope: | Readonly<{
87
+ grants: readonly Readonly<{
88
+ capability: OysterKeyCapability;
89
+ targets: GrantTargets;
90
+ }>[];
91
+ }>
92
+ | null;
93
+ grantVersion: number;
94
+ expiresAt: number | null;
95
+ revokedAt: number | null;
96
+ rateLimit: | Readonly<{
97
+ limit: number;
98
+ windowSeconds: number;
99
+ }>
100
+ | null;
101
+ lastUsedAt: number | null;
102
+ createdAt: number;
103
+ updatedAt: number;
104
+ }>>>;
105
+ ```
106
+
107
+ Revoke a key by id; idempotent on repeat.
108
+
109
+ ###### Parameters
110
+
111
+ | Parameter | Type |
112
+ | ----------- | -------- |
113
+ | `owner` | `string` |
114
+ | `requestId` | `string` |
115
+ | `keyId` | `string` |
116
+
117
+ ###### Returns
118
+
119
+ `Promise`\<`KeyOutcome`\<`Readonly`\<\{ `keyId`: `string`; `owner`: `string`;
120
+ `name`: `string`; `scope`: \| `Readonly`\<\{ `grants`: readonly `Readonly`\<\{
121
+ `capability`: [`OysterKeyCapability`](keys.md#oysterkeycapability); `targets`:
122
+ `GrantTargets`; \}\>[]; \}\> \| `null`; `grantVersion`: `number`; `expiresAt`:
123
+ `number` \| `null`; `revokedAt`: `number` \| `null`; `rateLimit`: \|
124
+ `Readonly`\<\{ `limit`: `number`; `windowSeconds`: `number`; \}\> \| `null`;
125
+ `lastUsedAt`: `number` \| `null`; `createdAt`: `number`; `updatedAt`: `number`;
126
+ \}\>\>\>
127
+
128
+ ##### list()
129
+
130
+ ```ts
131
+ list(owner): Promise<KeyOutcome<readonly Readonly<{
132
+ keyId: string;
133
+ owner: string;
134
+ name: string;
135
+ scope: | Readonly<{
136
+ grants: readonly Readonly<{
137
+ capability: ...;
138
+ targets: ...;
139
+ }>[];
140
+ }>
141
+ | null;
142
+ grantVersion: number;
143
+ expiresAt: number | null;
144
+ revokedAt: number | null;
145
+ rateLimit: | Readonly<{
146
+ limit: number;
147
+ windowSeconds: number;
148
+ }>
149
+ | null;
150
+ lastUsedAt: number | null;
151
+ createdAt: number;
152
+ updatedAt: number;
153
+ }>[]>>;
154
+ ```
155
+
156
+ Every key this tenant has issued, newest first.
157
+
158
+ ###### Parameters
159
+
160
+ | Parameter | Type |
161
+ | --------- | -------- |
162
+ | `owner` | `string` |
163
+
164
+ ###### Returns
165
+
166
+ `Promise`\<`KeyOutcome`\<readonly `Readonly`\<\{ `keyId`: `string`; `owner`:
167
+ `string`; `name`: `string`; `scope`: \| `Readonly`\<\{ `grants`: readonly
168
+ `Readonly`\<\{ `capability`: ...; `targets`: ...; \}\>[]; \}\> \| `null`;
169
+ `grantVersion`: `number`; `expiresAt`: `number` \| `null`; `revokedAt`: `number`
170
+ \| `null`; `rateLimit`: \| `Readonly`\<\{ `limit`: `number`; `windowSeconds`:
171
+ `number`; \}\> \| `null`; `lastUsedAt`: `number` \| `null`; `createdAt`:
172
+ `number`; `updatedAt`: `number`; \}\>[]\>\>
173
+
174
+ ##### verify()
175
+
176
+ ```ts
177
+ verify(secret): Promise<KeyOutcome<Readonly<{
178
+ keyId: string;
179
+ owner: string;
180
+ name: string;
181
+ scope: Scope<Capability>;
182
+ grantVersion: number;
183
+ expiresAt: number | null;
184
+ }>>>;
185
+ ```
186
+
187
+ Verify a bearer secret and return its current principal.
188
+
189
+ ###### Parameters
190
+
191
+ | Parameter | Type |
192
+ | --------- | -------- |
193
+ | `secret` | `string` |
194
+
195
+ ###### Returns
196
+
197
+ `Promise`\<`KeyOutcome`\<`Readonly`\<\{ `keyId`: `string`; `owner`: `string`;
198
+ `name`: `string`; `scope`: `Scope`\<`Capability`\>; `grantVersion`: `number`;
199
+ `expiresAt`: `number` \| `null`; \}\>\>\>
200
+
201
+ ##### live()
202
+
203
+ ```ts
204
+ live(keyId): Promise<
205
+ | Readonly<{
206
+ keyId: string;
207
+ owner: string;
208
+ grantVersion: number;
209
+ grants: readonly Readonly<{
210
+ capability: OysterKeyCapability;
211
+ targets: GrantTargets;
212
+ }>[];
213
+ }>
214
+ | null>;
215
+ ```
216
+
217
+ The live facts behind one key id, for the host's `keys.live` port; `null` for an
218
+ unknown, revoked, expired or suspended key.
219
+
220
+ ###### Parameters
221
+
222
+ | Parameter | Type |
223
+ | --------- | -------- |
224
+ | `keyId` | `string` |
225
+
226
+ ###### Returns
227
+
228
+ `Promise`\< \| `Readonly`\<\{ `keyId`: `string`; `owner`: `string`;
229
+ `grantVersion`: `number`; `grants`: readonly `Readonly`\<\{ `capability`:
230
+ [`OysterKeyCapability`](keys.md#oysterkeycapability); `targets`: `GrantTargets`;
231
+ \}\>[]; \}\> \| `null`\>
232
+
233
+ ---
234
+
235
+ ### OysterWebhooks
236
+
237
+ The tenant's App event delivery owner: webhook subscriptions with signed,
238
+ retried deliveries, and host recipients with durable per-recipient records. An
239
+ emit commits here and returns; every delivery happens on the alarm.
240
+
241
+ #### Extends
242
+
243
+ - `DurableObject`\<`Env`\>
244
+
245
+ #### Type Parameters
246
+
247
+ | Type Parameter | Default type |
248
+ | ------------------------------------------------- | --------------------------------- |
249
+ | `Env` _extends_ [`OysterKeysEnv`](#oysterkeysenv) | [`OysterKeysEnv`](#oysterkeysenv) |
250
+
251
+ #### Constructors
252
+
253
+ ##### Constructor
254
+
255
+ ```ts
256
+ new OysterWebhooks<Env>(ctx, env): OysterWebhooks<Env>;
257
+ ```
258
+
259
+ ###### Parameters
260
+
261
+ | Parameter | Type |
262
+ | --------- | -------------------- |
263
+ | `ctx` | `DurableObjectState` |
264
+ | `env` | `Env` |
265
+
266
+ ###### Returns
267
+
268
+ [`OysterWebhooks`](#oysterwebhooks)\<`Env`\>
269
+
270
+ ###### Overrides
271
+
272
+ ```ts
273
+ DurableObject<Env>.constructor
274
+ ```
275
+
276
+ #### Methods
277
+
278
+ ##### recipientDeliveries()
279
+
280
+ ```ts
281
+ recipientDeliveries(recipient): Readonly<{
282
+ recipient: string;
283
+ eventId: string;
284
+ type: string;
285
+ state: "pending" | "failed" | "delivered";
286
+ attempts: number;
287
+ lastError: string | null;
288
+ updatedAt: number;
289
+ }>[];
290
+ ```
291
+
292
+ Recent deliveries to one host recipient, newest first.
293
+
294
+ ###### Parameters
295
+
296
+ | Parameter | Type |
297
+ | ----------- | -------- |
298
+ | `recipient` | `string` |
299
+
300
+ ###### Returns
301
+
302
+ `Readonly`\<\{ `recipient`: `string`; `eventId`: `string`; `type`: `string`;
303
+ `state`: `"pending"` \| `"failed"` \| `"delivered"`; `attempts`: `number`;
304
+ `lastError`: `string` \| `null`; `updatedAt`: `number`; \}\>[]
305
+
306
+ ##### subscribe()
307
+
308
+ ```ts
309
+ subscribe(input): SubscriptionCreated;
310
+ ```
311
+
312
+ Subscribe `url` to an installation's events; returns the secret once.
313
+
314
+ ###### Parameters
315
+
316
+ | Parameter | Type |
317
+ | ---------------------- | ----------------------------------------------------------------------------------------------------- |
318
+ | `input` | \{ `installationId`: `string`; `url`: `string`; `types`: readonly `string`[]; `secret?`: `string`; \} |
319
+ | `input.installationId` | `string` |
320
+ | `input.url` | `string` |
321
+ | `input.types` | readonly `string`[] |
322
+ | `input.secret?` | `string` |
323
+
324
+ ###### Returns
325
+
326
+ [`SubscriptionCreated`](#subscriptioncreated)
327
+
328
+ ##### subscriptions()
329
+
330
+ ```ts
331
+ subscriptions(): Readonly<{
332
+ id: string;
333
+ installationId: string;
334
+ url: string;
335
+ types: readonly string[];
336
+ createdAt: number;
337
+ }>[];
338
+ ```
339
+
340
+ Every subscription.
341
+
342
+ ###### Returns
343
+
344
+ `Readonly`\<\{ `id`: `string`; `installationId`: `string`; `url`: `string`;
345
+ `types`: readonly `string`[]; `createdAt`: `number`; \}\>[]
346
+
347
+ ##### unsubscribe()
348
+
349
+ ```ts
350
+ unsubscribe(id): boolean;
351
+ ```
352
+
353
+ Remove a subscription and its deliveries.
354
+
355
+ ###### Parameters
356
+
357
+ | Parameter | Type |
358
+ | --------- | -------- |
359
+ | `id` | `string` |
360
+
361
+ ###### Returns
362
+
363
+ `boolean`
364
+
365
+ ##### deliveries()
366
+
367
+ ```ts
368
+ deliveries(subscription): Readonly<{
369
+ id: string;
370
+ subscription: string;
371
+ type: string;
372
+ state: "pending" | "failed" | "delivered";
373
+ attempts: number;
374
+ lastStatus: number | null;
375
+ updatedAt: number;
376
+ }>[];
377
+ ```
378
+
379
+ Recent deliveries for one subscription, newest first.
380
+
381
+ ###### Parameters
382
+
383
+ | Parameter | Type |
384
+ | -------------- | -------- |
385
+ | `subscription` | `string` |
386
+
387
+ ###### Returns
388
+
389
+ `Readonly`\<\{ `id`: `string`; `subscription`: `string`; `type`: `string`;
390
+ `state`: `"pending"` \| `"failed"` \| `"delivered"`; `attempts`: `number`;
391
+ `lastStatus`: `number` \| `null`; `updatedAt`: `number`; \}\>[]
392
+
393
+ ##### enqueue()
394
+
395
+ ```ts
396
+ enqueue(
397
+ source,
398
+ payload,
399
+ eventId,
400
+ recipients
401
+ ): Promise<number>;
402
+ ```
403
+
404
+ Accept an emitted event: queue it for every matching subscription and every
405
+ named host recipient (idempotent per event id). Nothing is delivered before this
406
+ returns, so no recipient can fail the emitter's write.
407
+
408
+ ###### Parameters
409
+
410
+ | Parameter | Type |
411
+ | ------------ | --------------------------------------------------------- |
412
+ | `source` | [`HostEventSource`](#hosteventsource) |
413
+ | `payload` | [`StandardWebhookPayload`](git.md#standardwebhookpayload) |
414
+ | `eventId` | `string` |
415
+ | `recipients` | readonly `string`[] |
416
+
417
+ ###### Returns
418
+
419
+ `Promise`\<`number`\>
420
+
421
+ ##### alarm()
422
+
423
+ ```ts
424
+ alarm(): Promise<void>;
425
+ ```
426
+
427
+ Deliver due webhooks and recipient rows, then schedule the next retry.
428
+
429
+ ###### Returns
430
+
431
+ `Promise`\<`void`\>
432
+
433
+ ###### Overrides
434
+
435
+ ```ts
436
+ DurableObject.alarm;
437
+ ```
438
+
439
+ ---
440
+
441
+ ### OysterBinding
442
+
443
+ A git Worker's one guest binding entrypoint, over `gitBindings`.
444
+
445
+ #### Extends
446
+
447
+ - `WorkerEntrypoint`\<[`OysterGitWorkerEnv`](#oystergitworkerenv),
448
+ `Readonly`\<\{ `instanceId`: `string`; `binding`: \| `"BACKGROUND"` \| `"GIT"`
449
+ \| `"EVENTS"` \| `"APPS"` \| `"WORKFLOWS"` \| `"APP_STORAGE"` \| `"MEDIA"` \|
450
+ `"COMPUTER"` \| `"INBOX"` \| `"AGENTS"`; `frameId`: `string`; \}\>, `this`\>
451
+
452
+ #### Constructors
453
+
454
+ ##### Constructor
455
+
456
+ ```ts
457
+ new OysterBinding(ctx, env): OysterBinding;
458
+ ```
459
+
460
+ ###### Parameters
461
+
462
+ | Parameter | Type |
463
+ | --------- | ------------------------------------------- |
464
+ | `ctx` | `ExecutionContext` |
465
+ | `env` | [`OysterGitWorkerEnv`](#oystergitworkerenv) |
466
+
467
+ ###### Returns
468
+
469
+ [`OysterBinding`](#oysterbinding)
470
+
471
+ ###### Inherited from
472
+
473
+ ```ts
474
+ oysterBindingEntrypoint(gitBindings).constructor;
475
+ ```
476
+
477
+ ---
478
+
479
+ ### `abstract` OysterGitInstance
480
+
481
+ An App Instance whose backend may also receive declared Git and Events bindings.
482
+ Background wakes readmit members through the deployable root's `hostFor`, the
483
+ same composition HTTP and MCP use.
484
+
485
+ #### Extends
486
+
487
+ - [`OysterInstance`](workers.md#oysterinstance)\<`Env`\>
488
+
489
+ #### Type Parameters
490
+
491
+ | Type Parameter | Default type |
492
+ | ----------------------------------------------------------- | ------------------------------------------- |
493
+ | `Env` _extends_ [`OysterGitWorkerEnv`](#oystergitworkerenv) | [`OysterGitWorkerEnv`](#oystergitworkerenv) |
494
+
495
+ #### Constructors
496
+
497
+ ##### Constructor
498
+
499
+ ```ts
500
+ new OysterGitInstance<Env>(ctx, env): OysterGitInstance<Env>;
501
+ ```
502
+
503
+ ###### Parameters
504
+
505
+ | Parameter | Type |
506
+ | --------- | -------------------- |
507
+ | `ctx` | `DurableObjectState` |
508
+ | `env` | `Env` |
509
+
510
+ ###### Returns
511
+
512
+ [`OysterGitInstance`](#abstract-oystergitinstance)\<`Env`\>
513
+
514
+ ###### Inherited from
515
+
516
+ [`OysterInstance`](workers.md#oysterinstance).[`constructor`](workers.md#constructor-3)
517
+
518
+ #### Methods
519
+
520
+ ##### bindingCall()
521
+
522
+ ```ts
523
+ bindingCall(
524
+ raw,
525
+ method,
526
+ input
527
+ ): Promise<FrameBindingReply<OysterBindingResult>>;
528
+ ```
529
+
530
+ Resolve each guest packet against its immutable frame before any host effect.
531
+
532
+ ###### Parameters
533
+
534
+ | Parameter | Type |
535
+ | --------- | ------------------------------------------------------ |
536
+ | `raw` | [`FrameBindingProps`](cloudflare.md#framebindingprops) |
537
+ | `method` | `string` |
538
+ | `input` | readonly `unknown`[] |
539
+
540
+ ###### Returns
541
+
542
+ `Promise`\<[`FrameBindingReply`](cloudflare.md#framebindingreply)\<[`OysterBindingResult`](workers.md#oysterbindingresult)\>\>
543
+
544
+ ###### Inherited from
545
+
546
+ [`OysterInstance`](workers.md#oysterinstance).[`bindingCall`](workers.md#bindingcall)
547
+
548
+ ##### gitTip()
549
+
550
+ ```ts
551
+ gitTip(
552
+ installationId,
553
+ repository,
554
+ ref,
555
+ tenantId?
556
+ ): Promise<string | null>;
557
+ ```
558
+
559
+ Last provider-accepted ref recorded by this installation's journal.
560
+
561
+ ###### Parameters
562
+
563
+ | Parameter | Type | Default value |
564
+ | ---------------- | ---------------------------------------- | --------------- |
565
+ | `installationId` | `string` | `undefined` |
566
+ | `repository` | `string` | `undefined` |
567
+ | `ref` | `string` | `undefined` |
568
+ | `tenantId` | `string` & `Brand`\<`"OysterTenantId"`\> | `defaultTenant` |
569
+
570
+ ###### Returns
571
+
572
+ `Promise`\<`string` \| `null`\>
573
+
574
+ ###### Inherited from
575
+
576
+ [`OysterInstance`](workers.md#oysterinstance).[`gitTip`](workers.md#gittip)
577
+
578
+ ##### recordGitPush()
579
+
580
+ ```ts
581
+ recordGitPush(
582
+ installationId,
583
+ fact,
584
+ tenantId?
585
+ ): Promise<"duplicate" | "recorded">;
586
+ ```
587
+
588
+ Join accepted fact identity and Carrier delivery in one local transaction.
589
+
590
+ ###### Parameters
591
+
592
+ | Parameter | Type | Default value |
593
+ | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------- |
594
+ | `installationId` | `string` | `undefined` |
595
+ | `fact` | \{ `repository`: `string`; `writer`: \| \{ `kind`: `"actor"`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `role?`: `"member"` \| `"owner"`; `workflow?`: \{ `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `branches`: `string`[]; `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; \}; \} \| \{ `kind`: `"installation"`; `installationId`: `string`; `onBehalfOf`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \} \| `null`; \}; `updates`: `object`[]; `unexplained?`: `object`[]; `eventId`: `string`; \} | `undefined` |
596
+ | `fact.repository` | `string` | `undefined` |
597
+ | `fact.writer` | \| \{ `kind`: `"actor"`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `role?`: `"member"` \| `"owner"`; `workflow?`: \{ `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `branches`: `string`[]; `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; \}; \} \| \{ `kind`: `"installation"`; `installationId`: `string`; `onBehalfOf`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \} \| `null`; \} | `undefined` |
598
+ | `fact.updates` | `object`[] | `undefined` |
599
+ | `fact.unexplained?` | `object`[] | `undefined` |
600
+ | `fact.eventId` | `string` | `undefined` |
601
+ | `tenantId` | `string` & `Brand`\<`"OysterTenantId"`\> | `defaultTenant` |
602
+
603
+ ###### Returns
604
+
605
+ `Promise`\<`"duplicate"` \| `"recorded"`\>
606
+
607
+ ###### Inherited from
608
+
609
+ [`OysterInstance`](workers.md#oysterinstance).[`recordGitPush`](workers.md#recordgitpush)
610
+
611
+ ##### alarm()
612
+
613
+ ```ts
614
+ alarm(): Promise<void>;
615
+ ```
616
+
617
+ Carrier owns retries, dead letters and retained delivery receipts.
618
+
619
+ ###### Returns
620
+
621
+ `Promise`\<`void`\>
622
+
623
+ ###### Inherited from
624
+
625
+ [`OysterInstance`](workers.md#oysterinstance).[`alarm`](workers.md#alarm)
626
+
627
+ ##### revoke()
628
+
629
+ ```ts
630
+ revoke(
631
+ installationId,
632
+ runId?,
633
+ tenantId?
634
+ ): Promise<void>;
635
+ ```
636
+
637
+ Installation changes end guest work; a Workflow cancel targets only its run.
638
+
639
+ ###### Parameters
640
+
641
+ | Parameter | Type | Default value |
642
+ | ---------------- | ---------------------------------------- | --------------- |
643
+ | `installationId` | `string` | `undefined` |
644
+ | `runId?` | `string` | `undefined` |
645
+ | `tenantId?` | `string` & `Brand`\<`"OysterTenantId"`\> | `defaultTenant` |
646
+
647
+ ###### Returns
648
+
649
+ `Promise`\<`void`\>
650
+
651
+ ###### Inherited from
652
+
653
+ [`OysterInstance`](workers.md#oysterinstance).[`revoke`](workers.md#revoke)
654
+
655
+ ##### apply()
656
+
657
+ ```ts
658
+ apply(
659
+ state,
660
+ release,
661
+ limits,
662
+ tenant
663
+ ): Promise<InstanceResult<{
664
+ instanceId: InstanceId;
665
+ owner: {
666
+ kind: "installation" | "deployment";
667
+ id: string;
668
+ };
669
+ appId: AppId;
670
+ releaseId: ReleaseId;
671
+ authorityVersion: number;
672
+ stateSchema: number | null;
673
+ desiredStatus: "enabled" | "disabled" | "deleted";
674
+ status: "disabled" | "deleted" | "active" | "deleting";
675
+ }>>;
676
+ ```
677
+
678
+ Remember `release`, then apply the owner state under the host's tenant pin.
679
+
680
+ ###### Parameters
681
+
682
+ | Parameter | Type |
683
+ | ------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
684
+ | `state` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; `status`: `"enabled"` \| `"disabled"` \| `"deleted"`; \} |
685
+ | `state.instanceId` | [`InstanceId`](index.md#instanceid) |
686
+ | `state.owner` | \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \} |
687
+ | `state.owner.kind` | `"installation"` \| `"deployment"` |
688
+ | `state.owner.id` | `string` |
689
+ | `state.appId` | `AppId` |
690
+ | `state.releaseId` | `ReleaseId` |
691
+ | `state.authorityVersion` | `number` |
692
+ | `state.status` | `"enabled"` \| `"disabled"` \| `"deleted"` |
693
+ | `release` | `Release` |
694
+ | `limits` | \| `Readonly`\<\{ `cpuMs`: `number`; `subRequests`: `number`; \}\> \| `undefined` |
695
+ | `tenant` | `Pick`\<[`TenantScope`](tenant.md#tenantscope), `"tenantId"` \| `"origin"`\> |
696
+
697
+ ###### Returns
698
+
699
+ `Promise`\<[`InstanceResult`](host.md#instanceresult)\<\{ `instanceId`:
700
+ [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \|
701
+ `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`;
702
+ `authorityVersion`: `number`; `stateSchema`: `number` \| `null`;
703
+ `desiredStatus`: `"enabled"` \| `"disabled"` \| `"deleted"`; `status`:
704
+ `"disabled"` \| `"deleted"` \| `"active"` \| `"deleting"`; \}\>\>
705
+
706
+ ###### Inherited from
707
+
708
+ [`OysterInstance`](workers.md#oysterinstance).[`apply`](workers.md#apply)
709
+
710
+ ##### backend()
711
+
712
+ ```ts
713
+ backend(
714
+ facts,
715
+ request,
716
+ limits?,
717
+ tenantId?
718
+ ): Promise<Response>;
719
+ ```
720
+
721
+ Forward an admitted HTTP request to the App backend.
722
+
723
+ ###### Parameters
724
+
725
+ | Parameter | Type | Default value |
726
+ | ----------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------- |
727
+ | `facts` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `selection`: \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; \}; `artifactDigest`: `Sha256Digest`; `subject`: \| \{ `kind`: `"call"`; `context`: \{ `computerId`: `string` \| `null`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `backgroundLane?`: `string`; `backgroundOrigin?`: \{ `method`: `string`; `seal`: `string`; \}; `role?`: `"member"` \| `"owner"`; `soleMember?`: `true`; `workflow?`: \{ `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; \}; `idempotencyKey?`: `string`; \}; `sessionId?`: `string`; `agentPolicy?`: \{ `policyRevision`: `string`; `grantorMemberId`: `string`; \}; `method?`: \{ `name`: `string`; `effect`: `"read"` \| `"write"` \| `"external"`; \}; `replay?`: \{ `lane`: `string`; `epoch`: `number`; `admitted`: readonly `string`[]; \}; \} \| \{ `kind`: `"lifecycle"`; `name`: `"onGitPush"`; `eventId`: `string`; \} \| \{ `kind`: `"lifecycle"`; `name`: `"syncRefused"`; `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \}; `grants`: readonly `object`[]; `deadlineAt`: `number`; `ancestry`: readonly [`InstanceId`](index.md#instanceid)[]; \} | `undefined` |
728
+ | `facts.instanceId` | [`InstanceId`](index.md#instanceid) | `instanceIdSchema` |
729
+ | `facts.selection` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; \} | `selectionSchema` |
730
+ | `facts.selection.instanceId?` | [`InstanceId`](index.md#instanceid) | `instanceIdSchema` |
731
+ | `facts.selection.owner?` | \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \} | `ownerSchema` |
732
+ | `facts.selection.owner.kind?` | `"installation"` \| `"deployment"` | `...` |
733
+ | `facts.selection.owner.id?` | `string` | `Schema.NonEmptyString` |
734
+ | `facts.selection.appId?` | `AppId` | `appIdSchema` |
735
+ | `facts.selection.releaseId?` | `ReleaseId` | `releaseIdSchema` |
736
+ | `facts.selection.authorityVersion?` | `number` | `...` |
737
+ | `facts.artifactDigest?` | `Sha256Digest` | `sha256DigestSchema` |
738
+ | `facts.subject?` | \| \{ `kind`: `"call"`; `context`: \{ `computerId`: `string` \| `null`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `backgroundLane?`: `string`; `backgroundOrigin?`: \{ `method`: `string`; `seal`: `string`; \}; `role?`: `"member"` \| `"owner"`; `soleMember?`: `true`; `workflow?`: \{ `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; \}; `idempotencyKey?`: `string`; \}; `sessionId?`: `string`; `agentPolicy?`: \{ `policyRevision`: `string`; `grantorMemberId`: `string`; \}; `method?`: \{ `name`: `string`; `effect`: `"read"` \| `"write"` \| `"external"`; \}; `replay?`: \{ `lane`: `string`; `epoch`: `number`; `admitted`: readonly `string`[]; \}; \} \| \{ `kind`: `"lifecycle"`; `name`: `"onGitPush"`; `eventId`: `string`; \} \| \{ `kind`: `"lifecycle"`; `name`: `"syncRefused"`; `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \} | `...` |
739
+ | `facts.grants?` | readonly `object`[] | `grantsSchema` |
740
+ | `facts.deadlineAt?` | `number` | `...` |
741
+ | `facts.ancestry?` | readonly [`InstanceId`](index.md#instanceid)[] | `...` |
742
+ | `request?` | `Request` | `undefined` |
743
+ | `limits?` | `Readonly`\<\{ `cpuMs`: `number`; `subRequests`: `number`; \}\> | `undefined` |
744
+ | `tenantId?` | `string` & `Brand`\<`"OysterTenantId"`\> | `defaultTenant` |
745
+
746
+ ###### Returns
747
+
748
+ `Promise`\<`Response`\>
749
+
750
+ ###### Inherited from
751
+
752
+ [`OysterInstance`](workers.md#oysterinstance).[`backend`](workers.md#backend)
753
+
754
+ ##### onGitPush()
755
+
756
+ ```ts
757
+ onGitPush(
758
+ facts,
759
+ fact,
760
+ limits?,
761
+ tenantId?
762
+ ): Promise<void>;
763
+ ```
764
+
765
+ Deliver a Git push through the same selected-Instance admission as methods.
766
+
767
+ ###### Parameters
768
+
769
+ | Parameter | Type | Default value |
770
+ | ----------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------- |
771
+ | `facts` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `selection`: \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; \}; `artifactDigest`: `Sha256Digest`; `subject`: \| \{ `kind`: `"call"`; `context`: \{ `computerId`: `string` \| `null`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `backgroundLane?`: `string`; `backgroundOrigin?`: \{ `method`: `string`; `seal`: `string`; \}; `role?`: `"member"` \| `"owner"`; `soleMember?`: `true`; `workflow?`: \{ `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; \}; `idempotencyKey?`: `string`; \}; `sessionId?`: `string`; `agentPolicy?`: \{ `policyRevision`: `string`; `grantorMemberId`: `string`; \}; `method?`: \{ `name`: `string`; `effect`: `"read"` \| `"write"` \| `"external"`; \}; `replay?`: \{ `lane`: `string`; `epoch`: `number`; `admitted`: readonly `string`[]; \}; \} \| \{ `kind`: `"lifecycle"`; `name`: `"onGitPush"`; `eventId`: `string`; \} \| \{ `kind`: `"lifecycle"`; `name`: `"syncRefused"`; `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \}; `grants`: readonly `object`[]; `deadlineAt`: `number`; `ancestry`: readonly [`InstanceId`](index.md#instanceid)[]; \} | `undefined` |
772
+ | `facts.instanceId` | [`InstanceId`](index.md#instanceid) | `instanceIdSchema` |
773
+ | `facts.selection` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; \} | `selectionSchema` |
774
+ | `facts.selection.instanceId?` | [`InstanceId`](index.md#instanceid) | `instanceIdSchema` |
775
+ | `facts.selection.owner?` | \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \} | `ownerSchema` |
776
+ | `facts.selection.owner.kind?` | `"installation"` \| `"deployment"` | `...` |
777
+ | `facts.selection.owner.id?` | `string` | `Schema.NonEmptyString` |
778
+ | `facts.selection.appId?` | `AppId` | `appIdSchema` |
779
+ | `facts.selection.releaseId?` | `ReleaseId` | `releaseIdSchema` |
780
+ | `facts.selection.authorityVersion?` | `number` | `...` |
781
+ | `facts.artifactDigest?` | `Sha256Digest` | `sha256DigestSchema` |
782
+ | `facts.subject?` | \| \{ `kind`: `"call"`; `context`: \{ `computerId`: `string` \| `null`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `backgroundLane?`: `string`; `backgroundOrigin?`: \{ `method`: `string`; `seal`: `string`; \}; `role?`: `"member"` \| `"owner"`; `soleMember?`: `true`; `workflow?`: \{ `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; \}; `idempotencyKey?`: `string`; \}; `sessionId?`: `string`; `agentPolicy?`: \{ `policyRevision`: `string`; `grantorMemberId`: `string`; \}; `method?`: \{ `name`: `string`; `effect`: `"read"` \| `"write"` \| `"external"`; \}; `replay?`: \{ `lane`: `string`; `epoch`: `number`; `admitted`: readonly `string`[]; \}; \} \| \{ `kind`: `"lifecycle"`; `name`: `"onGitPush"`; `eventId`: `string`; \} \| \{ `kind`: `"lifecycle"`; `name`: `"syncRefused"`; `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \} | `...` |
783
+ | `facts.grants?` | readonly `object`[] | `grantsSchema` |
784
+ | `facts.deadlineAt?` | `number` | `...` |
785
+ | `facts.ancestry?` | readonly [`InstanceId`](index.md#instanceid)[] | `...` |
786
+ | `fact?` | \{ `repository`: `string`; `writer`: \| \{ `kind`: `"actor"`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `role?`: `"member"` \| `"owner"`; `workflow?`: \{ `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `branches`: `string`[]; `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; \}; \} \| \{ `kind`: `"installation"`; `installationId`: `string`; `onBehalfOf`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \} \| `null`; \}; `updates`: `object`[]; `unexplained?`: `object`[]; `eventId`: `string`; \} | `undefined` |
787
+ | `fact.repository?` | `string` | `undefined` |
788
+ | `fact.writer?` | \| \{ `kind`: `"actor"`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `role?`: `"member"` \| `"owner"`; `workflow?`: \{ `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `branches`: `string`[]; `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; \}; \} \| \{ `kind`: `"installation"`; `installationId`: `string`; `onBehalfOf`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \} \| `null`; \} | `undefined` |
789
+ | `fact.updates?` | `object`[] | `undefined` |
790
+ | `fact.unexplained?` | `object`[] | `undefined` |
791
+ | `fact.eventId?` | `string` | `undefined` |
792
+ | `limits?` | `Readonly`\<\{ `cpuMs`: `number`; `subRequests`: `number`; \}\> | `undefined` |
793
+ | `tenantId?` | `string` & `Brand`\<`"OysterTenantId"`\> | `defaultTenant` |
794
+
795
+ ###### Returns
796
+
797
+ `Promise`\<`void`\>
798
+
799
+ ###### Inherited from
800
+
801
+ [`OysterInstance`](workers.md#oysterinstance).[`onGitPush`](workers.md#ongitpush)
802
+
803
+ ##### authorizeGitPush()
804
+
805
+ ```ts
806
+ authorizeGitPush(
807
+ facts,
808
+ question,
809
+ limits?,
810
+ tenantId?
811
+ ): Promise<
812
+ | {
813
+ allowed: true;
814
+ }
815
+ | {
816
+ allowed: false;
817
+ refused: object[];
818
+ }>;
819
+ ```
820
+
821
+ Ask the App's declared authorizer through the same frame-bound connection.
822
+
823
+ ###### Parameters
824
+
825
+ | Parameter | Type | Default value |
826
+ | -------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------- |
827
+ | `facts` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `selection`: \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; \}; `artifactDigest`: `Sha256Digest`; `subject`: \| \{ `kind`: `"call"`; `context`: \{ `computerId`: `string` \| `null`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `backgroundLane?`: `string`; `backgroundOrigin?`: \{ `method`: `string`; `seal`: `string`; \}; `role?`: `"member"` \| `"owner"`; `soleMember?`: `true`; `workflow?`: \{ `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; \}; `idempotencyKey?`: `string`; \}; `sessionId?`: `string`; `agentPolicy?`: \{ `policyRevision`: `string`; `grantorMemberId`: `string`; \}; `method?`: \{ `name`: `string`; `effect`: `"read"` \| `"write"` \| `"external"`; \}; `replay?`: \{ `lane`: `string`; `epoch`: `number`; `admitted`: readonly `string`[]; \}; \} \| \{ `kind`: `"lifecycle"`; `name`: `"onGitPush"`; `eventId`: `string`; \} \| \{ `kind`: `"lifecycle"`; `name`: `"syncRefused"`; `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \}; `grants`: readonly `object`[]; `deadlineAt`: `number`; `ancestry`: readonly [`InstanceId`](index.md#instanceid)[]; \} | `undefined` |
828
+ | `facts.instanceId` | [`InstanceId`](index.md#instanceid) | `instanceIdSchema` |
829
+ | `facts.selection` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; \} | `selectionSchema` |
830
+ | `facts.selection.instanceId?` | [`InstanceId`](index.md#instanceid) | `instanceIdSchema` |
831
+ | `facts.selection.owner?` | \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \} | `ownerSchema` |
832
+ | `facts.selection.owner.kind?` | `"installation"` \| `"deployment"` | `...` |
833
+ | `facts.selection.owner.id?` | `string` | `Schema.NonEmptyString` |
834
+ | `facts.selection.appId?` | `AppId` | `appIdSchema` |
835
+ | `facts.selection.releaseId?` | `ReleaseId` | `releaseIdSchema` |
836
+ | `facts.selection.authorityVersion?` | `number` | `...` |
837
+ | `facts.artifactDigest?` | `Sha256Digest` | `sha256DigestSchema` |
838
+ | `facts.subject?` | \| \{ `kind`: `"call"`; `context`: \{ `computerId`: `string` \| `null`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `backgroundLane?`: `string`; `backgroundOrigin?`: \{ `method`: `string`; `seal`: `string`; \}; `role?`: `"member"` \| `"owner"`; `soleMember?`: `true`; `workflow?`: \{ `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; \}; `idempotencyKey?`: `string`; \}; `sessionId?`: `string`; `agentPolicy?`: \{ `policyRevision`: `string`; `grantorMemberId`: `string`; \}; `method?`: \{ `name`: `string`; `effect`: `"read"` \| `"write"` \| `"external"`; \}; `replay?`: \{ `lane`: `string`; `epoch`: `number`; `admitted`: readonly `string`[]; \}; \} \| \{ `kind`: `"lifecycle"`; `name`: `"onGitPush"`; `eventId`: `string`; \} \| \{ `kind`: `"lifecycle"`; `name`: `"syncRefused"`; `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \} | `...` |
839
+ | `facts.grants?` | readonly `object`[] | `grantsSchema` |
840
+ | `facts.deadlineAt?` | `number` | `...` |
841
+ | `facts.ancestry?` | readonly [`InstanceId`](index.md#instanceid)[] | `...` |
842
+ | `question?` | \{ `repository`: `string`; `writer`: \{ `kind`: `"actor"`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `role?`: `"member"` \| `"owner"`; `workflow?`: \{ `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `branches`: `string`[]; `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; \}; \}; `updates`: `object`[]; \} | `undefined` |
843
+ | `question.repository?` | `string` | `undefined` |
844
+ | `question.writer?` | \{ `kind`: `"actor"`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `role?`: `"member"` \| `"owner"`; `workflow?`: \{ `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `branches`: `string`[]; `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; \}; \} | `undefined` |
845
+ | `question.writer.kind?` | `"actor"` | `undefined` |
846
+ | `question.writer.actor?` | \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \} | `undefined` |
847
+ | `question.writer.role?` | `"member"` \| `"owner"` | `undefined` |
848
+ | `question.writer.workflow?` | \{ `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `branches`: `string`[]; `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; \} | `undefined` |
849
+ | `question.writer.workflow.armedBy?` | \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \} | `undefined` |
850
+ | `question.writer.workflow.branches?` | `string`[] | `undefined` |
851
+ | `question.writer.workflow.workflowId?` | `string` | `undefined` |
852
+ | `question.writer.workflow.runId?` | `string` | `undefined` |
853
+ | `question.writer.workflow.nodeId?` | `string` | `undefined` |
854
+ | `question.updates?` | `object`[] | `undefined` |
855
+ | `limits?` | `Readonly`\<\{ `cpuMs`: `number`; `subRequests`: `number`; \}\> | `undefined` |
856
+ | `tenantId?` | `string` & `Brand`\<`"OysterTenantId"`\> | `defaultTenant` |
857
+
858
+ ###### Returns
859
+
860
+ `Promise`\< \| \{ `allowed`: `true`; \} \| \{ `allowed`: `false`; `refused`:
861
+ `object`[]; \}\>
862
+
863
+ ###### Inherited from
864
+
865
+ [`OysterInstance`](workers.md#oysterinstance).[`authorizeGitPush`](workers.md#authorizegitpush)
866
+
867
+ ##### syncRefused()
868
+
869
+ ```ts
870
+ syncRefused(
871
+ facts,
872
+ refusal,
873
+ limits?,
874
+ tenantId?
875
+ ): Promise<void>;
876
+ ```
877
+
878
+ An available lane settles a refusal under an active frame with no binding
879
+ grants.
880
+
881
+ ###### Parameters
882
+
883
+ | Parameter | Type | Default value |
884
+ | ----------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------- |
885
+ | `facts` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `selection`: \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; \}; `artifactDigest`: `Sha256Digest`; `subject`: \| \{ `kind`: `"call"`; `context`: \{ `computerId`: `string` \| `null`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `backgroundLane?`: `string`; `backgroundOrigin?`: \{ `method`: `string`; `seal`: `string`; \}; `role?`: `"member"` \| `"owner"`; `soleMember?`: `true`; `workflow?`: \{ `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; \}; `idempotencyKey?`: `string`; \}; `sessionId?`: `string`; `agentPolicy?`: \{ `policyRevision`: `string`; `grantorMemberId`: `string`; \}; `method?`: \{ `name`: `string`; `effect`: `"read"` \| `"write"` \| `"external"`; \}; `replay?`: \{ `lane`: `string`; `epoch`: `number`; `admitted`: readonly `string`[]; \}; \} \| \{ `kind`: `"lifecycle"`; `name`: `"onGitPush"`; `eventId`: `string`; \} \| \{ `kind`: `"lifecycle"`; `name`: `"syncRefused"`; `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \}; `grants`: readonly `object`[]; `deadlineAt`: `number`; `ancestry`: readonly [`InstanceId`](index.md#instanceid)[]; \} | `undefined` |
886
+ | `facts.instanceId` | [`InstanceId`](index.md#instanceid) | `instanceIdSchema` |
887
+ | `facts.selection` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; \} | `selectionSchema` |
888
+ | `facts.selection.instanceId?` | [`InstanceId`](index.md#instanceid) | `instanceIdSchema` |
889
+ | `facts.selection.owner?` | \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \} | `ownerSchema` |
890
+ | `facts.selection.owner.kind?` | `"installation"` \| `"deployment"` | `...` |
891
+ | `facts.selection.owner.id?` | `string` | `Schema.NonEmptyString` |
892
+ | `facts.selection.appId?` | `AppId` | `appIdSchema` |
893
+ | `facts.selection.releaseId?` | `ReleaseId` | `releaseIdSchema` |
894
+ | `facts.selection.authorityVersion?` | `number` | `...` |
895
+ | `facts.artifactDigest?` | `Sha256Digest` | `sha256DigestSchema` |
896
+ | `facts.subject?` | \| \{ `kind`: `"call"`; `context`: \{ `computerId`: `string` \| `null`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `backgroundLane?`: `string`; `backgroundOrigin?`: \{ `method`: `string`; `seal`: `string`; \}; `role?`: `"member"` \| `"owner"`; `soleMember?`: `true`; `workflow?`: \{ `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; \}; `idempotencyKey?`: `string`; \}; `sessionId?`: `string`; `agentPolicy?`: \{ `policyRevision`: `string`; `grantorMemberId`: `string`; \}; `method?`: \{ `name`: `string`; `effect`: `"read"` \| `"write"` \| `"external"`; \}; `replay?`: \{ `lane`: `string`; `epoch`: `number`; `admitted`: readonly `string`[]; \}; \} \| \{ `kind`: `"lifecycle"`; `name`: `"onGitPush"`; `eventId`: `string`; \} \| \{ `kind`: `"lifecycle"`; `name`: `"syncRefused"`; `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \} | `...` |
897
+ | `facts.grants?` | readonly `object`[] | `grantsSchema` |
898
+ | `facts.deadlineAt?` | `number` | `...` |
899
+ | `facts.ancestry?` | readonly [`InstanceId`](index.md#instanceid)[] | `...` |
900
+ | `refusal?` | \{ `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \} | `undefined` |
901
+ | `refusal.lane?` | `string` | `undefined` |
902
+ | `refusal.code?` | `"access_changed"` \| `"installation_unavailable"` | `undefined` |
903
+ | `limits?` | `Readonly`\<\{ `cpuMs`: `number`; `subRequests`: `number`; \}\> | `undefined` |
904
+ | `tenantId?` | `string` & `Brand`\<`"OysterTenantId"`\> | `defaultTenant` |
905
+
906
+ ###### Returns
907
+
908
+ `Promise`\<`void`\>
909
+
910
+ ###### Inherited from
911
+
912
+ [`OysterInstance`](workers.md#oysterinstance).[`syncRefused`](workers.md#syncrefused)
913
+
914
+ ##### gill()
915
+
916
+ ```ts
917
+ gill(
918
+ facts,
919
+ _api,
920
+ source,
921
+ input,
922
+ limits?,
923
+ tenantId?
924
+ ): Promise<InstanceResult<
925
+ | {
926
+ viewId: string;
927
+ title: string;
928
+ state: "empty";
929
+ rows: readonly [];
930
+ next?: string;
931
+ }
932
+ | {
933
+ viewId: string;
934
+ title: string;
935
+ state: "error";
936
+ rows: readonly [];
937
+ reason?: "exec_isolation_required" | "params_required";
938
+ error: string;
939
+ recovery?: | {
940
+ kind: "configure";
941
+ param: string;
942
+ }
943
+ | {
944
+ kind: "open";
945
+ };
946
+ }
947
+ | {
948
+ viewId: string;
949
+ title: string;
950
+ state: "full";
951
+ rows: readonly object[];
952
+ next?: string;
953
+ }
954
+ | {
955
+ options: readonly object[];
956
+ next?: string;
957
+ }>>;
958
+ ```
959
+
960
+ Invoke a Release-declared Gill in a fresh immutable frame.
961
+
962
+ ###### Parameters
963
+
964
+ | Parameter | Type | Default value |
965
+ | ----------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------- |
966
+ | `facts` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `selection`: \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; \}; `artifactDigest`: `Sha256Digest`; `subject`: \| \{ `kind`: `"call"`; `context`: \{ `computerId`: `string` \| `null`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `backgroundLane?`: `string`; `backgroundOrigin?`: \{ `method`: `string`; `seal`: `string`; \}; `role?`: `"member"` \| `"owner"`; `soleMember?`: `true`; `workflow?`: \{ `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; \}; `idempotencyKey?`: `string`; \}; `sessionId?`: `string`; `agentPolicy?`: \{ `policyRevision`: `string`; `grantorMemberId`: `string`; \}; `method?`: \{ `name`: `string`; `effect`: `"read"` \| `"write"` \| `"external"`; \}; `replay?`: \{ `lane`: `string`; `epoch`: `number`; `admitted`: readonly `string`[]; \}; \} \| \{ `kind`: `"lifecycle"`; `name`: `"onGitPush"`; `eventId`: `string`; \} \| \{ `kind`: `"lifecycle"`; `name`: `"syncRefused"`; `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \}; `grants`: readonly `object`[]; `deadlineAt`: `number`; `ancestry`: readonly [`InstanceId`](index.md#instanceid)[]; \} | `undefined` |
967
+ | `facts.instanceId` | [`InstanceId`](index.md#instanceid) | `instanceIdSchema` |
968
+ | `facts.selection` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; \} | `selectionSchema` |
969
+ | `facts.selection.instanceId` | [`InstanceId`](index.md#instanceid) | `instanceIdSchema` |
970
+ | `facts.selection.owner` | \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \} | `ownerSchema` |
971
+ | `facts.selection.owner.kind?` | `"installation"` \| `"deployment"` | `...` |
972
+ | `facts.selection.owner.id?` | `string` | `Schema.NonEmptyString` |
973
+ | `facts.selection.appId?` | `AppId` | `appIdSchema` |
974
+ | `facts.selection.releaseId?` | `ReleaseId` | `releaseIdSchema` |
975
+ | `facts.selection.authorityVersion?` | `number` | `...` |
976
+ | `facts.artifactDigest?` | `Sha256Digest` | `sha256DigestSchema` |
977
+ | `facts.subject?` | \| \{ `kind`: `"call"`; `context`: \{ `computerId`: `string` \| `null`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `backgroundLane?`: `string`; `backgroundOrigin?`: \{ `method`: `string`; `seal`: `string`; \}; `role?`: `"member"` \| `"owner"`; `soleMember?`: `true`; `workflow?`: \{ `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; \}; `idempotencyKey?`: `string`; \}; `sessionId?`: `string`; `agentPolicy?`: \{ `policyRevision`: `string`; `grantorMemberId`: `string`; \}; `method?`: \{ `name`: `string`; `effect`: `"read"` \| `"write"` \| `"external"`; \}; `replay?`: \{ `lane`: `string`; `epoch`: `number`; `admitted`: readonly `string`[]; \}; \} \| \{ `kind`: `"lifecycle"`; `name`: `"onGitPush"`; `eventId`: `string`; \} \| \{ `kind`: `"lifecycle"`; `name`: `"syncRefused"`; `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \} | `...` |
978
+ | `facts.grants?` | readonly `object`[] | `grantsSchema` |
979
+ | `facts.deadlineAt?` | `number` | `...` |
980
+ | `facts.ancestry?` | readonly [`InstanceId`](index.md#instanceid)[] | `...` |
981
+ | `_api?` | `AppApi` | `undefined` |
982
+ | `source?` | `string` | `undefined` |
983
+ | `input?` | \{ `id`: `string`; `params?`: \{ \[`key`: `string`\]: `string`; \}; `after?`: `string`; `options?`: `string`; \} | `undefined` |
984
+ | `input.id?` | `string` | `undefined` |
985
+ | `input.params?` | \{ \[`key`: `string`\]: `string`; \} | `undefined` |
986
+ | `input.after?` | `string` | `undefined` |
987
+ | `input.options?` | `string` | `undefined` |
988
+ | `limits?` | `Readonly`\<\{ `cpuMs`: `number`; `subRequests`: `number`; \}\> | `undefined` |
989
+ | `tenantId?` | `string` & `Brand`\<`"OysterTenantId"`\> | `defaultTenant` |
990
+
991
+ ###### Returns
992
+
993
+ `Promise`\<[`InstanceResult`](host.md#instanceresult)\< \| \{ `viewId`:
994
+ `string`; `title`: `string`; `state`: `"empty"`; `rows`: readonly \[\]; `next?`:
995
+ `string`; \} \| \{ `viewId`: `string`; `title`: `string`; `state`: `"error"`;
996
+ `rows`: readonly \[\]; `reason?`: `"exec_isolation_required"` \|
997
+ `"params_required"`; `error`: `string`; `recovery?`: \| \{ `kind`:
998
+ `"configure"`; `param`: `string`; \} \| \{ `kind`: `"open"`; \}; \} \| \{
999
+ `viewId`: `string`; `title`: `string`; `state`: `"full"`; `rows`: readonly
1000
+ `object`[]; `next?`: `string`; \} \| \{ `options`: readonly `object`[]; `next?`:
1001
+ `string`; \}\>\>
1002
+
1003
+ ###### Inherited from
1004
+
1005
+ [`OysterInstance`](workers.md#oysterinstance).[`gill`](workers.md#gill)
1006
+
1007
+ ##### call()
1008
+
1009
+ ```ts
1010
+ call(
1011
+ facts,
1012
+ _api,
1013
+ name,
1014
+ input,
1015
+ limits?,
1016
+ tenantId?
1017
+ ): Promise<InstanceResult<Json>>;
1018
+ ```
1019
+
1020
+ Invoke one declared App method; the value is its AppMethodReply wire, which the
1021
+ host handle decodes.
1022
+
1023
+ ###### Parameters
1024
+
1025
+ | Parameter | Type | Default value |
1026
+ | ----------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------- |
1027
+ | `facts` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `selection`: \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; \}; `artifactDigest`: `Sha256Digest`; `subject`: \| \{ `kind`: `"call"`; `context`: \{ `computerId`: `string` \| `null`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `backgroundLane?`: `string`; `backgroundOrigin?`: \{ `method`: `string`; `seal`: `string`; \}; `role?`: `"member"` \| `"owner"`; `soleMember?`: `true`; `workflow?`: \{ `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; \}; `idempotencyKey?`: `string`; \}; `sessionId?`: `string`; `agentPolicy?`: \{ `policyRevision`: `string`; `grantorMemberId`: `string`; \}; `method?`: \{ `name`: `string`; `effect`: `"read"` \| `"write"` \| `"external"`; \}; `replay?`: \{ `lane`: `string`; `epoch`: `number`; `admitted`: readonly `string`[]; \}; \} \| \{ `kind`: `"lifecycle"`; `name`: `"onGitPush"`; `eventId`: `string`; \} \| \{ `kind`: `"lifecycle"`; `name`: `"syncRefused"`; `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \}; `grants`: readonly `object`[]; `deadlineAt`: `number`; `ancestry`: readonly [`InstanceId`](index.md#instanceid)[]; \} | `undefined` |
1028
+ | `facts.instanceId` | [`InstanceId`](index.md#instanceid) | `instanceIdSchema` |
1029
+ | `facts.selection` | \{ `instanceId`: [`InstanceId`](index.md#instanceid); `owner`: \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \}; `appId`: `AppId`; `releaseId`: `ReleaseId`; `authorityVersion`: `number`; \} | `selectionSchema` |
1030
+ | `facts.selection.instanceId` | [`InstanceId`](index.md#instanceid) | `instanceIdSchema` |
1031
+ | `facts.selection.owner` | \{ `kind`: `"installation"` \| `"deployment"`; `id`: `string`; \} | `ownerSchema` |
1032
+ | `facts.selection.owner.kind?` | `"installation"` \| `"deployment"` | `...` |
1033
+ | `facts.selection.owner.id?` | `string` | `Schema.NonEmptyString` |
1034
+ | `facts.selection.appId?` | `AppId` | `appIdSchema` |
1035
+ | `facts.selection.releaseId?` | `ReleaseId` | `releaseIdSchema` |
1036
+ | `facts.selection.authorityVersion?` | `number` | `...` |
1037
+ | `facts.artifactDigest?` | `Sha256Digest` | `sha256DigestSchema` |
1038
+ | `facts.subject?` | \| \{ `kind`: `"call"`; `context`: \{ `computerId`: `string` \| `null`; `actor`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; `backgroundLane?`: `string`; `backgroundOrigin?`: \{ `method`: `string`; `seal`: `string`; \}; `role?`: `"member"` \| `"owner"`; `soleMember?`: `true`; `workflow?`: \{ `workflowId`: `string`; `runId`: `string`; `nodeId`: `string`; `armedBy`: \| \{ `kind`: `"member"`; `memberId`: `string`; \} \| \{ `kind`: `"agent"`; `agentId`: `string`; \} \| \{ `kind`: `"team-key"`; `keyId`: `string`; \}; \}; `idempotencyKey?`: `string`; \}; `sessionId?`: `string`; `agentPolicy?`: \{ `policyRevision`: `string`; `grantorMemberId`: `string`; \}; `method?`: \{ `name`: `string`; `effect`: `"read"` \| `"write"` \| `"external"`; \}; `replay?`: \{ `lane`: `string`; `epoch`: `number`; `admitted`: readonly `string`[]; \}; \} \| \{ `kind`: `"lifecycle"`; `name`: `"onGitPush"`; `eventId`: `string`; \} \| \{ `kind`: `"lifecycle"`; `name`: `"syncRefused"`; `lane`: `string`; `code`: `"access_changed"` \| `"installation_unavailable"`; \} | `...` |
1039
+ | `facts.grants?` | readonly `object`[] | `grantsSchema` |
1040
+ | `facts.deadlineAt?` | `number` | `...` |
1041
+ | `facts.ancestry?` | readonly [`InstanceId`](index.md#instanceid)[] | `...` |
1042
+ | `_api?` | `AppApi` | `undefined` |
1043
+ | `name?` | `string` | `undefined` |
1044
+ | `input?` | `Json` | `undefined` |
1045
+ | `limits?` | `Readonly`\<\{ `cpuMs`: `number`; `subRequests`: `number`; \}\> | `undefined` |
1046
+ | `tenantId?` | `string` & `Brand`\<`"OysterTenantId"`\> | `defaultTenant` |
1047
+
1048
+ ###### Returns
1049
+
1050
+ `Promise`\<[`InstanceResult`](host.md#instanceresult)\<`Json`\>\>
1051
+
1052
+ ###### Inherited from
1053
+
1054
+ [`OysterInstance`](workers.md#oysterinstance).[`call`](workers.md#call)
1055
+
1056
+ ## Type Aliases
1057
+
1058
+ ### HostEventSource
1059
+
1060
+ ```ts
1061
+ type HostEventSource = Readonly<{
1062
+ installationId: string;
1063
+ appId: string;
1064
+ releaseId: string;
1065
+ }>;
1066
+ ```
1067
+
1068
+ The emitting installation as the host attested it on the emit's frame.
1069
+
1070
+ ---
1071
+
1072
+ ### HostRecipientEvent
1073
+
1074
+ ```ts
1075
+ type HostRecipientEvent = Readonly<{
1076
+ source: HostEventSource;
1077
+ type: string;
1078
+ eventId: string;
1079
+ payload: Readonly<{
1080
+ type: string;
1081
+ timestamp: string;
1082
+ data: unknown;
1083
+ }>;
1084
+ }>;
1085
+ ```
1086
+
1087
+ One accepted event, as a host recipient receives it.
1088
+
1089
+ ---
1090
+
1091
+ ### RecipientDelivery
1092
+
1093
+ ```ts
1094
+ type RecipientDelivery = Readonly<{
1095
+ recipient: string;
1096
+ eventId: string;
1097
+ type: string;
1098
+ state: "pending" | "delivered" | "failed";
1099
+ attempts: number;
1100
+ lastError: string | null;
1101
+ updatedAt: number;
1102
+ }>;
1103
+ ```
1104
+
1105
+ One recipient's delivery record for one event.
1106
+
1107
+ ---
1108
+
1109
+ ### ArtifactsGit
1110
+
1111
+ ```ts
1112
+ type ArtifactsGit = Omit<GitBinding, "cloneUrl"> &
1113
+ Readonly<{
1114
+ credential: Promise<
1115
+ Readonly<{
1116
+ remote: string;
1117
+ token: string;
1118
+ }>
1119
+ >;
1120
+ }>;
1121
+ ```
1122
+
1123
+ The GIT binding plus the credential only the host's git door may use.
1124
+
1125
+ ---
1126
+
1127
+ ### OysterKeysEnv
1128
+
1129
+ ```ts
1130
+ type OysterKeysEnv = Readonly<Record<never, never>>;
1131
+ ```
1132
+
1133
+ Bindings the keys and webhook objects need: none of their own.
1134
+
1135
+ ---
1136
+
1137
+ ### WebhookSubscription
1138
+
1139
+ ```ts
1140
+ type WebhookSubscription = Readonly<{
1141
+ id: string;
1142
+ installationId: string;
1143
+ url: string;
1144
+ types: readonly string[];
1145
+ createdAt: number;
1146
+ }>;
1147
+ ```
1148
+
1149
+ One webhook subscription for an installation's events.
1150
+
1151
+ ---
1152
+
1153
+ ### SubscriptionCreated
1154
+
1155
+ ```ts
1156
+ type SubscriptionCreated = Readonly<{
1157
+ subscription: WebhookSubscription;
1158
+ secret: string;
1159
+ }>;
1160
+ ```
1161
+
1162
+ A new subscription and its signing secret, shown once.
1163
+
1164
+ ---
1165
+
1166
+ ### WebhookDelivery
1167
+
1168
+ ```ts
1169
+ type WebhookDelivery = Readonly<{
1170
+ id: string;
1171
+ subscription: string;
1172
+ type: string;
1173
+ state: "pending" | "delivered" | "failed";
1174
+ attempts: number;
1175
+ lastStatus: number | null;
1176
+ updatedAt: number;
1177
+ }>;
1178
+ ```
1179
+
1180
+ One delivery attempt record.
1181
+
1182
+ ---
1183
+
1184
+ ### OysterGitEnv
1185
+
1186
+ ```ts
1187
+ type OysterGitEnv = Readonly<{
1188
+ ARTIFACTS?: ArtifactsNamespace;
1189
+ ARTIFACTS_ACCOUNT_ID?: string;
1190
+ ARTIFACTS_NAMESPACE?: string;
1191
+ ARTIFACTS_API_TOKEN?: string;
1192
+ KEYS: DurableObjectNamespace<OysterKeys>;
1193
+ WEBHOOKS: DurableObjectNamespace<OysterWebhooks>;
1194
+ }>;
1195
+ ```
1196
+
1197
+ Bindings the git adapters read from a standalone Oyster Worker.
1198
+
1199
+ ---
1200
+
1201
+ ### OysterKeySummary
1202
+
1203
+ ```ts
1204
+ type OysterKeySummary = Readonly<{
1205
+ keyId: string;
1206
+ name: string;
1207
+ grants: readonly Grant<OysterKeyCapability>[];
1208
+ expiresAt: number | null;
1209
+ createdAt: number;
1210
+ lastUsedAt: number | null;
1211
+ revokedAt: number | null;
1212
+ }>;
1213
+ ```
1214
+
1215
+ One listed or issued key's owner-facing summary; never its secret or owner id.
1216
+
1217
+ ---
1218
+
1219
+ ### OysterGitWorkerEnv
1220
+
1221
+ ```ts
1222
+ type OysterGitWorkerEnv = OysterWorkerEnv &
1223
+ OysterGitEnv &
1224
+ Readonly<{
1225
+ OYSTER_ORIGIN: string;
1226
+ OYSTER_OWNER_NAME?: string;
1227
+ }>;
1228
+ ```
1229
+
1230
+ A standalone Oyster Worker that also hosts git Apps.
1231
+
1232
+ ---
1233
+
1234
+ ### OysterGitWorkerOptions
1235
+
1236
+ ```ts
1237
+ type OysterGitWorkerOptions<Env> = Readonly<{
1238
+ tenancy: (env) => OysterTenancy;
1239
+ homeInstallationId?: (env) => string;
1240
+ pageScript?: string;
1241
+ agents?: (env, scope) => OysterAgents;
1242
+ workspace?: (env, keysLive) => OysterWorkspace;
1243
+ capabilities?: (env, workspace, keysLive) => readonly OysterCapability[];
1244
+ workflowGitPass?: (
1245
+ env,
1246
+ scope,
1247
+ pass,
1248
+ target,
1249
+ ) => Promise<Extract<
1250
+ GitWriter,
1251
+ {
1252
+ kind: "actor";
1253
+ }
1254
+ > | null>;
1255
+ buildGitPass?: (
1256
+ env,
1257
+ scope,
1258
+ pass,
1259
+ target,
1260
+ ) => Promise<Extract<
1261
+ GitWriter,
1262
+ {
1263
+ kind: "actor";
1264
+ }
1265
+ > | null>;
1266
+ ownerRoutes?: (env, scope) => Hono<OysterEnv>;
1267
+ }>;
1268
+ ```
1269
+
1270
+ One deployable Git root's options. Every door (HTTP, MCP, Agents, Workflows,
1271
+ background wakes) composes its tenant host from this one value through
1272
+ `oysterGitRoot(options).hostFor`.
1273
+
1274
+ #### Type Parameters
1275
+
1276
+ | Type Parameter |
1277
+ | ----------------------------------------------------------- |
1278
+ | `Env` _extends_ [`OysterGitWorkerEnv`](#oystergitworkerenv) |
1279
+
1280
+ ---
1281
+
1282
+ ### OysterGitWorkerHost
1283
+
1284
+ ```ts
1285
+ type OysterGitWorkerHost = OysterHost &
1286
+ Readonly<{
1287
+ git: OysterGitHost;
1288
+ }>;
1289
+ ```
1290
+
1291
+ A tenant's whole Git host: the App server, `host.git` and the owner routes.
1292
+
1293
+ ---
1294
+
1295
+ ### OysterKeysLivePort
1296
+
1297
+ ```ts
1298
+ type OysterKeysLivePort = (keyId) => Promise<LiveOysterKey | null>;
1299
+ ```
1300
+
1301
+ `host.keys.live`'s own shape: the live facts behind a key id, re-checked against
1302
+ the tenant's current owner on every read; null for an unknown, revoked, expired,
1303
+ suspended key, or one a since-reassigned tenant's former owner held. The one
1304
+ path every caller -- the HTTP/MCP host, a workspace's own Computer admission --
1305
+ reaches a key's liveness through.
1306
+
1307
+ #### Parameters
1308
+
1309
+ | Parameter | Type |
1310
+ | --------- | -------- |
1311
+ | `keyId` | `string` |
1312
+
1313
+ #### Returns
1314
+
1315
+ `Promise`\<[`LiveOysterKey`](keys.md#liveoysterkey) \| `null`\>
1316
+
1317
+ ---
1318
+
1319
+ ### OysterGitRoot
1320
+
1321
+ ```ts
1322
+ type OysterGitRoot<Env> = Readonly<{
1323
+ admit: Promise<Readonly<{
1324
+ scope: TenantScope;
1325
+ auth: OysterAuth;
1326
+ }> | null>;
1327
+ hostFor: OysterGitWorkerHost;
1328
+ }>;
1329
+ ```
1330
+
1331
+ The one composition root of a Git Worker; build it once from its options.
1332
+
1333
+ #### Type Parameters
1334
+
1335
+ | Type Parameter |
1336
+ | ----------------------------------------------------------- |
1337
+ | `Env` _extends_ [`OysterGitWorkerEnv`](#oystergitworkerenv) |
1338
+
1339
+ ---
1340
+
1341
+ ### OysterWorkerGitOptions
1342
+
1343
+ ```ts
1344
+ type OysterWorkerGitOptions<Env> = Pick<
1345
+ OysterGitWorkerOptions<Env>,
1346
+ "workflowGitPass" | "buildGitPass"
1347
+ > &
1348
+ Readonly<{
1349
+ scope: TenantScope;
1350
+ }>;
1351
+ ```
1352
+
1353
+ What `oysterWorkerGit` needs beyond the Worker's bindings.
1354
+
1355
+ #### Type Parameters
1356
+
1357
+ | Type Parameter |
1358
+ | ----------------------------------------------------------- |
1359
+ | `Env` _extends_ [`OysterGitWorkerEnv`](#oystergitworkerenv) |
1360
+
1361
+ ---
1362
+
1363
+ ### OysterGitFrame
1364
+
1365
+ ```ts
1366
+ type OysterGitFrame = Readonly<{
1367
+ invocation: InvocationFrame<OysterInvocationHost>;
1368
+ store?: ArtifactsGit;
1369
+ }>;
1370
+ ```
1371
+
1372
+ One live guest frame's Git custody; never a guest argument.
1373
+
1374
+ ## Variables
1375
+
1376
+ ### eventsBinding
1377
+
1378
+ ```ts
1379
+ const eventsBinding: OysterBindingRow<OysterGitWorkerEnv>;
1380
+ ```
1381
+
1382
+ EVENTS for a host with webhook subscribers only.
1383
+
1384
+ ---
1385
+
1386
+ ### gitBindings
1387
+
1388
+ ```ts
1389
+ const gitBindings: OysterBindingTable<OysterGitWorkerEnv>;
1390
+ ```
1391
+
1392
+ The plain host's bindings plus native GIT over Artifacts and signed EVENTS.
1393
+
1394
+ ## Functions
1395
+
1396
+ ### createArtifactsGit()
1397
+
1398
+ ```ts
1399
+ function createArtifactsGit(binding, prefix, grant): ArtifactsGit;
1400
+ ```
1401
+
1402
+ The GIT binding over Artifacts for one installation (`prefix` scopes its names).
1403
+ Credentials remain host-held and are reused until thirty seconds before the
1404
+ provider expiry or eight minutes, whichever comes first. Every operation still
1405
+ checks its captured grant. Provider 401/403 discards the credential for remint.
1406
+
1407
+ #### Parameters
1408
+
1409
+ | Parameter | Type |
1410
+ | --------- | --------------------------------------------------------------------------------------- |
1411
+ | `binding` | `ArtifactsNamespace` |
1412
+ | `prefix` | `string` |
1413
+ | `grant` | `Readonly`\<\{ `operations`: readonly `string`[]; `beforeProvider?`: () => `void`; \}\> |
1414
+
1415
+ #### Returns
1416
+
1417
+ [`ArtifactsGit`](#artifactsgit)
1418
+
1419
+ ---
1420
+
1421
+ ### artifactsOf()
1422
+
1423
+ ```ts
1424
+ function artifactsOf(env): ArtifactsNamespace;
1425
+ ```
1426
+
1427
+ The Artifacts namespace: the binding when present, else the REST API.
1428
+
1429
+ #### Parameters
1430
+
1431
+ | Parameter | Type |
1432
+ | --------- | ------------------------------- |
1433
+ | `env` | [`OysterGitEnv`](#oystergitenv) |
1434
+
1435
+ #### Returns
1436
+
1437
+ `ArtifactsNamespace`
1438
+
1439
+ ---
1440
+
1441
+ ### eventsBindingFor()
1442
+
1443
+ ```ts
1444
+ function eventsBindingFor<Env>(recipients): OysterBindingRow<Env>;
1445
+ ```
1446
+
1447
+ EVENTS: commit the emit to this tenant's delivery owner and return. Webhook
1448
+ subscribers and the host recipients a root names are delivered afterwards, so a
1449
+ subscriber outage never fails the emitting App's write.
1450
+
1451
+ #### Type Parameters
1452
+
1453
+ | Type Parameter |
1454
+ | ----------------------------------------------------------- |
1455
+ | `Env` _extends_ [`OysterGitWorkerEnv`](#oystergitworkerenv) |
1456
+
1457
+ #### Parameters
1458
+
1459
+ | Parameter | Type |
1460
+ | ------------ | -------------------------------------------------------- |
1461
+ | `recipients` | (`context`, `frame`) => `Promise`\<readonly `string`[]\> |
1462
+
1463
+ #### Returns
1464
+
1465
+ [`OysterBindingRow`](workers.md#oysterbindingrow)\<`Env`\>
1466
+
1467
+ ---
1468
+
1469
+ ### gitAdminRoutes()
1470
+
1471
+ ```ts
1472
+ function gitAdminRoutes(env, scope): Hono<OysterEnv>;
1473
+ ```
1474
+
1475
+ Owner routes for keys and webhooks; `createOyster` mounts them owner-only.
1476
+
1477
+ #### Parameters
1478
+
1479
+ | Parameter | Type |
1480
+ | --------- | -------------------------------------- |
1481
+ | `env` | [`OysterGitEnv`](#oystergitenv) |
1482
+ | `scope` | [`TenantScope`](tenant.md#tenantscope) |
1483
+
1484
+ #### Returns
1485
+
1486
+ `Hono`\<[`OysterEnv`](host.md#oysterenv)\>
1487
+
1488
+ ---
1489
+
1490
+ ### oysterGitRoot()
1491
+
1492
+ ```ts
1493
+ function oysterGitRoot<Env>(options): OysterGitRoot<Env>;
1494
+ ```
1495
+
1496
+ Compose a Git Worker's root from its one options value.
1497
+
1498
+ #### Type Parameters
1499
+
1500
+ | Type Parameter |
1501
+ | ----------------------------------------------------------- |
1502
+ | `Env` _extends_ [`OysterGitWorkerEnv`](#oystergitworkerenv) |
1503
+
1504
+ #### Parameters
1505
+
1506
+ | Parameter | Type |
1507
+ | --------- | ------------------------------------------------------------ |
1508
+ | `options` | [`OysterGitWorkerOptions`](#oystergitworkeroptions)\<`Env`\> |
1509
+
1510
+ #### Returns
1511
+
1512
+ [`OysterGitRoot`](#oystergitroot)\<`Env`\>
1513
+
1514
+ ---
1515
+
1516
+ ### ownerOrKeyTenancy()
1517
+
1518
+ ```ts
1519
+ function ownerOrKeyTenancy(env): OysterTenancy;
1520
+ ```
1521
+
1522
+ The single-owner root's tenancy: the owner key or a named key, at the configured
1523
+ origin only.
1524
+
1525
+ #### Parameters
1526
+
1527
+ | Parameter | Type |
1528
+ | --------- | ------------------------------------------- |
1529
+ | `env` | [`OysterGitWorkerEnv`](#oystergitworkerenv) |
1530
+
1531
+ #### Returns
1532
+
1533
+ [`OysterTenancy`](tenant.md#oystertenancy)
1534
+
1535
+ ---
1536
+
1537
+ ### createOysterGitWorker()
1538
+
1539
+ ```ts
1540
+ function createOysterGitWorker<Env>(root): ExportedHandler<Env>;
1541
+ ```
1542
+
1543
+ The standalone Worker's `fetch` handler with the git door and owner routes.
1544
+
1545
+ #### Type Parameters
1546
+
1547
+ | Type Parameter |
1548
+ | ----------------------------------------------------------- |
1549
+ | `Env` _extends_ [`OysterGitWorkerEnv`](#oystergitworkerenv) |
1550
+
1551
+ #### Parameters
1552
+
1553
+ | Parameter | Type |
1554
+ | --------- | ------------------------------------------ |
1555
+ | `root` | [`OysterGitRoot`](#oystergitroot)\<`Env`\> |
1556
+
1557
+ #### Returns
1558
+
1559
+ `ExportedHandler`\<`Env`\>
1560
+
1561
+ ---
1562
+
1563
+ ### oysterWorkerGit()
1564
+
1565
+ ```ts
1566
+ function oysterWorkerGit<Env>(env, options, frame?): OysterGitHost;
1567
+ ```
1568
+
1569
+ `host.git` for an Oyster Worker: the git door's writer projection and the
1570
+ admitted, installation-scoped Artifacts path with the App's push policy and the
1571
+ Instance journal. Set it on your own `createOyster` host; the full standalone
1572
+ composition (`oysterGitWorkerHost`) uses this same builder.
1573
+
1574
+ #### Type Parameters
1575
+
1576
+ | Type Parameter |
1577
+ | ----------------------------------------------------------- |
1578
+ | `Env` _extends_ [`OysterGitWorkerEnv`](#oystergitworkerenv) |
1579
+
1580
+ #### Parameters
1581
+
1582
+ | Parameter | Type |
1583
+ | --------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
1584
+ | `env` | `Env` |
1585
+ | `options` | [`OysterWorkerGitOptions`](#oysterworkergitoptions)\<`Env`\> |
1586
+ | `frame?` | `Readonly`\<\{ `invocation`: [`InvocationFrame`](invocation.md#invocationframe)\<[`OysterInvocationHost`](workers.md#oysterinvocationhost)\>; `store?`: [`ArtifactsGit`](#artifactsgit); \}\> |
1587
+
1588
+ #### Returns
1589
+
1590
+ [`OysterGitHost`](host.md#oystergithost)
1591
+
1592
+ ---
1593
+
1594
+ ### oysterGitWorkerHost()
1595
+
1596
+ ```ts
1597
+ function oysterGitWorkerHost<Env>(env, options, selected): OysterGitWorkerHost;
1598
+ ```
1599
+
1600
+ One selected tenant's whole host from a root's options. Roots reach it through
1601
+ `oysterGitRoot(options).hostFor`; a cold directory passes its own resolved
1602
+ tenant.
1603
+
1604
+ #### Type Parameters
1605
+
1606
+ | Type Parameter |
1607
+ | ----------------------------------------------------------- |
1608
+ | `Env` _extends_ [`OysterGitWorkerEnv`](#oystergitworkerenv) |
1609
+
1610
+ #### Parameters
1611
+
1612
+ | Parameter | Type |
1613
+ | ---------- | ------------------------------------------------------------ |
1614
+ | `env` | `Env` |
1615
+ | `options` | [`OysterGitWorkerOptions`](#oystergitworkeroptions)\<`Env`\> |
1616
+ | `selected` | [`ResolvedTenant`](tenant.md#resolvedtenant) |
1617
+
1618
+ #### Returns
1619
+
1620
+ [`OysterGitWorkerHost`](#oystergitworkerhost)
1621
+
1622
+ ---
1623
+
1624
+ ### createOysterGitMcpOwner()
1625
+
1626
+ ```ts
1627
+ function createOysterGitMcpOwner<Env>(root): (ctx, env) => OysterMcpOwner<Env>;
1628
+ ```
1629
+
1630
+ Deploy the MCP owner from the same root as createOysterGitWorker.
1631
+
1632
+ #### Type Parameters
1633
+
1634
+ | Type Parameter |
1635
+ | ----------------------------------------------------------- |
1636
+ | `Env` _extends_ [`OysterGitWorkerEnv`](#oystergitworkerenv) |
1637
+
1638
+ #### Parameters
1639
+
1640
+ | Parameter | Type |
1641
+ | --------- | ------------------------------------------ |
1642
+ | `root` | [`OysterGitRoot`](#oystergitroot)\<`Env`\> |
1643
+
1644
+ #### Returns
1645
+
1646
+ (`ctx`, `env`) => [`OysterMcpOwner`](workers.md#oystermcpowner)\<`Env`\>