@sixb/core 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1582) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +470 -0
  3. package/dist/actions/builders/define-action.d.ts +7 -0
  4. package/dist/actions/builders/define-action.d.ts.map +1 -0
  5. package/dist/actions/builders/params.d.ts +23 -0
  6. package/dist/actions/builders/params.d.ts.map +1 -0
  7. package/dist/actions/builders.d.ts +3 -0
  8. package/dist/actions/builders.d.ts.map +1 -0
  9. package/dist/actions/commit-edits.d.ts +54 -0
  10. package/dist/actions/commit-edits.d.ts.map +1 -0
  11. package/dist/actions/errors.d.ts +9 -0
  12. package/dist/actions/errors.d.ts.map +1 -0
  13. package/dist/actions/index.d.ts +14 -0
  14. package/dist/actions/index.d.ts.map +1 -0
  15. package/dist/actions/index.js +73 -0
  16. package/dist/actions/index.js.map +9 -0
  17. package/dist/actions/read-facade.d.ts +56 -0
  18. package/dist/actions/read-facade.d.ts.map +1 -0
  19. package/dist/actions/registry.d.ts +17 -0
  20. package/dist/actions/registry.d.ts.map +1 -0
  21. package/dist/actions/request.d.ts +37 -0
  22. package/dist/actions/request.d.ts.map +1 -0
  23. package/dist/actions/run-id.d.ts +3 -0
  24. package/dist/actions/run-id.d.ts.map +1 -0
  25. package/dist/actions/runtime.d.ts +11 -0
  26. package/dist/actions/runtime.d.ts.map +1 -0
  27. package/dist/actions/types/context.d.ts +147 -0
  28. package/dist/actions/types/context.d.ts.map +1 -0
  29. package/dist/actions/types/definitions.d.ts +67 -0
  30. package/dist/actions/types/definitions.d.ts.map +1 -0
  31. package/dist/actions/types/handlers.d.ts +19 -0
  32. package/dist/actions/types/handlers.d.ts.map +1 -0
  33. package/dist/actions/types/params.d.ts +45 -0
  34. package/dist/actions/types/params.d.ts.map +1 -0
  35. package/dist/actions/types.d.ts +5 -0
  36. package/dist/actions/types.d.ts.map +1 -0
  37. package/dist/actions/validation.d.ts +33 -0
  38. package/dist/actions/validation.d.ts.map +1 -0
  39. package/dist/actions/validators.d.ts +8 -0
  40. package/dist/actions/validators.d.ts.map +1 -0
  41. package/dist/actions/worker.d.ts +3 -0
  42. package/dist/actions/worker.d.ts.map +1 -0
  43. package/dist/actions/worker.js +324 -0
  44. package/dist/actions/worker.js.map +11 -0
  45. package/dist/agents/adapters.d.ts +185 -0
  46. package/dist/agents/adapters.d.ts.map +1 -0
  47. package/dist/agents/api-gateway.d.ts +21 -0
  48. package/dist/agents/api-gateway.d.ts.map +1 -0
  49. package/dist/agents/builders.d.ts +10 -0
  50. package/dist/agents/builders.d.ts.map +1 -0
  51. package/dist/agents/context-model.d.ts +4 -0
  52. package/dist/agents/context-model.d.ts.map +1 -0
  53. package/dist/agents/context-resolution.d.ts +5 -0
  54. package/dist/agents/context-resolution.d.ts.map +1 -0
  55. package/dist/agents/context.d.ts +57 -0
  56. package/dist/agents/context.d.ts.map +1 -0
  57. package/dist/agents/context.js +23 -0
  58. package/dist/agents/context.js.map +9 -0
  59. package/dist/agents/dispatch.d.ts +36 -0
  60. package/dist/agents/dispatch.d.ts.map +1 -0
  61. package/dist/agents/errors.d.ts +27 -0
  62. package/dist/agents/errors.d.ts.map +1 -0
  63. package/dist/agents/ids.d.ts +11 -0
  64. package/dist/agents/ids.d.ts.map +1 -0
  65. package/dist/agents/index.d.ts +24 -0
  66. package/dist/agents/index.d.ts.map +1 -0
  67. package/dist/agents/index.js +121 -0
  68. package/dist/agents/index.js.map +9 -0
  69. package/dist/agents/message.d.ts +78 -0
  70. package/dist/agents/message.d.ts.map +1 -0
  71. package/dist/agents/prompt.d.ts +15 -0
  72. package/dist/agents/prompt.d.ts.map +1 -0
  73. package/dist/agents/request.d.ts +42 -0
  74. package/dist/agents/request.d.ts.map +1 -0
  75. package/dist/agents/runtime.d.ts +41 -0
  76. package/dist/agents/runtime.d.ts.map +1 -0
  77. package/dist/agents/streams.d.ts +72 -0
  78. package/dist/agents/streams.d.ts.map +1 -0
  79. package/dist/agents/streams.js +32 -0
  80. package/dist/agents/streams.js.map +9 -0
  81. package/dist/agents/types.d.ts +52 -0
  82. package/dist/agents/types.d.ts.map +1 -0
  83. package/dist/agents/validation.d.ts +10 -0
  84. package/dist/agents/validation.d.ts.map +1 -0
  85. package/dist/auth/access-tokens.d.ts +19 -0
  86. package/dist/auth/access-tokens.d.ts.map +1 -0
  87. package/dist/auth/audience.d.ts +8 -0
  88. package/dist/auth/audience.d.ts.map +1 -0
  89. package/dist/auth/cookies.d.ts +50 -0
  90. package/dist/auth/cookies.d.ts.map +1 -0
  91. package/dist/auth/csrf.d.ts +8 -0
  92. package/dist/auth/csrf.d.ts.map +1 -0
  93. package/dist/auth/errors.d.ts +7 -0
  94. package/dist/auth/errors.d.ts.map +1 -0
  95. package/dist/auth/index.d.ts +15 -0
  96. package/dist/auth/index.d.ts.map +1 -0
  97. package/dist/auth/index.js +101 -0
  98. package/dist/auth/index.js.map +9 -0
  99. package/dist/auth/runtime.d.ts +129 -0
  100. package/dist/auth/runtime.d.ts.map +1 -0
  101. package/dist/auth/session-cache.d.ts +44 -0
  102. package/dist/auth/session-cache.d.ts.map +1 -0
  103. package/dist/auth/sessions.d.ts +16 -0
  104. package/dist/auth/sessions.d.ts.map +1 -0
  105. package/dist/auth/strategy.d.ts +11 -0
  106. package/dist/auth/strategy.d.ts.map +1 -0
  107. package/dist/auth/strategy.js +14 -0
  108. package/dist/auth/strategy.js.map +9 -0
  109. package/dist/auth/types.d.ts +460 -0
  110. package/dist/auth/types.d.ts.map +1 -0
  111. package/dist/auth/validation.d.ts +26 -0
  112. package/dist/auth/validation.d.ts.map +1 -0
  113. package/dist/authorization/application-access.d.ts +18 -0
  114. package/dist/authorization/application-access.d.ts.map +1 -0
  115. package/dist/authorization/decision.d.ts +104 -0
  116. package/dist/authorization/decision.d.ts.map +1 -0
  117. package/dist/authorization/errors.d.ts +10 -0
  118. package/dist/authorization/errors.d.ts.map +1 -0
  119. package/dist/authorization/event-visibility.d.ts +16 -0
  120. package/dist/authorization/event-visibility.d.ts.map +1 -0
  121. package/dist/authorization/grant-kinds.d.ts +48 -0
  122. package/dist/authorization/grant-kinds.d.ts.map +1 -0
  123. package/dist/authorization/index.d.ts +11 -0
  124. package/dist/authorization/index.d.ts.map +1 -0
  125. package/dist/authorization/index.js +48 -0
  126. package/dist/authorization/index.js.map +9 -0
  127. package/dist/authorization/resolve.d.ts +28 -0
  128. package/dist/authorization/resolve.d.ts.map +1 -0
  129. package/dist/authorization/run-visibility.d.ts +15 -0
  130. package/dist/authorization/run-visibility.d.ts.map +1 -0
  131. package/dist/authorization/types.d.ts +46 -0
  132. package/dist/authorization/types.d.ts.map +1 -0
  133. package/dist/blob-storage/browser.d.ts +14 -0
  134. package/dist/blob-storage/browser.d.ts.map +1 -0
  135. package/dist/blob-storage/browser.js +22 -0
  136. package/dist/blob-storage/browser.js.map +9 -0
  137. package/dist/blob-storage/constants.d.ts +10 -0
  138. package/dist/blob-storage/constants.d.ts.map +1 -0
  139. package/dist/blob-storage/derive.d.ts +4 -0
  140. package/dist/blob-storage/derive.d.ts.map +1 -0
  141. package/dist/blob-storage/errors.d.ts +7 -0
  142. package/dist/blob-storage/errors.d.ts.map +1 -0
  143. package/dist/blob-storage/in-memory.d.ts +10 -0
  144. package/dist/blob-storage/in-memory.d.ts.map +1 -0
  145. package/dist/blob-storage/index.d.ts +8 -0
  146. package/dist/blob-storage/index.d.ts.map +1 -0
  147. package/dist/blob-storage/index.js +44 -0
  148. package/dist/blob-storage/index.js.map +9 -0
  149. package/dist/blob-storage/types.d.ts +126 -0
  150. package/dist/blob-storage/types.d.ts.map +1 -0
  151. package/dist/blob-storage/utils.d.ts +9 -0
  152. package/dist/blob-storage/utils.d.ts.map +1 -0
  153. package/dist/blob-storage/validation.d.ts +6 -0
  154. package/dist/blob-storage/validation.d.ts.map +1 -0
  155. package/dist/bootstrap/discovery.d.ts +34 -0
  156. package/dist/bootstrap/discovery.d.ts.map +1 -0
  157. package/dist/bootstrap/index.d.ts +4 -0
  158. package/dist/bootstrap/index.d.ts.map +1 -0
  159. package/dist/bootstrap/index.js +80 -0
  160. package/dist/bootstrap/index.js.map +9 -0
  161. package/dist/bootstrap/ontology-type-manifest.d.ts +22 -0
  162. package/dist/bootstrap/ontology-type-manifest.d.ts.map +1 -0
  163. package/dist/broker/errors.d.ts +12 -0
  164. package/dist/broker/errors.d.ts.map +1 -0
  165. package/dist/broker/in-memory.d.ts +53 -0
  166. package/dist/broker/in-memory.d.ts.map +1 -0
  167. package/dist/broker/index.d.ts +5 -0
  168. package/dist/broker/index.d.ts.map +1 -0
  169. package/dist/broker/index.js +15 -0
  170. package/dist/broker/index.js.map +9 -0
  171. package/dist/broker/types.d.ts +119 -0
  172. package/dist/broker/types.d.ts.map +1 -0
  173. package/dist/chunk-04b07a9q.js +89 -0
  174. package/dist/chunk-04b07a9q.js.map +10 -0
  175. package/dist/chunk-0fygrz37.js +354 -0
  176. package/dist/chunk-0fygrz37.js.map +17 -0
  177. package/dist/chunk-0psb6kdw.js +989 -0
  178. package/dist/chunk-0psb6kdw.js.map +15 -0
  179. package/dist/chunk-1evzqhks.js +76 -0
  180. package/dist/chunk-1evzqhks.js.map +10 -0
  181. package/dist/chunk-1vffvydj.js +109 -0
  182. package/dist/chunk-1vffvydj.js.map +10 -0
  183. package/dist/chunk-2ab72m2h.js +59 -0
  184. package/dist/chunk-2ab72m2h.js.map +10 -0
  185. package/dist/chunk-2gpr6jsz.js +1968 -0
  186. package/dist/chunk-2gpr6jsz.js.map +13 -0
  187. package/dist/chunk-2s6sydsh.js +368 -0
  188. package/dist/chunk-2s6sydsh.js.map +12 -0
  189. package/dist/chunk-45tw90k7.js +72 -0
  190. package/dist/chunk-45tw90k7.js.map +11 -0
  191. package/dist/chunk-4pycxcj3.js +35 -0
  192. package/dist/chunk-4pycxcj3.js.map +11 -0
  193. package/dist/chunk-50kv63vj.js +523 -0
  194. package/dist/chunk-50kv63vj.js.map +12 -0
  195. package/dist/chunk-51fjndv0.js +17 -0
  196. package/dist/chunk-51fjndv0.js.map +11 -0
  197. package/dist/chunk-590dejbp.js +49 -0
  198. package/dist/chunk-590dejbp.js.map +10 -0
  199. package/dist/chunk-5yny9z0e.js +60 -0
  200. package/dist/chunk-5yny9z0e.js.map +10 -0
  201. package/dist/chunk-6wetht33.js +89 -0
  202. package/dist/chunk-6wetht33.js.map +10 -0
  203. package/dist/chunk-74drx9gd.js +362 -0
  204. package/dist/chunk-74drx9gd.js.map +11 -0
  205. package/dist/chunk-867jxh7c.js +1156 -0
  206. package/dist/chunk-867jxh7c.js.map +19 -0
  207. package/dist/chunk-88ppkr54.js +257 -0
  208. package/dist/chunk-88ppkr54.js.map +12 -0
  209. package/dist/chunk-8r8cw2xw.js +373 -0
  210. package/dist/chunk-8r8cw2xw.js.map +11 -0
  211. package/dist/chunk-8ydjhh27.js +95 -0
  212. package/dist/chunk-8ydjhh27.js.map +11 -0
  213. package/dist/chunk-9dzba0f2.js +43 -0
  214. package/dist/chunk-9dzba0f2.js.map +10 -0
  215. package/dist/chunk-aebzcsxr.js +5272 -0
  216. package/dist/chunk-aebzcsxr.js.map +48 -0
  217. package/dist/chunk-b49dgvsj.js +49 -0
  218. package/dist/chunk-b49dgvsj.js.map +10 -0
  219. package/dist/chunk-btpe64e4.js +554 -0
  220. package/dist/chunk-btpe64e4.js.map +13 -0
  221. package/dist/chunk-c3zd880g.js +629 -0
  222. package/dist/chunk-c3zd880g.js.map +14 -0
  223. package/dist/chunk-dcgrzj1t.js +2954 -0
  224. package/dist/chunk-dcgrzj1t.js.map +36 -0
  225. package/dist/chunk-dhmj53mx.js +501 -0
  226. package/dist/chunk-dhmj53mx.js.map +16 -0
  227. package/dist/chunk-dktq02ne.js +16 -0
  228. package/dist/chunk-dktq02ne.js.map +10 -0
  229. package/dist/chunk-f2b5e2gf.js +141 -0
  230. package/dist/chunk-f2b5e2gf.js.map +11 -0
  231. package/dist/chunk-gqdd7508.js +273 -0
  232. package/dist/chunk-gqdd7508.js.map +11 -0
  233. package/dist/chunk-hsv43v58.js +1390 -0
  234. package/dist/chunk-hsv43v58.js.map +21 -0
  235. package/dist/chunk-jdwx7vzs.js +454 -0
  236. package/dist/chunk-jdwx7vzs.js.map +14 -0
  237. package/dist/chunk-k25jm1x5.js +102 -0
  238. package/dist/chunk-k25jm1x5.js.map +10 -0
  239. package/dist/chunk-k41ajtz7.js +352 -0
  240. package/dist/chunk-k41ajtz7.js.map +13 -0
  241. package/dist/chunk-k6j72mtt.js +9 -0
  242. package/dist/chunk-k6j72mtt.js.map +10 -0
  243. package/dist/chunk-mx84y05q.js +426 -0
  244. package/dist/chunk-mx84y05q.js.map +11 -0
  245. package/dist/chunk-nvamz5dv.js +819 -0
  246. package/dist/chunk-nvamz5dv.js.map +21 -0
  247. package/dist/chunk-p6r5g77m.js +113 -0
  248. package/dist/chunk-p6r5g77m.js.map +10 -0
  249. package/dist/chunk-pv1yad91.js +1165 -0
  250. package/dist/chunk-pv1yad91.js.map +27 -0
  251. package/dist/chunk-q4qzq0ea.js +832 -0
  252. package/dist/chunk-q4qzq0ea.js.map +14 -0
  253. package/dist/chunk-r65yscvk.js +187 -0
  254. package/dist/chunk-r65yscvk.js.map +11 -0
  255. package/dist/chunk-ry24jbr1.js +50 -0
  256. package/dist/chunk-ry24jbr1.js.map +10 -0
  257. package/dist/chunk-t358gywy.js +991 -0
  258. package/dist/chunk-t358gywy.js.map +34 -0
  259. package/dist/chunk-t72dvahb.js +167 -0
  260. package/dist/chunk-t72dvahb.js.map +12 -0
  261. package/dist/chunk-tsk2bxs3.js +1254 -0
  262. package/dist/chunk-tsk2bxs3.js.map +17 -0
  263. package/dist/chunk-v5c085yp.js +49 -0
  264. package/dist/chunk-v5c085yp.js.map +10 -0
  265. package/dist/chunk-vj723r3p.js +146 -0
  266. package/dist/chunk-vj723r3p.js.map +12 -0
  267. package/dist/chunk-wj01s5hr.js +363 -0
  268. package/dist/chunk-wj01s5hr.js.map +11 -0
  269. package/dist/chunk-wxhdnwh4.js +37 -0
  270. package/dist/chunk-wxhdnwh4.js.map +10 -0
  271. package/dist/chunk-xqbtf4wn.js +170 -0
  272. package/dist/chunk-xqbtf4wn.js.map +10 -0
  273. package/dist/chunk-xwnf87e1.js +324 -0
  274. package/dist/chunk-xwnf87e1.js.map +13 -0
  275. package/dist/chunk-xz5g49bp.js +239 -0
  276. package/dist/chunk-xz5g49bp.js.map +11 -0
  277. package/dist/chunk-y64skrwp.js +19 -0
  278. package/dist/chunk-y64skrwp.js.map +9 -0
  279. package/dist/chunk-ya6brh8a.js +136 -0
  280. package/dist/chunk-ya6brh8a.js.map +11 -0
  281. package/dist/chunk-yt8wphsx.js +12 -0
  282. package/dist/chunk-yt8wphsx.js.map +10 -0
  283. package/dist/chunk-yvef9xwc.js +3842 -0
  284. package/dist/chunk-yvef9xwc.js.map +44 -0
  285. package/dist/chunk-yxss87qa.js +821 -0
  286. package/dist/chunk-yxss87qa.js.map +14 -0
  287. package/dist/connectors/builders.d.ts +10 -0
  288. package/dist/connectors/builders.d.ts.map +1 -0
  289. package/dist/connectors/errors.d.ts +14 -0
  290. package/dist/connectors/errors.d.ts.map +1 -0
  291. package/dist/connectors/index.d.ts +5 -0
  292. package/dist/connectors/index.d.ts.map +1 -0
  293. package/dist/connectors/runtime.d.ts +13 -0
  294. package/dist/connectors/runtime.d.ts.map +1 -0
  295. package/dist/connectors/types.d.ts +39 -0
  296. package/dist/connectors/types.d.ts.map +1 -0
  297. package/dist/datasets/builders.d.ts +54 -0
  298. package/dist/datasets/builders.d.ts.map +1 -0
  299. package/dist/datasets/errors.d.ts +4 -0
  300. package/dist/datasets/errors.d.ts.map +1 -0
  301. package/dist/datasets/index.d.ts +5 -0
  302. package/dist/datasets/index.d.ts.map +1 -0
  303. package/dist/datasets/types.d.ts +23 -0
  304. package/dist/datasets/types.d.ts.map +1 -0
  305. package/dist/datasets/validation.d.ts +8 -0
  306. package/dist/datasets/validation.d.ts.map +1 -0
  307. package/dist/edits/errors.d.ts +4 -0
  308. package/dist/edits/errors.d.ts.map +1 -0
  309. package/dist/edits/index.d.ts +4 -0
  310. package/dist/edits/index.d.ts.map +1 -0
  311. package/dist/edits/index.js +14 -0
  312. package/dist/edits/index.js.map +9 -0
  313. package/dist/edits/normalize.d.ts +14 -0
  314. package/dist/edits/normalize.d.ts.map +1 -0
  315. package/dist/edits/properties.d.ts +25 -0
  316. package/dist/edits/properties.d.ts.map +1 -0
  317. package/dist/edits/recorder.d.ts +4 -0
  318. package/dist/edits/recorder.d.ts.map +1 -0
  319. package/dist/edits/types.d.ts +159 -0
  320. package/dist/edits/types.d.ts.map +1 -0
  321. package/dist/error-reporting/capability.d.ts +57 -0
  322. package/dist/error-reporting/capability.d.ts.map +1 -0
  323. package/dist/error-reporting/internal.d.ts +4 -0
  324. package/dist/error-reporting/internal.d.ts.map +1 -0
  325. package/dist/error-reporting/internal.js +24 -0
  326. package/dist/error-reporting/internal.js.map +9 -0
  327. package/dist/error-reporting/normalize.d.ts +3 -0
  328. package/dist/error-reporting/normalize.d.ts.map +1 -0
  329. package/dist/error-reporting/reporter.d.ts +10 -0
  330. package/dist/error-reporting/reporter.d.ts.map +1 -0
  331. package/dist/error-reporting/types.d.ts +112 -0
  332. package/dist/error-reporting/types.d.ts.map +1 -0
  333. package/dist/events/definitions.d.ts +76 -0
  334. package/dist/events/definitions.d.ts.map +1 -0
  335. package/dist/events/envelope.d.ts +56 -0
  336. package/dist/events/envelope.d.ts.map +1 -0
  337. package/dist/events/errors.d.ts +8 -0
  338. package/dist/events/errors.d.ts.map +1 -0
  339. package/dist/events/index.d.ts +11 -0
  340. package/dist/events/index.d.ts.map +1 -0
  341. package/dist/events/index.js +68 -0
  342. package/dist/events/index.js.map +9 -0
  343. package/dist/events/outbox-dispatcher.d.ts +82 -0
  344. package/dist/events/outbox-dispatcher.d.ts.map +1 -0
  345. package/dist/events/property-changes.d.ts +16 -0
  346. package/dist/events/property-changes.d.ts.map +1 -0
  347. package/dist/events/runtime.d.ts +87 -0
  348. package/dist/events/runtime.d.ts.map +1 -0
  349. package/dist/events/scope.d.ts +25 -0
  350. package/dist/events/scope.d.ts.map +1 -0
  351. package/dist/events/scope.js +10 -0
  352. package/dist/events/scope.js.map +9 -0
  353. package/dist/events/selectors/builder.d.ts +64 -0
  354. package/dist/events/selectors/builder.d.ts.map +1 -0
  355. package/dist/events/selectors/index.d.ts +5 -0
  356. package/dist/events/selectors/index.d.ts.map +1 -0
  357. package/dist/events/selectors/index.js +15 -0
  358. package/dist/events/selectors/index.js.map +9 -0
  359. package/dist/events/selectors/predicate.d.ts +5 -0
  360. package/dist/events/selectors/predicate.d.ts.map +1 -0
  361. package/dist/events/selectors/types.d.ts +141 -0
  362. package/dist/events/selectors/types.d.ts.map +1 -0
  363. package/dist/events/toStoredEvent.d.ts +10 -0
  364. package/dist/events/toStoredEvent.d.ts.map +1 -0
  365. package/dist/events/types/actions.d.ts +39 -0
  366. package/dist/events/types/actions.d.ts.map +1 -0
  367. package/dist/events/types/datasets.d.ts +20 -0
  368. package/dist/events/types/datasets.d.ts.map +1 -0
  369. package/dist/events/types/index.d.ts +137 -0
  370. package/dist/events/types/index.d.ts.map +1 -0
  371. package/dist/events/types/links.d.ts +37 -0
  372. package/dist/events/types/links.d.ts.map +1 -0
  373. package/dist/events/types/objects.d.ts +33 -0
  374. package/dist/events/types/objects.d.ts.map +1 -0
  375. package/dist/events/types/pipelines.d.ts +59 -0
  376. package/dist/events/types/pipelines.d.ts.map +1 -0
  377. package/dist/events/types/rules.d.ts +28 -0
  378. package/dist/events/types/rules.d.ts.map +1 -0
  379. package/dist/events/types/schedules.d.ts +14 -0
  380. package/dist/events/types/schedules.d.ts.map +1 -0
  381. package/dist/events/types/syncs.d.ts +25 -0
  382. package/dist/events/types/syncs.d.ts.map +1 -0
  383. package/dist/events/types/telemetry.d.ts +17 -0
  384. package/dist/events/types/telemetry.d.ts.map +1 -0
  385. package/dist/events/types/workflows.d.ts +150 -0
  386. package/dist/events/types/workflows.d.ts.map +1 -0
  387. package/dist/http/api-routes.d.ts +24 -0
  388. package/dist/http/api-routes.d.ts.map +1 -0
  389. package/dist/http/index.d.ts +4 -0
  390. package/dist/http/index.d.ts.map +1 -0
  391. package/dist/http/index.js +16 -0
  392. package/dist/http/index.js.map +9 -0
  393. package/dist/http/route-pattern.d.ts +14 -0
  394. package/dist/http/route-pattern.d.ts.map +1 -0
  395. package/dist/index.d.ts +70 -0
  396. package/dist/index.d.ts.map +1 -0
  397. package/dist/index.js +430 -0
  398. package/dist/index.js.map +9 -0
  399. package/dist/json.d.ts +14 -0
  400. package/dist/json.d.ts.map +1 -0
  401. package/dist/lake-storage/definition-updates.d.ts +40 -0
  402. package/dist/lake-storage/definition-updates.d.ts.map +1 -0
  403. package/dist/lake-storage/errors.d.ts +7 -0
  404. package/dist/lake-storage/errors.d.ts.map +1 -0
  405. package/dist/lake-storage/in-memory.d.ts +25 -0
  406. package/dist/lake-storage/in-memory.d.ts.map +1 -0
  407. package/dist/lake-storage/index.d.ts +9 -0
  408. package/dist/lake-storage/index.d.ts.map +1 -0
  409. package/dist/lake-storage/index.js +24 -0
  410. package/dist/lake-storage/index.js.map +9 -0
  411. package/dist/lake-storage/sql-transforms.d.ts +45 -0
  412. package/dist/lake-storage/sql-transforms.d.ts.map +1 -0
  413. package/dist/lake-storage/types.d.ts +114 -0
  414. package/dist/lake-storage/types.d.ts.map +1 -0
  415. package/dist/logging/console-logger.d.ts +17 -0
  416. package/dist/logging/console-logger.d.ts.map +1 -0
  417. package/dist/logging/index.d.ts +5 -0
  418. package/dist/logging/index.d.ts.map +1 -0
  419. package/dist/logging/index.js +45 -0
  420. package/dist/logging/index.js.map +9 -0
  421. package/dist/logging/record.d.ts +10 -0
  422. package/dist/logging/record.d.ts.map +1 -0
  423. package/dist/logging/run-logger.d.ts +61 -0
  424. package/dist/logging/run-logger.d.ts.map +1 -0
  425. package/dist/logging/runtime.d.ts +87 -0
  426. package/dist/logging/runtime.d.ts.map +1 -0
  427. package/dist/logging/stream.d.ts +24 -0
  428. package/dist/logging/stream.d.ts.map +1 -0
  429. package/dist/logging/types.d.ts +82 -0
  430. package/dist/logging/types.d.ts.map +1 -0
  431. package/dist/logging/types.js +27 -0
  432. package/dist/logging/types.js.map +9 -0
  433. package/dist/maintenance/index.d.ts +3 -0
  434. package/dist/maintenance/index.d.ts.map +1 -0
  435. package/dist/maintenance/ontology-maintenance.d.ts +48 -0
  436. package/dist/maintenance/ontology-maintenance.d.ts.map +1 -0
  437. package/dist/maintenance/types.d.ts +53 -0
  438. package/dist/maintenance/types.d.ts.map +1 -0
  439. package/dist/materialization/dataset-watermark.d.ts +5 -0
  440. package/dist/materialization/dataset-watermark.d.ts.map +1 -0
  441. package/dist/materialization/errors.d.ts +37 -0
  442. package/dist/materialization/errors.d.ts.map +1 -0
  443. package/dist/materialization/events.d.ts +57 -0
  444. package/dist/materialization/events.d.ts.map +1 -0
  445. package/dist/materialization/identity.d.ts +8 -0
  446. package/dist/materialization/identity.d.ts.map +1 -0
  447. package/dist/materialization/index.d.ts +13 -0
  448. package/dist/materialization/index.d.ts.map +1 -0
  449. package/dist/materialization/index.js +56 -0
  450. package/dist/materialization/index.js.map +9 -0
  451. package/dist/materialization/model.d.ts +342 -0
  452. package/dist/materialization/model.d.ts.map +1 -0
  453. package/dist/materialization/refs.d.ts +24 -0
  454. package/dist/materialization/refs.d.ts.map +1 -0
  455. package/dist/materializer/context.d.ts +34 -0
  456. package/dist/materializer/context.d.ts.map +1 -0
  457. package/dist/materializer/edits/apply.d.ts +35 -0
  458. package/dist/materializer/edits/apply.d.ts.map +1 -0
  459. package/dist/materializer/edits/commit.d.ts +4 -0
  460. package/dist/materializer/edits/commit.d.ts.map +1 -0
  461. package/dist/materializer/edits/execution-units.d.ts +14 -0
  462. package/dist/materializer/edits/execution-units.d.ts.map +1 -0
  463. package/dist/materializer/edits/load-state.d.ts +6 -0
  464. package/dist/materializer/edits/load-state.d.ts.map +1 -0
  465. package/dist/materializer/edits/operations.d.ts +32 -0
  466. package/dist/materializer/edits/operations.d.ts.map +1 -0
  467. package/dist/materializer/edits/plan.d.ts +18 -0
  468. package/dist/materializer/edits/plan.d.ts.map +1 -0
  469. package/dist/materializer/edits/read-set.d.ts +8 -0
  470. package/dist/materializer/edits/read-set.d.ts.map +1 -0
  471. package/dist/materializer/edits/working-state.d.ts +30 -0
  472. package/dist/materializer/edits/working-state.d.ts.map +1 -0
  473. package/dist/materializer/effective/build-events.d.ts +26 -0
  474. package/dist/materializer/effective/build-events.d.ts.map +1 -0
  475. package/dist/materializer/effective/diff.d.ts +15 -0
  476. package/dist/materializer/effective/diff.d.ts.map +1 -0
  477. package/dist/materializer/effective/load-state.d.ts +7 -0
  478. package/dist/materializer/effective/load-state.d.ts.map +1 -0
  479. package/dist/materializer/effective/resolve.d.ts +26 -0
  480. package/dist/materializer/effective/resolve.d.ts.map +1 -0
  481. package/dist/materializer/effective/validate.d.ts +11 -0
  482. package/dist/materializer/effective/validate.d.ts.map +1 -0
  483. package/dist/materializer/execution/commit-lifecycle.d.ts +8 -0
  484. package/dist/materializer/execution/commit-lifecycle.d.ts.map +1 -0
  485. package/dist/materializer/execution/plan-stream.d.ts +8 -0
  486. package/dist/materializer/execution/plan-stream.d.ts.map +1 -0
  487. package/dist/materializer/execution/run-correlation.d.ts +19 -0
  488. package/dist/materializer/execution/run-correlation.d.ts.map +1 -0
  489. package/dist/materializer/execution/work-executor.d.ts +13 -0
  490. package/dist/materializer/execution/work-executor.d.ts.map +1 -0
  491. package/dist/materializer/execution/work-records.d.ts +15 -0
  492. package/dist/materializer/execution/work-records.d.ts.map +1 -0
  493. package/dist/materializer/index.d.ts +15 -0
  494. package/dist/materializer/index.d.ts.map +1 -0
  495. package/dist/materializer/index.js +134 -0
  496. package/dist/materializer/index.js.map +9 -0
  497. package/dist/materializer/materializer.d.ts +27 -0
  498. package/dist/materializer/materializer.d.ts.map +1 -0
  499. package/dist/materializer/projections/entry-validator.d.ts +8 -0
  500. package/dist/materializer/projections/entry-validator.d.ts.map +1 -0
  501. package/dist/materializer/projections/finish-run.d.ts +4 -0
  502. package/dist/materializer/projections/finish-run.d.ts.map +1 -0
  503. package/dist/materializer/projections/replace.d.ts +4 -0
  504. package/dist/materializer/projections/replace.d.ts.map +1 -0
  505. package/dist/materializer/projections/replacement-plan.d.ts +14 -0
  506. package/dist/materializer/projections/replacement-plan.d.ts.map +1 -0
  507. package/dist/materializer/projections/source-materialization.d.ts +27 -0
  508. package/dist/materializer/projections/source-materialization.d.ts.map +1 -0
  509. package/dist/materializer/shared/abort.d.ts +2 -0
  510. package/dist/materializer/shared/abort.d.ts.map +1 -0
  511. package/dist/materializer/shared/batching.d.ts +11 -0
  512. package/dist/materializer/shared/batching.d.ts.map +1 -0
  513. package/dist/materializer/shared/chunking.d.ts +6 -0
  514. package/dist/materializer/shared/chunking.d.ts.map +1 -0
  515. package/dist/materializer/shared/identity.d.ts +38 -0
  516. package/dist/materializer/shared/identity.d.ts.map +1 -0
  517. package/dist/materializer/shared/normalize.d.ts +10 -0
  518. package/dist/materializer/shared/normalize.d.ts.map +1 -0
  519. package/dist/materializer/shared/projection-run.d.ts +19 -0
  520. package/dist/materializer/shared/projection-run.d.ts.map +1 -0
  521. package/dist/materializer/telemetry/append.d.ts +4 -0
  522. package/dist/materializer/telemetry/append.d.ts.map +1 -0
  523. package/dist/materializer/telemetry/plan.d.ts +12 -0
  524. package/dist/materializer/telemetry/plan.d.ts.map +1 -0
  525. package/dist/objects/action/errors.d.ts +39 -0
  526. package/dist/objects/action/errors.d.ts.map +1 -0
  527. package/dist/objects/action/index.d.ts +4 -0
  528. package/dist/objects/action/index.d.ts.map +1 -0
  529. package/dist/objects/action/request.d.ts +23 -0
  530. package/dist/objects/action/request.d.ts.map +1 -0
  531. package/dist/objects/context/index.d.ts +3 -0
  532. package/dist/objects/context/index.d.ts.map +1 -0
  533. package/dist/objects/context/resolve.d.ts +27 -0
  534. package/dist/objects/context/resolve.d.ts.map +1 -0
  535. package/dist/objects/context/types.d.ts +28 -0
  536. package/dist/objects/context/types.d.ts.map +1 -0
  537. package/dist/objects/contexts.d.ts +45 -0
  538. package/dist/objects/contexts.d.ts.map +1 -0
  539. package/dist/objects/errors.d.ts +8 -0
  540. package/dist/objects/errors.d.ts.map +1 -0
  541. package/dist/objects/helpers.d.ts +7 -0
  542. package/dist/objects/helpers.d.ts.map +1 -0
  543. package/dist/objects/index.d.ts +18 -0
  544. package/dist/objects/index.d.ts.map +1 -0
  545. package/dist/objects/index.js +71 -0
  546. package/dist/objects/index.js.map +9 -0
  547. package/dist/objects/link/authorization.d.ts +25 -0
  548. package/dist/objects/link/authorization.d.ts.map +1 -0
  549. package/dist/objects/link/endpoints.d.ts +28 -0
  550. package/dist/objects/link/endpoints.d.ts.map +1 -0
  551. package/dist/objects/link/index.d.ts +4 -0
  552. package/dist/objects/link/index.d.ts.map +1 -0
  553. package/dist/objects/link/remove.d.ts +8 -0
  554. package/dist/objects/link/remove.d.ts.map +1 -0
  555. package/dist/objects/link/upsert-batch.d.ts +11 -0
  556. package/dist/objects/link/upsert-batch.d.ts.map +1 -0
  557. package/dist/objects/link/upsert.d.ts +12 -0
  558. package/dist/objects/link/upsert.d.ts.map +1 -0
  559. package/dist/objects/materializer-adapter.d.ts +114 -0
  560. package/dist/objects/materializer-adapter.d.ts.map +1 -0
  561. package/dist/objects/object/delete.d.ts +17 -0
  562. package/dist/objects/object/delete.d.ts.map +1 -0
  563. package/dist/objects/object/index.d.ts +4 -0
  564. package/dist/objects/object/index.d.ts.map +1 -0
  565. package/dist/objects/object/upsert-batch.d.ts +7 -0
  566. package/dist/objects/object/upsert-batch.d.ts.map +1 -0
  567. package/dist/objects/object/upsert.d.ts +7 -0
  568. package/dist/objects/object/upsert.d.ts.map +1 -0
  569. package/dist/objects/query/errors.d.ts +23 -0
  570. package/dist/objects/query/errors.d.ts.map +1 -0
  571. package/dist/objects/query/executor.d.ts +63 -0
  572. package/dist/objects/query/executor.d.ts.map +1 -0
  573. package/dist/objects/query/explain-format.d.ts +10 -0
  574. package/dist/objects/query/explain-format.d.ts.map +1 -0
  575. package/dist/objects/query/explain.d.ts +26 -0
  576. package/dist/objects/query/explain.d.ts.map +1 -0
  577. package/dist/objects/query/index.d.ts +14 -0
  578. package/dist/objects/query/index.d.ts.map +1 -0
  579. package/dist/objects/query/index.js +54 -0
  580. package/dist/objects/query/index.js.map +9 -0
  581. package/dist/objects/query/ir.d.ts +166 -0
  582. package/dist/objects/query/ir.d.ts.map +1 -0
  583. package/dist/objects/query/normalize.d.ts +12 -0
  584. package/dist/objects/query/normalize.d.ts.map +1 -0
  585. package/dist/objects/query/planner.d.ts +32 -0
  586. package/dist/objects/query/planner.d.ts.map +1 -0
  587. package/dist/objects/query/scalar-values.d.ts +6 -0
  588. package/dist/objects/query/scalar-values.d.ts.map +1 -0
  589. package/dist/objects/query/validate.d.ts +23 -0
  590. package/dist/objects/query/validate.d.ts.map +1 -0
  591. package/dist/objects/runtime-batch.d.ts +29 -0
  592. package/dist/objects/runtime-batch.d.ts.map +1 -0
  593. package/dist/objects/sdk/index.d.ts +3 -0
  594. package/dist/objects/sdk/index.d.ts.map +1 -0
  595. package/dist/objects/sdk/object-handle.d.ts +6 -0
  596. package/dist/objects/sdk/object-handle.d.ts.map +1 -0
  597. package/dist/objects/sdk/object-set.d.ts +14 -0
  598. package/dist/objects/sdk/object-set.d.ts.map +1 -0
  599. package/dist/objects/sdk/query-builder.d.ts +20 -0
  600. package/dist/objects/sdk/query-builder.d.ts.map +1 -0
  601. package/dist/objects/sdk/query-executor.d.ts +51 -0
  602. package/dist/objects/sdk/query-executor.d.ts.map +1 -0
  603. package/dist/objects/sdk/runtime-query-executor.d.ts +16 -0
  604. package/dist/objects/sdk/runtime-query-executor.d.ts.map +1 -0
  605. package/dist/objects/sdk/telemetry-channel.d.ts +6 -0
  606. package/dist/objects/sdk/telemetry-channel.d.ts.map +1 -0
  607. package/dist/objects/sdk/where.d.ts +15 -0
  608. package/dist/objects/sdk/where.d.ts.map +1 -0
  609. package/dist/objects/service/action-service.d.ts +12 -0
  610. package/dist/objects/service/action-service.d.ts.map +1 -0
  611. package/dist/objects/service/index.d.ts +7 -0
  612. package/dist/objects/service/index.d.ts.map +1 -0
  613. package/dist/objects/service/link-service.d.ts +26 -0
  614. package/dist/objects/service/link-service.d.ts.map +1 -0
  615. package/dist/objects/service/list-service.d.ts +24 -0
  616. package/dist/objects/service/list-service.d.ts.map +1 -0
  617. package/dist/objects/service/object-service.d.ts +12 -0
  618. package/dist/objects/service/object-service.d.ts.map +1 -0
  619. package/dist/objects/service/telemetry-service.d.ts +12 -0
  620. package/dist/objects/service/telemetry-service.d.ts.map +1 -0
  621. package/dist/objects/telemetry/append-batch.d.ts +10 -0
  622. package/dist/objects/telemetry/append-batch.d.ts.map +1 -0
  623. package/dist/objects/telemetry/history.d.ts +8 -0
  624. package/dist/objects/telemetry/history.d.ts.map +1 -0
  625. package/dist/objects/telemetry/index.d.ts +5 -0
  626. package/dist/objects/telemetry/index.d.ts.map +1 -0
  627. package/dist/objects/telemetry/write-batch.d.ts +8 -0
  628. package/dist/objects/telemetry/write-batch.d.ts.map +1 -0
  629. package/dist/ontology/builders.d.ts +323 -0
  630. package/dist/ontology/builders.d.ts.map +1 -0
  631. package/dist/ontology/decimal.d.ts +28 -0
  632. package/dist/ontology/decimal.d.ts.map +1 -0
  633. package/dist/ontology/errors.d.ts +20 -0
  634. package/dist/ontology/errors.d.ts.map +1 -0
  635. package/dist/ontology/index.d.ts +23 -0
  636. package/dist/ontology/index.d.ts.map +1 -0
  637. package/dist/ontology/index.js +120 -0
  638. package/dist/ontology/index.js.map +9 -0
  639. package/dist/ontology/inference/index.d.ts +112 -0
  640. package/dist/ontology/inference/index.d.ts.map +1 -0
  641. package/dist/ontology/internal.d.ts +4 -0
  642. package/dist/ontology/internal.d.ts.map +1 -0
  643. package/dist/ontology/internal.js +118 -0
  644. package/dist/ontology/internal.js.map +10 -0
  645. package/dist/ontology/json-schema.d.ts +9 -0
  646. package/dist/ontology/json-schema.d.ts.map +1 -0
  647. package/dist/ontology/refs.d.ts +16 -0
  648. package/dist/ontology/refs.d.ts.map +1 -0
  649. package/dist/ontology/registry.d.ts +82 -0
  650. package/dist/ontology/registry.d.ts.map +1 -0
  651. package/dist/ontology/tokens.d.ts +54 -0
  652. package/dist/ontology/tokens.d.ts.map +1 -0
  653. package/dist/ontology/types.d.ts +402 -0
  654. package/dist/ontology/types.d.ts.map +1 -0
  655. package/dist/ontology/units/index.d.ts +74 -0
  656. package/dist/ontology/units/index.d.ts.map +1 -0
  657. package/dist/ontology/units/quantitative-types.d.ts +1605 -0
  658. package/dist/ontology/units/quantitative-types.d.ts.map +1 -0
  659. package/dist/ontology/units/types.d.ts +26 -0
  660. package/dist/ontology/units/types.d.ts.map +1 -0
  661. package/dist/ontology/validation/index.d.ts +7 -0
  662. package/dist/ontology/validation/index.d.ts.map +1 -0
  663. package/dist/ontology/validation/links.d.ts +18 -0
  664. package/dist/ontology/validation/links.d.ts.map +1 -0
  665. package/dist/ontology/validation/normalize.d.ts +21 -0
  666. package/dist/ontology/validation/normalize.d.ts.map +1 -0
  667. package/dist/ontology/validation/properties.d.ts +19 -0
  668. package/dist/ontology/validation/properties.d.ts.map +1 -0
  669. package/dist/ontology/validation/query.d.ts +3 -0
  670. package/dist/ontology/validation/query.d.ts.map +1 -0
  671. package/dist/ontology/validation/schema.d.ts +7 -0
  672. package/dist/ontology/validation/schema.d.ts.map +1 -0
  673. package/dist/ontology/validation/telemetry.d.ts +7 -0
  674. package/dist/ontology/validation/telemetry.d.ts.map +1 -0
  675. package/dist/pipelines/builders.d.ts +14 -0
  676. package/dist/pipelines/builders.d.ts.map +1 -0
  677. package/dist/pipelines/errors.d.ts +4 -0
  678. package/dist/pipelines/errors.d.ts.map +1 -0
  679. package/dist/pipelines/index.d.ts +7 -0
  680. package/dist/pipelines/index.d.ts.map +1 -0
  681. package/dist/pipelines/request.d.ts +31 -0
  682. package/dist/pipelines/request.d.ts.map +1 -0
  683. package/dist/pipelines/types.d.ts +84 -0
  684. package/dist/pipelines/types.d.ts.map +1 -0
  685. package/dist/predicates/builders.d.ts +24 -0
  686. package/dist/predicates/builders.d.ts.map +1 -0
  687. package/dist/predicates/evaluate.d.ts +8 -0
  688. package/dist/predicates/evaluate.d.ts.map +1 -0
  689. package/dist/predicates/index.d.ts +5 -0
  690. package/dist/predicates/index.d.ts.map +1 -0
  691. package/dist/predicates/types.d.ts +69 -0
  692. package/dist/predicates/types.d.ts.map +1 -0
  693. package/dist/predicates/validation.d.ts +15 -0
  694. package/dist/predicates/validation.d.ts.map +1 -0
  695. package/dist/projections/builders.d.ts +212 -0
  696. package/dist/projections/builders.d.ts.map +1 -0
  697. package/dist/projections/errors.d.ts +4 -0
  698. package/dist/projections/errors.d.ts.map +1 -0
  699. package/dist/projections/index.d.ts +5 -0
  700. package/dist/projections/index.d.ts.map +1 -0
  701. package/dist/projections/internal.d.ts +24 -0
  702. package/dist/projections/internal.d.ts.map +1 -0
  703. package/dist/projections/internal.js +26 -0
  704. package/dist/projections/internal.js.map +9 -0
  705. package/dist/projections/ownership.d.ts +9 -0
  706. package/dist/projections/ownership.d.ts.map +1 -0
  707. package/dist/projections/registry.d.ts +30 -0
  708. package/dist/projections/registry.d.ts.map +1 -0
  709. package/dist/projections/revision.d.ts +7 -0
  710. package/dist/projections/revision.d.ts.map +1 -0
  711. package/dist/projections/types.d.ts +153 -0
  712. package/dist/projections/types.d.ts.map +1 -0
  713. package/dist/projections/validation.d.ts +97 -0
  714. package/dist/projections/validation.d.ts.map +1 -0
  715. package/dist/provider-scope.d.ts +12 -0
  716. package/dist/provider-scope.d.ts.map +1 -0
  717. package/dist/query.d.ts +17 -0
  718. package/dist/query.d.ts.map +1 -0
  719. package/dist/query.js +21 -0
  720. package/dist/query.js.map +9 -0
  721. package/dist/queues/errors.d.ts +7 -0
  722. package/dist/queues/errors.d.ts.map +1 -0
  723. package/dist/queues/in-memory.d.ts +73 -0
  724. package/dist/queues/in-memory.d.ts.map +1 -0
  725. package/dist/queues/index.d.ts +5 -0
  726. package/dist/queues/index.d.ts.map +1 -0
  727. package/dist/queues/index.js +12 -0
  728. package/dist/queues/index.js.map +9 -0
  729. package/dist/queues/types.d.ts +182 -0
  730. package/dist/queues/types.d.ts.map +1 -0
  731. package/dist/rules/builders.d.ts +10 -0
  732. package/dist/rules/builders.d.ts.map +1 -0
  733. package/dist/rules/dependencies.d.ts +9 -0
  734. package/dist/rules/dependencies.d.ts.map +1 -0
  735. package/dist/rules/errors.d.ts +11 -0
  736. package/dist/rules/errors.d.ts.map +1 -0
  737. package/dist/rules/index.d.ts +6 -0
  738. package/dist/rules/index.d.ts.map +1 -0
  739. package/dist/rules/internal.d.ts +9 -0
  740. package/dist/rules/internal.d.ts.map +1 -0
  741. package/dist/rules/internal.js +10 -0
  742. package/dist/rules/internal.js.map +9 -0
  743. package/dist/rules/types.d.ts +72 -0
  744. package/dist/rules/types.d.ts.map +1 -0
  745. package/dist/rules/validation.d.ts +23 -0
  746. package/dist/rules/validation.d.ts.map +1 -0
  747. package/dist/runtime/create.d.ts +68 -0
  748. package/dist/runtime/create.d.ts.map +1 -0
  749. package/dist/runtime/errors.d.ts +9 -0
  750. package/dist/runtime/errors.d.ts.map +1 -0
  751. package/dist/runtime/index.d.ts +26 -0
  752. package/dist/runtime/index.d.ts.map +1 -0
  753. package/dist/runtime/internal.d.ts +3 -0
  754. package/dist/runtime/internal.d.ts.map +1 -0
  755. package/dist/runtime/internal.js +16 -0
  756. package/dist/runtime/internal.js.map +9 -0
  757. package/dist/runtime/ontology-mutations.d.ts +16 -0
  758. package/dist/runtime/ontology-mutations.d.ts.map +1 -0
  759. package/dist/runtime/scoped.d.ts +158 -0
  760. package/dist/runtime/scoped.d.ts.map +1 -0
  761. package/dist/runtime/sixb.d.ts +226 -0
  762. package/dist/runtime/sixb.d.ts.map +1 -0
  763. package/dist/runtime/storage-readiness.d.ts +20 -0
  764. package/dist/runtime/storage-readiness.d.ts.map +1 -0
  765. package/dist/runtime/types.d.ts +840 -0
  766. package/dist/runtime/types.d.ts.map +1 -0
  767. package/dist/sandboxes/errors.d.ts +20 -0
  768. package/dist/sandboxes/errors.d.ts.map +1 -0
  769. package/dist/sandboxes/exec.d.ts +17 -0
  770. package/dist/sandboxes/exec.d.ts.map +1 -0
  771. package/dist/sandboxes/index.d.ts +5 -0
  772. package/dist/sandboxes/index.d.ts.map +1 -0
  773. package/dist/sandboxes/index.js +18 -0
  774. package/dist/sandboxes/index.js.map +9 -0
  775. package/dist/sandboxes/sandbox.d.ts +110 -0
  776. package/dist/sandboxes/sandbox.d.ts.map +1 -0
  777. package/dist/scheduler/errors.d.ts +7 -0
  778. package/dist/scheduler/errors.d.ts.map +1 -0
  779. package/dist/scheduler/index.d.ts +4 -0
  780. package/dist/scheduler/index.d.ts.map +1 -0
  781. package/dist/scheduler/index.js +18 -0
  782. package/dist/scheduler/index.js.map +9 -0
  783. package/dist/scheduler/runtime.d.ts +32 -0
  784. package/dist/scheduler/runtime.d.ts.map +1 -0
  785. package/dist/schedules/builders.d.ts +4 -0
  786. package/dist/schedules/builders.d.ts.map +1 -0
  787. package/dist/schedules/cron.d.ts +14 -0
  788. package/dist/schedules/cron.d.ts.map +1 -0
  789. package/dist/schedules/errors.d.ts +7 -0
  790. package/dist/schedules/errors.d.ts.map +1 -0
  791. package/dist/schedules/index.d.ts +12 -0
  792. package/dist/schedules/index.d.ts.map +1 -0
  793. package/dist/schedules/index.js +37 -0
  794. package/dist/schedules/index.js.map +9 -0
  795. package/dist/schedules/next-occurrence.d.ts +11 -0
  796. package/dist/schedules/next-occurrence.d.ts.map +1 -0
  797. package/dist/schedules/runtime.d.ts +17 -0
  798. package/dist/schedules/runtime.d.ts.map +1 -0
  799. package/dist/schedules/types.d.ts +99 -0
  800. package/dist/schedules/types.d.ts.map +1 -0
  801. package/dist/schedules/validation.d.ts +13 -0
  802. package/dist/schedules/validation.d.ts.map +1 -0
  803. package/dist/security/applications.d.ts +15 -0
  804. package/dist/security/applications.d.ts.map +1 -0
  805. package/dist/security/builders.d.ts +20 -0
  806. package/dist/security/builders.d.ts.map +1 -0
  807. package/dist/security/errors.d.ts +4 -0
  808. package/dist/security/errors.d.ts.map +1 -0
  809. package/dist/security/every.d.ts +68 -0
  810. package/dist/security/every.d.ts.map +1 -0
  811. package/dist/security/grants.d.ts +40 -0
  812. package/dist/security/grants.d.ts.map +1 -0
  813. package/dist/security/index.d.ts +12 -0
  814. package/dist/security/index.d.ts.map +1 -0
  815. package/dist/security/membership-policies.d.ts +17 -0
  816. package/dist/security/membership-policies.d.ts.map +1 -0
  817. package/dist/security/runtime.d.ts +16 -0
  818. package/dist/security/runtime.d.ts.map +1 -0
  819. package/dist/security/types.d.ts +133 -0
  820. package/dist/security/types.d.ts.map +1 -0
  821. package/dist/security/validation.d.ts +36 -0
  822. package/dist/security/validation.d.ts.map +1 -0
  823. package/dist/storage/action-runs/errors.d.ts +10 -0
  824. package/dist/storage/action-runs/errors.d.ts.map +1 -0
  825. package/dist/storage/action-runs/idempotency.d.ts +10 -0
  826. package/dist/storage/action-runs/idempotency.d.ts.map +1 -0
  827. package/dist/storage/action-runs/in-memory.d.ts +28 -0
  828. package/dist/storage/action-runs/in-memory.d.ts.map +1 -0
  829. package/dist/storage/action-runs/index.d.ts +6 -0
  830. package/dist/storage/action-runs/index.d.ts.map +1 -0
  831. package/dist/storage/action-runs/types.d.ts +138 -0
  832. package/dist/storage/action-runs/types.d.ts.map +1 -0
  833. package/dist/storage/agents/errors.d.ts +11 -0
  834. package/dist/storage/agents/errors.d.ts.map +1 -0
  835. package/dist/storage/agents/in-memory.d.ts +70 -0
  836. package/dist/storage/agents/in-memory.d.ts.map +1 -0
  837. package/dist/storage/agents/index.d.ts +7 -0
  838. package/dist/storage/agents/index.d.ts.map +1 -0
  839. package/dist/storage/agents/types.d.ts +295 -0
  840. package/dist/storage/agents/types.d.ts.map +1 -0
  841. package/dist/storage/auth/errors.d.ts +10 -0
  842. package/dist/storage/auth/errors.d.ts.map +1 -0
  843. package/dist/storage/auth/in-memory/access-tokens.d.ts +32 -0
  844. package/dist/storage/auth/in-memory/access-tokens.d.ts.map +1 -0
  845. package/dist/storage/auth/in-memory/auth-storage.d.ts +36 -0
  846. package/dist/storage/auth/in-memory/auth-storage.d.ts.map +1 -0
  847. package/dist/storage/auth/in-memory/group-memberships.d.ts +21 -0
  848. package/dist/storage/auth/in-memory/group-memberships.d.ts.map +1 -0
  849. package/dist/storage/auth/in-memory/identities.d.ts +17 -0
  850. package/dist/storage/auth/in-memory/identities.d.ts.map +1 -0
  851. package/dist/storage/auth/in-memory/index.d.ts +2 -0
  852. package/dist/storage/auth/in-memory/index.d.ts.map +1 -0
  853. package/dist/storage/auth/in-memory/invitations.d.ts +28 -0
  854. package/dist/storage/auth/in-memory/invitations.d.ts.map +1 -0
  855. package/dist/storage/auth/in-memory/magic-links.d.ts +28 -0
  856. package/dist/storage/auth/in-memory/magic-links.d.ts.map +1 -0
  857. package/dist/storage/auth/in-memory/oidc-attempts.d.ts +18 -0
  858. package/dist/storage/auth/in-memory/oidc-attempts.d.ts.map +1 -0
  859. package/dist/storage/auth/in-memory/service-account-group-memberships.d.ts +17 -0
  860. package/dist/storage/auth/in-memory/service-account-group-memberships.d.ts.map +1 -0
  861. package/dist/storage/auth/in-memory/service-accounts.d.ts +14 -0
  862. package/dist/storage/auth/in-memory/service-accounts.d.ts.map +1 -0
  863. package/dist/storage/auth/in-memory/sessions.d.ts +55 -0
  864. package/dist/storage/auth/in-memory/sessions.d.ts.map +1 -0
  865. package/dist/storage/auth/in-memory/shared.d.ts +71 -0
  866. package/dist/storage/auth/in-memory/shared.d.ts.map +1 -0
  867. package/dist/storage/auth/in-memory/users.d.ts +19 -0
  868. package/dist/storage/auth/in-memory/users.d.ts.map +1 -0
  869. package/dist/storage/auth/in-memory.d.ts +2 -0
  870. package/dist/storage/auth/in-memory.d.ts.map +1 -0
  871. package/dist/storage/auth/index.d.ts +5 -0
  872. package/dist/storage/auth/index.d.ts.map +1 -0
  873. package/dist/storage/auth/types.d.ts +584 -0
  874. package/dist/storage/auth/types.d.ts.map +1 -0
  875. package/dist/storage/errors.d.ts +27 -0
  876. package/dist/storage/errors.d.ts.map +1 -0
  877. package/dist/storage/file-upload-sessions/errors.d.ts +15 -0
  878. package/dist/storage/file-upload-sessions/errors.d.ts.map +1 -0
  879. package/dist/storage/file-upload-sessions/in-memory.d.ts +27 -0
  880. package/dist/storage/file-upload-sessions/in-memory.d.ts.map +1 -0
  881. package/dist/storage/file-upload-sessions/index.d.ts +6 -0
  882. package/dist/storage/file-upload-sessions/index.d.ts.map +1 -0
  883. package/dist/storage/file-upload-sessions/types.d.ts +53 -0
  884. package/dist/storage/file-upload-sessions/types.d.ts.map +1 -0
  885. package/dist/storage/file-upload-sessions/utils.d.ts +11 -0
  886. package/dist/storage/file-upload-sessions/utils.d.ts.map +1 -0
  887. package/dist/storage/in-memory/index.d.ts +105 -0
  888. package/dist/storage/in-memory/index.d.ts.map +1 -0
  889. package/dist/storage/in-memory/testing.d.ts +8 -0
  890. package/dist/storage/in-memory/testing.d.ts.map +1 -0
  891. package/dist/storage/index.d.ts +44 -0
  892. package/dist/storage/index.d.ts.map +1 -0
  893. package/dist/storage/index.js +144 -0
  894. package/dist/storage/index.js.map +9 -0
  895. package/dist/storage/migrations/check-schema.d.ts +19 -0
  896. package/dist/storage/migrations/check-schema.d.ts.map +1 -0
  897. package/dist/storage/migrations/index.d.ts +5 -0
  898. package/dist/storage/migrations/index.d.ts.map +1 -0
  899. package/dist/storage/migrations/migrate-storage.d.ts +6 -0
  900. package/dist/storage/migrations/migrate-storage.d.ts.map +1 -0
  901. package/dist/storage/migrations/migration-set.d.ts +27 -0
  902. package/dist/storage/migrations/migration-set.d.ts.map +1 -0
  903. package/dist/storage/migrations/types.d.ts +115 -0
  904. package/dist/storage/migrations/types.d.ts.map +1 -0
  905. package/dist/storage/objects/in-memory.d.ts +126 -0
  906. package/dist/storage/objects/in-memory.d.ts.map +1 -0
  907. package/dist/storage/objects/index.d.ts +2 -0
  908. package/dist/storage/objects/index.d.ts.map +1 -0
  909. package/dist/storage/objects/types.d.ts +222 -0
  910. package/dist/storage/objects/types.d.ts.map +1 -0
  911. package/dist/storage/ontology/commits.d.ts +117 -0
  912. package/dist/storage/ontology/commits.d.ts.map +1 -0
  913. package/dist/storage/ontology/in-memory/commits.d.ts +12 -0
  914. package/dist/storage/ontology/in-memory/commits.d.ts.map +1 -0
  915. package/dist/storage/ontology/in-memory/index.d.ts +36 -0
  916. package/dist/storage/ontology/in-memory/index.d.ts.map +1 -0
  917. package/dist/storage/ontology/in-memory/materializations-finalization.d.ts +5 -0
  918. package/dist/storage/ontology/in-memory/materializations-finalization.d.ts.map +1 -0
  919. package/dist/storage/ontology/in-memory/materializations-state.d.ts +20 -0
  920. package/dist/storage/ontology/in-memory/materializations-state.d.ts.map +1 -0
  921. package/dist/storage/ontology/in-memory/materializations-work.d.ts +6 -0
  922. package/dist/storage/ontology/in-memory/materializations-work.d.ts.map +1 -0
  923. package/dist/storage/ontology/in-memory/materializations.d.ts +101 -0
  924. package/dist/storage/ontology/in-memory/materializations.d.ts.map +1 -0
  925. package/dist/storage/ontology/in-memory/outbox.d.ts +19 -0
  926. package/dist/storage/ontology/in-memory/outbox.d.ts.map +1 -0
  927. package/dist/storage/ontology/in-memory/shared-state.d.ts +48 -0
  928. package/dist/storage/ontology/in-memory/shared-state.d.ts.map +1 -0
  929. package/dist/storage/ontology/in-memory/sources.d.ts +23 -0
  930. package/dist/storage/ontology/in-memory/sources.d.ts.map +1 -0
  931. package/dist/storage/ontology/in-memory/testing.d.ts +11 -0
  932. package/dist/storage/ontology/in-memory/testing.d.ts.map +1 -0
  933. package/dist/storage/ontology/index.d.ts +16 -0
  934. package/dist/storage/ontology/index.d.ts.map +1 -0
  935. package/dist/storage/ontology/materializations.d.ts +333 -0
  936. package/dist/storage/ontology/materializations.d.ts.map +1 -0
  937. package/dist/storage/ontology/outbox.d.ts +66 -0
  938. package/dist/storage/ontology/outbox.d.ts.map +1 -0
  939. package/dist/storage/ontology/provider-header-validation.d.ts +4 -0
  940. package/dist/storage/ontology/provider-header-validation.d.ts.map +1 -0
  941. package/dist/storage/ontology/provider-validation.d.ts +6 -0
  942. package/dist/storage/ontology/provider-validation.d.ts.map +1 -0
  943. package/dist/storage/ontology/provider-work.d.ts +12 -0
  944. package/dist/storage/ontology/provider-work.d.ts.map +1 -0
  945. package/dist/storage/ontology/provider.d.ts +191 -0
  946. package/dist/storage/ontology/provider.d.ts.map +1 -0
  947. package/dist/storage/ontology/provider.js +115 -0
  948. package/dist/storage/ontology/provider.js.map +9 -0
  949. package/dist/storage/ontology/sources.d.ts +151 -0
  950. package/dist/storage/ontology/sources.d.ts.map +1 -0
  951. package/dist/storage/operation-scope.d.ts +32 -0
  952. package/dist/storage/operation-scope.d.ts.map +1 -0
  953. package/dist/storage/operation-scope.js +22 -0
  954. package/dist/storage/operation-scope.js.map +9 -0
  955. package/dist/storage/pagination.d.ts +11 -0
  956. package/dist/storage/pagination.d.ts.map +1 -0
  957. package/dist/storage/pipeline-runs/errors.d.ts +7 -0
  958. package/dist/storage/pipeline-runs/errors.d.ts.map +1 -0
  959. package/dist/storage/pipeline-runs/in-memory.d.ts +26 -0
  960. package/dist/storage/pipeline-runs/in-memory.d.ts.map +1 -0
  961. package/dist/storage/pipeline-runs/index.d.ts +4 -0
  962. package/dist/storage/pipeline-runs/index.d.ts.map +1 -0
  963. package/dist/storage/pipeline-runs/types.d.ts +133 -0
  964. package/dist/storage/pipeline-runs/types.d.ts.map +1 -0
  965. package/dist/storage/projection-runs/errors.d.ts +9 -0
  966. package/dist/storage/projection-runs/errors.d.ts.map +1 -0
  967. package/dist/storage/projection-runs/in-memory.d.ts +42 -0
  968. package/dist/storage/projection-runs/in-memory.d.ts.map +1 -0
  969. package/dist/storage/projection-runs/index.d.ts +5 -0
  970. package/dist/storage/projection-runs/index.d.ts.map +1 -0
  971. package/dist/storage/projection-runs/lifecycle.d.ts +93 -0
  972. package/dist/storage/projection-runs/lifecycle.d.ts.map +1 -0
  973. package/dist/storage/projection-runs/lifecycle.js +64 -0
  974. package/dist/storage/projection-runs/lifecycle.js.map +9 -0
  975. package/dist/storage/projection-runs/types.d.ts +175 -0
  976. package/dist/storage/projection-runs/types.d.ts.map +1 -0
  977. package/dist/storage/rules/in-memory.d.ts +26 -0
  978. package/dist/storage/rules/in-memory.d.ts.map +1 -0
  979. package/dist/storage/rules/index.d.ts +3 -0
  980. package/dist/storage/rules/index.d.ts.map +1 -0
  981. package/dist/storage/rules/types.d.ts +60 -0
  982. package/dist/storage/rules/types.d.ts.map +1 -0
  983. package/dist/storage/run-listing.d.ts +36 -0
  984. package/dist/storage/run-listing.d.ts.map +1 -0
  985. package/dist/storage/sync-runs/errors.d.ts +8 -0
  986. package/dist/storage/sync-runs/errors.d.ts.map +1 -0
  987. package/dist/storage/sync-runs/in-memory.d.ts +16 -0
  988. package/dist/storage/sync-runs/in-memory.d.ts.map +1 -0
  989. package/dist/storage/sync-runs/index.d.ts +4 -0
  990. package/dist/storage/sync-runs/index.d.ts.map +1 -0
  991. package/dist/storage/sync-runs/types.d.ts +85 -0
  992. package/dist/storage/sync-runs/types.d.ts.map +1 -0
  993. package/dist/storage/timeseries/index.d.ts +2 -0
  994. package/dist/storage/timeseries/index.d.ts.map +1 -0
  995. package/dist/storage/timeseries/store.d.ts +46 -0
  996. package/dist/storage/timeseries/store.d.ts.map +1 -0
  997. package/dist/storage/timeseries/types.d.ts +50 -0
  998. package/dist/storage/timeseries/types.d.ts.map +1 -0
  999. package/dist/storage/transaction.d.ts +4 -0
  1000. package/dist/storage/transaction.d.ts.map +1 -0
  1001. package/dist/storage/types.d.ts +78 -0
  1002. package/dist/storage/types.d.ts.map +1 -0
  1003. package/dist/storage/webhook-deliveries/in-memory.d.ts +18 -0
  1004. package/dist/storage/webhook-deliveries/in-memory.d.ts.map +1 -0
  1005. package/dist/storage/webhook-deliveries/index.d.ts +3 -0
  1006. package/dist/storage/webhook-deliveries/index.d.ts.map +1 -0
  1007. package/dist/storage/webhook-deliveries/types.d.ts +43 -0
  1008. package/dist/storage/webhook-deliveries/types.d.ts.map +1 -0
  1009. package/dist/storage/webhook-runs/errors.d.ts +7 -0
  1010. package/dist/storage/webhook-runs/errors.d.ts.map +1 -0
  1011. package/dist/storage/webhook-runs/in-memory.d.ts +16 -0
  1012. package/dist/storage/webhook-runs/in-memory.d.ts.map +1 -0
  1013. package/dist/storage/webhook-runs/index.d.ts +4 -0
  1014. package/dist/storage/webhook-runs/index.d.ts.map +1 -0
  1015. package/dist/storage/webhook-runs/types.d.ts +66 -0
  1016. package/dist/storage/webhook-runs/types.d.ts.map +1 -0
  1017. package/dist/storage/workflow-interventions/errors.d.ts +7 -0
  1018. package/dist/storage/workflow-interventions/errors.d.ts.map +1 -0
  1019. package/dist/storage/workflow-interventions/in-memory.d.ts +18 -0
  1020. package/dist/storage/workflow-interventions/in-memory.d.ts.map +1 -0
  1021. package/dist/storage/workflow-interventions/index.d.ts +4 -0
  1022. package/dist/storage/workflow-interventions/index.d.ts.map +1 -0
  1023. package/dist/storage/workflow-interventions/types.d.ts +94 -0
  1024. package/dist/storage/workflow-interventions/types.d.ts.map +1 -0
  1025. package/dist/storage/workflow-runs/errors.d.ts +7 -0
  1026. package/dist/storage/workflow-runs/errors.d.ts.map +1 -0
  1027. package/dist/storage/workflow-runs/in-memory.d.ts +83 -0
  1028. package/dist/storage/workflow-runs/in-memory.d.ts.map +1 -0
  1029. package/dist/storage/workflow-runs/index.d.ts +4 -0
  1030. package/dist/storage/workflow-runs/index.d.ts.map +1 -0
  1031. package/dist/storage/workflow-runs/types.d.ts +305 -0
  1032. package/dist/storage/workflow-runs/types.d.ts.map +1 -0
  1033. package/dist/syncs/builders.d.ts +9 -0
  1034. package/dist/syncs/builders.d.ts.map +1 -0
  1035. package/dist/syncs/errors.d.ts +4 -0
  1036. package/dist/syncs/errors.d.ts.map +1 -0
  1037. package/dist/syncs/index.d.ts +7 -0
  1038. package/dist/syncs/index.d.ts.map +1 -0
  1039. package/dist/syncs/request.d.ts +41 -0
  1040. package/dist/syncs/request.d.ts.map +1 -0
  1041. package/dist/syncs/types.d.ts +76 -0
  1042. package/dist/syncs/types.d.ts.map +1 -0
  1043. package/dist/testing/agent-storage-contract.d.ts +16 -0
  1044. package/dist/testing/agent-storage-contract.d.ts.map +1 -0
  1045. package/dist/testing/auth-storage-contract.d.ts +16 -0
  1046. package/dist/testing/auth-storage-contract.d.ts.map +1 -0
  1047. package/dist/testing/blob-storage-contract.d.ts +10 -0
  1048. package/dist/testing/blob-storage-contract.d.ts.map +1 -0
  1049. package/dist/testing/broker-contract.d.ts +39 -0
  1050. package/dist/testing/broker-contract.d.ts.map +1 -0
  1051. package/dist/testing/effective-storage-contract.d.ts +7 -0
  1052. package/dist/testing/effective-storage-contract.d.ts.map +1 -0
  1053. package/dist/testing/index.d.ts +15 -0
  1054. package/dist/testing/index.d.ts.map +1 -0
  1055. package/dist/testing/index.js +7000 -0
  1056. package/dist/testing/index.js.map +24 -0
  1057. package/dist/testing/lake-storage-contract.d.ts +29 -0
  1058. package/dist/testing/lake-storage-contract.d.ts.map +1 -0
  1059. package/dist/testing/materialization-failure-contract.d.ts +26 -0
  1060. package/dist/testing/materialization-failure-contract.d.ts.map +1 -0
  1061. package/dist/testing/materializer-fixture.d.ts +35 -0
  1062. package/dist/testing/materializer-fixture.d.ts.map +1 -0
  1063. package/dist/testing/materializer-storage-contract.d.ts +7 -0
  1064. package/dist/testing/materializer-storage-contract.d.ts.map +1 -0
  1065. package/dist/testing/object-query-contract.d.ts +21 -0
  1066. package/dist/testing/object-query-contract.d.ts.map +1 -0
  1067. package/dist/testing/ontology-contract-fixture.d.ts +33 -0
  1068. package/dist/testing/ontology-contract-fixture.d.ts.map +1 -0
  1069. package/dist/testing/ontology-storage-contract.d.ts +21 -0
  1070. package/dist/testing/ontology-storage-contract.d.ts.map +1 -0
  1071. package/dist/testing/projection-run-storage-contract.d.ts +10 -0
  1072. package/dist/testing/projection-run-storage-contract.d.ts.map +1 -0
  1073. package/dist/testing/queues-contract.d.ts +31 -0
  1074. package/dist/testing/queues-contract.d.ts.map +1 -0
  1075. package/dist/testing/sandboxes-contract.d.ts +31 -0
  1076. package/dist/testing/sandboxes-contract.d.ts.map +1 -0
  1077. package/dist/tsconfig.json +5 -0
  1078. package/dist/webhooks/builders.d.ts +41 -0
  1079. package/dist/webhooks/builders.d.ts.map +1 -0
  1080. package/dist/webhooks/connector.d.ts +10 -0
  1081. package/dist/webhooks/connector.d.ts.map +1 -0
  1082. package/dist/webhooks/errors.d.ts +4 -0
  1083. package/dist/webhooks/errors.d.ts.map +1 -0
  1084. package/dist/webhooks/index.d.ts +9 -0
  1085. package/dist/webhooks/index.d.ts.map +1 -0
  1086. package/dist/webhooks/registry.d.ts +7 -0
  1087. package/dist/webhooks/registry.d.ts.map +1 -0
  1088. package/dist/webhooks/types.d.ts +79 -0
  1089. package/dist/webhooks/types.d.ts.map +1 -0
  1090. package/dist/webhooks/unverified.d.ts +57 -0
  1091. package/dist/webhooks/unverified.d.ts.map +1 -0
  1092. package/dist/workers/errors.d.ts +17 -0
  1093. package/dist/workers/errors.d.ts.map +1 -0
  1094. package/dist/workers/index.d.ts +7 -0
  1095. package/dist/workers/index.d.ts.map +1 -0
  1096. package/dist/workers/index.js +506 -0
  1097. package/dist/workers/index.js.map +13 -0
  1098. package/dist/workers/queue-delivery.d.ts +38 -0
  1099. package/dist/workers/queue-delivery.d.ts.map +1 -0
  1100. package/dist/workers/queue-worker.d.ts +30 -0
  1101. package/dist/workers/queue-worker.d.ts.map +1 -0
  1102. package/dist/workers/worker.d.ts +14 -0
  1103. package/dist/workers/worker.d.ts.map +1 -0
  1104. package/dist/workflows/builders.d.ts +27 -0
  1105. package/dist/workflows/builders.d.ts.map +1 -0
  1106. package/dist/workflows/errors.d.ts +11 -0
  1107. package/dist/workflows/errors.d.ts.map +1 -0
  1108. package/dist/workflows/index.d.ts +9 -0
  1109. package/dist/workflows/index.d.ts.map +1 -0
  1110. package/dist/workflows/index.js +108 -0
  1111. package/dist/workflows/index.js.map +9 -0
  1112. package/dist/workflows/request.d.ts +29 -0
  1113. package/dist/workflows/request.d.ts.map +1 -0
  1114. package/dist/workflows/runtime.d.ts +33 -0
  1115. package/dist/workflows/runtime.d.ts.map +1 -0
  1116. package/dist/workflows/snapshot.d.ts +55 -0
  1117. package/dist/workflows/snapshot.d.ts.map +1 -0
  1118. package/dist/workflows/types.d.ts +288 -0
  1119. package/dist/workflows/types.d.ts.map +1 -0
  1120. package/dist/workflows/validation.d.ts +66 -0
  1121. package/dist/workflows/validation.d.ts.map +1 -0
  1122. package/package.json +312 -0
  1123. package/src/actions/builders/define-action.ts +243 -0
  1124. package/src/actions/builders/params.ts +48 -0
  1125. package/src/actions/builders.ts +2 -0
  1126. package/src/actions/commit-edits.ts +110 -0
  1127. package/src/actions/errors.ts +15 -0
  1128. package/src/actions/index.ts +75 -0
  1129. package/src/actions/read-facade.ts +224 -0
  1130. package/src/actions/registry.ts +135 -0
  1131. package/src/actions/request.ts +407 -0
  1132. package/src/actions/run-id.ts +17 -0
  1133. package/src/actions/runtime.ts +31 -0
  1134. package/src/actions/types/context.ts +224 -0
  1135. package/src/actions/types/definitions.ts +181 -0
  1136. package/src/actions/types/handlers.ts +68 -0
  1137. package/src/actions/types/params.ts +82 -0
  1138. package/src/actions/types.ts +4 -0
  1139. package/src/actions/validation.ts +186 -0
  1140. package/src/actions/validators.ts +56 -0
  1141. package/src/actions/worker.ts +2 -0
  1142. package/src/agents/adapters.ts +647 -0
  1143. package/src/agents/api-gateway.ts +57 -0
  1144. package/src/agents/builders.ts +46 -0
  1145. package/src/agents/context-model.ts +41 -0
  1146. package/src/agents/context-resolution.ts +43 -0
  1147. package/src/agents/context.ts +185 -0
  1148. package/src/agents/dispatch.ts +107 -0
  1149. package/src/agents/errors.ts +40 -0
  1150. package/src/agents/ids.ts +24 -0
  1151. package/src/agents/index.ts +122 -0
  1152. package/src/agents/message.ts +91 -0
  1153. package/src/agents/prompt.ts +45 -0
  1154. package/src/agents/request.ts +198 -0
  1155. package/src/agents/runtime.ts +124 -0
  1156. package/src/agents/streams.ts +194 -0
  1157. package/src/agents/types.ts +70 -0
  1158. package/src/agents/validation.ts +151 -0
  1159. package/src/auth/access-tokens.ts +125 -0
  1160. package/src/auth/audience.ts +28 -0
  1161. package/src/auth/cookies.ts +263 -0
  1162. package/src/auth/csrf.ts +41 -0
  1163. package/src/auth/errors.ts +19 -0
  1164. package/src/auth/index.ts +149 -0
  1165. package/src/auth/runtime.ts +1642 -0
  1166. package/src/auth/session-cache.ts +112 -0
  1167. package/src/auth/sessions.ts +55 -0
  1168. package/src/auth/strategy.ts +46 -0
  1169. package/src/auth/types.ts +573 -0
  1170. package/src/auth/validation.ts +241 -0
  1171. package/src/authorization/application-access.ts +34 -0
  1172. package/src/authorization/decision.ts +215 -0
  1173. package/src/authorization/errors.ts +12 -0
  1174. package/src/authorization/event-visibility.ts +99 -0
  1175. package/src/authorization/grant-kinds.ts +149 -0
  1176. package/src/authorization/index.ts +24 -0
  1177. package/src/authorization/resolve.ts +101 -0
  1178. package/src/authorization/run-visibility.ts +78 -0
  1179. package/src/authorization/types.ts +52 -0
  1180. package/src/blob-storage/browser.ts +28 -0
  1181. package/src/blob-storage/constants.ts +9 -0
  1182. package/src/blob-storage/derive.ts +13 -0
  1183. package/src/blob-storage/errors.ts +6 -0
  1184. package/src/blob-storage/in-memory.ts +74 -0
  1185. package/src/blob-storage/index.ts +37 -0
  1186. package/src/blob-storage/types.ts +143 -0
  1187. package/src/blob-storage/utils.ts +126 -0
  1188. package/src/blob-storage/validation.ts +58 -0
  1189. package/src/bootstrap/discovery.ts +507 -0
  1190. package/src/bootstrap/index.ts +26 -0
  1191. package/src/bootstrap/ontology-type-manifest.ts +316 -0
  1192. package/src/broker/errors.ts +15 -0
  1193. package/src/broker/in-memory.ts +511 -0
  1194. package/src/broker/index.ts +12 -0
  1195. package/src/broker/types.ts +129 -0
  1196. package/src/connectors/builders.ts +33 -0
  1197. package/src/connectors/errors.ts +15 -0
  1198. package/src/connectors/index.ts +9 -0
  1199. package/src/connectors/runtime.ts +100 -0
  1200. package/src/connectors/types.ts +64 -0
  1201. package/src/datasets/builders.ts +233 -0
  1202. package/src/datasets/errors.ts +3 -0
  1203. package/src/datasets/index.ts +13 -0
  1204. package/src/datasets/types.ts +52 -0
  1205. package/src/datasets/validation.ts +251 -0
  1206. package/src/edits/errors.ts +6 -0
  1207. package/src/edits/index.ts +24 -0
  1208. package/src/edits/normalize.ts +87 -0
  1209. package/src/edits/properties.ts +153 -0
  1210. package/src/edits/recorder.ts +312 -0
  1211. package/src/edits/types.ts +275 -0
  1212. package/src/error-reporting/capability.ts +160 -0
  1213. package/src/error-reporting/internal.ts +13 -0
  1214. package/src/error-reporting/normalize.ts +35 -0
  1215. package/src/error-reporting/reporter.ts +65 -0
  1216. package/src/error-reporting/types.ts +125 -0
  1217. package/src/events/definitions.ts +241 -0
  1218. package/src/events/envelope.ts +68 -0
  1219. package/src/events/errors.ts +7 -0
  1220. package/src/events/index.ts +167 -0
  1221. package/src/events/outbox-dispatcher.ts +534 -0
  1222. package/src/events/property-changes.ts +9 -0
  1223. package/src/events/runtime.ts +401 -0
  1224. package/src/events/scope.ts +71 -0
  1225. package/src/events/selectors/builder.ts +531 -0
  1226. package/src/events/selectors/index.ts +42 -0
  1227. package/src/events/selectors/predicate.ts +91 -0
  1228. package/src/events/selectors/types.ts +258 -0
  1229. package/src/events/toStoredEvent.ts +35 -0
  1230. package/src/events/types/actions.ts +42 -0
  1231. package/src/events/types/datasets.ts +21 -0
  1232. package/src/events/types/index.ts +206 -0
  1233. package/src/events/types/links.ts +42 -0
  1234. package/src/events/types/objects.ts +38 -0
  1235. package/src/events/types/pipelines.ts +67 -0
  1236. package/src/events/types/rules.ts +31 -0
  1237. package/src/events/types/schedules.ts +15 -0
  1238. package/src/events/types/syncs.ts +27 -0
  1239. package/src/events/types/telemetry.ts +19 -0
  1240. package/src/events/types/workflows.ts +172 -0
  1241. package/src/http/api-routes.ts +384 -0
  1242. package/src/http/index.ts +3 -0
  1243. package/src/http/route-pattern.ts +37 -0
  1244. package/src/index.ts +916 -0
  1245. package/src/json.ts +137 -0
  1246. package/src/lake-storage/definition-updates.ts +263 -0
  1247. package/src/lake-storage/errors.ts +6 -0
  1248. package/src/lake-storage/in-memory.ts +348 -0
  1249. package/src/lake-storage/index.ts +48 -0
  1250. package/src/lake-storage/sql-transforms.ts +67 -0
  1251. package/src/lake-storage/types.ts +135 -0
  1252. package/src/logging/console-logger.ts +63 -0
  1253. package/src/logging/index.ts +43 -0
  1254. package/src/logging/record.ts +126 -0
  1255. package/src/logging/run-logger.ts +350 -0
  1256. package/src/logging/runtime.ts +341 -0
  1257. package/src/logging/stream.ts +38 -0
  1258. package/src/logging/types.ts +156 -0
  1259. package/src/maintenance/index.ts +9 -0
  1260. package/src/maintenance/ontology-maintenance.ts +351 -0
  1261. package/src/maintenance/types.ts +57 -0
  1262. package/src/materialization/dataset-watermark.ts +52 -0
  1263. package/src/materialization/errors.ts +73 -0
  1264. package/src/materialization/events.ts +92 -0
  1265. package/src/materialization/identity.ts +36 -0
  1266. package/src/materialization/index.ts +75 -0
  1267. package/src/materialization/model.ts +394 -0
  1268. package/src/materialization/refs.ts +134 -0
  1269. package/src/materializer/README.md +130 -0
  1270. package/src/materializer/context.ts +75 -0
  1271. package/src/materializer/edits/apply.ts +241 -0
  1272. package/src/materializer/edits/commit.ts +311 -0
  1273. package/src/materializer/edits/execution-units.ts +32 -0
  1274. package/src/materializer/edits/load-state.ts +148 -0
  1275. package/src/materializer/edits/operations.ts +298 -0
  1276. package/src/materializer/edits/plan.ts +192 -0
  1277. package/src/materializer/edits/read-set.ts +79 -0
  1278. package/src/materializer/edits/working-state.ts +171 -0
  1279. package/src/materializer/effective/build-events.ts +197 -0
  1280. package/src/materializer/effective/diff.ts +169 -0
  1281. package/src/materializer/effective/load-state.ts +75 -0
  1282. package/src/materializer/effective/resolve.ts +96 -0
  1283. package/src/materializer/effective/validate.ts +180 -0
  1284. package/src/materializer/execution/commit-lifecycle.ts +57 -0
  1285. package/src/materializer/execution/plan-stream.ts +97 -0
  1286. package/src/materializer/execution/run-correlation.ts +73 -0
  1287. package/src/materializer/execution/work-executor.ts +143 -0
  1288. package/src/materializer/execution/work-records.ts +186 -0
  1289. package/src/materializer/index.ts +109 -0
  1290. package/src/materializer/materializer.ts +64 -0
  1291. package/src/materializer/projections/entry-validator.ts +162 -0
  1292. package/src/materializer/projections/finish-run.ts +194 -0
  1293. package/src/materializer/projections/replace.ts +447 -0
  1294. package/src/materializer/projections/replacement-plan.ts +376 -0
  1295. package/src/materializer/projections/source-materialization.ts +99 -0
  1296. package/src/materializer/shared/abort.ts +7 -0
  1297. package/src/materializer/shared/batching.ts +32 -0
  1298. package/src/materializer/shared/chunking.ts +27 -0
  1299. package/src/materializer/shared/identity.ts +141 -0
  1300. package/src/materializer/shared/normalize.ts +527 -0
  1301. package/src/materializer/shared/projection-run.ts +61 -0
  1302. package/src/materializer/telemetry/append.ts +503 -0
  1303. package/src/materializer/telemetry/plan.ts +363 -0
  1304. package/src/objects/action/errors.ts +56 -0
  1305. package/src/objects/action/index.ts +3 -0
  1306. package/src/objects/action/request.ts +63 -0
  1307. package/src/objects/context/index.ts +6 -0
  1308. package/src/objects/context/resolve.ts +51 -0
  1309. package/src/objects/context/types.ts +31 -0
  1310. package/src/objects/contexts.ts +64 -0
  1311. package/src/objects/errors.ts +7 -0
  1312. package/src/objects/helpers.ts +18 -0
  1313. package/src/objects/index.ts +26 -0
  1314. package/src/objects/link/authorization.ts +26 -0
  1315. package/src/objects/link/endpoints.ts +66 -0
  1316. package/src/objects/link/index.ts +3 -0
  1317. package/src/objects/link/remove.ts +42 -0
  1318. package/src/objects/link/upsert-batch.ts +80 -0
  1319. package/src/objects/link/upsert.ts +56 -0
  1320. package/src/objects/materializer-adapter.ts +307 -0
  1321. package/src/objects/object/delete.ts +47 -0
  1322. package/src/objects/object/index.ts +3 -0
  1323. package/src/objects/object/upsert-batch.ts +57 -0
  1324. package/src/objects/object/upsert.ts +38 -0
  1325. package/src/objects/query/errors.ts +55 -0
  1326. package/src/objects/query/executor.ts +1345 -0
  1327. package/src/objects/query/explain-format.ts +34 -0
  1328. package/src/objects/query/explain.ts +215 -0
  1329. package/src/objects/query/index.ts +77 -0
  1330. package/src/objects/query/ir.ts +211 -0
  1331. package/src/objects/query/normalize.ts +245 -0
  1332. package/src/objects/query/planner.ts +538 -0
  1333. package/src/objects/query/scalar-values.ts +100 -0
  1334. package/src/objects/query/validate.ts +1276 -0
  1335. package/src/objects/runtime-batch.ts +105 -0
  1336. package/src/objects/sdk/index.ts +2 -0
  1337. package/src/objects/sdk/object-handle.ts +139 -0
  1338. package/src/objects/sdk/object-set.ts +224 -0
  1339. package/src/objects/sdk/query-builder.ts +386 -0
  1340. package/src/objects/sdk/query-executor.ts +62 -0
  1341. package/src/objects/sdk/runtime-query-executor.ts +88 -0
  1342. package/src/objects/sdk/telemetry-channel.ts +81 -0
  1343. package/src/objects/sdk/where.ts +87 -0
  1344. package/src/objects/service/action-service.ts +40 -0
  1345. package/src/objects/service/index.ts +6 -0
  1346. package/src/objects/service/link-service.ts +74 -0
  1347. package/src/objects/service/list-service.ts +89 -0
  1348. package/src/objects/service/object-service.ts +28 -0
  1349. package/src/objects/service/telemetry-service.ts +17 -0
  1350. package/src/objects/telemetry/append-batch.ts +74 -0
  1351. package/src/objects/telemetry/history.ts +32 -0
  1352. package/src/objects/telemetry/index.ts +4 -0
  1353. package/src/objects/telemetry/write-batch.ts +52 -0
  1354. package/src/ontology/builders.ts +695 -0
  1355. package/src/ontology/decimal.ts +120 -0
  1356. package/src/ontology/errors.ts +25 -0
  1357. package/src/ontology/index.ts +80 -0
  1358. package/src/ontology/inference/index.ts +215 -0
  1359. package/src/ontology/internal.ts +3 -0
  1360. package/src/ontology/json-schema.ts +123 -0
  1361. package/src/ontology/refs.ts +80 -0
  1362. package/src/ontology/registry.ts +417 -0
  1363. package/src/ontology/tokens.ts +113 -0
  1364. package/src/ontology/types.ts +436 -0
  1365. package/src/ontology/units/index.ts +115 -0
  1366. package/src/ontology/units/quantitative-types.ts +608 -0
  1367. package/src/ontology/units/types.ts +27 -0
  1368. package/src/ontology/validation/index.ts +36 -0
  1369. package/src/ontology/validation/links.ts +126 -0
  1370. package/src/ontology/validation/normalize.ts +215 -0
  1371. package/src/ontology/validation/properties.ts +235 -0
  1372. package/src/ontology/validation/query.ts +300 -0
  1373. package/src/ontology/validation/schema.ts +174 -0
  1374. package/src/ontology/validation/telemetry.ts +53 -0
  1375. package/src/pipelines/builders.ts +155 -0
  1376. package/src/pipelines/errors.ts +3 -0
  1377. package/src/pipelines/index.ts +26 -0
  1378. package/src/pipelines/request.ts +71 -0
  1379. package/src/pipelines/types.ts +199 -0
  1380. package/src/predicates/builders.ts +152 -0
  1381. package/src/predicates/evaluate.ts +107 -0
  1382. package/src/predicates/index.ts +28 -0
  1383. package/src/predicates/types.ts +124 -0
  1384. package/src/predicates/validation.ts +152 -0
  1385. package/src/projections/builders.ts +770 -0
  1386. package/src/projections/errors.ts +3 -0
  1387. package/src/projections/index.ts +32 -0
  1388. package/src/projections/internal.ts +75 -0
  1389. package/src/projections/ownership.ts +134 -0
  1390. package/src/projections/registry.ts +269 -0
  1391. package/src/projections/revision.ts +245 -0
  1392. package/src/projections/types.ts +165 -0
  1393. package/src/projections/validation.ts +531 -0
  1394. package/src/provider-scope.ts +11 -0
  1395. package/src/query.ts +75 -0
  1396. package/src/queues/errors.ts +6 -0
  1397. package/src/queues/in-memory.ts +364 -0
  1398. package/src/queues/index.ts +23 -0
  1399. package/src/queues/types.ts +230 -0
  1400. package/src/rules/builders.ts +126 -0
  1401. package/src/rules/dependencies.ts +76 -0
  1402. package/src/rules/errors.ts +11 -0
  1403. package/src/rules/index.ts +30 -0
  1404. package/src/rules/internal.ts +8 -0
  1405. package/src/rules/types.ts +113 -0
  1406. package/src/rules/validation.ts +153 -0
  1407. package/src/runtime/create.ts +163 -0
  1408. package/src/runtime/errors.ts +8 -0
  1409. package/src/runtime/index.ts +67 -0
  1410. package/src/runtime/internal.ts +7 -0
  1411. package/src/runtime/ontology-mutations.ts +90 -0
  1412. package/src/runtime/scoped.ts +436 -0
  1413. package/src/runtime/sixb.ts +822 -0
  1414. package/src/runtime/storage-readiness.ts +91 -0
  1415. package/src/runtime/types.ts +1401 -0
  1416. package/src/sandboxes/errors.ts +22 -0
  1417. package/src/sandboxes/exec.ts +102 -0
  1418. package/src/sandboxes/index.ts +19 -0
  1419. package/src/sandboxes/sandbox.ts +124 -0
  1420. package/src/scheduler/errors.ts +7 -0
  1421. package/src/scheduler/index.ts +3 -0
  1422. package/src/scheduler/runtime.ts +174 -0
  1423. package/src/schedules/builders.ts +257 -0
  1424. package/src/schedules/cron.ts +166 -0
  1425. package/src/schedules/errors.ts +7 -0
  1426. package/src/schedules/index.ts +44 -0
  1427. package/src/schedules/next-occurrence.ts +217 -0
  1428. package/src/schedules/runtime.ts +241 -0
  1429. package/src/schedules/types.ts +212 -0
  1430. package/src/schedules/validation.ts +398 -0
  1431. package/src/security/applications.ts +11 -0
  1432. package/src/security/builders.ts +128 -0
  1433. package/src/security/errors.ts +3 -0
  1434. package/src/security/every.ts +108 -0
  1435. package/src/security/grants.ts +215 -0
  1436. package/src/security/index.ts +51 -0
  1437. package/src/security/membership-policies.ts +101 -0
  1438. package/src/security/runtime.ts +101 -0
  1439. package/src/security/types.ts +156 -0
  1440. package/src/security/validation.ts +430 -0
  1441. package/src/storage/action-runs/errors.ts +13 -0
  1442. package/src/storage/action-runs/idempotency.ts +68 -0
  1443. package/src/storage/action-runs/in-memory.ts +420 -0
  1444. package/src/storage/action-runs/index.ts +31 -0
  1445. package/src/storage/action-runs/types.ts +169 -0
  1446. package/src/storage/agents/errors.ts +22 -0
  1447. package/src/storage/agents/in-memory.ts +498 -0
  1448. package/src/storage/agents/index.ts +42 -0
  1449. package/src/storage/agents/types.ts +348 -0
  1450. package/src/storage/auth/errors.ts +40 -0
  1451. package/src/storage/auth/in-memory/access-tokens.ts +123 -0
  1452. package/src/storage/auth/in-memory/auth-storage.ts +559 -0
  1453. package/src/storage/auth/in-memory/group-memberships.ts +46 -0
  1454. package/src/storage/auth/in-memory/identities.ts +66 -0
  1455. package/src/storage/auth/in-memory/index.ts +1 -0
  1456. package/src/storage/auth/in-memory/invitations.ts +165 -0
  1457. package/src/storage/auth/in-memory/magic-links.ts +98 -0
  1458. package/src/storage/auth/in-memory/oidc-attempts.ts +75 -0
  1459. package/src/storage/auth/in-memory/service-account-group-memberships.ts +102 -0
  1460. package/src/storage/auth/in-memory/service-accounts.ts +80 -0
  1461. package/src/storage/auth/in-memory/sessions.ts +177 -0
  1462. package/src/storage/auth/in-memory/shared.ts +602 -0
  1463. package/src/storage/auth/in-memory/users.ts +139 -0
  1464. package/src/storage/auth/in-memory.ts +1 -0
  1465. package/src/storage/auth/index.ts +58 -0
  1466. package/src/storage/auth/types.ts +639 -0
  1467. package/src/storage/errors.ts +45 -0
  1468. package/src/storage/file-upload-sessions/errors.ts +24 -0
  1469. package/src/storage/file-upload-sessions/in-memory.ts +161 -0
  1470. package/src/storage/file-upload-sessions/index.ts +19 -0
  1471. package/src/storage/file-upload-sessions/types.ts +61 -0
  1472. package/src/storage/file-upload-sessions/utils.ts +49 -0
  1473. package/src/storage/in-memory/index.ts +297 -0
  1474. package/src/storage/in-memory/testing.ts +21 -0
  1475. package/src/storage/index.ts +489 -0
  1476. package/src/storage/migrations/check-schema.ts +49 -0
  1477. package/src/storage/migrations/index.ts +23 -0
  1478. package/src/storage/migrations/migrate-storage.ts +24 -0
  1479. package/src/storage/migrations/migration-set.ts +270 -0
  1480. package/src/storage/migrations/types.ts +129 -0
  1481. package/src/storage/objects/in-memory.ts +1154 -0
  1482. package/src/storage/objects/index.ts +24 -0
  1483. package/src/storage/objects/types.ts +244 -0
  1484. package/src/storage/ontology/commits.ts +132 -0
  1485. package/src/storage/ontology/in-memory/commits.ts +122 -0
  1486. package/src/storage/ontology/in-memory/index.ts +94 -0
  1487. package/src/storage/ontology/in-memory/materializations-finalization.ts +484 -0
  1488. package/src/storage/ontology/in-memory/materializations-state.ts +183 -0
  1489. package/src/storage/ontology/in-memory/materializations-work.ts +62 -0
  1490. package/src/storage/ontology/in-memory/materializations.ts +1192 -0
  1491. package/src/storage/ontology/in-memory/outbox.ts +227 -0
  1492. package/src/storage/ontology/in-memory/shared-state.ts +161 -0
  1493. package/src/storage/ontology/in-memory/sources.ts +566 -0
  1494. package/src/storage/ontology/in-memory/testing.ts +29 -0
  1495. package/src/storage/ontology/index.ts +119 -0
  1496. package/src/storage/ontology/materializations.ts +414 -0
  1497. package/src/storage/ontology/outbox.ts +79 -0
  1498. package/src/storage/ontology/provider-header-validation.ts +173 -0
  1499. package/src/storage/ontology/provider-validation.ts +36 -0
  1500. package/src/storage/ontology/provider-work.ts +330 -0
  1501. package/src/storage/ontology/provider.ts +852 -0
  1502. package/src/storage/ontology/sources.ts +195 -0
  1503. package/src/storage/operation-scope.ts +248 -0
  1504. package/src/storage/pagination.ts +23 -0
  1505. package/src/storage/pipeline-runs/errors.ts +6 -0
  1506. package/src/storage/pipeline-runs/in-memory.ts +307 -0
  1507. package/src/storage/pipeline-runs/index.ts +19 -0
  1508. package/src/storage/pipeline-runs/types.ts +148 -0
  1509. package/src/storage/projection-runs/errors.ts +15 -0
  1510. package/src/storage/projection-runs/in-memory.ts +321 -0
  1511. package/src/storage/projection-runs/index.ts +36 -0
  1512. package/src/storage/projection-runs/lifecycle.ts +793 -0
  1513. package/src/storage/projection-runs/types.ts +254 -0
  1514. package/src/storage/rules/in-memory.ts +191 -0
  1515. package/src/storage/rules/index.ts +12 -0
  1516. package/src/storage/rules/types.ts +80 -0
  1517. package/src/storage/run-listing.ts +107 -0
  1518. package/src/storage/sync-runs/errors.ts +7 -0
  1519. package/src/storage/sync-runs/in-memory.ts +181 -0
  1520. package/src/storage/sync-runs/index.ts +14 -0
  1521. package/src/storage/sync-runs/types.ts +93 -0
  1522. package/src/storage/timeseries/index.ts +7 -0
  1523. package/src/storage/timeseries/store.ts +214 -0
  1524. package/src/storage/timeseries/types.ts +57 -0
  1525. package/src/storage/transaction.ts +56 -0
  1526. package/src/storage/types.ts +299 -0
  1527. package/src/storage/webhook-deliveries/in-memory.ts +108 -0
  1528. package/src/storage/webhook-deliveries/index.ts +9 -0
  1529. package/src/storage/webhook-deliveries/types.ts +41 -0
  1530. package/src/storage/webhook-runs/errors.ts +6 -0
  1531. package/src/storage/webhook-runs/in-memory.ts +131 -0
  1532. package/src/storage/webhook-runs/index.ts +12 -0
  1533. package/src/storage/webhook-runs/types.ts +69 -0
  1534. package/src/storage/workflow-interventions/errors.ts +6 -0
  1535. package/src/storage/workflow-interventions/in-memory.ts +192 -0
  1536. package/src/storage/workflow-interventions/index.ts +14 -0
  1537. package/src/storage/workflow-interventions/types.ts +100 -0
  1538. package/src/storage/workflow-runs/errors.ts +6 -0
  1539. package/src/storage/workflow-runs/in-memory.ts +777 -0
  1540. package/src/storage/workflow-runs/index.ts +45 -0
  1541. package/src/storage/workflow-runs/types.ts +344 -0
  1542. package/src/syncs/builders.ts +101 -0
  1543. package/src/syncs/errors.ts +3 -0
  1544. package/src/syncs/index.ts +22 -0
  1545. package/src/syncs/request.ts +91 -0
  1546. package/src/syncs/types.ts +136 -0
  1547. package/src/testing/agent-storage-contract.ts +824 -0
  1548. package/src/testing/auth-storage-contract.ts +1932 -0
  1549. package/src/testing/blob-storage-contract.ts +108 -0
  1550. package/src/testing/broker-contract.ts +819 -0
  1551. package/src/testing/effective-storage-contract.ts +182 -0
  1552. package/src/testing/index.ts +65 -0
  1553. package/src/testing/lake-storage-contract.ts +699 -0
  1554. package/src/testing/materialization-failure-contract.ts +66 -0
  1555. package/src/testing/materializer-fixture.ts +119 -0
  1556. package/src/testing/materializer-storage-contract.ts +389 -0
  1557. package/src/testing/object-query-contract.ts +1205 -0
  1558. package/src/testing/ontology-contract-fixture.ts +192 -0
  1559. package/src/testing/ontology-storage-contract.ts +922 -0
  1560. package/src/testing/projection-run-storage-contract.ts +372 -0
  1561. package/src/testing/queues-contract.ts +634 -0
  1562. package/src/testing/sandboxes-contract.ts +404 -0
  1563. package/src/webhooks/builders.ts +154 -0
  1564. package/src/webhooks/connector.ts +19 -0
  1565. package/src/webhooks/errors.ts +3 -0
  1566. package/src/webhooks/index.ts +25 -0
  1567. package/src/webhooks/registry.ts +127 -0
  1568. package/src/webhooks/types.ts +98 -0
  1569. package/src/webhooks/unverified.ts +82 -0
  1570. package/src/workers/errors.ts +25 -0
  1571. package/src/workers/index.ts +6 -0
  1572. package/src/workers/queue-delivery.ts +309 -0
  1573. package/src/workers/queue-worker.ts +260 -0
  1574. package/src/workers/worker.ts +87 -0
  1575. package/src/workflows/builders.ts +471 -0
  1576. package/src/workflows/errors.ts +13 -0
  1577. package/src/workflows/index.ts +94 -0
  1578. package/src/workflows/request.ts +161 -0
  1579. package/src/workflows/runtime.ts +68 -0
  1580. package/src/workflows/snapshot.ts +383 -0
  1581. package/src/workflows/types.ts +781 -0
  1582. package/src/workflows/validation.ts +572 -0
@@ -0,0 +1,840 @@
1
+ /**
2
+ * Core type definitions for the runtime layer.
3
+ *
4
+ * Hierarchy: Broker + Storage + Queues → Sixb → ObjectSet → ObjectByIdHandle
5
+ * Each level narrows generic parameters so downstream code stays type-safe.
6
+ */
7
+ import type { ActionDefinition, ActionParamsConfig, ActionRegistry, ActionsRuntime, InferActionParams, RequestActionAndWaitInput, RequestActionInput, RequestActionResult } from "../actions";
8
+ import type { AgentsRuntime, RequestAgentRunInput, RequestAgentRunResult } from "../agents";
9
+ import type { AuthRuntime } from "../auth";
10
+ import type { AuthorizationContext } from "../authorization";
11
+ import type { BlobStorage } from "../blob-storage";
12
+ import type { Broker } from "../broker";
13
+ import type { ConnectorAdapter, ConnectorClient, ConnectorDefinition } from "../connectors";
14
+ import type { DatasetDefinition } from "../datasets";
15
+ import type { DomainEventLog } from "../events";
16
+ import type { LakeStorage } from "../lake-storage";
17
+ import type { LogsRuntime } from "../logging";
18
+ import type { OntologyMaintenanceHandle, OntologyOperationalStatus, SixbReadiness } from "../maintenance";
19
+ import type { ObjectQuery, ObjectQueryExplanation, ObjectQueryPredicateComparison, ObjectQueryPredicateContains, ObjectQueryPredicateExists, ObjectQueryPredicateGroup, ObjectQueryPredicateIn, ObjectQueryPredicateNot, ObjectQuerySortDirection, ValidatedObjectQuery } from "../objects/query";
20
+ import type { ObjectLinkTargetType, ObjectRef, ObjectType, Property, ValueType } from "../ontology";
21
+ import type { InferObjectProperties, InferPropertyUnit, InferPropertyValue, InferTelemetryBatchProperties, InferTelemetryPropertyIds } from "../ontology/inference";
22
+ import type { OntologyDocumentInput, OntologyRegistry, OntologySource } from "../ontology/registry";
23
+ import type { LinkToken, ObjectTypeWithPropertyTokens, PropertyToken } from "../ontology/tokens";
24
+ import type { PipelineRunRequestResult, RequestPipelineRunInput } from "../pipelines/request";
25
+ import type { PipelineDefinition } from "../pipelines/types";
26
+ import type { LinkProjectionDefinition, ObjectProjectionDefinition, ProjectionDefinition, TelemetryProjectionDefinition } from "../projections/types";
27
+ import type { Queues } from "../queues";
28
+ import type { RuleDefinition } from "../rules";
29
+ import type { SandboxFactory } from "../sandboxes";
30
+ import type { ScheduleDefinition } from "../schedules";
31
+ import type { SecurityRegistry } from "../security";
32
+ import type { ActionRunRecord, ObjectLinkRow, ObjectRow, Storage } from "../storage";
33
+ import type { RequestSyncRunInput, SyncDefinition, SyncRunRequestResult } from "../syncs";
34
+ import type { RegisteredWebhook } from "../webhooks";
35
+ import type { RequestWorkflowRunInput, WorkflowRunRequestResult, WorkflowsRuntime } from "../workflows";
36
+ import type { ScopedSixb } from "./scoped";
37
+ /**
38
+ * Shared runtime context holding infrastructure + ontology registry.
39
+ *
40
+ * Built once by `Sixb` at construction time and threaded to `objects/`
41
+ * service and leaf functions.
42
+ *
43
+ * `Sixb` satisfies this structurally — callers can pass `sixb` directly
44
+ * wherever a `SixbRuntimeContext` is expected.
45
+ */
46
+ export interface SixbRuntimeContext {
47
+ readonly projectId: string;
48
+ readonly ontology: OntologyRegistry;
49
+ readonly actionRegistry: ActionRegistry;
50
+ readonly events: DomainEventLog;
51
+ readonly storage: Storage;
52
+ readonly lakeStorage: LakeStorage;
53
+ readonly blobStorage: BlobStorage;
54
+ readonly queues: Queues;
55
+ readonly sandboxes?: SandboxFactory;
56
+ readonly rules?: readonly RuleDefinition[];
57
+ /**
58
+ * Principal scope for this context. Absent on privileged runtimes (raw
59
+ * `sixb`, syncs, workers, tests); present on contexts created by
60
+ * `sixb.as(context)`, where data operations enforce default-deny grants.
61
+ */
62
+ readonly authorization?: AuthorizationContext;
63
+ }
64
+ /**
65
+ * Per-item result for batch operations.
66
+ *
67
+ * Allows batch ops to report successes and failures per item without throwing,
68
+ * so callers (e.g. projection executors) can map failures to per-row issues.
69
+ */
70
+ export type BatchItemResult<T> = {
71
+ readonly ok: true;
72
+ readonly value: T;
73
+ } | {
74
+ readonly ok: false;
75
+ readonly error: Error;
76
+ };
77
+ export type { OntologyDocumentInput, OntologySource };
78
+ type ObjectTypeFromSource<TSource> = TSource extends {
79
+ objectTypes: infer TObjectTypes extends readonly ObjectTypeWithPropertyTokens[];
80
+ } ? TObjectTypes[number] : TSource extends ObjectTypeWithPropertyTokens ? TSource : never;
81
+ type ValueTypeFromSource<TSource> = TSource extends {
82
+ valueTypes: infer TValueTypes extends readonly ValueType[];
83
+ } ? TValueTypes[number] : never;
84
+ export type RegisteredObjectType<TOntologySources extends readonly OntologySource[]> = ObjectTypeFromSource<TOntologySources[number]>;
85
+ export type RegisteredValueTypes<TOntologySources extends readonly OntologySource[]> = readonly ValueTypeFromSource<TOntologySources[number]>[];
86
+ export type TwinObject<TObjectType extends ObjectType, TValueTypes extends readonly ValueType[]> = {
87
+ primaryId: string;
88
+ objectTypeId: TObjectType["id"];
89
+ properties: InferObjectProperties<TObjectType, TValueTypes>;
90
+ createdAt: Date;
91
+ updatedAt: Date;
92
+ };
93
+ type MaterializedObjectRow<TObjectType extends Pick<ObjectType, "id" | "properties">, TValueTypes extends readonly ValueType[]> = {
94
+ primaryId: string;
95
+ objectTypeId: TObjectType["id"];
96
+ properties: InferObjectProperties<TObjectType, TValueTypes>;
97
+ createdAt: Date;
98
+ updatedAt: Date;
99
+ };
100
+ type Simplify<T> = {
101
+ [K in keyof T]: T[K];
102
+ } & {};
103
+ export type { ObjectRef };
104
+ /**
105
+ * Resolve link target type id for ObjectRef:
106
+ * - `string[]` → union of elements
107
+ * - `"*"` → any string
108
+ * - `string` → literal
109
+ */
110
+ type ResolveTargetTypeId<T> = T extends readonly string[] ? T[number] : T extends "*" ? string : T;
111
+ /**
112
+ * Link token constrained to the given object type.
113
+ *
114
+ * This powers `byId(...).link(Room.l.hasThermostat, target)` style APIs.
115
+ */
116
+ type LinkTokenForObjectType<TObjectType extends ObjectTypeWithPropertyTokens> = LinkToken<TObjectType["id"], TObjectType["links"][number]["id"], TObjectType["links"][number]["targetObjectTypeId"], TObjectType["links"][number]>;
117
+ type PropertyById<TObjectType extends ObjectTypeWithPropertyTokens, TPropertyId extends TObjectType["properties"][number]["id"]> = Extract<TObjectType["properties"][number], {
118
+ id: TPropertyId;
119
+ }>;
120
+ type PropertyWhereValue<TObjectType extends ObjectTypeWithPropertyTokens, TPropertyId extends TObjectType["properties"][number]["id"], TValueTypes extends readonly ValueType[]> = InferPropertyValue<PropertyById<TObjectType, TPropertyId>, TValueTypes>;
121
+ type PropertyWhereContainsValue<TObjectType extends ObjectTypeWithPropertyTokens, TPropertyId extends TObjectType["properties"][number]["id"], TValueTypes extends readonly ValueType[]> = NonNullable<PropertyWhereValue<TObjectType, TPropertyId, TValueTypes>> extends string ? string : NonNullable<PropertyWhereValue<TObjectType, TPropertyId, TValueTypes>> extends readonly (infer TItem)[] ? TItem : NonNullable<PropertyWhereValue<TObjectType, TPropertyId, TValueTypes>> extends Record<string, unknown> ? string : never;
122
+ type PropertyWhereComparisonClause<TObjectType extends ObjectTypeWithPropertyTokens, TPropertyId extends TObjectType["properties"][number]["id"], TValueTypes extends readonly ValueType[]> = Omit<ObjectQueryPredicateComparison, "propertyId" | "value"> & {
123
+ propertyId: TPropertyId;
124
+ value: PropertyWhereValue<TObjectType, TPropertyId, TValueTypes>;
125
+ };
126
+ type PropertyWhereInClause<TObjectType extends ObjectTypeWithPropertyTokens, TPropertyId extends TObjectType["properties"][number]["id"], TValueTypes extends readonly ValueType[]> = Omit<ObjectQueryPredicateIn, "propertyId" | "values"> & {
127
+ propertyId: TPropertyId;
128
+ values: readonly PropertyWhereValue<TObjectType, TPropertyId, TValueTypes>[];
129
+ };
130
+ type PropertyWhereExistsClause<TObjectType extends ObjectTypeWithPropertyTokens, TPropertyId extends TObjectType["properties"][number]["id"]> = Omit<ObjectQueryPredicateExists, "propertyId"> & {
131
+ propertyId: TPropertyId;
132
+ };
133
+ type PropertyWhereContainsClause<TObjectType extends ObjectTypeWithPropertyTokens, TPropertyId extends TObjectType["properties"][number]["id"], TValueTypes extends readonly ValueType[]> = Omit<ObjectQueryPredicateContains, "propertyId" | "value"> & {
134
+ propertyId: TPropertyId;
135
+ value: PropertyWhereContainsValue<TObjectType, TPropertyId, TValueTypes>;
136
+ };
137
+ /** Predicate operators exposed on `where` builder properties. */
138
+ type PropertyPredicate<TObjectType extends ObjectTypeWithPropertyTokens, TPropertyId extends TObjectType["properties"][number]["id"], TValueTypes extends readonly ValueType[]> = {
139
+ eq(value: PropertyWhereValue<TObjectType, TPropertyId, TValueTypes>): PropertyWhereComparisonClause<TObjectType, TPropertyId, TValueTypes> & {
140
+ op: "eq";
141
+ };
142
+ neq(value: PropertyWhereValue<TObjectType, TPropertyId, TValueTypes>): PropertyWhereComparisonClause<TObjectType, TPropertyId, TValueTypes> & {
143
+ op: "neq";
144
+ };
145
+ lt(value: PropertyWhereValue<TObjectType, TPropertyId, TValueTypes>): PropertyWhereComparisonClause<TObjectType, TPropertyId, TValueTypes> & {
146
+ op: "lt";
147
+ };
148
+ lte(value: PropertyWhereValue<TObjectType, TPropertyId, TValueTypes>): PropertyWhereComparisonClause<TObjectType, TPropertyId, TValueTypes> & {
149
+ op: "lte";
150
+ };
151
+ gt(value: PropertyWhereValue<TObjectType, TPropertyId, TValueTypes>): PropertyWhereComparisonClause<TObjectType, TPropertyId, TValueTypes> & {
152
+ op: "gt";
153
+ };
154
+ gte(value: PropertyWhereValue<TObjectType, TPropertyId, TValueTypes>): PropertyWhereComparisonClause<TObjectType, TPropertyId, TValueTypes> & {
155
+ op: "gte";
156
+ };
157
+ in(values: readonly PropertyWhereValue<TObjectType, TPropertyId, TValueTypes>[]): PropertyWhereInClause<TObjectType, TPropertyId, TValueTypes>;
158
+ exists(value?: boolean): PropertyWhereExistsClause<TObjectType, TPropertyId>;
159
+ contains(value: PropertyWhereContainsValue<TObjectType, TPropertyId, TValueTypes>): PropertyWhereContainsClause<TObjectType, TPropertyId, TValueTypes>;
160
+ };
161
+ type PropertyWhereClause<TObjectType extends ObjectTypeWithPropertyTokens, TValueTypes extends readonly ValueType[]> = HasKnownPropertyIds<TObjectType> extends false ? ObjectQueryPredicateComparison | ObjectQueryPredicateIn | ObjectQueryPredicateExists | ObjectQueryPredicateContains : {
162
+ [TPropertyId in TObjectType["properties"][number]["id"]]: PropertyWhereComparisonClause<TObjectType, TPropertyId, TValueTypes> | PropertyWhereInClause<TObjectType, TPropertyId, TValueTypes> | PropertyWhereExistsClause<TObjectType, TPropertyId> | PropertyWhereContainsClause<TObjectType, TPropertyId, TValueTypes>;
163
+ }[TObjectType["properties"][number]["id"]];
164
+ /**
165
+ * Predicate operators for an object type whose properties are not statically
166
+ * known, such as after traversing a link whose target type is unresolved.
167
+ * Mirrors `PropertyPredicate` with IR-level value types, and keeps the type
168
+ * shallow — instantiating the typed predicate map over the broad `Property`
169
+ * union overflows TypeScript's recursion limits.
170
+ */
171
+ type UntypedPropertyPredicate = {
172
+ eq(value: unknown): ObjectQueryPredicateComparison & {
173
+ op: "eq";
174
+ };
175
+ neq(value: unknown): ObjectQueryPredicateComparison & {
176
+ op: "neq";
177
+ };
178
+ lt(value: unknown): ObjectQueryPredicateComparison & {
179
+ op: "lt";
180
+ };
181
+ lte(value: unknown): ObjectQueryPredicateComparison & {
182
+ op: "lte";
183
+ };
184
+ gt(value: unknown): ObjectQueryPredicateComparison & {
185
+ op: "gt";
186
+ };
187
+ gte(value: unknown): ObjectQueryPredicateComparison & {
188
+ op: "gte";
189
+ };
190
+ in(values: readonly unknown[]): ObjectQueryPredicateIn;
191
+ exists(value?: boolean): ObjectQueryPredicateExists;
192
+ contains(value: unknown): ObjectQueryPredicateContains;
193
+ };
194
+ /** True when the object type's property ids are statically known literals. */
195
+ type HasKnownPropertyIds<TObjectType extends ObjectTypeWithPropertyTokens> = string extends TObjectType["properties"][number]["id"] ? false : true;
196
+ /** Typed ObjectSet where predicate. Serialized shape matches object query IR predicates. */
197
+ export type ObjectWhereClause<TObjectType extends ObjectTypeWithPropertyTokens, TValueTypes extends readonly ValueType[]> = PropertyWhereClause<TObjectType, TValueTypes> | (Omit<ObjectQueryPredicateGroup, "items"> & {
198
+ items: readonly ObjectWhereClause<TObjectType, TValueTypes>[];
199
+ }) | (Omit<ObjectQueryPredicateNot, "item"> & {
200
+ item: ObjectWhereClause<TObjectType, TValueTypes>;
201
+ });
202
+ /**
203
+ * Builder object passed to object query `where` callbacks.
204
+ *
205
+ * Example: `(r) => r.p.externalId.eq("RM-101")`
206
+ */
207
+ export type ObjectWhereBuilder<TObjectType extends ObjectTypeWithPropertyTokens, TValueTypes extends readonly ValueType[]> = {
208
+ p: HasKnownPropertyIds<TObjectType> extends false ? Record<string, UntypedPropertyPredicate> : {
209
+ [TPropertyId in TObjectType["properties"][number]["id"]]: PropertyPredicate<TObjectType, TPropertyId, TValueTypes>;
210
+ };
211
+ and(...items: readonly ObjectWhereClause<TObjectType, TValueTypes>[]): ObjectWhereClause<TObjectType, TValueTypes>;
212
+ or(...items: readonly ObjectWhereClause<TObjectType, TValueTypes>[]): ObjectWhereClause<TObjectType, TValueTypes>;
213
+ not(item: ObjectWhereClause<TObjectType, TValueTypes>): ObjectWhereClause<TObjectType, TValueTypes>;
214
+ };
215
+ export type TelemetryPropertyToken<TObjectType extends ObjectTypeWithPropertyTokens> = TObjectType["p"][InferTelemetryPropertyIds<TObjectType>];
216
+ type AnyPropertyToken = PropertyToken<string, string, Property>;
217
+ type ObjectSetPropertyId<TObjectType extends ObjectTypeWithPropertyTokens> = TObjectType["properties"][number]["id"];
218
+ export type ObjectSetQueryPropertyToken<TObjectType extends ObjectTypeWithPropertyTokens> = TObjectType["p"][ObjectSetPropertyId<TObjectType>];
219
+ /**
220
+ * Unit requirement is conditional:
221
+ * - if property has a semantic type, unit is required
222
+ * - otherwise unit is disallowed
223
+ */
224
+ type TelemetryUnitField<TToken extends AnyPropertyToken, TValueTypes extends readonly ValueType[]> = InferPropertyUnit<TToken["property"], TValueTypes> extends never ? {
225
+ unit?: never;
226
+ } : {
227
+ unit: InferPropertyUnit<TToken["property"], TValueTypes>;
228
+ };
229
+ export type TelemetryAppendInput<TToken extends AnyPropertyToken, TValueTypes extends readonly ValueType[]> = {
230
+ value: InferPropertyValue<TToken["property"], TValueTypes>;
231
+ at: Date;
232
+ } & TelemetryUnitField<TToken, TValueTypes>;
233
+ export interface TelemetryHistoryInput {
234
+ readonly from?: Date;
235
+ readonly to?: Date;
236
+ readonly limit?: number;
237
+ readonly order?: "asc" | "desc";
238
+ }
239
+ /**
240
+ * One object's telemetry for one property, readable and writable.
241
+ *
242
+ * Named a channel rather than an appender because telemetry is not write-only: `history()` reads the
243
+ * same series back, typed through the same token, instead of sending the caller under the typed
244
+ * surface to `sixb.storage.timeseries`.
245
+ */
246
+ export type TelemetryChannel<TToken extends AnyPropertyToken, TValueTypes extends readonly ValueType[]> = {
247
+ append(input: TelemetryAppendInput<TToken, TValueTypes>): Promise<void>;
248
+ /**
249
+ * Points for this series, oldest first unless `order: "desc"`.
250
+ *
251
+ * The default matches `storage.timeseries.getHistoryBatch`, deliberately: a typed read that ordered
252
+ * differently from the contract underneath it would be its own trap.
253
+ *
254
+ * The point shape is written inline rather than extracted into a named alias. One more level of
255
+ * alias indirection around `InferPropertyValue` in this output position overflows TS's instantiation
256
+ * depth (TS2589) in consumers as ordinary as `points.map(...)` — the same budget the note on
257
+ * `TwinObject` describes. `unit` is inferred through the same token as `append` writes it, rather
258
+ * than widened to `string`: a read that kept `value` precise and gave up on `unit` would be an
259
+ * arbitrary line, and both are the current ontology's view of a series it validated on write.
260
+ */
261
+ history(input?: TelemetryHistoryInput): Promise<readonly {
262
+ readonly value: InferPropertyValue<TToken["property"], TValueTypes>;
263
+ readonly at: Date;
264
+ readonly unit?: InferPropertyUnit<TToken["property"], TValueTypes>;
265
+ }[]>;
266
+ };
267
+ type TypedActionReference<TParams extends ActionParamsConfig = ActionParamsConfig> = {
268
+ readonly id: string;
269
+ readonly params: TParams;
270
+ };
271
+ type TypedActionParams<TAction extends TypedActionReference> = TAction extends TypedActionReference<infer TParams> ? InferActionParams<TParams> : never;
272
+ export type ListResult<T> = {
273
+ objects: T[];
274
+ hasMore: boolean;
275
+ nextPageToken?: string;
276
+ total: number;
277
+ };
278
+ export type ListResultWithoutTotal<T> = {
279
+ objects: T[];
280
+ hasMore: boolean;
281
+ nextPageToken?: string;
282
+ total?: undefined;
283
+ };
284
+ export type ObjectQueryListOptions = {
285
+ includeTotal?: boolean;
286
+ };
287
+ export type ObjectQueryFacetInput<TObjectType extends ObjectTypeWithPropertyTokens> = {
288
+ property: ObjectSetQueryPropertyToken<TObjectType>;
289
+ limit: number;
290
+ };
291
+ export type ObjectQueryFacetBucket = {
292
+ value: unknown;
293
+ count: number;
294
+ };
295
+ export type ObjectQueryFacetResult = {
296
+ propertyId: string;
297
+ buckets: ObjectQueryFacetBucket[];
298
+ };
299
+ export type ObjectSetListInput = {
300
+ idPrefix?: string;
301
+ idSuffix?: string;
302
+ updatedAfter?: Date;
303
+ updatedBefore?: Date;
304
+ createdAfter?: Date;
305
+ createdBefore?: Date;
306
+ limit?: number;
307
+ offset?: number;
308
+ orderBy?: "createdAt" | "updatedAt" | "primaryId";
309
+ order?: "asc" | "desc";
310
+ };
311
+ type LinkTargetObjectTypeIdValue = string | readonly string[];
312
+ type LinkTargetObjectTypeId<TLinkToken> = TLinkToken extends LinkToken<string, string, infer TTargetObjectTypeId> ? TTargetObjectTypeId extends readonly (infer TTargetId extends string)[] ? TTargetId : TTargetObjectTypeId extends string ? TTargetObjectTypeId : never : never;
313
+ type ObjectTypeForId<TRegisteredObjectTypes extends ObjectTypeWithPropertyTokens, TObjectTypeId extends string> = [Extract<TRegisteredObjectTypes, {
314
+ id: TObjectTypeId;
315
+ }>] extends [never] ? ObjectTypeWithPropertyTokens : Extract<TRegisteredObjectTypes, {
316
+ id: TObjectTypeId;
317
+ }>;
318
+ type DirectObjectTypeForLink<TLinkToken> = TLinkToken extends LinkToken<string, string, LinkTargetObjectTypeIdValue, infer TLink> ? Extract<ObjectLinkTargetType<TLink>, ObjectTypeWithPropertyTokens> : never;
319
+ type ObjectTypeForLinkTarget<TRegisteredObjectTypes extends ObjectTypeWithPropertyTokens, TLinkToken> = [DirectObjectTypeForLink<TLinkToken>] extends [never] ? ObjectTypeForId<TRegisteredObjectTypes, LinkTargetObjectTypeId<TLinkToken>> : DirectObjectTypeForLink<TLinkToken>;
320
+ /**
321
+ * True when the target type is a concrete ontology type rather than the degraded
322
+ * generic base. Direct ObjectType links resolve before this point; unresolved
323
+ * id-only refs fall back to the base type, whose property ids are `string`.
324
+ * Instantiating the typed token map over the broad `Property` union there
325
+ * overflows TypeScript (the same reason `UntypedPropertyPredicate` exists). The
326
+ * expand option/sort types degrade to a loose shape in that case so unresolved
327
+ * client paths stay shallow instead of failing.
328
+ */
329
+ type HasKnownObjectType<TObjectType extends ObjectTypeWithPropertyTokens> = string extends TObjectType["id"] ? false : true;
330
+ /** Deterministic top-N ordering for a bounded `"many"` expansion, typed against the target type. */
331
+ export type ObjectExpansionSort<TObjectType extends ObjectTypeWithPropertyTokens> = HasKnownObjectType<TObjectType> extends false ? {
332
+ property: PropertyToken;
333
+ direction?: ObjectQuerySortDirection;
334
+ } : {
335
+ property: ObjectSetQueryPropertyToken<TObjectType>;
336
+ direction?: ObjectQuerySortDirection;
337
+ };
338
+ /** Options for a single `.expand(...)` of an outgoing link. */
339
+ export type ObjectExpandOptions<TObjectType extends ObjectTypeWithPropertyTokens> = {
340
+ /** Bound a `"many"` expansion to the top-N target objects per parent. */
341
+ limit?: number;
342
+ /** Order the target objects of a bounded `"many"` expansion. */
343
+ orderBy?: readonly ObjectExpansionSort<TObjectType>[];
344
+ };
345
+ /**
346
+ * Cardinality declared on a link token's underlying link; absent cardinality is
347
+ * treated as `"many"`, matching the executor (`link.cardinality ?? "many"`) and
348
+ * the ontology default.
349
+ */
350
+ type LinkTokenCardinality<TLinkToken> = TLinkToken extends LinkToken<string, string, LinkTargetObjectTypeIdValue, infer TLink> ? TLink extends {
351
+ cardinality: infer TCardinality extends string;
352
+ } ? TCardinality : "many" : "many";
353
+ type LinkTokenId<TLinkToken> = TLinkToken extends LinkToken<string, infer TLinkId, LinkTargetObjectTypeIdValue> ? TLinkId : never;
354
+ type LinkTokenSourceObjectTypeId<TLinkToken> = TLinkToken extends LinkToken<infer TObjectTypeId, string, LinkTargetObjectTypeIdValue> ? TObjectTypeId : string;
355
+ type ObjectLinkCardinality<TLink> = TLink extends {
356
+ cardinality: infer TCardinality extends string;
357
+ } ? TCardinality : "many";
358
+ type ObjectLinkTarget<TRegisteredObjectTypes extends ObjectTypeWithPropertyTokens, TLink> = [
359
+ Extract<ObjectLinkTargetType<TLink>, ObjectTypeWithPropertyTokens>
360
+ ] extends [never] ? TLink extends {
361
+ targetObjectTypeId: infer TTargetObjectTypeId extends LinkTargetObjectTypeIdValue;
362
+ } ? ObjectTypeForId<TRegisteredObjectTypes, ResolveTargetTypeId<TTargetObjectTypeId>> : ObjectTypeWithPropertyTokens : Extract<ObjectLinkTargetType<TLink>, ObjectTypeWithPropertyTokens>;
363
+ type ObjectLinkById<TObjectType extends Pick<ObjectType, "links">, TLinkId extends string> = Extract<TObjectType["links"][number], {
364
+ id: TLinkId;
365
+ }>;
366
+ type HasKnownObjectLinkIds<TObjectType extends Pick<ObjectType, "links">> = string extends TObjectType["links"][number]["id"] ? false : true;
367
+ /**
368
+ * A branded accumulator entry for one expanded link. Unconstrained on purpose —
369
+ * keeping recursion out of constraints is what avoids TS2589.
370
+ */
371
+ type ExpansionNode<TLinkToken, TRegisteredObjectTypes, TTarget, TCardinality, TChildren> = {
372
+ readonly __linkToken: TLinkToken;
373
+ readonly __registeredObjectTypes: TRegisteredObjectTypes;
374
+ readonly __target: TTarget;
375
+ readonly __cardinality: TCardinality;
376
+ readonly __children: TChildren;
377
+ };
378
+ /** The single-key accumulator contribution of one `.expand(link, …)` call. */
379
+ type ExpansionEntry<TLinkToken extends LinkToken<string, string, LinkTargetObjectTypeIdValue>, TRegisteredObjectTypes extends ObjectTypeWithPropertyTokens, TChild> = {
380
+ [K in TLinkToken["id"]]: ExpansionNode<TLinkToken, TRegisteredObjectTypes, ObjectTypeForLinkTarget<TRegisteredObjectTypes, TLinkToken>, LinkTokenCardinality<TLinkToken>, TChild>;
381
+ };
382
+ type ExpansionNodeForSource<TNode, TObjectType extends Pick<ObjectType, "id" | "links">> = TNode extends ExpansionNode<infer TLinkToken, infer TRegisteredObjectTypes extends ObjectTypeWithPropertyTokens, infer TTarget, infer TCardinality, infer TChildren> ? LinkTokenId<TLinkToken> extends infer TLinkId extends string ? HasKnownObjectLinkIds<TObjectType> extends true ? [ObjectLinkById<TObjectType, TLinkId>] extends [never] ? never : ExpansionNode<TLinkToken, TRegisteredObjectTypes, ObjectLinkTarget<TRegisteredObjectTypes, ObjectLinkById<TObjectType, TLinkId>>, ObjectLinkCardinality<ObjectLinkById<TObjectType, TLinkId>>, TChildren> : LinkTokenSourceObjectTypeId<TLinkToken> extends TObjectType["id"] ? ExpansionNode<TLinkToken, TRegisteredObjectTypes, TTarget, TCardinality, TChildren> : never : never : never;
383
+ type ExpansionLinksForSource<TLinks, TObjectType extends Pick<ObjectType, "id" | "links">> = {
384
+ [K in keyof TLinks as [ExpansionNodeForSource<TLinks[K], TObjectType>] extends [never] ? never : K]: ExpansionNodeForSource<TLinks[K], TObjectType>;
385
+ };
386
+ /** Materialize one accumulated expansion entry into its row value. */
387
+ type ExpandedLinkType<TNode, TValueTypes extends readonly ValueType[]> = TNode extends ExpansionNode<unknown, infer TRegisteredObjectTypes extends ObjectTypeWithPropertyTokens, infer TTarget, infer TCardinality, infer TChildren> ? TCardinality extends "one" ? ExpandedRowType<TTarget, TChildren, TValueTypes, TRegisteredObjectTypes> | null : ExpandedRowType<TTarget, TChildren, TValueTypes, TRegisteredObjectTypes>[] : never;
388
+ /**
389
+ * An expanded child row: the target object, optional edge `linkProperties` (the
390
+ * executor attaches it only when the relationship carries metadata), and its own
391
+ * nested `links` (present only when the child was itself expanded). The recursion
392
+ * is confined to this lazily-evaluated position.
393
+ */
394
+ /**
395
+ * Loud row substituted for a `.expand()` whose target type is MISSING from an
396
+ * otherwise-present ontology manifest (a stale manifest, or a wrong link target
397
+ * id). Reading a real property is then a compile error pointing at the fix,
398
+ * instead of the old silent `Record<string, unknown>`. The no-manifest loose
399
+ * default stays graceful — this only fires when the registry is concrete yet the
400
+ * target id is absent, i.e. precision was expected but lost.
401
+ */
402
+ type UnresolvedExpansionRow = {
403
+ primaryId: string;
404
+ objectTypeId: string;
405
+ properties: {
406
+ readonly sixb_unresolvedExpansionTarget: "This expansion target is not in the generated ontology manifest. Run `sixb build` / `dev` / `check` to regenerate types, or fix the link's target id.";
407
+ };
408
+ createdAt: Date;
409
+ updatedAt: Date;
410
+ };
411
+ type ExpandedRowType<TTarget, TChildren, TValueTypes extends readonly ValueType[], TRegisteredObjectTypes extends ObjectTypeWithPropertyTokens> = TTarget extends Pick<ObjectType, "id" | "properties" | "links"> ? string extends TTarget["id"] ? string extends TRegisteredObjectTypes["id"] ? ExpandedRowForSource<TTarget, TValueTypes, ExpansionLinksForSource<TChildren, TTarget>, {
412
+ linkProperties?: Record<string, unknown>;
413
+ }> : UnresolvedExpansionRow : ExpandedRowForSource<TTarget, TValueTypes, ExpansionLinksForSource<TChildren, TTarget>, {
414
+ linkProperties?: Record<string, unknown>;
415
+ }> : never;
416
+ type ExpandedRowForSource<TObjectType extends Pick<ObjectType, "id" | "properties" | "links">, TValueTypes extends readonly ValueType[], TLinks, TExtra = unknown> = Simplify<MaterializedObjectRow<TObjectType, TValueTypes> & TExtra & ([keyof TLinks] extends [never] ? unknown : {
417
+ links: {
418
+ [K in keyof TLinks]: ExpandedLinkType<TLinks[K], TValueTypes>;
419
+ };
420
+ })>;
421
+ /**
422
+ * The terminal row of a query: the matched object, plus a typed `links` map once
423
+ * the query accumulated expansions. A query with no `.expand(...)` returns the
424
+ * plain materialized row, so existing `list`/`first` consumers are unchanged.
425
+ */
426
+ export type ObjectQueryRow<TObjectType extends ObjectTypeWithPropertyTokens, TValueTypes extends readonly ValueType[], TLinks> = TObjectType extends ObjectTypeWithPropertyTokens ? ExpandedRowForSource<TObjectType, TValueTypes, ExpansionLinksForSource<TLinks, TObjectType>> : never;
427
+ /**
428
+ * Builder passed to the nested `.expand(..., (e) => …)` callback. Exposes only
429
+ * `expand`, resolving the next target type from direct metadata or the id
430
+ * registry so deeper hops stay typed and accumulating `TAccumulated` so the
431
+ * nested `.links` shape is recovered from the callback's return.
432
+ *
433
+ * A type alias (not an interface) so relating two instantiations stays
434
+ * structural — the same discipline `TwinObject` follows to avoid TS2589
435
+ * (see the note above `TwinObject`). The only recursion is in the lazily
436
+ * evaluated return/callback positions.
437
+ *
438
+ * When the target type is the degraded base (an unresolved id-only target), the
439
+ * builder collapses to the untyped, non-generic {@link UntypedExpandBuilder}:
440
+ * nested expansion still works, just without target-specific link/property
441
+ * checking, and — crucially — without the self-referential generic instantiation
442
+ * over the broad base type that would otherwise overflow TypeScript.
443
+ */
444
+ export type ObjectExpandBuilder<TObjectType extends ObjectTypeWithPropertyTokens, TRegisteredObjectTypes extends ObjectTypeWithPropertyTokens, TAccumulated = unknown> = HasKnownObjectType<TObjectType> extends false ? UntypedExpandBuilder : {
445
+ readonly __links?: TAccumulated;
446
+ expand<TLinkToken extends LinkToken<TObjectType["id"], string, LinkTargetObjectTypeIdValue>, TChild = unknown>(link: TLinkToken, build: ObjectExpandNested<TLinkToken, TRegisteredObjectTypes, TChild>): ObjectExpandBuilder<TObjectType, TRegisteredObjectTypes, TAccumulated & ExpansionEntry<TLinkToken, TRegisteredObjectTypes, TChild>>;
447
+ expand<TLinkToken extends LinkToken<TObjectType["id"], string, LinkTargetObjectTypeIdValue>, TChild = unknown>(link: TLinkToken, options?: ObjectExpandOptions<ObjectTypeForLinkTarget<TRegisteredObjectTypes, TLinkToken>>, build?: ObjectExpandNested<TLinkToken, TRegisteredObjectTypes, TChild>): ObjectExpandBuilder<TObjectType, TRegisteredObjectTypes, TAccumulated & ExpansionEntry<TLinkToken, TRegisteredObjectTypes, TChild>>;
448
+ };
449
+ /**
450
+ * Loose expand builder for degraded targets. Non-generic and self-referential,
451
+ * so it never instantiates the typed token machinery over the broad base type.
452
+ * Nested expansions still run; their shape simply degrades to the loose row.
453
+ */
454
+ type UntypedExpandBuilder = {
455
+ expand(link: LinkToken, optionsOrBuild?: ObjectExpandOptions<ObjectTypeWithPropertyTokens> | ((nested: UntypedExpandBuilder) => UntypedExpandBuilder), build?: (nested: UntypedExpandBuilder) => UntypedExpandBuilder): UntypedExpandBuilder;
456
+ };
457
+ /**
458
+ * The nested-expansion callback for a link token's resolved target type. `TChild`
459
+ * is inferred from the returned builder's accumulator, recovering the nested
460
+ * `.links` shape; on the degraded path the builder collapses and `TChild` stays
461
+ * its `unknown` default.
462
+ *
463
+ * Kept a plain (non-conditional) function type on purpose: wrapping the callback
464
+ * in a `TLinkToken extends … ? … : never` conditional blocks inference of
465
+ * `TChild` from the argument, so it would silently fall back to `unknown`.
466
+ */
467
+ type ObjectExpandNested<TLinkToken extends LinkToken<string, string, LinkTargetObjectTypeIdValue>, TRegisteredObjectTypes extends ObjectTypeWithPropertyTokens, TChild> = (nested: ObjectExpandBuilder<ObjectTypeForLinkTarget<TRegisteredObjectTypes, TLinkToken>, TRegisteredObjectTypes>) => ObjectExpandBuilder<ObjectTypeForLinkTarget<TRegisteredObjectTypes, TLinkToken>, TRegisteredObjectTypes, TChild>;
468
+ export interface ObjectQueryBuilder<TObjectType extends ObjectTypeWithPropertyTokens, TRegisteredObjectTypes extends ObjectTypeWithPropertyTokens, TValueTypes extends readonly ValueType[], TLinks = unknown> {
469
+ /** Normalized provider-neutral query IR. */
470
+ readonly ir: ObjectQuery;
471
+ /** Add a typed property predicate at the current object type. */
472
+ where(where: (builder: ObjectWhereBuilder<TObjectType, TValueTypes>) => ObjectWhereClause<TObjectType, TValueTypes> | readonly ObjectWhereClause<TObjectType, TValueTypes>[]): ObjectQueryBuilder<TObjectType, TRegisteredObjectTypes, TValueTypes, TLinks>;
473
+ /** Search configured text fields at the current object type. */
474
+ search(query: string, options?: {
475
+ fields?: readonly ObjectSetQueryPropertyToken<TObjectType>[];
476
+ }): ObjectQueryBuilder<TObjectType, TRegisteredObjectTypes, TValueTypes, TLinks>;
477
+ /** Search a vector property at the current object type. */
478
+ vector(property: ObjectSetQueryPropertyToken<TObjectType>, vector: readonly number[], options: {
479
+ k: number;
480
+ }): ObjectQueryBuilder<TObjectType, TRegisteredObjectTypes, TValueTypes, TLinks>;
481
+ /** Follow an outgoing link and make the linked object type the current result type. */
482
+ traverse<TLinkToken extends LinkToken<TObjectType["id"], string, LinkTargetObjectTypeIdValue>>(link: TLinkToken, options?: {
483
+ direction?: "outgoing";
484
+ }): ObjectQueryBuilder<ObjectTypeForLinkTarget<TRegisteredObjectTypes, TLinkToken>, TRegisteredObjectTypes, TValueTypes>;
485
+ /** Follow an incoming link and make the link source object type the current result type. */
486
+ traverse<TLinkToken extends LinkToken<string, string, TObjectType["id"] | readonly string[]>>(link: TLinkToken, options: {
487
+ direction: "incoming";
488
+ }): ObjectQueryBuilder<ObjectTypeForId<TRegisteredObjectTypes, TLinkToken["objectTypeId"]>, TRegisteredObjectTypes, TValueTypes>;
489
+ /**
490
+ * Attach an outgoing link's target objects to each row under `.links`, without
491
+ * changing the result type — the additive counterpart to `traverse` (which
492
+ * replaces the set). The callback nests deeper hops.
493
+ *
494
+ * Each call widens `TLinks`, so `list`/`first` rows gain a typed `.links` entry
495
+ * for this link (cardinality `"one"` → `Target | null`, `"many"` → `Target[]`,
496
+ * each carrying optional `linkProperties` and its own nested `.links`). Nested
497
+ * targets stay precise when the link uses direct object targets or when the id
498
+ * target resolves through the registry, and otherwise degrade to the loose base.
499
+ */
500
+ expand<TLinkToken extends LinkToken<TObjectType["id"], string, LinkTargetObjectTypeIdValue>, TChild = unknown>(link: TLinkToken, build: ObjectExpandNested<TLinkToken, TRegisteredObjectTypes, TChild>): ObjectQueryBuilder<TObjectType, TRegisteredObjectTypes, TValueTypes, TLinks & ExpansionEntry<TLinkToken, TRegisteredObjectTypes, TChild>>;
501
+ expand<TLinkToken extends LinkToken<TObjectType["id"], string, LinkTargetObjectTypeIdValue>, TChild = unknown>(link: TLinkToken, options?: ObjectExpandOptions<ObjectTypeForLinkTarget<TRegisteredObjectTypes, TLinkToken>>, build?: ObjectExpandNested<TLinkToken, TRegisteredObjectTypes, TChild>): ObjectQueryBuilder<TObjectType, TRegisteredObjectTypes, TValueTypes, TLinks & ExpansionEntry<TLinkToken, TRegisteredObjectTypes, TChild>>;
502
+ /** Add property ordering at the current object type. */
503
+ orderBy(property: ObjectSetQueryPropertyToken<TObjectType>, direction?: ObjectQuerySortDirection): ObjectQueryBuilder<TObjectType, TRegisteredObjectTypes, TValueTypes, TLinks>;
504
+ /** Add relevance ordering for providers that support ranked search. */
505
+ orderByRelevance(direction?: ObjectQuerySortDirection): ObjectQueryBuilder<TObjectType, TRegisteredObjectTypes, TValueTypes, TLinks>;
506
+ /** Bound the result count. */
507
+ limit(limit: number): ObjectQueryBuilder<TObjectType, TRegisteredObjectTypes, TValueTypes, TLinks>;
508
+ /** Request one page of results. */
509
+ page(input: {
510
+ pageSize: number;
511
+ pageToken?: string;
512
+ }): ObjectQueryBuilder<TObjectType, TRegisteredObjectTypes, TValueTypes, TLinks>;
513
+ /** Validate this query against the registered ontology. */
514
+ validate(): ValidatedObjectQuery;
515
+ /** Return a provider-neutral explanation tree for this query. */
516
+ explain(): ObjectQueryExplanation;
517
+ /** Format `explain()` as a compact diagnostic string. */
518
+ formatExplanation(): string;
519
+ /** Execute this query and return matching objects (rows carry `.links` when expanded). */
520
+ list(): Promise<ListResult<ObjectQueryRow<TObjectType, TValueTypes, TLinks>>>;
521
+ list(options: {
522
+ includeTotal: false;
523
+ }): Promise<ListResultWithoutTotal<ObjectQueryRow<TObjectType, TValueTypes, TLinks>>>;
524
+ list(options: {
525
+ includeTotal?: true;
526
+ }): Promise<ListResult<ObjectQueryRow<TObjectType, TValueTypes, TLinks>>>;
527
+ list(options?: ObjectQueryListOptions): Promise<ListResult<ObjectQueryRow<TObjectType, TValueTypes, TLinks>> | ListResultWithoutTotal<ObjectQueryRow<TObjectType, TValueTypes, TLinks>>>;
528
+ /** Count the matching objects without returning rows. */
529
+ count(): Promise<number>;
530
+ /** Check whether any object matches without returning rows. */
531
+ exists(): Promise<boolean>;
532
+ /** Count matching objects by configured facetable properties. */
533
+ facets(input: readonly ObjectQueryFacetInput<TObjectType>[]): Promise<ObjectQueryFacetResult[]>;
534
+ /** Execute this query with an outer limit of one and return the first object. */
535
+ first(): Promise<ObjectQueryRow<TObjectType, TValueTypes, TLinks> | null>;
536
+ }
537
+ export interface ObjectByIdHandle<TObjectType extends ObjectTypeWithPropertyTokens, TValueTypes extends readonly ValueType[]> {
538
+ /** Get the object at this id, or null if it doesn't exist. */
539
+ get(): Promise<TwinObject<TObjectType, TValueTypes> | null>;
540
+ /** List links from this object, optionally filtered by link token. */
541
+ listLinks(link?: LinkTokenForObjectType<TObjectType>): Promise<readonly ObjectLinkRow[]>;
542
+ /** Create or update a link from the current object to a target object. */
543
+ link<TLinkToken extends LinkTokenForObjectType<TObjectType>>(link: TLinkToken, target: ObjectRef<ResolveTargetTypeId<TLinkToken["targetObjectTypeId"]>>, options?: {
544
+ properties?: Record<string, unknown>;
545
+ }): Promise<void>;
546
+ /** Remove a link from the current object to a target object. */
547
+ unlink<TLinkToken extends LinkTokenForObjectType<TObjectType>>(link: TLinkToken, target: ObjectRef<ResolveTargetTypeId<TLinkToken["targetObjectTypeId"]>>): Promise<void>;
548
+ /** Request an action on this object by id (dynamic / server contexts). */
549
+ requestAction(input: {
550
+ actionId: string;
551
+ params?: Record<string, unknown>;
552
+ runId?: string;
553
+ }): Promise<RequestActionResult>;
554
+ /**
555
+ * Request an action on this object using a typed action reference.
556
+ * Params are inferred from the action's declared shape.
557
+ */
558
+ requestAction<const TAction extends TypedActionReference>(input: {
559
+ action: TAction;
560
+ params: NoInfer<TypedActionParams<TAction>>;
561
+ runId?: string;
562
+ }): Promise<RequestActionResult>;
563
+ /** Request an action and wait for the terminal lifecycle event. */
564
+ requestActionAndWait(input: {
565
+ actionId: string;
566
+ params?: Record<string, unknown>;
567
+ timeoutMs?: number;
568
+ signal?: AbortSignal;
569
+ }): Promise<ActionRunRecord>;
570
+ /** Request a typed action and wait for the terminal lifecycle event. */
571
+ requestActionAndWait<const TAction extends TypedActionReference>(input: {
572
+ action: TAction;
573
+ params: NoInfer<TypedActionParams<TAction>>;
574
+ timeoutMs?: number;
575
+ signal?: AbortSignal;
576
+ }): Promise<ActionRunRecord>;
577
+ /**
578
+ * Delete this object, cascading over its links in the same commit.
579
+ *
580
+ * For an object written only from code this is not reversible — the identity ceases to exist, and
581
+ * `restore()` has nothing to bring back. For an object a projection also writes, the delete records
582
+ * a managed override: the object stays hidden even while the projection keeps asserting it, until
583
+ * `restore()` withdraws the override.
584
+ *
585
+ * Deleting a missing object is a no-op.
586
+ */
587
+ delete(): Promise<void>;
588
+ /** Withdraw a previous `delete()`. A no-op unless a projection still asserts this object. */
589
+ restore(): Promise<void>;
590
+ /** Read and write telemetry for one telemetry-mode property token. */
591
+ telemetry<TToken extends TelemetryPropertyToken<TObjectType>>(property: TToken): TelemetryChannel<TToken, TValueTypes>;
592
+ }
593
+ /**
594
+ * Public API surface of a Sixb runtime instance.
595
+ *
596
+ * The class `Sixb<T>` implements this interface so the contract is
597
+ * enforced at compile time and easy to scan in one place.
598
+ */
599
+ export interface SixbInstance<_ extends readonly OntologySource[]> {
600
+ readonly id: string;
601
+ readonly ontology: OntologyRegistry;
602
+ readonly broker: Broker;
603
+ readonly events: DomainEventLog;
604
+ readonly logs: LogsRuntime;
605
+ readonly storage: Storage;
606
+ readonly lakeStorage: LakeStorage;
607
+ readonly blobStorage: BlobStorage;
608
+ readonly queues: Queues;
609
+ readonly sandboxes?: SandboxFactory;
610
+ readonly rules?: readonly RuleDefinition[];
611
+ readonly security: SecurityRegistry;
612
+ readonly auth: AuthRuntime;
613
+ readonly actions: ActionsRuntime;
614
+ readonly workflows: WorkflowsRuntime;
615
+ readonly agents: AgentsRuntime;
616
+ /** Create a principal-scoped runtime surface that enforces authorization grants. */
617
+ as(context: AuthorizationContext): ScopedSixb<_>;
618
+ /** All registered object types. */
619
+ listObjectTypes(): readonly ObjectTypeWithPropertyTokens[];
620
+ /** Lookup an object type by id. */
621
+ getObjectTypeById(objectTypeId: string): ObjectTypeWithPropertyTokens | null;
622
+ /** Resolve an object type by id, or throw if it is unknown. */
623
+ resolveObjectType(objectTypeId: string): ObjectTypeWithPropertyTokens;
624
+ /** Value types registered in the runtime ontology, keyed by id. */
625
+ getValueTypesById(): ReadonlyMap<string, ValueType>;
626
+ /** All registered action definitions. */
627
+ listActions(): readonly ActionDefinition[];
628
+ /** Lookup an action definition by id. */
629
+ getActionById(actionId: string): ActionDefinition | null;
630
+ /** All registered global actions. */
631
+ listGlobalActions(): readonly ActionDefinition[];
632
+ /** All actions valid for an object type, including inherited actions. */
633
+ listActionsForType(objectType: ObjectType): readonly ActionDefinition[];
634
+ /** All registered dataset definitions. */
635
+ listDatasets(): readonly DatasetDefinition[];
636
+ /** Lookup a dataset definition by id. */
637
+ getDatasetById(datasetId: string): DatasetDefinition | null;
638
+ /** All registered sync definitions. */
639
+ listSyncs(): readonly SyncDefinition[];
640
+ /** Lookup a sync definition by id. */
641
+ getSyncById(syncId: string): SyncDefinition | null;
642
+ /** All registered pipeline definitions. */
643
+ listPipelines(): readonly PipelineDefinition[];
644
+ /** Lookup a pipeline definition by id. */
645
+ getPipelineById(pipelineId: string): PipelineDefinition | null;
646
+ /**
647
+ * Request an action run by id. Queued, not run inline — see `requestActionAndWait`.
648
+ *
649
+ * Every start verb on this runtime is `request*` for that reason: `run*` implied inline execution
650
+ * that never happened.
651
+ */
652
+ requestAction(input: RequestActionInput): Promise<RequestActionResult>;
653
+ /** Request an action run and wait for it to reach a terminal state. */
654
+ requestActionAndWait(input: RequestActionAndWaitInput): Promise<ActionRunRecord>;
655
+ /** Queue a workflow run by id. */
656
+ requestWorkflowRun(input: RequestWorkflowRunInput): Promise<WorkflowRunRequestResult>;
657
+ /** Queue a sync run by id. */
658
+ requestSyncRun(input: RequestSyncRunInput): Promise<SyncRunRequestResult>;
659
+ /** Queue a pipeline run by id. */
660
+ requestPipelineRun(input: RequestPipelineRunInput): Promise<PipelineRunRequestResult>;
661
+ /** Queue an agent turn by id. */
662
+ requestAgentRun(input: RequestAgentRunInput): Promise<RequestAgentRunResult>;
663
+ /** All registered schedule definitions. */
664
+ listSchedules(): readonly ScheduleDefinition[];
665
+ /** Lookup a schedule definition by id. */
666
+ getScheduleById(scheduleId: string): ScheduleDefinition | null;
667
+ /** All registered rule definitions. */
668
+ listRules(): readonly RuleDefinition[];
669
+ /** Lookup a rule definition by id. */
670
+ getRuleById(ruleId: string): RuleDefinition | null;
671
+ /** All registered connector definitions. */
672
+ listConnectors(): readonly ConnectorDefinition[];
673
+ /** Lookup a connector definition by id. */
674
+ getConnectorById(connectorId: string): ConnectorDefinition | null;
675
+ /** All webhook endpoints registered through connector adapters. */
676
+ listWebhooks(): readonly RegisteredWebhook[];
677
+ /** Lookup a registered connector webhook by connector id and webhook id. */
678
+ getWebhookById(connectorId: string, webhookId: string): RegisteredWebhook | null;
679
+ /**
680
+ * Resolve a connector definition to its connected client.
681
+ *
682
+ * The first call connects lazily and caches the result for reuse within the runtime.
683
+ */
684
+ connector<TAdapter extends ConnectorAdapter>(definition: ConnectorDefinition<string, TAdapter>): Promise<ConnectorClient<TAdapter>>;
685
+ /** Start the scheduler runtime for all registered schedules. */
686
+ startScheduler(): Promise<void>;
687
+ /** Stop the scheduler runtime. */
688
+ stopScheduler(): Promise<void>;
689
+ /** Start durable outbox recovery and bounded ontology retention. */
690
+ startOntologyMaintenance(): Promise<OntologyMaintenanceHandle>;
691
+ /** Latest cached asynchronous delivery and cleanup status. */
692
+ getOntologyOperationalStatus(): OntologyOperationalStatus;
693
+ /** Verify required storage reachability and migration state. */
694
+ checkReadiness(): Promise<SixbReadiness>;
695
+ /** Disconnect all currently connected connector clients. */
696
+ disconnectConnectors(): Promise<void>;
697
+ /** Close the runtime broker provider if it owns external resources. */
698
+ closeBroker(): Promise<void>;
699
+ /** Close the process logger provider, flushing buffered output. */
700
+ closeLogger(): Promise<void>;
701
+ /**
702
+ * Type-safe ObjectSet for a registered object type.
703
+ *
704
+ * Not part of this interface because `ObjectSet` triggers deep type
705
+ * instantiation when the generic parameter is the widened base
706
+ * `ObjectTypeWithPropertyTokens`. Use `sixb.objects(MyConcreteType)`
707
+ * directly — TypeScript infers the narrow type from the literal.
708
+ *
709
+ * Signature: `objects<T>(objectType: T): ObjectSet<T, RegisteredValueTypes>`
710
+ */
711
+ /** Get the primary property id for a given object type. */
712
+ getPrimaryPropertyId(objectTypeId: string): string;
713
+ /** Upsert an object by type id (for server / dynamic contexts). */
714
+ upsertObject(objectTypeId: string, properties: Record<string, unknown>): Promise<ObjectRow>;
715
+ /** Append telemetry for multiple objects of a given type. */
716
+ appendTelemetry(objectTypeId: string, items: readonly {
717
+ id: string;
718
+ properties: Record<string, unknown>;
719
+ at?: Date;
720
+ }[]): Promise<void>;
721
+ /** Create or update a link from source to target. */
722
+ upsertLink(objectTypeId: string, sourceId: string, linkId: string, target: {
723
+ targetTypeId: string;
724
+ targetId: string;
725
+ properties?: Record<string, unknown>;
726
+ }): Promise<void>;
727
+ /** Remove a link from source to target. */
728
+ removeLink(objectTypeId: string, sourceId: string, linkId: string, target: {
729
+ targetTypeId: string;
730
+ targetId: string;
731
+ }): Promise<void>;
732
+ /** Batch upsert objects of a single type. Returns per-item results. */
733
+ upsertObjectBatch(objectTypeId: string, items: readonly {
734
+ properties: Record<string, unknown>;
735
+ }[]): Promise<readonly BatchItemResult<ObjectRow>[]>;
736
+ /** Batch upsert links. Returns per-item results. */
737
+ upsertLinkBatch(items: readonly {
738
+ objectTypeId: string;
739
+ sourceId: string;
740
+ linkId: string;
741
+ target: {
742
+ targetTypeId: string;
743
+ targetId: string;
744
+ properties?: Record<string, unknown>;
745
+ };
746
+ }[]): Promise<readonly BatchItemResult<void>[]>;
747
+ /** Cross-type object listing for dashboards and search. */
748
+ list(params: {
749
+ objectTypeIds?: readonly string[];
750
+ idPrefix?: string;
751
+ idSuffix?: string;
752
+ updatedAfter?: Date;
753
+ updatedBefore?: Date;
754
+ createdAfter?: Date;
755
+ createdBefore?: Date;
756
+ limit?: number;
757
+ offset?: number;
758
+ orderBy?: "createdAt" | "updatedAt" | "primaryId";
759
+ order?: "asc" | "desc";
760
+ }): Promise<ListResult<ObjectRow>>;
761
+ /** Collect all transitive sub-types of the given object type id. */
762
+ listSubTypes(objectTypeId: string): string[];
763
+ /** All registered object projection definitions. */
764
+ listObjectProjections(): readonly ObjectProjectionDefinition[];
765
+ /** All registered link projection definitions. */
766
+ listLinkProjections(): readonly LinkProjectionDefinition[];
767
+ /** All registered telemetry projection definitions. */
768
+ listTelemetryProjections(): readonly TelemetryProjectionDefinition[];
769
+ /** Lookup a registered projection by id. */
770
+ getProjectionById(projectionId: string): ProjectionDefinition | null;
771
+ }
772
+ export interface ObjectSet<TObjectType extends ObjectTypeWithPropertyTokens, TValueTypes extends readonly ValueType[], TRegisteredObjectTypes extends ObjectTypeWithPropertyTokens = TObjectType> {
773
+ /** Get an object by id, or null if it doesn't exist. */
774
+ get(id: string): Promise<TwinObject<TObjectType, TValueTypes> | null>;
775
+ /** Upsert object state facts (latest projection). */
776
+ upsert(input: {
777
+ properties: InferObjectProperties<TObjectType, TValueTypes>;
778
+ }): Promise<TwinObject<TObjectType, TValueTypes>>;
779
+ /** Build an executable provider-neutral object query rooted at this object type. */
780
+ query(): ObjectQueryBuilder<TObjectType, TRegisteredObjectTypes, TValueTypes>;
781
+ /** Bind operations to a specific object id. */
782
+ byId(id: string): ObjectByIdHandle<TObjectType, TValueTypes>;
783
+ /** List stored objects of this type with storage-system filtering and pagination. */
784
+ list(input?: ObjectSetListInput): Promise<ListResult<TwinObject<TObjectType, TValueTypes>>>;
785
+ /** Append telemetry for multiple objects in a single batch. */
786
+ appendTelemetryBatch(items: readonly {
787
+ id: string;
788
+ properties: InferTelemetryBatchProperties<TObjectType, TValueTypes>;
789
+ at?: Date;
790
+ }[]): Promise<void>;
791
+ /** Request an action on an object of this type by id (dynamic / server contexts). */
792
+ requestAction(input: {
793
+ id: string;
794
+ actionId: string;
795
+ params?: Record<string, unknown>;
796
+ runId?: string;
797
+ }): Promise<RequestActionResult>;
798
+ /**
799
+ * Request an action on an object of this type using a typed action reference.
800
+ * Params are inferred from the action's declared shape.
801
+ */
802
+ requestAction<const TAction extends TypedActionReference>(input: {
803
+ id: string;
804
+ action: TAction;
805
+ params: NoInfer<TypedActionParams<TAction>>;
806
+ runId?: string;
807
+ }): Promise<RequestActionResult>;
808
+ /** Request an action on an object and wait for the terminal lifecycle event. */
809
+ requestActionAndWait(input: {
810
+ id: string;
811
+ actionId: string;
812
+ params?: Record<string, unknown>;
813
+ timeoutMs?: number;
814
+ signal?: AbortSignal;
815
+ }): Promise<ActionRunRecord>;
816
+ /** Request a typed action and wait for the terminal lifecycle event. */
817
+ requestActionAndWait<const TAction extends TypedActionReference>(input: {
818
+ id: string;
819
+ action: TAction;
820
+ params: NoInfer<TypedActionParams<TAction>>;
821
+ timeoutMs?: number;
822
+ signal?: AbortSignal;
823
+ }): Promise<ActionRunRecord>;
824
+ /** Create or update a link (string-based, for server/dynamic usage). */
825
+ upsertLink(input: {
826
+ sourceId: string;
827
+ linkId: string;
828
+ targetTypeId: string;
829
+ targetId: string;
830
+ properties?: Record<string, unknown>;
831
+ }): Promise<void>;
832
+ /** Remove a link (string-based, for server/dynamic usage). */
833
+ removeLink(input: {
834
+ sourceId: string;
835
+ linkId: string;
836
+ targetTypeId: string;
837
+ targetId: string;
838
+ }): Promise<void>;
839
+ }
840
+ //# sourceMappingURL=types.d.ts.map