@aria-cli/tools 1.0.19 → 1.0.33

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 (459) hide show
  1. package/dist/.aria-build-stamp.json +1 -1
  2. package/dist/ask-user-interaction.js +23 -0
  3. package/dist/cache/web-cache.js +67 -0
  4. package/dist/definitions/arion.js +105 -0
  5. package/dist/definitions/browser/browser.js +419 -0
  6. package/dist/definitions/browser/index.js +5 -0
  7. package/dist/definitions/browser/pw-downloads.js +115 -0
  8. package/dist/definitions/browser/pw-interactions.js +200 -0
  9. package/dist/definitions/browser/pw-responses.js +77 -0
  10. package/dist/definitions/browser/pw-session.js +311 -0
  11. package/dist/definitions/browser/pw-shared.js +67 -0
  12. package/dist/definitions/browser/pw-snapshot.js +302 -0
  13. package/dist/definitions/browser/pw-state.js +63 -0
  14. package/dist/definitions/browser/types.js +5 -0
  15. package/dist/definitions/code-intelligence.js +471 -0
  16. package/dist/definitions/core.js +110 -0
  17. package/dist/definitions/delegation.js +513 -0
  18. package/dist/definitions/deploy.js +66 -0
  19. package/dist/definitions/filesystem.js +197 -0
  20. package/dist/definitions/frg.js +64 -0
  21. package/{dist-cjs/definitions/index.d.ts → dist/definitions/index.js} +2 -0
  22. package/dist/definitions/memory.js +124 -0
  23. package/dist/definitions/messaging.js +626 -0
  24. package/dist/definitions/meta.js +350 -0
  25. package/dist/definitions/network.js +160 -0
  26. package/dist/definitions/outlook.js +278 -0
  27. package/dist/definitions/patch/apply-patch.js +185 -0
  28. package/dist/definitions/patch/fuzzy-match.js +167 -0
  29. package/{dist-cjs/definitions/patch/index.d.ts → dist/definitions/patch/index.js} +1 -0
  30. package/dist/definitions/patch/patch-parser.js +208 -0
  31. package/dist/definitions/patch/sandbox-paths.js +106 -0
  32. package/dist/definitions/process/index.js +5 -0
  33. package/dist/definitions/process/process-registry.js +214 -0
  34. package/dist/definitions/process/process.js +387 -0
  35. package/dist/definitions/process/pty-keys.js +255 -0
  36. package/dist/definitions/process/session-slug.js +143 -0
  37. package/dist/definitions/quip.js +196 -0
  38. package/dist/definitions/search.js +61 -0
  39. package/dist/definitions/session-history.js +70 -0
  40. package/dist/definitions/shell.js +182 -0
  41. package/dist/definitions/slack.js +181 -0
  42. package/dist/definitions/web.js +110 -0
  43. package/dist/executors/apply-patch.js +902 -0
  44. package/dist/executors/arion.js +120 -0
  45. package/dist/executors/code-intelligence.js +883 -0
  46. package/dist/executors/deploy.js +849 -0
  47. package/dist/executors/filesystem.js +1119 -0
  48. package/dist/executors/frg-freshness.js +577 -0
  49. package/dist/executors/frg.js +299 -0
  50. package/{dist-cjs/executors/index.d.ts → dist/executors/index.js} +22 -19
  51. package/dist/executors/learning-meta.js +1147 -0
  52. package/dist/executors/lsp-client.js +297 -0
  53. package/dist/executors/memory.js +751 -0
  54. package/dist/executors/meta.js +221 -0
  55. package/dist/executors/process-registry.js +466 -0
  56. package/dist/executors/pty-session-store.js +31 -0
  57. package/dist/executors/pty.js +281 -0
  58. package/dist/executors/restart.js +120 -0
  59. package/dist/executors/search-freshness.js +196 -0
  60. package/dist/executors/search-types.js +53 -0
  61. package/dist/executors/search.js +67 -0
  62. package/dist/executors/self-diagnose.js +399 -0
  63. package/dist/executors/session-history.js +284 -0
  64. package/dist/executors/shell-safety.js +474 -0
  65. package/dist/executors/shell.js +955 -0
  66. package/dist/executors/utils.js +34 -0
  67. package/dist/executors/web.js +543 -0
  68. package/dist/extraction/content-extraction.js +248 -0
  69. package/dist/extraction/index.js +5 -0
  70. package/dist/headless-control-contract.js +968 -0
  71. package/dist/{index-v49pd2a0.js → index-45qvfjbf.js} +2 -2
  72. package/dist/index.js +71 -372
  73. package/dist/local-control-http-auth.js +3 -0
  74. package/dist/mcp/client.js +182 -0
  75. package/dist/mcp/connection.js +484 -0
  76. package/dist/mcp/index.js +11 -0
  77. package/dist/mcp/jsonrpc.js +145 -0
  78. package/dist/mcp/types.js +8 -0
  79. package/dist/network-control-adapter.js +73 -0
  80. package/dist/network-runtime/address-types.js +166 -0
  81. package/dist/network-runtime/db-owner-fencing.js +70 -0
  82. package/dist/network-runtime/delivery-receipts.js +270 -0
  83. package/dist/network-runtime/direct-endpoint-authority.js +26 -0
  84. package/dist/network-runtime/index.js +13 -1
  85. package/dist/network-runtime/local-control-contract.js +628 -0
  86. package/dist/network-runtime/node-store-contract.js +35 -0
  87. package/dist/network-runtime/pair-route-contract.js +78 -0
  88. package/dist/network-runtime/peer-capabilities.js +29 -0
  89. package/dist/network-runtime/peer-principal-ref.js +13 -0
  90. package/dist/network-runtime/peer-state-machine.js +122 -0
  91. package/dist/network-runtime/protocol-schemas.js +206 -0
  92. package/dist/network-runtime/runtime-bootstrap-contract.js +61 -0
  93. package/dist/outlook/desktop-session.js +280 -0
  94. package/dist/policy.js +150 -0
  95. package/dist/providers/brave.js +63 -0
  96. package/dist/providers/duckduckgo.js +177 -0
  97. package/dist/providers/exa.js +64 -0
  98. package/dist/providers/firecrawl.js +56 -0
  99. package/{dist-cjs/providers/index.d.ts → dist/providers/index.js} +1 -1
  100. package/dist/providers/jina.js +50 -0
  101. package/dist/providers/router.js +97 -0
  102. package/dist/providers/search-provider.js +33 -0
  103. package/dist/providers/tavily.js +55 -0
  104. package/dist/pty-w5c9dv33.js +1 -0
  105. package/dist/quip/desktop-session.js +318 -0
  106. package/{dist-cjs/registry/index.d.ts → dist/registry/index.js} +1 -0
  107. package/dist/registry/registry.js +757 -0
  108. package/dist/runtime-socket-local-control-client.js +331 -0
  109. package/dist/security/dns-normalization.js +20 -0
  110. package/dist/security/dns-pinning.js +124 -0
  111. package/dist/security/external-content.js +92 -0
  112. package/dist/security/ssrf.js +182 -0
  113. package/dist/slack/desktop-session.js +325 -0
  114. package/dist/tool-factory.js +48 -0
  115. package/dist/types.js +8 -0
  116. package/dist/utils/retry.js +133 -0
  117. package/dist/utils/safe-parse-json.js +161 -0
  118. package/dist/utils/url.js +20 -0
  119. package/dist-cjs/ask-user-interaction.js +28 -0
  120. package/dist-cjs/cache/web-cache.js +71 -0
  121. package/dist-cjs/definitions/arion.js +108 -0
  122. package/dist-cjs/definitions/browser/browser.js +422 -0
  123. package/dist-cjs/definitions/browser/index.js +9 -0
  124. package/dist-cjs/definitions/browser/pw-downloads.js +118 -0
  125. package/dist-cjs/definitions/browser/pw-interactions.js +214 -0
  126. package/dist-cjs/definitions/browser/pw-responses.js +85 -0
  127. package/dist-cjs/definitions/browser/pw-session.js +327 -0
  128. package/dist-cjs/definitions/browser/pw-shared.js +73 -0
  129. package/dist-cjs/definitions/browser/pw-snapshot.js +308 -0
  130. package/dist-cjs/definitions/browser/pw-state.js +71 -0
  131. package/dist-cjs/definitions/browser/types.js +6 -0
  132. package/dist-cjs/definitions/code-intelligence.js +474 -0
  133. package/dist-cjs/definitions/core.js +134 -0
  134. package/dist-cjs/definitions/delegation.js +516 -0
  135. package/dist-cjs/definitions/deploy.js +69 -0
  136. package/dist-cjs/definitions/filesystem.js +200 -0
  137. package/dist-cjs/definitions/frg.js +67 -0
  138. package/dist-cjs/definitions/index.js +44 -0
  139. package/dist-cjs/definitions/memory.js +127 -0
  140. package/dist-cjs/definitions/messaging.js +632 -0
  141. package/dist-cjs/definitions/meta.js +353 -0
  142. package/dist-cjs/definitions/network.js +163 -0
  143. package/dist-cjs/definitions/outlook.js +281 -0
  144. package/dist-cjs/definitions/patch/apply-patch.js +192 -0
  145. package/dist-cjs/definitions/patch/fuzzy-match.js +173 -0
  146. package/dist-cjs/definitions/patch/index.js +6 -0
  147. package/dist-cjs/definitions/patch/patch-parser.js +216 -0
  148. package/dist-cjs/definitions/patch/sandbox-paths.js +114 -0
  149. package/dist-cjs/definitions/process/index.js +9 -0
  150. package/dist-cjs/definitions/process/process-registry.js +232 -0
  151. package/dist-cjs/definitions/process/process.js +390 -0
  152. package/dist-cjs/definitions/process/pty-keys.js +260 -0
  153. package/dist-cjs/definitions/process/session-slug.js +146 -0
  154. package/dist-cjs/definitions/quip.js +199 -0
  155. package/dist-cjs/definitions/search.js +64 -0
  156. package/dist-cjs/definitions/session-history.js +73 -0
  157. package/dist-cjs/definitions/shell.js +185 -0
  158. package/dist-cjs/definitions/slack.js +184 -0
  159. package/dist-cjs/definitions/web.js +113 -0
  160. package/dist-cjs/executors/apply-patch.js +939 -0
  161. package/dist-cjs/executors/arion.js +126 -0
  162. package/dist-cjs/executors/code-intelligence.js +926 -0
  163. package/dist-cjs/executors/deploy.js +870 -0
  164. package/dist-cjs/executors/filesystem.js +1164 -0
  165. package/dist-cjs/executors/frg-freshness.js +628 -0
  166. package/dist-cjs/executors/frg.js +335 -0
  167. package/dist-cjs/executors/index.js +144 -0
  168. package/dist-cjs/executors/learning-meta.js +1166 -0
  169. package/dist-cjs/executors/memory.js +797 -0
  170. package/dist-cjs/executors/meta.js +227 -0
  171. package/dist-cjs/executors/process-registry.js +470 -0
  172. package/dist-cjs/executors/pty-session-store.js +35 -0
  173. package/dist-cjs/executors/pty.js +289 -0
  174. package/dist-cjs/executors/restart.js +156 -0
  175. package/dist-cjs/executors/search-freshness.js +235 -0
  176. package/dist-cjs/executors/search-types.js +57 -0
  177. package/dist-cjs/executors/search.js +103 -0
  178. package/dist-cjs/executors/self-diagnose.js +435 -0
  179. package/dist-cjs/executors/session-history.js +321 -0
  180. package/dist-cjs/executors/shell-safety.js +479 -0
  181. package/dist-cjs/executors/shell.js +1002 -0
  182. package/dist-cjs/executors/utils.js +74 -0
  183. package/dist-cjs/executors/web.js +548 -0
  184. package/dist-cjs/extraction/content-extraction.js +289 -0
  185. package/dist-cjs/extraction/index.js +9 -0
  186. package/dist-cjs/headless-control-contract.js +973 -0
  187. package/dist-cjs/index.js +436 -385
  188. package/dist-cjs/local-control-http-auth.js +6 -0
  189. package/dist-cjs/mcp/client.js +186 -0
  190. package/dist-cjs/mcp/connection.js +488 -0
  191. package/dist-cjs/mcp/index.js +31 -0
  192. package/dist-cjs/mcp/jsonrpc.js +149 -0
  193. package/dist-cjs/mcp/types.js +9 -0
  194. package/dist-cjs/network-control-adapter.js +78 -0
  195. package/dist-cjs/network-runtime/address-types.js +169 -0
  196. package/dist-cjs/network-runtime/db-owner-fencing.js +77 -0
  197. package/dist-cjs/network-runtime/delivery-receipts.js +279 -0
  198. package/dist-cjs/network-runtime/direct-endpoint-authority.js +30 -0
  199. package/dist-cjs/network-runtime/index.js +173 -8
  200. package/dist-cjs/network-runtime/local-control-contract.js +634 -0
  201. package/dist-cjs/network-runtime/node-store-contract.js +39 -0
  202. package/dist-cjs/network-runtime/pair-route-contract.js +81 -0
  203. package/dist-cjs/network-runtime/peer-capabilities.js +38 -0
  204. package/dist-cjs/network-runtime/peer-principal-ref.js +16 -0
  205. package/dist-cjs/network-runtime/peer-state-machine.js +130 -0
  206. package/dist-cjs/network-runtime/protocol-schemas.js +213 -0
  207. package/dist-cjs/network-runtime/runtime-bootstrap-contract.js +64 -0
  208. package/dist-cjs/outlook/desktop-session.js +319 -0
  209. package/dist-cjs/policy.js +156 -0
  210. package/dist-cjs/providers/brave.js +67 -0
  211. package/dist-cjs/providers/duckduckgo.js +181 -0
  212. package/dist-cjs/providers/exa.js +68 -0
  213. package/dist-cjs/providers/firecrawl.js +60 -0
  214. package/dist-cjs/providers/index.js +18 -0
  215. package/dist-cjs/providers/jina.js +54 -0
  216. package/dist-cjs/providers/router.js +101 -0
  217. package/dist-cjs/providers/search-provider.js +37 -0
  218. package/dist-cjs/providers/tavily.js +59 -0
  219. package/dist-cjs/quip/desktop-session.js +354 -0
  220. package/dist-cjs/registry/index.js +7 -0
  221. package/dist-cjs/registry/registry.js +762 -0
  222. package/dist-cjs/runtime-socket-local-control-client.js +368 -0
  223. package/dist-cjs/security/dns-normalization.js +23 -0
  224. package/dist-cjs/security/dns-pinning.js +161 -0
  225. package/dist-cjs/security/external-content.js +96 -0
  226. package/dist-cjs/security/ssrf.js +222 -0
  227. package/dist-cjs/slack/desktop-session.js +367 -0
  228. package/dist-cjs/tool-factory.js +51 -0
  229. package/dist-cjs/types.js +9 -0
  230. package/dist-cjs/utils/retry.js +170 -0
  231. package/dist-cjs/utils/safe-parse-json.js +165 -0
  232. package/dist-cjs/utils/url.js +24 -0
  233. package/package.json +11 -10
  234. package/dist/ask-user-interaction.d.ts +0 -10
  235. package/dist/cache/web-cache.d.ts +0 -52
  236. package/dist/definitions/arion.d.ts +0 -8
  237. package/dist/definitions/browser/browser.d.ts +0 -2
  238. package/dist/definitions/browser/index.d.ts +0 -1
  239. package/dist/definitions/browser/pw-downloads.d.ts +0 -13
  240. package/dist/definitions/browser/pw-interactions.d.ts +0 -78
  241. package/dist/definitions/browser/pw-responses.d.ts +0 -28
  242. package/dist/definitions/browser/pw-session.d.ts +0 -65
  243. package/dist/definitions/browser/pw-shared.d.ts +0 -22
  244. package/dist/definitions/browser/pw-snapshot.d.ts +0 -34
  245. package/dist/definitions/browser/pw-state.d.ts +0 -22
  246. package/dist/definitions/browser/types.d.ts +0 -277
  247. package/dist/definitions/code-intelligence.d.ts +0 -8
  248. package/dist/definitions/core.d.ts +0 -47
  249. package/dist/definitions/delegation.d.ts +0 -11
  250. package/dist/definitions/deploy.d.ts +0 -15
  251. package/dist/definitions/filesystem.d.ts +0 -9
  252. package/dist/definitions/frg.d.ts +0 -3
  253. package/dist/definitions/index.d.ts +0 -19
  254. package/dist/definitions/memory.d.ts +0 -8
  255. package/dist/definitions/messaging.d.ts +0 -11
  256. package/dist/definitions/meta.d.ts +0 -11
  257. package/dist/definitions/network.d.ts +0 -11
  258. package/dist/definitions/outlook.d.ts +0 -2
  259. package/dist/definitions/patch/apply-patch.d.ts +0 -11
  260. package/dist/definitions/patch/fuzzy-match.d.ts +0 -10
  261. package/dist/definitions/patch/index.d.ts +0 -1
  262. package/dist/definitions/patch/patch-parser.d.ts +0 -50
  263. package/dist/definitions/patch/sandbox-paths.d.ts +0 -18
  264. package/dist/definitions/process/index.d.ts +0 -1
  265. package/dist/definitions/process/process-registry.d.ts +0 -67
  266. package/dist/definitions/process/process.d.ts +0 -9
  267. package/dist/definitions/process/pty-keys.d.ts +0 -13
  268. package/dist/definitions/process/session-slug.d.ts +0 -1
  269. package/dist/definitions/quip.d.ts +0 -2
  270. package/dist/definitions/search.d.ts +0 -9
  271. package/dist/definitions/session-history.d.ts +0 -11
  272. package/dist/definitions/shell.d.ts +0 -8
  273. package/dist/definitions/slack.d.ts +0 -2
  274. package/dist/definitions/web.d.ts +0 -8
  275. package/dist/executors/apply-patch.d.ts +0 -51
  276. package/dist/executors/arion.d.ts +0 -50
  277. package/dist/executors/code-intelligence.d.ts +0 -138
  278. package/dist/executors/deploy.d.ts +0 -169
  279. package/dist/executors/filesystem.d.ts +0 -150
  280. package/dist/executors/frg-freshness.d.ts +0 -93
  281. package/dist/executors/frg.d.ts +0 -27
  282. package/dist/executors/index.d.ts +0 -44
  283. package/dist/executors/learning-meta.d.ts +0 -87
  284. package/dist/executors/lsp-client.d.ts +0 -38
  285. package/dist/executors/memory.d.ts +0 -203
  286. package/dist/executors/meta.d.ts +0 -73
  287. package/dist/executors/process-registry.d.ts +0 -98
  288. package/dist/executors/pty-session-store.d.ts +0 -14
  289. package/dist/executors/pty.d.ts +0 -133
  290. package/dist/executors/restart.d.ts +0 -13
  291. package/dist/executors/search-freshness.d.ts +0 -50
  292. package/dist/executors/search-types.d.ts +0 -52
  293. package/dist/executors/search.d.ts +0 -11
  294. package/dist/executors/self-diagnose.d.ts +0 -89
  295. package/dist/executors/session-history.d.ts +0 -75
  296. package/dist/executors/shell-safety.d.ts +0 -27
  297. package/dist/executors/shell.d.ts +0 -168
  298. package/dist/executors/utils.d.ts +0 -20
  299. package/dist/executors/web.d.ts +0 -89
  300. package/dist/extraction/content-extraction.d.ts +0 -48
  301. package/dist/extraction/index.d.ts +0 -4
  302. package/dist/headless-control-contract.d.ts +0 -3182
  303. package/dist/index.d.ts +0 -62
  304. package/dist/local-control-http-auth.d.ts +0 -2
  305. package/dist/mcp/client.d.ts +0 -68
  306. package/dist/mcp/connection.d.ts +0 -54
  307. package/dist/mcp/index.d.ts +0 -10
  308. package/dist/mcp/jsonrpc.d.ts +0 -36
  309. package/dist/mcp/types.d.ts +0 -178
  310. package/dist/network-control-adapter.d.ts +0 -4
  311. package/dist/network-runtime/address-types.d.ts +0 -201
  312. package/dist/network-runtime/db-owner-fencing.d.ts +0 -43
  313. package/dist/network-runtime/delivery-receipts.d.ts +0 -117
  314. package/dist/network-runtime/direct-endpoint-authority.d.ts +0 -8
  315. package/dist/network-runtime/index.d.ts +0 -24
  316. package/dist/network-runtime/local-control-contract.d.ts +0 -758
  317. package/dist/network-runtime/node-store-contract.d.ts +0 -49
  318. package/dist/network-runtime/pair-route-contract.d.ts +0 -100
  319. package/dist/network-runtime/peer-capabilities.d.ts +0 -10
  320. package/dist/network-runtime/peer-principal-ref.d.ts +0 -9
  321. package/dist/network-runtime/peer-state-machine.d.ts +0 -70
  322. package/dist/network-runtime/protocol-schemas.d.ts +0 -328
  323. package/dist/network-runtime/runtime-bootstrap-contract.d.ts +0 -81
  324. package/dist/outlook/desktop-session.d.ts +0 -68
  325. package/dist/policy.d.ts +0 -43
  326. package/dist/providers/brave.d.ts +0 -10
  327. package/dist/providers/duckduckgo.d.ts +0 -18
  328. package/dist/providers/exa.d.ts +0 -10
  329. package/dist/providers/firecrawl.d.ts +0 -10
  330. package/dist/providers/index.d.ts +0 -8
  331. package/dist/providers/jina.d.ts +0 -10
  332. package/dist/providers/router.d.ts +0 -21
  333. package/dist/providers/search-provider.d.ts +0 -35
  334. package/dist/providers/tavily.d.ts +0 -10
  335. package/dist/pty-cf6pmvx6.js +0 -1
  336. package/dist/quip/desktop-session.d.ts +0 -69
  337. package/dist/registry/index.d.ts +0 -1
  338. package/dist/registry/registry.d.ts +0 -156
  339. package/dist/runtime-socket-local-control-client.d.ts +0 -10
  340. package/dist/security/dns-normalization.d.ts +0 -6
  341. package/dist/security/dns-pinning.d.ts +0 -27
  342. package/dist/security/external-content.d.ts +0 -40
  343. package/dist/security/ssrf.d.ts +0 -40
  344. package/dist/slack/desktop-session.d.ts +0 -69
  345. package/dist/tool-factory.d.ts +0 -46
  346. package/dist/types.d.ts +0 -1192
  347. package/dist/utils/retry.d.ts +0 -11
  348. package/dist/utils/safe-parse-json.d.ts +0 -26
  349. package/dist/utils/url.d.ts +0 -10
  350. package/dist-cjs/ask-user-interaction.d.ts +0 -10
  351. package/dist-cjs/cache/web-cache.d.ts +0 -52
  352. package/dist-cjs/definitions/arion.d.ts +0 -8
  353. package/dist-cjs/definitions/browser/browser.d.ts +0 -2
  354. package/dist-cjs/definitions/browser/index.d.ts +0 -1
  355. package/dist-cjs/definitions/browser/pw-downloads.d.ts +0 -13
  356. package/dist-cjs/definitions/browser/pw-interactions.d.ts +0 -78
  357. package/dist-cjs/definitions/browser/pw-responses.d.ts +0 -28
  358. package/dist-cjs/definitions/browser/pw-session.d.ts +0 -65
  359. package/dist-cjs/definitions/browser/pw-shared.d.ts +0 -22
  360. package/dist-cjs/definitions/browser/pw-snapshot.d.ts +0 -34
  361. package/dist-cjs/definitions/browser/pw-state.d.ts +0 -22
  362. package/dist-cjs/definitions/browser/types.d.ts +0 -277
  363. package/dist-cjs/definitions/code-intelligence.d.ts +0 -8
  364. package/dist-cjs/definitions/core.d.ts +0 -47
  365. package/dist-cjs/definitions/delegation.d.ts +0 -11
  366. package/dist-cjs/definitions/deploy.d.ts +0 -15
  367. package/dist-cjs/definitions/filesystem.d.ts +0 -9
  368. package/dist-cjs/definitions/frg.d.ts +0 -3
  369. package/dist-cjs/definitions/memory.d.ts +0 -8
  370. package/dist-cjs/definitions/messaging.d.ts +0 -11
  371. package/dist-cjs/definitions/meta.d.ts +0 -11
  372. package/dist-cjs/definitions/network.d.ts +0 -11
  373. package/dist-cjs/definitions/outlook.d.ts +0 -2
  374. package/dist-cjs/definitions/patch/apply-patch.d.ts +0 -11
  375. package/dist-cjs/definitions/patch/fuzzy-match.d.ts +0 -10
  376. package/dist-cjs/definitions/patch/patch-parser.d.ts +0 -50
  377. package/dist-cjs/definitions/patch/sandbox-paths.d.ts +0 -18
  378. package/dist-cjs/definitions/process/index.d.ts +0 -1
  379. package/dist-cjs/definitions/process/process-registry.d.ts +0 -67
  380. package/dist-cjs/definitions/process/process.d.ts +0 -9
  381. package/dist-cjs/definitions/process/pty-keys.d.ts +0 -13
  382. package/dist-cjs/definitions/process/session-slug.d.ts +0 -1
  383. package/dist-cjs/definitions/quip.d.ts +0 -2
  384. package/dist-cjs/definitions/search.d.ts +0 -9
  385. package/dist-cjs/definitions/session-history.d.ts +0 -11
  386. package/dist-cjs/definitions/shell.d.ts +0 -8
  387. package/dist-cjs/definitions/slack.d.ts +0 -2
  388. package/dist-cjs/definitions/web.d.ts +0 -8
  389. package/dist-cjs/executors/apply-patch.d.ts +0 -51
  390. package/dist-cjs/executors/arion.d.ts +0 -50
  391. package/dist-cjs/executors/code-intelligence.d.ts +0 -138
  392. package/dist-cjs/executors/deploy.d.ts +0 -169
  393. package/dist-cjs/executors/filesystem.d.ts +0 -150
  394. package/dist-cjs/executors/frg-freshness.d.ts +0 -93
  395. package/dist-cjs/executors/frg.d.ts +0 -27
  396. package/dist-cjs/executors/learning-meta.d.ts +0 -87
  397. package/dist-cjs/executors/lsp-client.d.ts +0 -38
  398. package/dist-cjs/executors/memory.d.ts +0 -203
  399. package/dist-cjs/executors/meta.d.ts +0 -73
  400. package/dist-cjs/executors/process-registry.d.ts +0 -98
  401. package/dist-cjs/executors/pty-session-store.d.ts +0 -14
  402. package/dist-cjs/executors/pty.d.ts +0 -133
  403. package/dist-cjs/executors/restart.d.ts +0 -13
  404. package/dist-cjs/executors/search-freshness.d.ts +0 -50
  405. package/dist-cjs/executors/search-types.d.ts +0 -52
  406. package/dist-cjs/executors/search.d.ts +0 -11
  407. package/dist-cjs/executors/self-diagnose.d.ts +0 -89
  408. package/dist-cjs/executors/session-history.d.ts +0 -75
  409. package/dist-cjs/executors/shell-safety.d.ts +0 -27
  410. package/dist-cjs/executors/shell.d.ts +0 -168
  411. package/dist-cjs/executors/utils.d.ts +0 -20
  412. package/dist-cjs/executors/web.d.ts +0 -89
  413. package/dist-cjs/extraction/content-extraction.d.ts +0 -48
  414. package/dist-cjs/extraction/index.d.ts +0 -4
  415. package/dist-cjs/headless-control-contract.d.ts +0 -3182
  416. package/dist-cjs/index.d.ts +0 -62
  417. package/dist-cjs/local-control-http-auth.d.ts +0 -2
  418. package/dist-cjs/mcp/client.d.ts +0 -68
  419. package/dist-cjs/mcp/connection.d.ts +0 -54
  420. package/dist-cjs/mcp/index.d.ts +0 -10
  421. package/dist-cjs/mcp/jsonrpc.d.ts +0 -36
  422. package/dist-cjs/mcp/types.d.ts +0 -178
  423. package/dist-cjs/network-control-adapter.d.ts +0 -4
  424. package/dist-cjs/network-runtime/address-types.d.ts +0 -201
  425. package/dist-cjs/network-runtime/db-owner-fencing.d.ts +0 -43
  426. package/dist-cjs/network-runtime/delivery-receipts.d.ts +0 -117
  427. package/dist-cjs/network-runtime/direct-endpoint-authority.d.ts +0 -8
  428. package/dist-cjs/network-runtime/index.d.ts +0 -24
  429. package/dist-cjs/network-runtime/local-control-contract.d.ts +0 -758
  430. package/dist-cjs/network-runtime/node-store-contract.d.ts +0 -49
  431. package/dist-cjs/network-runtime/pair-route-contract.d.ts +0 -100
  432. package/dist-cjs/network-runtime/peer-capabilities.d.ts +0 -10
  433. package/dist-cjs/network-runtime/peer-principal-ref.d.ts +0 -9
  434. package/dist-cjs/network-runtime/peer-state-machine.d.ts +0 -70
  435. package/dist-cjs/network-runtime/protocol-schemas.d.ts +0 -328
  436. package/dist-cjs/network-runtime/runtime-bootstrap-contract.d.ts +0 -81
  437. package/dist-cjs/outlook/desktop-session.d.ts +0 -68
  438. package/dist-cjs/policy.d.ts +0 -43
  439. package/dist-cjs/providers/brave.d.ts +0 -10
  440. package/dist-cjs/providers/duckduckgo.d.ts +0 -18
  441. package/dist-cjs/providers/exa.d.ts +0 -10
  442. package/dist-cjs/providers/firecrawl.d.ts +0 -10
  443. package/dist-cjs/providers/jina.d.ts +0 -10
  444. package/dist-cjs/providers/router.d.ts +0 -21
  445. package/dist-cjs/providers/search-provider.d.ts +0 -35
  446. package/dist-cjs/providers/tavily.d.ts +0 -10
  447. package/dist-cjs/quip/desktop-session.d.ts +0 -69
  448. package/dist-cjs/registry/registry.d.ts +0 -156
  449. package/dist-cjs/runtime-socket-local-control-client.d.ts +0 -10
  450. package/dist-cjs/security/dns-normalization.d.ts +0 -6
  451. package/dist-cjs/security/dns-pinning.d.ts +0 -27
  452. package/dist-cjs/security/external-content.d.ts +0 -40
  453. package/dist-cjs/security/ssrf.d.ts +0 -40
  454. package/dist-cjs/slack/desktop-session.d.ts +0 -69
  455. package/dist-cjs/tool-factory.d.ts +0 -46
  456. package/dist-cjs/types.d.ts +0 -1192
  457. package/dist-cjs/utils/retry.d.ts +0 -11
  458. package/dist-cjs/utils/safe-parse-json.d.ts +0 -26
  459. package/dist-cjs/utils/url.d.ts +0 -10
@@ -0,0 +1,279 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DeliveryReceiptInputSchema = exports.OutboxReceiptStatusSchema = exports.QueuedReasonSchema = exports.DeliveryReadinessSchema = exports.SessionStateSchema = exports.DeliveryStateSchema = exports.RuntimeTransportSchema = void 0;
4
+ exports.canonicalizeDeliveryReceipt = canonicalizeDeliveryReceipt;
5
+ exports.createAckedDeliveryReceipt = createAckedDeliveryReceipt;
6
+ exports.createQueuedForRouteReceipt = createQueuedForRouteReceipt;
7
+ exports.createDispatchingDeliveryReceipt = createDispatchingDeliveryReceipt;
8
+ exports.createSentDeliveryReceipt = createSentDeliveryReceipt;
9
+ exports.canonicalizeOutboxReceiptStatus = canonicalizeOutboxReceiptStatus;
10
+ const zod_1 = require("zod");
11
+ exports.RuntimeTransportSchema = zod_1.z.enum(["in_process", "local_runtime", "tunnel", "relay"]);
12
+ exports.DeliveryStateSchema = zod_1.z.enum([
13
+ "accepted",
14
+ "queued_for_route",
15
+ "dispatching",
16
+ "sent",
17
+ "acked",
18
+ "expired",
19
+ "failed",
20
+ "rejected",
21
+ ]);
22
+ exports.SessionStateSchema = zod_1.z.enum([
23
+ "none",
24
+ "handshaking",
25
+ "connected",
26
+ "reconnecting",
27
+ "dead",
28
+ ]);
29
+ exports.DeliveryReadinessSchema = zod_1.z.enum(["cannot_address", "can_queue_only", "can_send_now"]);
30
+ exports.QueuedReasonSchema = zod_1.z.enum([
31
+ "route_not_established",
32
+ "awaiting_remote_ack",
33
+ "transport_unavailable",
34
+ ]);
35
+ exports.OutboxReceiptStatusSchema = zod_1.z.enum([
36
+ "queued_for_route",
37
+ "dispatching",
38
+ "acked",
39
+ "expired",
40
+ ]);
41
+ exports.DeliveryReceiptInputSchema = zod_1.z
42
+ .object({
43
+ transport: exports.RuntimeTransportSchema,
44
+ delivered: zod_1.z.boolean(),
45
+ queued: zod_1.z.boolean(),
46
+ accepted: zod_1.z.boolean().optional(),
47
+ deliveryState: exports.DeliveryStateSchema.optional(),
48
+ sessionState: exports.SessionStateSchema.optional(),
49
+ deliveryReadiness: exports.DeliveryReadinessSchema.optional(),
50
+ queuedReason: exports.QueuedReasonSchema.optional(),
51
+ })
52
+ .strict();
53
+ const DELIVERY_STATE_RESTRICTIVENESS = {
54
+ rejected: 0,
55
+ failed: 1,
56
+ expired: 2,
57
+ queued_for_route: 3,
58
+ dispatching: 4,
59
+ accepted: 5,
60
+ sent: 6,
61
+ acked: 7,
62
+ };
63
+ const SESSION_STATE_RESTRICTIVENESS = {
64
+ dead: 0,
65
+ none: 1,
66
+ handshaking: 2,
67
+ reconnecting: 3,
68
+ connected: 4,
69
+ };
70
+ const DELIVERY_READINESS_RESTRICTIVENESS = {
71
+ cannot_address: 0,
72
+ can_queue_only: 1,
73
+ can_send_now: 2,
74
+ };
75
+ function inferLegacyDeliveryState(input, accepted) {
76
+ if (!accepted) {
77
+ return input.deliveryState === "rejected" ? "rejected" : "failed";
78
+ }
79
+ if (input.delivered) {
80
+ return "acked";
81
+ }
82
+ if (input.queued) {
83
+ if (input.queuedReason === "awaiting_remote_ack" ||
84
+ input.deliveryState === "dispatching" ||
85
+ input.deliveryState === "sent") {
86
+ return "dispatching";
87
+ }
88
+ return "queued_for_route";
89
+ }
90
+ if (input.deliveryState === "expired") {
91
+ return "expired";
92
+ }
93
+ return "sent";
94
+ }
95
+ function normalizeExplicitDeliveryState(input) {
96
+ if (!input.deliveryState) {
97
+ return undefined;
98
+ }
99
+ if (input.deliveryState === "sent" &&
100
+ input.queued &&
101
+ input.queuedReason === "awaiting_remote_ack") {
102
+ return "dispatching";
103
+ }
104
+ return input.deliveryState;
105
+ }
106
+ function chooseMoreRestrictiveDeliveryState(left, right) {
107
+ return DELIVERY_STATE_RESTRICTIVENESS[left] <= DELIVERY_STATE_RESTRICTIVENESS[right]
108
+ ? left
109
+ : right;
110
+ }
111
+ function inferSessionStateFromDeliveryState(transport, deliveryState) {
112
+ if (transport === "local_runtime") {
113
+ return "none";
114
+ }
115
+ switch (deliveryState) {
116
+ case "queued_for_route":
117
+ return "handshaking";
118
+ case "dispatching":
119
+ return "connected";
120
+ case "failed":
121
+ case "rejected":
122
+ case "expired":
123
+ return "none";
124
+ case "acked":
125
+ return "connected";
126
+ case "accepted":
127
+ case "sent":
128
+ return "connected";
129
+ default:
130
+ return "none";
131
+ }
132
+ }
133
+ function chooseMoreRestrictiveSessionState(transport, explicit, inferred) {
134
+ if (transport === "local_runtime") {
135
+ return "none";
136
+ }
137
+ if (!explicit) {
138
+ return inferred;
139
+ }
140
+ return SESSION_STATE_RESTRICTIVENESS[explicit] <= SESSION_STATE_RESTRICTIVENESS[inferred]
141
+ ? explicit
142
+ : inferred;
143
+ }
144
+ function inferDeliveryReadinessFromState(transport, deliveryState, sessionState) {
145
+ if (deliveryState === "failed" || deliveryState === "rejected") {
146
+ return "cannot_address";
147
+ }
148
+ if (transport === "local_runtime" && deliveryState === "acked") {
149
+ return "can_queue_only";
150
+ }
151
+ if (deliveryState === "queued_for_route") {
152
+ return "can_queue_only";
153
+ }
154
+ if (deliveryState === "dispatching") {
155
+ return sessionState === "reconnecting" ? "can_queue_only" : "can_send_now";
156
+ }
157
+ if (deliveryState === "expired") {
158
+ return "cannot_address";
159
+ }
160
+ return sessionState === "connected" ? "can_send_now" : "can_queue_only";
161
+ }
162
+ function chooseMoreRestrictiveDeliveryReadiness(explicit, inferred) {
163
+ if (!explicit) {
164
+ return inferred;
165
+ }
166
+ return DELIVERY_READINESS_RESTRICTIVENESS[explicit] <=
167
+ DELIVERY_READINESS_RESTRICTIVENESS[inferred]
168
+ ? explicit
169
+ : inferred;
170
+ }
171
+ function deriveCanonicalAccepted(input, deliveryState) {
172
+ if (deliveryState === "rejected") {
173
+ return false;
174
+ }
175
+ return input.accepted ?? true;
176
+ }
177
+ function isQueuedDeliveryState(deliveryState) {
178
+ return deliveryState === "queued_for_route" || deliveryState === "dispatching";
179
+ }
180
+ function inferQueuedReason(input, deliveryState, queued) {
181
+ if (!queued) {
182
+ return undefined;
183
+ }
184
+ if (input.queuedReason) {
185
+ return input.queuedReason;
186
+ }
187
+ if (deliveryState === "dispatching") {
188
+ return "awaiting_remote_ack";
189
+ }
190
+ if (deliveryState === "queued_for_route") {
191
+ return "route_not_established";
192
+ }
193
+ return undefined;
194
+ }
195
+ function canonicalizeDeliveryReceipt(input) {
196
+ const inferredDeliveryState = inferLegacyDeliveryState(input, input.accepted ?? true);
197
+ const explicitDeliveryState = normalizeExplicitDeliveryState(input);
198
+ const deliveryState = explicitDeliveryState
199
+ ? chooseMoreRestrictiveDeliveryState(explicitDeliveryState, inferredDeliveryState)
200
+ : inferredDeliveryState;
201
+ const accepted = deriveCanonicalAccepted(input, deliveryState);
202
+ const delivered = deliveryState === "acked";
203
+ const queued = isQueuedDeliveryState(deliveryState);
204
+ const inferredSessionState = inferSessionStateFromDeliveryState(input.transport, deliveryState);
205
+ const sessionState = chooseMoreRestrictiveSessionState(input.transport, input.sessionState, inferredSessionState);
206
+ const inferredDeliveryReadiness = inferDeliveryReadinessFromState(input.transport, deliveryState, sessionState);
207
+ const deliveryReadiness = chooseMoreRestrictiveDeliveryReadiness(input.deliveryReadiness, inferredDeliveryReadiness);
208
+ const queuedReason = inferQueuedReason(input, deliveryState, queued);
209
+ return {
210
+ transport: input.transport,
211
+ delivered,
212
+ queued,
213
+ accepted,
214
+ deliveryState,
215
+ sessionState,
216
+ deliveryReadiness,
217
+ ...(queuedReason ? { queuedReason } : {}),
218
+ };
219
+ }
220
+ function createAckedDeliveryReceipt(input) {
221
+ return canonicalizeDeliveryReceipt({
222
+ transport: input.transport,
223
+ delivered: true,
224
+ queued: false,
225
+ accepted: true,
226
+ deliveryState: "acked",
227
+ ...(input.sessionState ? { sessionState: input.sessionState } : {}),
228
+ ...(input.deliveryReadiness ? { deliveryReadiness: input.deliveryReadiness } : {}),
229
+ });
230
+ }
231
+ function createQueuedForRouteReceipt(input) {
232
+ return canonicalizeDeliveryReceipt({
233
+ transport: input.transport,
234
+ delivered: false,
235
+ queued: true,
236
+ accepted: true,
237
+ deliveryState: "queued_for_route",
238
+ queuedReason: "route_not_established",
239
+ ...(input.sessionState ? { sessionState: input.sessionState } : {}),
240
+ ...(input.deliveryReadiness ? { deliveryReadiness: input.deliveryReadiness } : {}),
241
+ });
242
+ }
243
+ function createDispatchingDeliveryReceipt(input) {
244
+ return canonicalizeDeliveryReceipt({
245
+ transport: input.transport,
246
+ delivered: false,
247
+ queued: true,
248
+ accepted: true,
249
+ deliveryState: "dispatching",
250
+ queuedReason: "awaiting_remote_ack",
251
+ ...(input.sessionState ? { sessionState: input.sessionState } : {}),
252
+ ...(input.deliveryReadiness ? { deliveryReadiness: input.deliveryReadiness } : {}),
253
+ });
254
+ }
255
+ function createSentDeliveryReceipt(input) {
256
+ return canonicalizeDeliveryReceipt({
257
+ transport: input.transport,
258
+ delivered: false,
259
+ queued: false,
260
+ accepted: true,
261
+ deliveryState: "sent",
262
+ ...(input.sessionState ? { sessionState: input.sessionState } : {}),
263
+ ...(input.deliveryReadiness ? { deliveryReadiness: input.deliveryReadiness } : {}),
264
+ });
265
+ }
266
+ function canonicalizeOutboxReceiptStatus(status) {
267
+ switch (status) {
268
+ case "queued":
269
+ case "queued_for_route":
270
+ return "queued_for_route";
271
+ case "dispatching":
272
+ case "acked":
273
+ case "expired":
274
+ return status;
275
+ default:
276
+ throw new Error(`[delivery-receipts] Unsupported outbox status: ${status}`);
277
+ }
278
+ }
279
+ //# sourceMappingURL=delivery-receipts.js.map
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.isLoopbackDirectEndpointHost = isLoopbackDirectEndpointHost;
4
+ exports.canonicalizeAuthoritativeDirectEndpoint = canonicalizeAuthoritativeDirectEndpoint;
5
+ function normalizeHost(host) {
6
+ return host.trim().toLowerCase();
7
+ }
8
+ function isLoopbackDirectEndpointHost(host) {
9
+ const normalized = normalizeHost(host);
10
+ return (normalized === "localhost" ||
11
+ normalized === "::1" ||
12
+ normalized === "[::1]" ||
13
+ normalized.endsWith(".localhost") ||
14
+ /^127\./.test(normalized));
15
+ }
16
+ function canonicalizeAuthoritativeDirectEndpoint(input) {
17
+ const rawHost = input.endpointHost?.trim();
18
+ const port = input.endpointPort;
19
+ if (!rawHost || typeof port !== "number" || !Number.isFinite(port)) {
20
+ return {};
21
+ }
22
+ if (isLoopbackDirectEndpointHost(rawHost)) {
23
+ return {};
24
+ }
25
+ return {
26
+ endpointHost: rawHost,
27
+ endpointPort: port,
28
+ };
29
+ }
30
+ //# sourceMappingURL=direct-endpoint-authority.js.map
@@ -1,8 +1,173 @@
1
- var Hn=Object.create;var{getPrototypeOf:En,defineProperty:H,getOwnPropertyNames:Ye,getOwnPropertyDescriptor:jn}=Object,ze=Object.prototype.hasOwnProperty;function $e(t){return this[t]}var Vn,Mn,So=(t,n,a)=>{var R=t!=null&&typeof t==="object";if(R){var b=n?Vn??=new WeakMap:Mn??=new WeakMap,I=b.get(t);if(I)return I}a=t!=null?Hn(En(t)):{};let A=n||!t||!t.__esModule?H(a,"default",{value:t,enumerable:!0}):a;for(let g of Ye(t))if(!ze.call(A,g))H(A,g,{get:$e.bind(t,g),enumerable:!0});if(R)b.set(t,A);return A},Jn=(t)=>{var n=(Qe??=new WeakMap).get(t),a;if(n)return n;if(n=H({},"__esModule",{value:!0}),t&&typeof t==="object"||typeof t==="function"){for(var R of Ye(t))if(!ze.call(n,R))H(n,R,{get:$e.bind(t,R),enumerable:!(a=jn(t,R))||a.enumerable})}return Qe.set(t,n),n},Qe;var Kn=(t)=>t;function Fn(t,n){this[t]=Kn.bind(null,n)}var Gn=(t,n)=>{for(var a in n)H(t,a,{get:n[a],enumerable:!0,configurable:!0,set:Fn.bind(n,a)})};var ho=(t,n)=>()=>(t&&(n=t(t=0)),n);var lo={};Gn(lo,{resolveTrustedRuntimeErrorMessage:()=>De,isValidPeerTransportTransition:()=>Tt,isValidPeerStateCombination:()=>we,isValidPeerIdentityTransition:()=>qt,isSupportedNetworkRuntimeProtocolVersion:()=>me,isLoopbackDirectEndpointHost:()=>Ke,ensureOwnerEpochTable:()=>Fe,derivePeerStateFromLegacyStatus:()=>It,createTrustedRuntimeError:()=>Et,createSentDeliveryReceipt:()=>ot,createQueuedForRouteReceipt:()=>tt,createDispatchingDeliveryReceipt:()=>nt,createAckedDeliveryReceipt:()=>et,comparePeerMutationPrecedence:()=>Bt,claimDbOwnerEpoch:()=>qn,canonicalizeOutboxReceiptStatus:()=>rt,canonicalizeDeliveryReceipt:()=>x,canonicalizeAuthoritativeDirectEndpoint:()=>In,canRefreshEndpoint:()=>Ln,canRecordPendingPair:()=>bn,canMutateTrustedState:()=>_n,canHeartbeat:()=>wn,canCommitVerifiedPair:()=>xn,canAttemptDurableDelivery:()=>Dn,canAttemptBestEffortTransport:()=>An,assertSupportedNetworkRuntimeProtocolVersion:()=>Pt,assertDbOwnership:()=>Tn,TransportInviteTokenSchema:()=>lt,TransportEndpointAdvertisementSchema:()=>h,TlsCaFingerprintSchema:()=>_,StaleOwnerError:()=>Z,SigningPublicKeySchema:()=>P,SignedContinuityBindSchema:()=>ee,SessionStateSchema:()=>V,RuntimeTransportSchema:()=>E,RuntimeStatusSchema:()=>$t,RuntimeRunEventSchema:()=>Mt,RuntimeRegisterRequestSchema:()=>vt,RuntimeQueuedReceiptSchema:()=>Jt,RuntimeOwnerRecordSchema:()=>Re,RuntimeNodeAdvertisementSchema:()=>yt,RuntimeIngressEnvelopeSchema:()=>ht,RuntimeIdSchema:()=>v,RuntimeEventSchema:()=>de,RuntimeEventKindSchema:()=>W,RuntimeEventCursorSchema:()=>Gt,RuntimeErrorDiagnosticSchema:()=>T,RuntimeDiscoveryAdvertisementSchema:()=>ft,RuntimeDeliveryReceiptSchema:()=>Kt,RuntimeBootstrapTlsSchema:()=>Je,RuntimeBootstrapRevisionSchema:()=>Ve,RuntimeBootstrapRecordSchema:()=>Cn,RuntimeBootstrapPhaseSchema:()=>ce,RuntimeBootstrapIdentitySchema:()=>kn,RuntimeBootstrapControlEndpointSchema:()=>Me,RuntimeAutonomousLoopStatusSchema:()=>Ie,RuntimeAutonomousLoopSafetyPolicySummarySchema:()=>re,RuntimeAutonomousLoopCommandSchema:()=>Zt,RunResultSchema:()=>jt,RunRequestSchema:()=>Ht,RevokePeerResponseSchema:()=>pn,RevokePeerRequestSchema:()=>un,RevocationOperatorConfirmationSchema:()=>se,RevocationGenerationSchema:()=>F,RevocationDecisionSchema:()=>at,ResumeRunRequestSchema:()=>Vt,RepairPeerResponseSchema:()=>mn,RepairPeerRequestSchema:()=>dn,RelayPendingResponseSchema:()=>At,RelayPendingRequestSchema:()=>be,RelayPendingQuerySchema:()=>Ce,RelayPendingQueryJsonSchema:()=>wt,QueuedReasonSchema:()=>J,PublicationRevisionSchema:()=>K,PrincipalFingerprintSchema:()=>p,PersistedInboxEventSchema:()=>Qt,PendingPairRequestViewSchema:()=>Xt,PendingInviteViewSchema:()=>qe,PeerViewEventSchema:()=>Yt,PeerTransportStateSchema:()=>$,PeerTransportIdSchema:()=>m,PeerStateSnapshotSchema:()=>Ae,PeerMutationKindSchema:()=>_t,PeerIdentityStateSchema:()=>z,PairRequestRouteBodySchema:()=>ve,PairRequestRouteBodyJsonSchema:()=>bt,PairRequestResponseSchema:()=>Wt,PairRequestDecisionSchema:()=>Ut,PairRelayRouteBodySchema:()=>ke,PairRelayRouteBodyJsonSchema:()=>Lt,PairProposalSchema:()=>kt,OwnerGenerationSchema:()=>G,OutboxReceiptStatusSchema:()=>We,OutboundMessageSchema:()=>Ft,NodePrincipalBindingRefSchema:()=>Q,NodeMetadataSchema:()=>it,NodeIdSchema:()=>i,NodeAdvertisementSchema:()=>U,NetworkRuntimeProtocolVersionSchema:()=>S,NetworkRouteRevokeRequestSchema:()=>fe,NetworkRouteRevokeRequestJsonSchema:()=>Ct,NearbyPeerViewSchema:()=>zt,NETWORK_RUNTIME_PROTOCOL_VERSION:()=>Y,MutationOperationSchema:()=>he,MutationEnvelopeSchema:()=>ye,LoopbackTlsIdentitySchema:()=>X,LocalRuntimeSummarySchema:()=>st,LocalControlSocketSuccessResponseSchema:()=>Ee,LocalControlSocketResponseSchema:()=>vn,LocalControlSocketRequestSchema:()=>fn,LocalControlSocketMethodSchema:()=>He,LocalControlSocketErrorResponseSchema:()=>je,LocalControlSocketDetachClientResponseSchema:()=>yn,LocalControlSocketDetachClientRequestSchema:()=>hn,LocalControlSocketAttachClientResponseSchema:()=>Sn,LocalControlSocketAttachClientRequestSchema:()=>ln,LocalControlClientKindSchema:()=>ie,LegacyPeerRuntimeShapeSchema:()=>Le,LegacyPeerRegistryStatusSchema:()=>xe,JoinRouteBodySchema:()=>le,JoinRouteBodyJsonSchema:()=>St,JoinRequestSchema:()=>N,InvitePeerResultSchema:()=>nn,InvitePeerRequestSchema:()=>tn,InboxListRequestSchema:()=>Ot,InboxCursorSchema:()=>_e,InboxAddressSchema:()=>O,EndpointRevisionSchema:()=>L,DurableSubmitResultSchema:()=>ut,DurableDeliveryResultSchema:()=>Rt,DurableDeliveryHandleSchema:()=>ue,DirectPairResponseSchema:()=>Rn,DirectPairRequestSchema:()=>Be,DirectPairRequestJsonSchema:()=>sn,DeliveryStateSchema:()=>j,DeliveryReadinessSchema:()=>M,DeliveryLifecycleRevisionSchema:()=>ct,DeliveryAckSchema:()=>Pe,CreateInviteResponseSchema:()=>en,CreateInviteRequestSchema:()=>Nt,ControlEndpointAdvertisementSchema:()=>l,ContinuityStatementSchema:()=>Se,ClientIdSchema:()=>D,CancelInviteResponseSchema:()=>cn,CancelInviteRequestSchema:()=>an,BindingGenerationSchema:()=>q,AttachedClientViewSchema:()=>Pn,AttachedClientLeaseGrantSchema:()=>ae,AttachedClientAuthSchema:()=>ge,AcceptInviteTokenResponseSchema:()=>rn,AcceptInviteTokenRequestSchema:()=>on,AcceptInviteResponseSchema:()=>Te,AcceptInviteRequestSchema:()=>ne,AcceptInviteRequestBodyJsonSchema:()=>xt});module.exports=Jn(lo);var y=require("zod"),E=y.z.enum(["in_process","local_runtime","tunnel","relay"]),j=y.z.enum(["accepted","queued_for_route","dispatching","sent","acked","expired","failed","rejected"]),V=y.z.enum(["none","handshaking","connected","reconnecting","dead"]),M=y.z.enum(["cannot_address","can_queue_only","can_send_now"]),J=y.z.enum(["route_not_established","awaiting_remote_ack","transport_unavailable"]),We=y.z.enum(["queued_for_route","dispatching","acked","expired"]),Ne=y.z.object({transport:E,delivered:y.z.boolean(),queued:y.z.boolean(),accepted:y.z.boolean().optional(),deliveryState:j.optional(),sessionState:V.optional(),deliveryReadiness:M.optional(),queuedReason:J.optional()}).strict(),Ze={rejected:0,failed:1,expired:2,queued_for_route:3,dispatching:4,accepted:5,sent:6,acked:7},Xe={dead:0,none:1,handshaking:2,reconnecting:3,connected:4},Ue={cannot_address:0,can_queue_only:1,can_send_now:2};function On(t,n){if(!n)return t.deliveryState==="rejected"?"rejected":"failed";if(t.delivered)return"acked";if(t.queued){if(t.queuedReason==="awaiting_remote_ack"||t.deliveryState==="dispatching"||t.deliveryState==="sent")return"dispatching";return"queued_for_route"}if(t.deliveryState==="expired")return"expired";return"sent"}function Qn(t){if(!t.deliveryState)return;if(t.deliveryState==="sent"&&t.queued&&t.queuedReason==="awaiting_remote_ack")return"dispatching";return t.deliveryState}function Yn(t,n){return Ze[t]<=Ze[n]?t:n}function zn(t,n){if(t==="local_runtime")return"none";switch(n){case"queued_for_route":return"handshaking";case"dispatching":return"connected";case"failed":case"rejected":case"expired":return"none";case"acked":return"connected";case"accepted":case"sent":return"connected";default:return"none"}}function $n(t,n,a){if(t==="local_runtime")return"none";if(!n)return a;return Xe[n]<=Xe[a]?n:a}function Zn(t,n,a){if(n==="failed"||n==="rejected")return"cannot_address";if(t==="local_runtime"&&n==="acked")return"can_queue_only";if(n==="queued_for_route")return"can_queue_only";if(n==="dispatching")return a==="reconnecting"?"can_queue_only":"can_send_now";if(n==="expired")return"cannot_address";return a==="connected"?"can_send_now":"can_queue_only"}function Xn(t,n){if(!t)return n;return Ue[t]<=Ue[n]?t:n}function Un(t,n){if(n==="rejected")return!1;return t.accepted??!0}function Wn(t){return t==="queued_for_route"||t==="dispatching"}function Nn(t,n,a){if(!a)return;if(t.queuedReason)return t.queuedReason;if(n==="dispatching")return"awaiting_remote_ack";if(n==="queued_for_route")return"route_not_established";return}function x(t){let n=On(t,t.accepted??!0),a=Qn(t),R=a?Yn(a,n):n,b=Un(t,R),I=R==="acked",A=Wn(R),g=zn(t.transport,R),Ge=$n(t.transport,t.sessionState,g),Bn=Zn(t.transport,R,Ge),gn=Xn(t.deliveryReadiness,Bn),Oe=Nn(t,R,A);return{transport:t.transport,delivered:I,queued:A,accepted:b,deliveryState:R,sessionState:Ge,deliveryReadiness:gn,...Oe?{queuedReason:Oe}:{}}}function et(t){return x({transport:t.transport,delivered:!0,queued:!1,accepted:!0,deliveryState:"acked",...t.sessionState?{sessionState:t.sessionState}:{},...t.deliveryReadiness?{deliveryReadiness:t.deliveryReadiness}:{}})}function tt(t){return x({transport:t.transport,delivered:!1,queued:!0,accepted:!0,deliveryState:"queued_for_route",queuedReason:"route_not_established",...t.sessionState?{sessionState:t.sessionState}:{},...t.deliveryReadiness?{deliveryReadiness:t.deliveryReadiness}:{}})}function nt(t){return x({transport:t.transport,delivered:!1,queued:!0,accepted:!0,deliveryState:"dispatching",queuedReason:"awaiting_remote_ack",...t.sessionState?{sessionState:t.sessionState}:{},...t.deliveryReadiness?{deliveryReadiness:t.deliveryReadiness}:{}})}function ot(t){return x({transport:t.transport,delivered:!1,queued:!1,accepted:!0,deliveryState:"sent",...t.sessionState?{sessionState:t.sessionState}:{},...t.deliveryReadiness?{deliveryReadiness:t.deliveryReadiness}:{}})}function rt(t){switch(t){case"queued":case"queued_for_route":return"queued_for_route";case"dispatching":case"acked":case"expired":return t;default:throw Error(`[delivery-receipts] Unsupported outbox status: ${t}`)}}var r=require("zod"),d=r.z.string().trim().min(1),i=d.brand(),v=d.brand(),it=r.z.object({nodeId:i,createdAt:d,schemaVersion:r.z.number().int().positive(),migratedFromLegacy:r.z.boolean()}),K=r.z.number().int().nonnegative(),L=r.z.number().int().nonnegative(),q=r.z.number().int().nonnegative(),F=r.z.number().int().nonnegative(),se=r.z.enum(["local_operator_confirmed","remote_capability_authenticated"]),at=r.z.object({localNodeId:i,targetNodeId:i,revocationGeneration:F,operatorConfirmation:se}),G=r.z.number().int().positive(),ct=r.z.number().int().nonnegative(),Re=r.z.object({schemaVersion:r.z.number().int().positive(),nodeId:i,ariaHome:d,runtimePid:r.z.number().int().positive(),runtimeId:v,displayNameSnapshot:d.optional(),runtimeSocket:d,startedAt:d,lastHeartbeat:d,ownerGeneration:G}).strict(),D=d.brand(),p=d.brand(),m=d.brand(),_=d.brand(),X=d.brand(),P=d.brand(),h=r.z.object({host:d,port:r.z.number().int().min(1).max(65535)}),O=r.z.discriminatedUnion("kind",[r.z.object({kind:r.z.literal("node"),nodeId:i}),r.z.object({kind:r.z.literal("client"),clientId:D})]),l=r.z.object({host:d,port:r.z.number().int().min(1).max(65535),tlsCaFingerprint:_,tlsServerIdentity:p,protocolVersion:r.z.number().int().positive(),endpointRevision:L.optional()}),U=r.z.object({nodeId:i,principalFingerprint:p,transportPublicKey:m,publicationRevision:K.optional(),controlEndpoint:l.optional(),displayNameSnapshot:d.optional()}),st=r.z.object({nodeId:i,runtimeId:v,lastHeartbeat:d.optional(),controlEndpoint:l.optional(),displayNameSnapshot:d.optional()}),ue=d.brand(),Rt=r.z.discriminatedUnion("status",[r.z.object({status:r.z.literal("pending"),queuedAt:r.z.string(),nextAttemptAt:r.z.string().optional(),attemptCount:r.z.number()}),r.z.object({status:r.z.literal("delivered"),deliveredAt:r.z.string()}),r.z.object({status:r.z.literal("expired"),reason:r.z.literal("ttl_exceeded"),queuedAt:r.z.string(),expiredAt:r.z.string()}),r.z.object({status:r.z.literal("rejected"),reason:r.z.enum(["recipient_revoked","recipient_unknown","envelope_invalid"])})]),ut=r.z.discriminatedUnion("status",[r.z.object({status:r.z.literal("accepted"),operationId:ue,queuedAt:r.z.string()}),r.z.object({status:r.z.literal("rejected"),reason:r.z.enum(["recipient_revoked","recipient_unknown","envelope_invalid"])})]);var pe=require("zod");var eo=pe.z.string().trim().min(1),Q=pe.z.object({nodeId:i,principalFingerprint:p,transportPublicKey:m,bindingGeneration:q,displayNameSnapshot:eo.optional()}).strict();var u=require("zod");var c=require("zod");var w=require("zod");var pt=w.z.string().trim().min(1),to=w.z.record(w.z.string(),w.z.unknown()),W=w.z.enum(["client_attached","client_detached","runtime_started","runtime_stopped","runtime_stale","runtime_restarted","pair_proposed","proof_committed","continuity_bound","revocation_committed","ingress_accepted","ingress_rejected","durable_send_queued","durable_send_dispatching","durable_send_acked","durable_send_expired"]),de=w.z.object({eventId:pt,nodeId:i,runtimeId:v,kind:W,revision:w.z.number().int().nonnegative().optional(),recordedAt:pt,payload:to}).strict();var s=c.z.string().trim().min(1),no=c.z.string().min(1).refine((t)=>t.trim().length>0),dt=c.z.record(c.z.string(),c.z.unknown());function mt(t){let n=c.z.toJSONSchema(t);return delete n.$schema,n}var Y=1,S=c.z.literal(Y);function me(t){return t===Y}function Pt(t,n="network runtime"){if(!me(t))throw Error(`Unsupported ${n} protocol version ${String(t)}. Supported: ${Y}`);return t}var Pe=c.z.object({protocolVersion:S,messageId:s,senderNodeId:i,recipientNodeId:i,storedAt:c.z.number().int().nonnegative()}).strict(),lt=c.z.object({nodeId:i,audienceNodeId:i.optional(),publicKey:m,leaderDisplayNameSnapshot:s.optional(),host:s,port:c.z.number().int().min(1).max(65535),controlEndpoint:l.optional(),psk:s,displayNameSnapshot:s.optional(),signingPublicKey:P.optional(),caCert:no.optional(),createdAt:c.z.number().int().nonnegative(),expiresAt:c.z.number().int().nonnegative(),tokenNonce:s,coordinationUrl:s.optional(),networkId:s.optional()}).strict(),N=c.z.object({protocolVersion:S,nodeId:i,principalFingerprint:p,peerPublicKey:m,signingPublicKey:P,transportEndpoint:h,controlEndpoint:l.optional(),displayNameSnapshot:s.optional(),inviteTokenNonce:s}).strict(),le=N.extend({proofOfWork:s}).strict(),St=mt(le),ht=c.z.union([c.z.object({protocolVersion:S,deliveryAck:Pe}).strict(),c.z.object({protocolVersion:S,ariaMessage:c.z.unknown()}).strict(),c.z.object({protocolVersion:S,joinRequest:N}).strict()]),yt=U.extend({protocolVersion:S,publicationRevision:K,signingPublicKey:P,transportEndpoint:h,advertisedHosts:c.z.array(s).min(1).optional()}).strict(),ft=c.z.object({protocolVersion:S,nodeId:i,displayNameSnapshot:s,principalFingerprint:p,controlPort:c.z.number().int().min(1).max(65535),advertisedHosts:c.z.array(s).min(1),tlsCaFingerprint:c.z.string().trim().min(1).optional()}).strict(),vt=c.z.object({protocolVersion:S,nodeId:i,transportPublicKey:m,principalFingerprint:p,endpointRevision:L,controlEndpoint:l.optional(),displayNameSnapshot:s.optional()}).strict(),kt=c.z.object({protocolVersion:S,nodeId:i,principalFingerprint:p,transportPublicKey:m,controlEndpoint:l.optional(),displayNameSnapshot:s.optional(),presharedKey:s}).strict(),Se=c.z.object({nodeId:i,previousPrincipalFingerprint:p,newPrincipalFingerprint:p,newTransportPublicKey:m.optional(),bindingGeneration:q,revocationGeneration:F.optional(),createdAt:s}).strict(),ee=c.z.object({statement:Se,delegationSignature:s,acceptanceSignature:s,previousPublicKey:s,newPublicKey:s}).strict(),he=c.z.enum(["network.register","network.revoke","network.list_peers","pair.direct","pair.relay","pair.relay_response","peer.update_capabilities","peer.update_trust_tier"]),ye=c.z.object({version:S,id:s,operation:he,principal:Q,target:Q,namespace:s,policyEpoch:c.z.number().int().nonnegative(),nonce:s,timestamp:c.z.number().int().nonnegative(),ttl:c.z.number().int().positive(),contextHash:s,payload:dt,signature:s,method:s.optional(),path:s.optional(),metadata:dt.optional(),reason:s.optional(),parentEnvelopeId:s.optional()}).strict(),fe=c.z.object({nodeId:i,envelope:ye}).strict(),Ct=mt(fe);var k=u.z.string().trim().min(1);function te(t){let n=u.z.toJSONSchema(t);return delete n.$schema,n}var ve=u.z.object({displayNameSnapshot:k,nodeId:i,signingPublicKey:P,port:u.z.number().int().min(1).max(65535),ephemeralPublicKey:u.z.string().max(512),ephemeralKeySignature:u.z.string().max(512),caCert:u.z.string().max(4096).optional(),protocolVersion:u.z.number().min(1).max(100).optional(),wait:u.z.boolean().optional()}).strict(),bt=te(ve),ne=u.z.object({inviteToken:k,nodeId:i,displayNameSnapshot:k.optional(),transportEndpoint:h,controlEndpoint:l,continuity:ee.optional()}).strict(),xt=te(ne),ke=u.z.object({targetNodeId:i,displayNameSnapshot:k,nodeId:i,signingPublicKey:P,port:u.z.number().int().min(1).max(65535),ephemeralPublicKey:u.z.string().max(512),ephemeralKeySignature:u.z.string().max(512),caCert:u.z.string().max(4096).optional()}).strict(),Lt=te(ke),Ce=u.z.object({targetNodeId:i,signingPublicKey:P,signature:k.max(512),timestamp:k.max(20)}).strict(),wt=te(Ce),be=u.z.object({id:k,nodeId:i,displayNameSnapshot:k.optional(),principalFingerprint:p,signingPublicKey:P,port:u.z.number().int().min(1).max(65535),ingressHost:k,responderControlHostHint:k.optional(),ephemeralPublicKey:u.z.string().max(512).optional(),ephemeralKeySignature:u.z.string().max(512).optional(),caCert:u.z.string().max(4096).optional(),expiresAt:u.z.number().int().nonnegative()}).strict(),At=u.z.object({requests:be.array()}).strict();var e=require("zod");var f=require("zod"),xe=f.z.enum(["active","pending","pending_tunnel","pending_verification","revoked"]),z=f.z.enum(["invited","joining","paired_unverified","verified","revoked"]),$=f.z.enum(["unknown","endpoint_known","connecting","connected","degraded","disconnected"]),_t=f.z.enum(["repair","continuity","revocation"]),Le=f.z.object({status:xe,endpointHost:f.z.string().nullable().optional(),endpointPort:f.z.number().int().nullable().optional(),lastHandshake:f.z.number().int().nullable().optional()}),oo={invited:["unknown","endpoint_known"],joining:["unknown","endpoint_known","connecting"],paired_unverified:["unknown","endpoint_known","connecting","connected","degraded","disconnected"],verified:["unknown","endpoint_known","connecting","connected","degraded","disconnected"],revoked:["unknown","disconnected"]};function we(t,n){return oo[t].includes(n)}var Ae=f.z.object({identityState:z,transportState:$}).superRefine((t,n)=>{if(!we(t.identityState,t.transportState))n.addIssue({code:f.z.ZodIssueCode.custom,message:`invalid peer state combination: ${t.identityState}/${t.transportState}`})});function It(t){let n=Le.parse(t),a=Boolean(n.endpointHost&&n.endpointPort),R=typeof n.lastHandshake==="number"&&Number.isFinite(n.lastHandshake)&&n.lastHandshake>0,b=n.status==="pending"?"invited":n.status==="revoked"?"revoked":n.status==="active"?"verified":"paired_unverified",I=(()=>{switch(n.status){case"active":return R?"connected":a?"endpoint_known":"disconnected";case"pending_tunnel":return R?"connected":a?"connecting":"unknown";case"pending_verification":return R?"connected":a?"endpoint_known":"unknown";case"pending":return a?"endpoint_known":"unknown";case"revoked":return a?"disconnected":"unknown"}})();return Ae.parse({identityState:b,transportState:I})}var ro={invited:["invited","joining","revoked"],joining:["joining","paired_unverified","revoked"],paired_unverified:["paired_unverified","verified","revoked"],verified:["verified","revoked"],revoked:["revoked"]};function qt(t,n,a={}){if(t==="verified"&&n==="paired_unverified")return a.viaContinuity===!0;return ro[t].includes(n)}var io={unknown:["unknown","endpoint_known"],endpoint_known:["endpoint_known","connecting","disconnected"],connecting:["connecting","connected","endpoint_known","disconnected"],connected:["connected","degraded","disconnected"],degraded:["degraded","connected","disconnected"],disconnected:["disconnected","endpoint_known"]};function Tt(t,n){return io[t].includes(n)}var Dt={repair:0,continuity:1,revocation:2};function Bt(t,n){return Dt[t]-Dt[n]}var o=e.z.string().trim().min(1),gt=e.z.enum(["minimal","balanced","high","full"]),oe=e.z.array(e.z.string()).optional(),ao=e.z.array(e.z.custom()).optional();function co(t){let n=e.z.toJSONSchema(t);return delete n.$schema,n}var Ht=e.z.object({task:o,arion:o.optional(),cwd:o.optional(),history:ao,requestedModel:o.optional(),preferredTier:e.z.enum(["fast","balanced","powerful","ensemble"]).optional(),budget:e.z.number().positive().optional(),maxTurns:e.z.number().int().positive().optional(),autonomy:gt.optional(),allowedTools:oe,deniedTools:oe,noMemory:e.z.boolean().optional(),systemPrompt:e.z.string().optional(),approvalMode:e.z.enum(["pause","approve","deny"]).optional(),askUserAnswers:e.z.array(e.z.string()).optional()}).strict(),T=e.z.lazy(()=>e.z.object({message:e.z.string(),name:e.z.string().optional(),stack:e.z.string().optional(),cause:T.optional()}).catchall(e.z.unknown()));function so(t){if(!t||typeof t!=="object")return;let n=t.message;if(typeof n!=="string")return;let a=n.trim();return a.length>0?a:void 0}function Ro(t){let n=t.trim().toLowerCase();return n==="internal server error"||n.startsWith("internal server error:")||n.startsWith("http 500")}function De(t,n){let a=typeof t==="string"&&t.trim().length>0?t:void 0,R=so(n);if(!R)return a;if(!a||Ro(a))return R;return a}function Et(t,n){let a=De(t,n)??"Trusted runtime error";return Object.assign(Error(a),{...n===void 0?{}:{diagnostic:n},...typeof t==="string"&&t.trim().length>0&&t!==a?{publicMessage:t}:{}})}var jt=e.z.object({success:e.z.boolean(),output:e.z.string().optional(),messages:e.z.array(e.z.unknown()).optional(),toolCalls:e.z.array(e.z.unknown()).optional(),usage:e.z.unknown().optional(),turnCount:e.z.number().int().nonnegative().optional(),thinking:e.z.array(e.z.unknown()).optional(),nativeToolResults:e.z.array(e.z.unknown()).optional(),traces:e.z.array(e.z.unknown()).optional(),pipelineTiming:e.z.unknown().optional(),guardrailEvents:e.z.array(e.z.unknown()).optional(),handoffs:e.z.array(e.z.unknown()).optional(),state:e.z.unknown().optional(),error:e.z.string().optional(),diagnostic:T.optional()}).strict(),Vt=e.z.object({state:e.z.unknown(),arion:o.optional(),cwd:o.optional(),requestedModel:o.optional(),preferredTier:e.z.enum(["fast","balanced","powerful","ensemble"]).optional(),budget:e.z.number().positive().optional(),maxTurns:e.z.number().int().positive().optional(),autonomy:gt.optional(),allowedTools:oe,deniedTools:oe,noMemory:e.z.boolean().optional(),systemPrompt:e.z.string().optional(),approvalMode:e.z.enum(["pause","approve","deny"]).optional(),askUserAnswers:e.z.array(e.z.string()).optional()}).strict(),Mt=e.z.discriminatedUnion("type",[e.z.object({type:e.z.literal("text_delta"),content:e.z.string()}),e.z.object({type:e.z.literal("tool_start"),id:o,name:o,input:e.z.unknown().optional()}),e.z.object({type:e.z.literal("approval_needed"),toolName:o,toolInput:e.z.unknown().optional(),riskLevel:e.z.string().optional(),issues:e.z.array(e.z.string()).optional()}),e.z.object({type:e.z.literal("tool_result"),id:o,name:o,durationMs:e.z.number().nonnegative(),result:e.z.unknown(),input:e.z.unknown().optional()}),e.z.object({type:e.z.literal("usage_update"),usage:e.z.unknown()}),e.z.object({type:e.z.literal("turn_complete"),turnNumber:e.z.number().int().nonnegative()}),e.z.object({type:e.z.literal("guardrail_rejected"),stage:e.z.enum(["input","output"]),message:e.z.string()}),e.z.object({type:e.z.literal("pipeline_timing"),report:e.z.unknown()}),e.z.object({type:e.z.literal("messages_snapshot"),messages:e.z.array(e.z.unknown())}),e.z.object({type:e.z.literal("error"),error:e.z.object({message:e.z.string(),diagnostic:T.optional()})}),e.z.object({type:e.z.literal("native_tool_result"),metadata:e.z.unknown()}),e.z.object({type:e.z.literal("thinking_start")}),e.z.object({type:e.z.literal("thinking_delta"),content:e.z.string()}),e.z.object({type:e.z.literal("thinking_end"),blocks:e.z.array(e.z.unknown()),durationMs:e.z.number().nonnegative()}),e.z.object({type:e.z.literal("tool_args_delta"),id:o,args:e.z.string()}),e.z.object({type:e.z.literal("span_start"),spanId:o,spanType:o,name:o}),e.z.object({type:e.z.literal("span_end"),spanId:o,durationMs:e.z.number().nonnegative()}),e.z.object({type:e.z.literal("handoff_start"),target:o,id:o}),e.z.object({type:e.z.literal("handoff_result"),target:o,result:e.z.string(),id:o}),e.z.object({type:e.z.literal("paused"),state:e.z.unknown()})]),Jt=e.z.object(Ne.shape).strict().transform((t)=>x(t)),Kt=e.z.object({transport:E,delivered:e.z.boolean(),queued:e.z.boolean(),accepted:e.z.boolean().optional(),deliveryState:j.optional(),sessionState:V.optional(),deliveryReadiness:M.optional(),queuedReason:J.optional(),storedAt:e.z.number().int().nonnegative().optional()}).strict().transform(({storedAt:t,...n})=>({...x(n),...t!==void 0?{storedAt:t}:{}})),Ft=e.z.object({rawMessage:e.z.record(e.z.string(),e.z.unknown()),recipientInbox:O.optional(),to:o.optional(),content:e.z.string().optional(),type:o.optional(),priority:e.z.number().int().optional(),correlationId:e.z.string().optional(),metadata:e.z.record(e.z.string(),e.z.unknown()).optional()}).strict().superRefine((t,n)=>{if(!t.recipientInbox||t.to===void 0)return;if(t.recipientInbox.kind==="client"){n.addIssue({code:e.z.ZodIssueCode.custom,message:'OutboundMessage.to is a compatibility alias for node recipients only; omit it for recipientInbox.kind === "client"',path:["to"]});return}if(t.recipientInbox.nodeId!==t.to)n.addIssue({code:e.z.ZodIssueCode.custom,message:"OutboundMessage.recipientInbox.nodeId must match OutboundMessage.to when both are provided",path:["to"]})}),Gt=e.z.object({afterRevision:e.z.number().int().nonnegative().optional()}).strict(),_e=e.z.object({afterCreatedAt:e.z.number().int().nonnegative().optional()}).strict(),Ot=e.z.object({cursor:_e.optional(),limit:e.z.number().int().positive().max(1000).optional(),unreadOnly:e.z.boolean().optional()}).strict(),Qt=e.z.object({id:o,senderNodeId:i,senderDisplayNameSnapshot:o.optional(),senderType:o.optional(),senderClientId:e.z.string().nullable().optional(),recipientClientId:e.z.string().nullable().optional(),inboxAddress:O,type:o,content:e.z.string(),priority:e.z.number().int(),createdAt:e.z.number().int().nonnegative(),correlationId:e.z.string().nullable().optional(),replyTo:e.z.string().nullable().optional()}).strict(),Yt=e.z.object({nodeId:i,transportPublicKey:m,displayNameSnapshot:o.optional(),identityState:z,transportState:$,endpointRevision:L,updatedAt:e.z.string(),lastSeenAt:e.z.string().optional()}).strict(),zt=e.z.object({displayNameSnapshot:o,nodeId:i,host:o,port:e.z.number().int().min(1).max(65535),principalFingerprint:p,version:o,tlsCaFingerprint:_.optional(),transport:e.z.enum(["lan","wan"]).optional(),status:e.z.enum(["discovered","connected"]).optional()}).strict(),re=e.z.object({allowedToolCategories:e.z.array(o).optional(),allowedShellCommands:e.z.array(o).optional(),maxWriteOpsPerMinute:e.z.number().int().positive().optional(),maxGitPushesPerHour:e.z.number().int().positive().optional()}).strict(),Ie=e.z.object({status:e.z.enum(["running","stopped"]),intervalMs:e.z.number().int().positive().nullable(),lastWakeTickAt:e.z.string().nullable(),lastCheckpointResult:e.z.enum(["success","error","never"]),safetyPolicySummary:re,ownerClientKind:o.nullable()}).strict();function uo(){return{status:"stopped",intervalMs:null,lastWakeTickAt:null,lastCheckpointResult:"never",safetyPolicySummary:{},ownerClientKind:null}}var $t=e.z.object({nodeId:i,runtimeId:v,port:e.z.number().int().min(1).max(65535),attachedClients:e.z.number().int().nonnegative().optional(),autonomousLoop:Ie.optional().default(uo())}).strict(),Zt=e.z.object({intervalMs:e.z.number().int().positive().optional(),safetyPolicy:re.optional()}).strict(),Xt=e.z.object({id:o,nodeId:i,displayNameSnapshot:o.optional(),principalFingerprint:p}).strict(),qe=e.z.object({inviteId:o,inviteLabel:o.optional(),createdAt:o,expiresAt:o.nullable().optional()}).strict(),Ut=e.z.object({requestId:o,accepted:e.z.boolean()}).strict(),Wt=e.z.object({accepted:e.z.boolean().optional(),inviteToken:e.z.string().optional(),error:e.z.string().optional()}).strict(),Nt=e.z.object({inviteLabel:o.optional(),durationMs:e.z.number().int().min(0).optional()}).strict(),en=e.z.object({inviteToken:o,pendingInvite:qe}).strict(),tn=e.z.object({nodeId:i,displayName:o,principalFingerprint:p.optional(),controlEndpoint:l,transportEndpoint:h.optional(),transport:e.z.enum(["lan","wan"]).optional()}).strict(),Mo=e.z.enum(["pending_verification"]),nn=e.z.discriminatedUnion("mode",[e.z.object({nodeId:i,displayNameSnapshot:o.optional(),mode:e.z.literal("lan_direct"),pairingProofState:e.z.literal("pending_verification")}).strict(),e.z.object({nodeId:i,displayNameSnapshot:o.optional(),mode:e.z.literal("wan_pair"),pairingProofState:e.z.literal("pending_verification")}).strict()]),Te=e.z.object({success:e.z.boolean(),nodeId:i,displayNameSnapshot:o.optional()}).strict(),on=e.z.object({inviteToken:o}).strict(),rn=Te,an=e.z.object({inviteId:o}).strict(),cn=e.z.object({cancelled:e.z.boolean(),inviteId:o}).strict(),Be=e.z.object({peerNodeId:i,principalFingerprint:p,peerDisplayName:o.optional(),peerWgPubkey:m,peerSigningPubkey:o,transportEndpoint:h,controlEndpoint:l,psk:o}).strict(),sn=co(Be),Rn=e.z.object({received:e.z.literal(!0),pairingProofState:e.z.literal("pending_verification")}).strict(),un=e.z.object({nodeId:i,envelope:e.z.record(e.z.string(),e.z.unknown()).optional()}).strict(),pn=e.z.object({revoked:e.z.boolean(),nodeId:i,displayNameSnapshot:o.optional()}).strict(),dn=e.z.object({nodeId:i,endpointHost:o,endpointPort:e.z.number().int().min(1).max(65535),endpointRevision:L}).strict(),mn=e.z.object({repaired:e.z.boolean(),nodeId:i,endpointHost:o,endpointPort:e.z.number().int().min(1).max(65535),endpointRevision:L}).strict(),ie=e.z.enum(["tui","daemon-launcher","pipe","local-api"]),Pn=e.z.object({clientId:D,clientKind:ie,displayLabel:o,self:e.z.boolean(),attachedAt:o,lastSeenAt:o}).strict(),ae=e.z.object({clientId:D,clientAuthToken:o}).strict(),ge=ae,ln=e.z.object({clientKind:ie,lease:e.z.boolean().optional(),pid:e.z.number().optional(),displayName:e.z.string().optional()}).strict(),Sn=ae,hn=e.z.object({clientId:D}).strict(),yn=e.z.object({detached:e.z.boolean()}).strict(),He=e.z.enum(["submitRun","resumeRun","streamRun","subscribeRuntimeEvents","sendBestEffort","sendDurable","listInbox","listDirectClientInbox","listPeers","listNearbyPeers","listAttachedClients","subscribeDirectClientInbox","getRuntimeStatus","startAutonomousLoop","stopAutonomousLoop","getRuntimeBootstrap","listPendingPairRequests","respondToPairRequest","createInvite","listPendingInvites","acceptInviteToken","cancelInvite","invitePeer","acceptInvite","directPair","revokePeer","repairPeer","attachClient","detachClient","watchInbox"]),po=new Set(["listAttachedClients","listDirectClientInbox","subscribeDirectClientInbox"]),fn=e.z.object({id:o,method:He,payload:e.z.unknown().optional(),auth:ge.optional()}).strict().superRefine((t,n)=>{if(po.has(t.method)&&t.auth===void 0)n.addIssue({code:e.z.ZodIssueCode.custom,message:`Local control socket method ${t.method} requires attached-client auth`,path:["auth"]})}),Ee=e.z.object({id:o,ok:e.z.literal(!0),payload:e.z.unknown().optional()}).strict(),je=e.z.object({id:o,ok:e.z.literal(!1),error:o,reason:e.z.string().optional(),diagnostic:T.optional()}).strict(),vn=e.z.discriminatedUnion("ok",[Ee,je]);var C=require("zod");var B=C.z.string().trim().min(1),mo=C.z.string().min(1).refine((t)=>t.trim().length>0),Ve=C.z.number().int().nonnegative(),ce=C.z.enum(["starting","tls_bound","control_ready","network_ready","mesh_ready","degraded","stopped"]),Me=C.z.object({host:B,port:C.z.number().int().min(1).max(65535)}).strict(),Je=C.z.object({caFingerprint:_,caCertPem:mo,principalIdentity:p,loopbackIdentity:X}).strict(),kn=C.z.object({signingPublicKey:P,transportPublicKey:m,transportEndpoint:h,displayNameSnapshot:B.optional()}).strict(),Cn=C.z.object({nodeId:i,runtimeId:v,arionName:B.optional(),ownerGeneration:G,bootstrapRevision:Ve,phase:ce,protocolVersion:S,controlEndpoint:Me,displayNameSnapshot:B.optional(),signingPublicKey:P,transportPublicKey:m,transportEndpoint:h,tls:Je,publishedAt:B,degradedReason:B.optional(),failedPhase:ce.optional()}).strict();function bn(t){return t==="invited"||t==="joining"}function xn(t,n){return t==="paired_unverified"&&n.proofValid}function Ln(t){return t==="joining"||t==="paired_unverified"||t==="verified"}function wn(t){return t==="paired_unverified"||t==="verified"}function An(t,n){if(t==="revoked")return!1;return n==="endpoint_known"||n==="connecting"||n==="connected"||n==="degraded"}function Dn(t,n){return t==="verified"&&n==="connected"}function _n(t){return t==="verified"}function Po(t){return t.trim().toLowerCase()}function Ke(t){let n=Po(t);return n==="localhost"||n==="::1"||n==="[::1]"||n.endsWith(".localhost")||/^127\./.test(n)}function In(t){let n=t.endpointHost?.trim(),a=t.endpointPort;if(!n||typeof a!=="number"||!Number.isFinite(a))return{};if(Ke(n))return{};return{endpointHost:n,endpointPort:a}}class Z extends Error{kind="StaleOwnerError";claimedGeneration;currentGeneration;constructor(t,n){super(`StaleOwnerError: runtime claims generation ${t} but store is at generation ${n}. This runtime has been superseded and must shut down immediately.`);this.name="StaleOwnerError",this.claimedGeneration=t,this.currentGeneration=n}}function Fe(t){t.exec(`
2
- CREATE TABLE IF NOT EXISTS owner_epoch (
3
- scope TEXT PRIMARY KEY DEFAULT 'runtime',
4
- owner_generation INTEGER NOT NULL
5
- )
6
- `)}function qn(t,n){if(Fe(t),t.prepare(`INSERT INTO owner_epoch (scope, owner_generation) VALUES ('runtime', ?)
7
- ON CONFLICT(scope) DO UPDATE SET owner_generation = excluded.owner_generation
8
- WHERE excluded.owner_generation > owner_epoch.owner_generation`).run(n).changes===0){let b=t.prepare("SELECT owner_generation FROM owner_epoch WHERE scope = 'runtime'").get()?.owner_generation??0;if(b>n)throw new Z(n,b)}}function Tn(t,n){let R=t.prepare("SELECT owner_generation FROM owner_epoch WHERE scope = 'runtime'").get()?.owner_generation??0;if(R>n)throw new Z(n,R)}
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.RunResultSchema = exports.RunRequestSchema = exports.RelayPendingResponseSchema = exports.RelayPendingRequestSchema = exports.RelayPendingQueryJsonSchema = exports.RelayPendingQuerySchema = exports.PairRelayRouteBodyJsonSchema = exports.PairRelayRouteBodySchema = exports.AcceptInviteRequestBodyJsonSchema = exports.AcceptInviteRequestSchema = exports.PairRequestRouteBodyJsonSchema = exports.PairRequestRouteBodySchema = exports.NodePrincipalBindingRefSchema = exports.LocalRuntimeSummarySchema = exports.NodeAdvertisementSchema = exports.ControlEndpointAdvertisementSchema = exports.InboxAddressSchema = exports.TransportEndpointAdvertisementSchema = exports.LoopbackTlsIdentitySchema = exports.TlsCaFingerprintSchema = exports.SigningPublicKeySchema = exports.PeerTransportIdSchema = exports.PrincipalFingerprintSchema = exports.ClientIdSchema = exports.DurableSubmitResultSchema = exports.DurableDeliveryResultSchema = exports.DurableDeliveryHandleSchema = exports.DeliveryLifecycleRevisionSchema = exports.OwnerGenerationSchema = exports.RevocationDecisionSchema = exports.RevocationOperatorConfirmationSchema = exports.RevocationGenerationSchema = exports.BindingGenerationSchema = exports.EndpointRevisionSchema = exports.PublicationRevisionSchema = exports.RuntimeIdSchema = exports.NodeMetadataSchema = exports.NodeIdSchema = exports.createSentDeliveryReceipt = exports.createDispatchingDeliveryReceipt = exports.createQueuedForRouteReceipt = exports.createAckedDeliveryReceipt = exports.canonicalizeOutboxReceiptStatus = exports.canonicalizeDeliveryReceipt = exports.OutboxReceiptStatusSchema = exports.QueuedReasonSchema = exports.DeliveryReadinessSchema = exports.SessionStateSchema = exports.DeliveryStateSchema = exports.RuntimeTransportSchema = void 0;
4
+ exports.LocalControlSocketErrorResponseSchema = exports.LocalControlSocketSuccessResponseSchema = exports.LocalControlSocketRequestSchema = exports.LocalControlSocketMethodSchema = exports.LocalControlSocketDetachClientResponseSchema = exports.LocalControlSocketDetachClientRequestSchema = exports.LocalControlSocketAttachClientResponseSchema = exports.LocalControlSocketAttachClientRequestSchema = exports.LocalControlClientKindSchema = exports.RepairPeerResponseSchema = exports.RepairPeerRequestSchema = exports.RevokePeerResponseSchema = exports.RevokePeerRequestSchema = exports.DirectPairResponseSchema = exports.DirectPairRequestJsonSchema = exports.DirectPairRequestSchema = exports.CancelInviteResponseSchema = exports.CancelInviteRequestSchema = exports.AcceptInviteTokenResponseSchema = exports.AcceptInviteTokenRequestSchema = exports.AcceptInviteResponseSchema = exports.InvitePeerResultSchema = exports.InvitePeerRequestSchema = exports.CreateInviteResponseSchema = exports.CreateInviteRequestSchema = exports.PairRequestResponseSchema = exports.PairRequestDecisionSchema = exports.PendingInviteViewSchema = exports.PendingPairRequestViewSchema = exports.RuntimeStatusSchema = exports.RuntimeAutonomousLoopCommandSchema = exports.RuntimeAutonomousLoopStatusSchema = exports.RuntimeAutonomousLoopSafetyPolicySummarySchema = exports.NearbyPeerViewSchema = exports.PeerViewEventSchema = exports.PersistedInboxEventSchema = exports.AttachedClientAuthSchema = exports.AttachedClientLeaseGrantSchema = exports.AttachedClientViewSchema = exports.InboxListRequestSchema = exports.InboxCursorSchema = exports.RuntimeEventCursorSchema = exports.OutboundMessageSchema = exports.RuntimeDeliveryReceiptSchema = exports.RuntimeQueuedReceiptSchema = exports.RuntimeRunEventSchema = exports.ResumeRunRequestSchema = exports.resolveTrustedRuntimeErrorMessage = exports.createTrustedRuntimeError = exports.RuntimeErrorDiagnosticSchema = void 0;
5
+ exports.isLoopbackDirectEndpointHost = exports.canonicalizeAuthoritativeDirectEndpoint = exports.canMutateTrustedState = exports.canAttemptDurableDelivery = exports.canAttemptBestEffortTransport = exports.canHeartbeat = exports.canRefreshEndpoint = exports.canCommitVerifiedPair = exports.canRecordPendingPair = exports.comparePeerMutationPrecedence = exports.isValidPeerTransportTransition = exports.isValidPeerIdentityTransition = exports.isValidPeerStateCombination = exports.derivePeerStateFromLegacyStatus = exports.PeerStateSnapshotSchema = exports.LegacyPeerRuntimeShapeSchema = exports.PeerMutationKindSchema = exports.PeerTransportStateSchema = exports.PeerIdentityStateSchema = exports.LegacyPeerRegistryStatusSchema = exports.assertSupportedNetworkRuntimeProtocolVersion = exports.isSupportedNetworkRuntimeProtocolVersion = exports.NetworkRouteRevokeRequestJsonSchema = exports.NetworkRouteRevokeRequestSchema = exports.MutationEnvelopeSchema = exports.MutationOperationSchema = exports.SignedContinuityBindSchema = exports.ContinuityStatementSchema = exports.PairProposalSchema = exports.RuntimeRegisterRequestSchema = exports.RuntimeDiscoveryAdvertisementSchema = exports.RuntimeNodeAdvertisementSchema = exports.RuntimeIngressEnvelopeSchema = exports.JoinRouteBodyJsonSchema = exports.JoinRouteBodySchema = exports.JoinRequestSchema = exports.TransportInviteTokenSchema = exports.DeliveryAckSchema = exports.NetworkRuntimeProtocolVersionSchema = exports.NETWORK_RUNTIME_PROTOCOL_VERSION = exports.RuntimeBootstrapRecordSchema = exports.RuntimeBootstrapIdentitySchema = exports.RuntimeBootstrapTlsSchema = exports.RuntimeBootstrapControlEndpointSchema = exports.RuntimeBootstrapPhaseSchema = exports.RuntimeBootstrapRevisionSchema = exports.RuntimeEventSchema = exports.RuntimeEventKindSchema = exports.RuntimeOwnerRecordSchema = exports.LocalControlSocketResponseSchema = void 0;
6
+ exports.assertDbOwnership = exports.claimDbOwnerEpoch = exports.ensureOwnerEpochTable = exports.StaleOwnerError = void 0;
7
+ var delivery_receipts_js_1 = require("./delivery-receipts.js");
8
+ Object.defineProperty(exports, "RuntimeTransportSchema", { enumerable: true, get: function () { return delivery_receipts_js_1.RuntimeTransportSchema; } });
9
+ Object.defineProperty(exports, "DeliveryStateSchema", { enumerable: true, get: function () { return delivery_receipts_js_1.DeliveryStateSchema; } });
10
+ Object.defineProperty(exports, "SessionStateSchema", { enumerable: true, get: function () { return delivery_receipts_js_1.SessionStateSchema; } });
11
+ Object.defineProperty(exports, "DeliveryReadinessSchema", { enumerable: true, get: function () { return delivery_receipts_js_1.DeliveryReadinessSchema; } });
12
+ Object.defineProperty(exports, "QueuedReasonSchema", { enumerable: true, get: function () { return delivery_receipts_js_1.QueuedReasonSchema; } });
13
+ Object.defineProperty(exports, "OutboxReceiptStatusSchema", { enumerable: true, get: function () { return delivery_receipts_js_1.OutboxReceiptStatusSchema; } });
14
+ Object.defineProperty(exports, "canonicalizeDeliveryReceipt", { enumerable: true, get: function () { return delivery_receipts_js_1.canonicalizeDeliveryReceipt; } });
15
+ Object.defineProperty(exports, "canonicalizeOutboxReceiptStatus", { enumerable: true, get: function () { return delivery_receipts_js_1.canonicalizeOutboxReceiptStatus; } });
16
+ Object.defineProperty(exports, "createAckedDeliveryReceipt", { enumerable: true, get: function () { return delivery_receipts_js_1.createAckedDeliveryReceipt; } });
17
+ Object.defineProperty(exports, "createQueuedForRouteReceipt", { enumerable: true, get: function () { return delivery_receipts_js_1.createQueuedForRouteReceipt; } });
18
+ Object.defineProperty(exports, "createDispatchingDeliveryReceipt", { enumerable: true, get: function () { return delivery_receipts_js_1.createDispatchingDeliveryReceipt; } });
19
+ Object.defineProperty(exports, "createSentDeliveryReceipt", { enumerable: true, get: function () { return delivery_receipts_js_1.createSentDeliveryReceipt; } });
20
+ var address_types_js_1 = require("./address-types.js");
21
+ Object.defineProperty(exports, "NodeIdSchema", { enumerable: true, get: function () { return address_types_js_1.NodeIdSchema; } });
22
+ Object.defineProperty(exports, "NodeMetadataSchema", { enumerable: true, get: function () { return address_types_js_1.NodeMetadataSchema; } });
23
+ Object.defineProperty(exports, "RuntimeIdSchema", { enumerable: true, get: function () { return address_types_js_1.RuntimeIdSchema; } });
24
+ Object.defineProperty(exports, "PublicationRevisionSchema", { enumerable: true, get: function () { return address_types_js_1.PublicationRevisionSchema; } });
25
+ Object.defineProperty(exports, "EndpointRevisionSchema", { enumerable: true, get: function () { return address_types_js_1.EndpointRevisionSchema; } });
26
+ Object.defineProperty(exports, "BindingGenerationSchema", { enumerable: true, get: function () { return address_types_js_1.BindingGenerationSchema; } });
27
+ Object.defineProperty(exports, "RevocationGenerationSchema", { enumerable: true, get: function () { return address_types_js_1.RevocationGenerationSchema; } });
28
+ Object.defineProperty(exports, "RevocationOperatorConfirmationSchema", { enumerable: true, get: function () { return address_types_js_1.RevocationOperatorConfirmationSchema; } });
29
+ Object.defineProperty(exports, "RevocationDecisionSchema", { enumerable: true, get: function () { return address_types_js_1.RevocationDecisionSchema; } });
30
+ Object.defineProperty(exports, "OwnerGenerationSchema", { enumerable: true, get: function () { return address_types_js_1.OwnerGenerationSchema; } });
31
+ Object.defineProperty(exports, "DeliveryLifecycleRevisionSchema", { enumerable: true, get: function () { return address_types_js_1.DeliveryLifecycleRevisionSchema; } });
32
+ Object.defineProperty(exports, "DurableDeliveryHandleSchema", { enumerable: true, get: function () { return address_types_js_1.DurableDeliveryHandleSchema; } });
33
+ Object.defineProperty(exports, "DurableDeliveryResultSchema", { enumerable: true, get: function () { return address_types_js_1.DurableDeliveryResultSchema; } });
34
+ Object.defineProperty(exports, "DurableSubmitResultSchema", { enumerable: true, get: function () { return address_types_js_1.DurableSubmitResultSchema; } });
35
+ Object.defineProperty(exports, "ClientIdSchema", { enumerable: true, get: function () { return address_types_js_1.ClientIdSchema; } });
36
+ Object.defineProperty(exports, "PrincipalFingerprintSchema", { enumerable: true, get: function () { return address_types_js_1.PrincipalFingerprintSchema; } });
37
+ Object.defineProperty(exports, "PeerTransportIdSchema", { enumerable: true, get: function () { return address_types_js_1.PeerTransportIdSchema; } });
38
+ Object.defineProperty(exports, "SigningPublicKeySchema", { enumerable: true, get: function () { return address_types_js_1.SigningPublicKeySchema; } });
39
+ Object.defineProperty(exports, "TlsCaFingerprintSchema", { enumerable: true, get: function () { return address_types_js_1.TlsCaFingerprintSchema; } });
40
+ Object.defineProperty(exports, "LoopbackTlsIdentitySchema", { enumerable: true, get: function () { return address_types_js_1.LoopbackTlsIdentitySchema; } });
41
+ Object.defineProperty(exports, "TransportEndpointAdvertisementSchema", { enumerable: true, get: function () { return address_types_js_1.TransportEndpointAdvertisementSchema; } });
42
+ Object.defineProperty(exports, "InboxAddressSchema", { enumerable: true, get: function () { return address_types_js_1.InboxAddressSchema; } });
43
+ Object.defineProperty(exports, "ControlEndpointAdvertisementSchema", { enumerable: true, get: function () { return address_types_js_1.ControlEndpointAdvertisementSchema; } });
44
+ Object.defineProperty(exports, "NodeAdvertisementSchema", { enumerable: true, get: function () { return address_types_js_1.NodeAdvertisementSchema; } });
45
+ Object.defineProperty(exports, "LocalRuntimeSummarySchema", { enumerable: true, get: function () { return address_types_js_1.LocalRuntimeSummarySchema; } });
46
+ var peer_principal_ref_js_1 = require("./peer-principal-ref.js");
47
+ Object.defineProperty(exports, "NodePrincipalBindingRefSchema", { enumerable: true, get: function () { return peer_principal_ref_js_1.NodePrincipalBindingRefSchema; } });
48
+ var pair_route_contract_js_1 = require("./pair-route-contract.js");
49
+ Object.defineProperty(exports, "PairRequestRouteBodySchema", { enumerable: true, get: function () { return pair_route_contract_js_1.PairRequestRouteBodySchema; } });
50
+ Object.defineProperty(exports, "PairRequestRouteBodyJsonSchema", { enumerable: true, get: function () { return pair_route_contract_js_1.PairRequestRouteBodyJsonSchema; } });
51
+ Object.defineProperty(exports, "AcceptInviteRequestSchema", { enumerable: true, get: function () { return pair_route_contract_js_1.AcceptInviteRequestSchema; } });
52
+ Object.defineProperty(exports, "AcceptInviteRequestBodyJsonSchema", { enumerable: true, get: function () { return pair_route_contract_js_1.AcceptInviteRequestBodyJsonSchema; } });
53
+ Object.defineProperty(exports, "PairRelayRouteBodySchema", { enumerable: true, get: function () { return pair_route_contract_js_1.PairRelayRouteBodySchema; } });
54
+ Object.defineProperty(exports, "PairRelayRouteBodyJsonSchema", { enumerable: true, get: function () { return pair_route_contract_js_1.PairRelayRouteBodyJsonSchema; } });
55
+ Object.defineProperty(exports, "RelayPendingQuerySchema", { enumerable: true, get: function () { return pair_route_contract_js_1.RelayPendingQuerySchema; } });
56
+ Object.defineProperty(exports, "RelayPendingQueryJsonSchema", { enumerable: true, get: function () { return pair_route_contract_js_1.RelayPendingQueryJsonSchema; } });
57
+ Object.defineProperty(exports, "RelayPendingRequestSchema", { enumerable: true, get: function () { return pair_route_contract_js_1.RelayPendingRequestSchema; } });
58
+ Object.defineProperty(exports, "RelayPendingResponseSchema", { enumerable: true, get: function () { return pair_route_contract_js_1.RelayPendingResponseSchema; } });
59
+ var local_control_contract_js_1 = require("./local-control-contract.js");
60
+ Object.defineProperty(exports, "RunRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RunRequestSchema; } });
61
+ Object.defineProperty(exports, "RunResultSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RunResultSchema; } });
62
+ Object.defineProperty(exports, "RuntimeErrorDiagnosticSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RuntimeErrorDiagnosticSchema; } });
63
+ Object.defineProperty(exports, "createTrustedRuntimeError", { enumerable: true, get: function () { return local_control_contract_js_1.createTrustedRuntimeError; } });
64
+ Object.defineProperty(exports, "resolveTrustedRuntimeErrorMessage", { enumerable: true, get: function () { return local_control_contract_js_1.resolveTrustedRuntimeErrorMessage; } });
65
+ Object.defineProperty(exports, "ResumeRunRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.ResumeRunRequestSchema; } });
66
+ Object.defineProperty(exports, "RuntimeRunEventSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RuntimeRunEventSchema; } });
67
+ Object.defineProperty(exports, "RuntimeQueuedReceiptSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RuntimeQueuedReceiptSchema; } });
68
+ Object.defineProperty(exports, "RuntimeDeliveryReceiptSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RuntimeDeliveryReceiptSchema; } });
69
+ Object.defineProperty(exports, "OutboundMessageSchema", { enumerable: true, get: function () { return local_control_contract_js_1.OutboundMessageSchema; } });
70
+ Object.defineProperty(exports, "RuntimeEventCursorSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RuntimeEventCursorSchema; } });
71
+ Object.defineProperty(exports, "InboxCursorSchema", { enumerable: true, get: function () { return local_control_contract_js_1.InboxCursorSchema; } });
72
+ Object.defineProperty(exports, "InboxListRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.InboxListRequestSchema; } });
73
+ Object.defineProperty(exports, "AttachedClientViewSchema", { enumerable: true, get: function () { return local_control_contract_js_1.AttachedClientViewSchema; } });
74
+ Object.defineProperty(exports, "AttachedClientLeaseGrantSchema", { enumerable: true, get: function () { return local_control_contract_js_1.AttachedClientLeaseGrantSchema; } });
75
+ Object.defineProperty(exports, "AttachedClientAuthSchema", { enumerable: true, get: function () { return local_control_contract_js_1.AttachedClientAuthSchema; } });
76
+ Object.defineProperty(exports, "PersistedInboxEventSchema", { enumerable: true, get: function () { return local_control_contract_js_1.PersistedInboxEventSchema; } });
77
+ Object.defineProperty(exports, "PeerViewEventSchema", { enumerable: true, get: function () { return local_control_contract_js_1.PeerViewEventSchema; } });
78
+ Object.defineProperty(exports, "NearbyPeerViewSchema", { enumerable: true, get: function () { return local_control_contract_js_1.NearbyPeerViewSchema; } });
79
+ Object.defineProperty(exports, "RuntimeAutonomousLoopSafetyPolicySummarySchema", { enumerable: true, get: function () { return local_control_contract_js_1.RuntimeAutonomousLoopSafetyPolicySummarySchema; } });
80
+ Object.defineProperty(exports, "RuntimeAutonomousLoopStatusSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RuntimeAutonomousLoopStatusSchema; } });
81
+ Object.defineProperty(exports, "RuntimeAutonomousLoopCommandSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RuntimeAutonomousLoopCommandSchema; } });
82
+ Object.defineProperty(exports, "RuntimeStatusSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RuntimeStatusSchema; } });
83
+ Object.defineProperty(exports, "PendingPairRequestViewSchema", { enumerable: true, get: function () { return local_control_contract_js_1.PendingPairRequestViewSchema; } });
84
+ Object.defineProperty(exports, "PendingInviteViewSchema", { enumerable: true, get: function () { return local_control_contract_js_1.PendingInviteViewSchema; } });
85
+ Object.defineProperty(exports, "PairRequestDecisionSchema", { enumerable: true, get: function () { return local_control_contract_js_1.PairRequestDecisionSchema; } });
86
+ Object.defineProperty(exports, "PairRequestResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.PairRequestResponseSchema; } });
87
+ Object.defineProperty(exports, "CreateInviteRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.CreateInviteRequestSchema; } });
88
+ Object.defineProperty(exports, "CreateInviteResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.CreateInviteResponseSchema; } });
89
+ Object.defineProperty(exports, "InvitePeerRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.InvitePeerRequestSchema; } });
90
+ Object.defineProperty(exports, "InvitePeerResultSchema", { enumerable: true, get: function () { return local_control_contract_js_1.InvitePeerResultSchema; } });
91
+ Object.defineProperty(exports, "AcceptInviteResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.AcceptInviteResponseSchema; } });
92
+ Object.defineProperty(exports, "AcceptInviteTokenRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.AcceptInviteTokenRequestSchema; } });
93
+ Object.defineProperty(exports, "AcceptInviteTokenResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.AcceptInviteTokenResponseSchema; } });
94
+ Object.defineProperty(exports, "CancelInviteRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.CancelInviteRequestSchema; } });
95
+ Object.defineProperty(exports, "CancelInviteResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.CancelInviteResponseSchema; } });
96
+ Object.defineProperty(exports, "DirectPairRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.DirectPairRequestSchema; } });
97
+ Object.defineProperty(exports, "DirectPairRequestJsonSchema", { enumerable: true, get: function () { return local_control_contract_js_1.DirectPairRequestJsonSchema; } });
98
+ Object.defineProperty(exports, "DirectPairResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.DirectPairResponseSchema; } });
99
+ Object.defineProperty(exports, "RevokePeerRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RevokePeerRequestSchema; } });
100
+ Object.defineProperty(exports, "RevokePeerResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RevokePeerResponseSchema; } });
101
+ Object.defineProperty(exports, "RepairPeerRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RepairPeerRequestSchema; } });
102
+ Object.defineProperty(exports, "RepairPeerResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.RepairPeerResponseSchema; } });
103
+ Object.defineProperty(exports, "LocalControlClientKindSchema", { enumerable: true, get: function () { return local_control_contract_js_1.LocalControlClientKindSchema; } });
104
+ Object.defineProperty(exports, "LocalControlSocketAttachClientRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.LocalControlSocketAttachClientRequestSchema; } });
105
+ Object.defineProperty(exports, "LocalControlSocketAttachClientResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.LocalControlSocketAttachClientResponseSchema; } });
106
+ Object.defineProperty(exports, "LocalControlSocketDetachClientRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.LocalControlSocketDetachClientRequestSchema; } });
107
+ Object.defineProperty(exports, "LocalControlSocketDetachClientResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.LocalControlSocketDetachClientResponseSchema; } });
108
+ Object.defineProperty(exports, "LocalControlSocketMethodSchema", { enumerable: true, get: function () { return local_control_contract_js_1.LocalControlSocketMethodSchema; } });
109
+ Object.defineProperty(exports, "LocalControlSocketRequestSchema", { enumerable: true, get: function () { return local_control_contract_js_1.LocalControlSocketRequestSchema; } });
110
+ Object.defineProperty(exports, "LocalControlSocketSuccessResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.LocalControlSocketSuccessResponseSchema; } });
111
+ Object.defineProperty(exports, "LocalControlSocketErrorResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.LocalControlSocketErrorResponseSchema; } });
112
+ Object.defineProperty(exports, "LocalControlSocketResponseSchema", { enumerable: true, get: function () { return local_control_contract_js_1.LocalControlSocketResponseSchema; } });
113
+ var node_store_contract_js_1 = require("./node-store-contract.js");
114
+ Object.defineProperty(exports, "RuntimeOwnerRecordSchema", { enumerable: true, get: function () { return node_store_contract_js_1.RuntimeOwnerRecordSchema; } });
115
+ Object.defineProperty(exports, "RuntimeEventKindSchema", { enumerable: true, get: function () { return node_store_contract_js_1.RuntimeEventKindSchema; } });
116
+ Object.defineProperty(exports, "RuntimeEventSchema", { enumerable: true, get: function () { return node_store_contract_js_1.RuntimeEventSchema; } });
117
+ var runtime_bootstrap_contract_js_1 = require("./runtime-bootstrap-contract.js");
118
+ Object.defineProperty(exports, "RuntimeBootstrapRevisionSchema", { enumerable: true, get: function () { return runtime_bootstrap_contract_js_1.RuntimeBootstrapRevisionSchema; } });
119
+ Object.defineProperty(exports, "RuntimeBootstrapPhaseSchema", { enumerable: true, get: function () { return runtime_bootstrap_contract_js_1.RuntimeBootstrapPhaseSchema; } });
120
+ Object.defineProperty(exports, "RuntimeBootstrapControlEndpointSchema", { enumerable: true, get: function () { return runtime_bootstrap_contract_js_1.RuntimeBootstrapControlEndpointSchema; } });
121
+ Object.defineProperty(exports, "RuntimeBootstrapTlsSchema", { enumerable: true, get: function () { return runtime_bootstrap_contract_js_1.RuntimeBootstrapTlsSchema; } });
122
+ Object.defineProperty(exports, "RuntimeBootstrapIdentitySchema", { enumerable: true, get: function () { return runtime_bootstrap_contract_js_1.RuntimeBootstrapIdentitySchema; } });
123
+ Object.defineProperty(exports, "RuntimeBootstrapRecordSchema", { enumerable: true, get: function () { return runtime_bootstrap_contract_js_1.RuntimeBootstrapRecordSchema; } });
124
+ var protocol_schemas_js_1 = require("./protocol-schemas.js");
125
+ Object.defineProperty(exports, "NETWORK_RUNTIME_PROTOCOL_VERSION", { enumerable: true, get: function () { return protocol_schemas_js_1.NETWORK_RUNTIME_PROTOCOL_VERSION; } });
126
+ Object.defineProperty(exports, "NetworkRuntimeProtocolVersionSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.NetworkRuntimeProtocolVersionSchema; } });
127
+ Object.defineProperty(exports, "DeliveryAckSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.DeliveryAckSchema; } });
128
+ Object.defineProperty(exports, "TransportInviteTokenSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.TransportInviteTokenSchema; } });
129
+ Object.defineProperty(exports, "JoinRequestSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.JoinRequestSchema; } });
130
+ Object.defineProperty(exports, "JoinRouteBodySchema", { enumerable: true, get: function () { return protocol_schemas_js_1.JoinRouteBodySchema; } });
131
+ Object.defineProperty(exports, "JoinRouteBodyJsonSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.JoinRouteBodyJsonSchema; } });
132
+ Object.defineProperty(exports, "RuntimeIngressEnvelopeSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.RuntimeIngressEnvelopeSchema; } });
133
+ Object.defineProperty(exports, "RuntimeNodeAdvertisementSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.RuntimeNodeAdvertisementSchema; } });
134
+ Object.defineProperty(exports, "RuntimeDiscoveryAdvertisementSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.RuntimeDiscoveryAdvertisementSchema; } });
135
+ Object.defineProperty(exports, "RuntimeRegisterRequestSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.RuntimeRegisterRequestSchema; } });
136
+ Object.defineProperty(exports, "PairProposalSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.PairProposalSchema; } });
137
+ Object.defineProperty(exports, "ContinuityStatementSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.ContinuityStatementSchema; } });
138
+ Object.defineProperty(exports, "SignedContinuityBindSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.SignedContinuityBindSchema; } });
139
+ Object.defineProperty(exports, "MutationOperationSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.MutationOperationSchema; } });
140
+ Object.defineProperty(exports, "MutationEnvelopeSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.MutationEnvelopeSchema; } });
141
+ Object.defineProperty(exports, "NetworkRouteRevokeRequestSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.NetworkRouteRevokeRequestSchema; } });
142
+ Object.defineProperty(exports, "NetworkRouteRevokeRequestJsonSchema", { enumerable: true, get: function () { return protocol_schemas_js_1.NetworkRouteRevokeRequestJsonSchema; } });
143
+ Object.defineProperty(exports, "isSupportedNetworkRuntimeProtocolVersion", { enumerable: true, get: function () { return protocol_schemas_js_1.isSupportedNetworkRuntimeProtocolVersion; } });
144
+ Object.defineProperty(exports, "assertSupportedNetworkRuntimeProtocolVersion", { enumerable: true, get: function () { return protocol_schemas_js_1.assertSupportedNetworkRuntimeProtocolVersion; } });
145
+ var peer_state_machine_js_1 = require("./peer-state-machine.js");
146
+ Object.defineProperty(exports, "LegacyPeerRegistryStatusSchema", { enumerable: true, get: function () { return peer_state_machine_js_1.LegacyPeerRegistryStatusSchema; } });
147
+ Object.defineProperty(exports, "PeerIdentityStateSchema", { enumerable: true, get: function () { return peer_state_machine_js_1.PeerIdentityStateSchema; } });
148
+ Object.defineProperty(exports, "PeerTransportStateSchema", { enumerable: true, get: function () { return peer_state_machine_js_1.PeerTransportStateSchema; } });
149
+ Object.defineProperty(exports, "PeerMutationKindSchema", { enumerable: true, get: function () { return peer_state_machine_js_1.PeerMutationKindSchema; } });
150
+ Object.defineProperty(exports, "LegacyPeerRuntimeShapeSchema", { enumerable: true, get: function () { return peer_state_machine_js_1.LegacyPeerRuntimeShapeSchema; } });
151
+ Object.defineProperty(exports, "PeerStateSnapshotSchema", { enumerable: true, get: function () { return peer_state_machine_js_1.PeerStateSnapshotSchema; } });
152
+ Object.defineProperty(exports, "derivePeerStateFromLegacyStatus", { enumerable: true, get: function () { return peer_state_machine_js_1.derivePeerStateFromLegacyStatus; } });
153
+ Object.defineProperty(exports, "isValidPeerStateCombination", { enumerable: true, get: function () { return peer_state_machine_js_1.isValidPeerStateCombination; } });
154
+ Object.defineProperty(exports, "isValidPeerIdentityTransition", { enumerable: true, get: function () { return peer_state_machine_js_1.isValidPeerIdentityTransition; } });
155
+ Object.defineProperty(exports, "isValidPeerTransportTransition", { enumerable: true, get: function () { return peer_state_machine_js_1.isValidPeerTransportTransition; } });
156
+ Object.defineProperty(exports, "comparePeerMutationPrecedence", { enumerable: true, get: function () { return peer_state_machine_js_1.comparePeerMutationPrecedence; } });
157
+ var peer_capabilities_js_1 = require("./peer-capabilities.js");
158
+ Object.defineProperty(exports, "canRecordPendingPair", { enumerable: true, get: function () { return peer_capabilities_js_1.canRecordPendingPair; } });
159
+ Object.defineProperty(exports, "canCommitVerifiedPair", { enumerable: true, get: function () { return peer_capabilities_js_1.canCommitVerifiedPair; } });
160
+ Object.defineProperty(exports, "canRefreshEndpoint", { enumerable: true, get: function () { return peer_capabilities_js_1.canRefreshEndpoint; } });
161
+ Object.defineProperty(exports, "canHeartbeat", { enumerable: true, get: function () { return peer_capabilities_js_1.canHeartbeat; } });
162
+ Object.defineProperty(exports, "canAttemptBestEffortTransport", { enumerable: true, get: function () { return peer_capabilities_js_1.canAttemptBestEffortTransport; } });
163
+ Object.defineProperty(exports, "canAttemptDurableDelivery", { enumerable: true, get: function () { return peer_capabilities_js_1.canAttemptDurableDelivery; } });
164
+ Object.defineProperty(exports, "canMutateTrustedState", { enumerable: true, get: function () { return peer_capabilities_js_1.canMutateTrustedState; } });
165
+ var direct_endpoint_authority_js_1 = require("./direct-endpoint-authority.js");
166
+ Object.defineProperty(exports, "canonicalizeAuthoritativeDirectEndpoint", { enumerable: true, get: function () { return direct_endpoint_authority_js_1.canonicalizeAuthoritativeDirectEndpoint; } });
167
+ Object.defineProperty(exports, "isLoopbackDirectEndpointHost", { enumerable: true, get: function () { return direct_endpoint_authority_js_1.isLoopbackDirectEndpointHost; } });
168
+ var db_owner_fencing_js_1 = require("./db-owner-fencing.js");
169
+ Object.defineProperty(exports, "StaleOwnerError", { enumerable: true, get: function () { return db_owner_fencing_js_1.StaleOwnerError; } });
170
+ Object.defineProperty(exports, "ensureOwnerEpochTable", { enumerable: true, get: function () { return db_owner_fencing_js_1.ensureOwnerEpochTable; } });
171
+ Object.defineProperty(exports, "claimDbOwnerEpoch", { enumerable: true, get: function () { return db_owner_fencing_js_1.claimDbOwnerEpoch; } });
172
+ Object.defineProperty(exports, "assertDbOwnership", { enumerable: true, get: function () { return db_owner_fencing_js_1.assertDbOwnership; } });
173
+ //# sourceMappingURL=index.js.map