@intentic/sandbox-contract 1.430.0 → 1.431.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (494) hide show
  1. package/README.md +12 -2
  2. package/dist/app-routes/app-pages.d.ts +1 -0
  3. package/dist/app-routes/app-pages.d.ts.map +1 -1
  4. package/dist/app-routes/app-pages.js +1 -0
  5. package/dist/app-routes/app-pages.js.map +1 -1
  6. package/dist/app-routes/index.d.ts +1 -0
  7. package/dist/app-routes/index.d.ts.map +1 -1
  8. package/dist/app-routes/index.js +1 -0
  9. package/dist/app-routes/index.js.map +1 -1
  10. package/dist/app-routes/return-path.d.ts +2 -0
  11. package/dist/app-routes/return-path.d.ts.map +1 -0
  12. package/dist/app-routes/return-path.js +8 -0
  13. package/dist/app-routes/return-path.js.map +1 -0
  14. package/dist/contracts/accounts.contract.d.ts.map +1 -1
  15. package/dist/contracts/accounts.contract.js +2 -0
  16. package/dist/contracts/accounts.contract.js.map +1 -1
  17. package/dist/contracts/agent.contract.d.ts +357 -0
  18. package/dist/contracts/agent.contract.d.ts.map +1 -1
  19. package/dist/contracts/agents.contract.d.ts +3221 -1576
  20. package/dist/contracts/agents.contract.d.ts.map +1 -1
  21. package/dist/contracts/agents.contract.js +35 -5
  22. package/dist/contracts/agents.contract.js.map +1 -1
  23. package/dist/contracts/automations.contract.d.ts +31 -0
  24. package/dist/contracts/automations.contract.d.ts.map +1 -1
  25. package/dist/contracts/automations.contract.js +1 -0
  26. package/dist/contracts/automations.contract.js.map +1 -1
  27. package/dist/contracts/capabilities.contract.d.ts +12 -0
  28. package/dist/contracts/capabilities.contract.d.ts.map +1 -1
  29. package/dist/contracts/capabilities.contract.js +3 -1
  30. package/dist/contracts/capabilities.contract.js.map +1 -1
  31. package/dist/contracts/device-ci-runners.contract.d.ts +108 -0
  32. package/dist/contracts/device-ci-runners.contract.d.ts.map +1 -0
  33. package/dist/contracts/device-ci-runners.contract.js +56 -0
  34. package/dist/contracts/device-ci-runners.contract.js.map +1 -0
  35. package/dist/contracts/device.contract.d.ts +27 -0
  36. package/dist/contracts/device.contract.d.ts.map +1 -1
  37. package/dist/contracts/extensions.contract.d.ts +1 -0
  38. package/dist/contracts/extensions.contract.d.ts.map +1 -1
  39. package/dist/contracts/extensions.contract.js +1 -1
  40. package/dist/contracts/extensions.contract.js.map +1 -1
  41. package/dist/contracts/git.contract.d.ts +7 -0
  42. package/dist/contracts/git.contract.d.ts.map +1 -1
  43. package/dist/contracts/issues.contract.d.ts +11 -0
  44. package/dist/contracts/issues.contract.d.ts.map +1 -1
  45. package/dist/contracts/needs.contract.d.ts +408 -0
  46. package/dist/contracts/needs.contract.d.ts.map +1 -1
  47. package/dist/contracts/offload.contract.d.ts +4 -0
  48. package/dist/contracts/offload.contract.d.ts.map +1 -1
  49. package/dist/contracts/ports.contract.d.ts +8 -0
  50. package/dist/contracts/ports.contract.d.ts.map +1 -1
  51. package/dist/contracts/ports.contract.js +6 -5
  52. package/dist/contracts/ports.contract.js.map +1 -1
  53. package/dist/contracts/remote.contract.d.ts +1 -0
  54. package/dist/contracts/remote.contract.d.ts.map +1 -1
  55. package/dist/contracts/runner.contract.d.ts +702 -1
  56. package/dist/contracts/runner.contract.d.ts.map +1 -1
  57. package/dist/contracts/runner.contract.js +49 -2
  58. package/dist/contracts/runner.contract.js.map +1 -1
  59. package/dist/contracts/runners.contract.d.ts +16 -0
  60. package/dist/contracts/runners.contract.d.ts.map +1 -0
  61. package/dist/contracts/runners.contract.js +15 -0
  62. package/dist/contracts/runners.contract.js.map +1 -0
  63. package/dist/contracts/safety.contract.d.ts.map +1 -1
  64. package/dist/contracts/safety.contract.js +1 -0
  65. package/dist/contracts/safety.contract.js.map +1 -1
  66. package/dist/contracts/seal.contract.d.ts +85 -0
  67. package/dist/contracts/seal.contract.d.ts.map +1 -1
  68. package/dist/contracts/secrets.contract.d.ts.map +1 -1
  69. package/dist/contracts/secrets.contract.js +6 -0
  70. package/dist/contracts/secrets.contract.js.map +1 -1
  71. package/dist/contracts/sessions.contract.d.ts +48 -0
  72. package/dist/contracts/sessions.contract.d.ts.map +1 -1
  73. package/dist/contracts/settings.contract.d.ts +2 -0
  74. package/dist/contracts/settings.contract.d.ts.map +1 -1
  75. package/dist/contracts/settings.contract.js +1 -0
  76. package/dist/contracts/settings.contract.js.map +1 -1
  77. package/dist/contracts/skills.contract.d.ts +6 -0
  78. package/dist/contracts/skills.contract.d.ts.map +1 -1
  79. package/dist/contracts/system.contract.d.ts +332 -4
  80. package/dist/contracts/system.contract.d.ts.map +1 -1
  81. package/dist/contracts/system.contract.js +14 -3
  82. package/dist/contracts/system.contract.js.map +1 -1
  83. package/dist/contracts/usage.contract.d.ts +3 -0
  84. package/dist/contracts/usage.contract.d.ts.map +1 -1
  85. package/dist/events/agent-events.d.ts +194 -0
  86. package/dist/events/agent-events.d.ts.map +1 -1
  87. package/dist/events/agent-events.js +2 -2
  88. package/dist/events/agent-events.js.map +1 -1
  89. package/dist/events/agent-transcript.d.ts +48 -0
  90. package/dist/events/agent-transcript.d.ts.map +1 -1
  91. package/dist/events/agent-words.d.ts +5 -0
  92. package/dist/events/agent-words.d.ts.map +1 -1
  93. package/dist/events/agent-words.js +20 -1
  94. package/dist/events/agent-words.js.map +1 -1
  95. package/dist/events/refusal-incidents.d.ts +1 -0
  96. package/dist/events/refusal-incidents.d.ts.map +1 -1
  97. package/dist/events/refusal-incidents.js +42 -19
  98. package/dist/events/refusal-incidents.js.map +1 -1
  99. package/dist/events/system-events.d.ts +86 -0
  100. package/dist/events/system-events.d.ts.map +1 -1
  101. package/dist/events/transcript.d.ts +240 -0
  102. package/dist/events/transcript.d.ts.map +1 -1
  103. package/dist/ids/conversation-ids.d.ts +1 -0
  104. package/dist/ids/conversation-ids.d.ts.map +1 -1
  105. package/dist/ids/conversation-ids.js +2 -1
  106. package/dist/ids/conversation-ids.js.map +1 -1
  107. package/dist/ids/project-id.d.ts.map +1 -1
  108. package/dist/ids/project-id.js +4 -4
  109. package/dist/ids/project-id.js.map +1 -1
  110. package/dist/ids/run-row-ids.d.ts +8 -0
  111. package/dist/ids/run-row-ids.d.ts.map +1 -0
  112. package/dist/ids/run-row-ids.js +32 -0
  113. package/dist/ids/run-row-ids.js.map +1 -0
  114. package/dist/index.d.ts +2 -0
  115. package/dist/index.d.ts.map +1 -1
  116. package/dist/index.js +2 -0
  117. package/dist/index.js.map +1 -1
  118. package/dist/models/agent-catalog.d.ts.map +1 -1
  119. package/dist/models/agent-catalog.js +3 -2
  120. package/dist/models/agent-catalog.js.map +1 -1
  121. package/dist/models/agent-lanes.d.ts.map +1 -1
  122. package/dist/models/agent-lanes.js +4 -1
  123. package/dist/models/agent-lanes.js.map +1 -1
  124. package/dist/models/agent-runtimes.d.ts.map +1 -1
  125. package/dist/models/agent-runtimes.js +2 -2
  126. package/dist/models/agent-runtimes.js.map +1 -1
  127. package/dist/models/agent-standing.d.ts +6 -1
  128. package/dist/models/agent-standing.d.ts.map +1 -1
  129. package/dist/models/agent-standing.js +1 -0
  130. package/dist/models/agent-standing.js.map +1 -1
  131. package/dist/models/providers/provider-traits.d.ts +215 -0
  132. package/dist/models/providers/provider-traits.d.ts.map +1 -0
  133. package/dist/models/providers/provider-traits.js +60 -0
  134. package/dist/models/providers/provider-traits.js.map +1 -0
  135. package/dist/netd/browser-wire.d.ts +8 -0
  136. package/dist/netd/browser-wire.d.ts.map +1 -1
  137. package/dist/netd/browser-wire.js +5 -0
  138. package/dist/netd/browser-wire.js.map +1 -1
  139. package/dist/netd/generated/wire.d.ts +42 -1
  140. package/dist/netd/generated/wire.d.ts.map +1 -1
  141. package/dist/policy/admin/admin-grant.d.ts +21 -0
  142. package/dist/policy/admin/admin-grant.d.ts.map +1 -0
  143. package/dist/policy/admin/admin-grant.js +41 -0
  144. package/dist/policy/admin/admin-grant.js.map +1 -0
  145. package/dist/policy/capabilities/capability-kinds.d.ts +268 -0
  146. package/dist/policy/capabilities/capability-kinds.d.ts.map +1 -0
  147. package/dist/policy/capabilities/capability-kinds.js +47 -0
  148. package/dist/policy/capabilities/capability-kinds.js.map +1 -0
  149. package/dist/policy/command-classes.d.ts.map +1 -1
  150. package/dist/policy/command-classes.js +3 -1
  151. package/dist/policy/command-classes.js.map +1 -1
  152. package/dist/policy/device-programs.d.ts +79 -2
  153. package/dist/policy/device-programs.d.ts.map +1 -1
  154. package/dist/policy/device-programs.js +15 -16
  155. package/dist/policy/device-programs.js.map +1 -1
  156. package/dist/policy/reserved-servers.d.ts.map +1 -1
  157. package/dist/policy/reserved-servers.js +5 -1
  158. package/dist/policy/reserved-servers.js.map +1 -1
  159. package/dist/policy/role-capability.d.ts.map +1 -1
  160. package/dist/policy/role-capability.js +2 -1
  161. package/dist/policy/role-capability.js.map +1 -1
  162. package/dist/policy/shell/command-normalise.d.ts +10 -0
  163. package/dist/policy/shell/command-normalise.d.ts.map +1 -0
  164. package/dist/policy/shell/command-normalise.js +153 -0
  165. package/dist/policy/shell/command-normalise.js.map +1 -0
  166. package/dist/protocol/doors/listener-protocol.d.ts +4 -0
  167. package/dist/protocol/doors/listener-protocol.d.ts.map +1 -1
  168. package/dist/protocol/doors/listener-protocol.js +4 -0
  169. package/dist/protocol/doors/listener-protocol.js.map +1 -1
  170. package/dist/protocol/doors/loopback-proof.d.ts +8 -0
  171. package/dist/protocol/doors/loopback-proof.d.ts.map +1 -0
  172. package/dist/protocol/doors/loopback-proof.js +11 -0
  173. package/dist/protocol/doors/loopback-proof.js.map +1 -0
  174. package/dist/protocol/doors/pass-scopes.d.ts +4 -0
  175. package/dist/protocol/doors/pass-scopes.d.ts.map +1 -0
  176. package/dist/protocol/doors/pass-scopes.js +3 -0
  177. package/dist/protocol/doors/pass-scopes.js.map +1 -0
  178. package/dist/protocol/doors/runner-protocol.d.ts +187 -0
  179. package/dist/protocol/doors/runner-protocol.d.ts.map +1 -1
  180. package/dist/protocol/doors/runner-protocol.js +48 -1
  181. package/dist/protocol/doors/runner-protocol.js.map +1 -1
  182. package/dist/protocol/doors/sandbox-pass.d.ts +19 -2
  183. package/dist/protocol/doors/sandbox-pass.d.ts.map +1 -1
  184. package/dist/protocol/doors/sandbox-pass.js +42 -10
  185. package/dist/protocol/doors/sandbox-pass.js.map +1 -1
  186. package/dist/protocol/member-reach.d.ts +6 -0
  187. package/dist/protocol/member-reach.d.ts.map +1 -1
  188. package/dist/protocol/member-reach.js +24 -0
  189. package/dist/protocol/member-reach.js.map +1 -1
  190. package/dist/protocol/peer-mcp-server.d.ts +2 -0
  191. package/dist/protocol/peer-mcp-server.d.ts.map +1 -1
  192. package/dist/protocol/peer-mcp-server.js +1 -0
  193. package/dist/protocol/peer-mcp-server.js.map +1 -1
  194. package/dist/protocol/raw/raw-json-routes.d.ts +512 -0
  195. package/dist/protocol/raw/raw-json-routes.d.ts.map +1 -1
  196. package/dist/protocol/raw/raw-json-routes.js +25 -2
  197. package/dist/protocol/raw/raw-json-routes.js.map +1 -1
  198. package/dist/protocol/raw/raw-routes.d.ts +164 -2
  199. package/dist/protocol/raw/raw-routes.d.ts.map +1 -1
  200. package/dist/protocol/raw/raw-routes.js +63 -35
  201. package/dist/protocol/raw/raw-routes.js.map +1 -1
  202. package/dist/protocol/route-meta.d.ts.map +1 -1
  203. package/dist/protocol/route-meta.js.map +1 -1
  204. package/dist/schemas/account-routes.d.ts +176 -0
  205. package/dist/schemas/account-routes.d.ts.map +1 -0
  206. package/dist/schemas/account-routes.js +73 -0
  207. package/dist/schemas/account-routes.js.map +1 -0
  208. package/dist/schemas/activity.d.ts.map +1 -1
  209. package/dist/schemas/activity.js.map +1 -1
  210. package/dist/schemas/agent-background.d.ts +48 -0
  211. package/dist/schemas/agent-background.d.ts.map +1 -0
  212. package/dist/schemas/agent-background.js +63 -0
  213. package/dist/schemas/agent-background.js.map +1 -0
  214. package/dist/schemas/agent-land.d.ts +7 -0
  215. package/dist/schemas/agent-land.d.ts.map +1 -1
  216. package/dist/schemas/agent-land.js +11 -0
  217. package/dist/schemas/agent-land.js.map +1 -1
  218. package/dist/schemas/agents-list.d.ts +34 -0
  219. package/dist/schemas/agents-list.d.ts.map +1 -1
  220. package/dist/schemas/agents.d.ts +656 -17
  221. package/dist/schemas/agents.d.ts.map +1 -1
  222. package/dist/schemas/agents.js +16 -41
  223. package/dist/schemas/agents.js.map +1 -1
  224. package/dist/schemas/auto-approve.d.ts +12 -0
  225. package/dist/schemas/auto-approve.d.ts.map +1 -0
  226. package/dist/schemas/auto-approve.js +12 -0
  227. package/dist/schemas/auto-approve.js.map +1 -0
  228. package/dist/schemas/automations.d.ts +83 -0
  229. package/dist/schemas/automations.d.ts.map +1 -1
  230. package/dist/schemas/automations.js +11 -1
  231. package/dist/schemas/automations.js.map +1 -1
  232. package/dist/schemas/bridge-heads.d.ts +57 -0
  233. package/dist/schemas/bridge-heads.d.ts.map +1 -0
  234. package/dist/schemas/bridge-heads.js +22 -0
  235. package/dist/schemas/bridge-heads.js.map +1 -0
  236. package/dist/schemas/capabilities.d.ts +21 -0
  237. package/dist/schemas/capabilities.d.ts.map +1 -1
  238. package/dist/schemas/capabilities.js +6 -0
  239. package/dist/schemas/capabilities.js.map +1 -1
  240. package/dist/schemas/checkout-hooks.d.ts +24 -0
  241. package/dist/schemas/checkout-hooks.d.ts.map +1 -0
  242. package/dist/schemas/checkout-hooks.js +23 -0
  243. package/dist/schemas/checkout-hooks.js.map +1 -0
  244. package/dist/schemas/ci-fleet.d.ts +216 -0
  245. package/dist/schemas/ci-fleet.d.ts.map +1 -0
  246. package/dist/schemas/ci-fleet.js +87 -0
  247. package/dist/schemas/ci-fleet.js.map +1 -0
  248. package/dist/schemas/connection-hub.d.ts +3 -1
  249. package/dist/schemas/connection-hub.d.ts.map +1 -1
  250. package/dist/schemas/connection-hub.js +2 -1
  251. package/dist/schemas/connection-hub.js.map +1 -1
  252. package/dist/schemas/context-continues.d.ts.map +1 -1
  253. package/dist/schemas/context-continues.js +2 -2
  254. package/dist/schemas/context-continues.js.map +1 -1
  255. package/dist/schemas/devices.d.ts +64 -0
  256. package/dist/schemas/devices.d.ts.map +1 -1
  257. package/dist/schemas/devices.js +6 -1
  258. package/dist/schemas/devices.js.map +1 -1
  259. package/dist/schemas/environment.d.ts +1 -0
  260. package/dist/schemas/environment.d.ts.map +1 -1
  261. package/dist/schemas/environment.js +1 -0
  262. package/dist/schemas/environment.js.map +1 -1
  263. package/dist/schemas/extension-updates.d.ts +2 -0
  264. package/dist/schemas/extension-updates.d.ts.map +1 -1
  265. package/dist/schemas/extension-updates.js +4 -0
  266. package/dist/schemas/extension-updates.js.map +1 -1
  267. package/dist/schemas/git/git.d.ts +13 -0
  268. package/dist/schemas/git/git.d.ts.map +1 -1
  269. package/dist/schemas/git/git.js +7 -7
  270. package/dist/schemas/git/git.js.map +1 -1
  271. package/dist/schemas/git/index-run.d.ts +1 -0
  272. package/dist/schemas/git/index-run.d.ts.map +1 -1
  273. package/dist/schemas/host-power.d.ts +54 -0
  274. package/dist/schemas/host-power.d.ts.map +1 -0
  275. package/dist/schemas/host-power.js +46 -0
  276. package/dist/schemas/host-power.js.map +1 -0
  277. package/dist/schemas/hosts.d.ts +139 -0
  278. package/dist/schemas/hosts.d.ts.map +1 -1
  279. package/dist/schemas/hosts.js +9 -1
  280. package/dist/schemas/hosts.js.map +1 -1
  281. package/dist/schemas/issues.d.ts +44 -0
  282. package/dist/schemas/issues.d.ts.map +1 -1
  283. package/dist/schemas/issues.js +12 -0
  284. package/dist/schemas/issues.js.map +1 -1
  285. package/dist/schemas/keyring-native.d.ts.map +1 -1
  286. package/dist/schemas/keyring-native.js +3 -1
  287. package/dist/schemas/keyring-native.js.map +1 -1
  288. package/dist/schemas/keyring.d.ts +1 -0
  289. package/dist/schemas/keyring.d.ts.map +1 -1
  290. package/dist/schemas/keyring.js +3 -1
  291. package/dist/schemas/keyring.js.map +1 -1
  292. package/dist/schemas/members.d.ts.map +1 -1
  293. package/dist/schemas/members.js +2 -14
  294. package/dist/schemas/members.js.map +1 -1
  295. package/dist/schemas/metrics.d.ts +8 -0
  296. package/dist/schemas/metrics.d.ts.map +1 -1
  297. package/dist/schemas/metrics.js +8 -0
  298. package/dist/schemas/metrics.js.map +1 -1
  299. package/dist/schemas/needs.d.ts +349 -1
  300. package/dist/schemas/needs.d.ts.map +1 -1
  301. package/dist/schemas/needs.js +45 -5
  302. package/dist/schemas/needs.js.map +1 -1
  303. package/dist/schemas/offload.d.ts +9 -0
  304. package/dist/schemas/offload.d.ts.map +1 -1
  305. package/dist/schemas/offload.js +2 -1
  306. package/dist/schemas/offload.js.map +1 -1
  307. package/dist/schemas/ports.d.ts +4 -0
  308. package/dist/schemas/ports.d.ts.map +1 -1
  309. package/dist/schemas/ports.js +3 -0
  310. package/dist/schemas/ports.js.map +1 -1
  311. package/dist/schemas/providers/capacity.d.ts +6 -0
  312. package/dist/schemas/providers/capacity.d.ts.map +1 -1
  313. package/dist/schemas/providers/refusals.d.ts +12 -0
  314. package/dist/schemas/providers/refusals.d.ts.map +1 -1
  315. package/dist/schemas/providers/refusals.js +4 -0
  316. package/dist/schemas/providers/refusals.js.map +1 -1
  317. package/dist/schemas/remote-access.d.ts +1 -0
  318. package/dist/schemas/remote-access.d.ts.map +1 -1
  319. package/dist/schemas/remote-access.js +1 -0
  320. package/dist/schemas/remote-access.js.map +1 -1
  321. package/dist/schemas/run-targets.d.ts.map +1 -1
  322. package/dist/schemas/run-targets.js +2 -1
  323. package/dist/schemas/run-targets.js.map +1 -1
  324. package/dist/schemas/runner-views.d.ts +24 -0
  325. package/dist/schemas/runner-views.d.ts.map +1 -0
  326. package/dist/schemas/runner-views.js +16 -0
  327. package/dist/schemas/runner-views.js.map +1 -0
  328. package/dist/schemas/sandbox-reach.d.ts +157 -0
  329. package/dist/schemas/sandbox-reach.d.ts.map +1 -0
  330. package/dist/schemas/sandbox-reach.js +112 -0
  331. package/dist/schemas/sandbox-reach.js.map +1 -0
  332. package/dist/schemas/settings.d.ts +18 -0
  333. package/dist/schemas/settings.d.ts.map +1 -1
  334. package/dist/schemas/settings.js +19 -1
  335. package/dist/schemas/settings.js.map +1 -1
  336. package/dist/schemas/system.d.ts +19 -0
  337. package/dist/schemas/system.d.ts.map +1 -1
  338. package/dist/schemas/system.js +9 -0
  339. package/dist/schemas/system.js.map +1 -1
  340. package/dist/schemas/terminal.d.ts +46 -0
  341. package/dist/schemas/terminal.d.ts.map +1 -1
  342. package/dist/schemas/terminal.js +19 -0
  343. package/dist/schemas/terminal.js.map +1 -1
  344. package/dist/state/auth-state.d.ts.map +1 -1
  345. package/dist/state/auth-state.js +1 -0
  346. package/dist/state/auth-state.js.map +1 -1
  347. package/dist/state/definition.d.ts +12 -0
  348. package/dist/state/definition.d.ts.map +1 -1
  349. package/dist/state/runtime-state.d.ts +1 -1
  350. package/dist/state/runtime-state.d.ts.map +1 -1
  351. package/dist/state/runtime-state.js +1 -1
  352. package/dist/state/runtime-state.js.map +1 -1
  353. package/dist/state/workspace-state.d.ts +1 -1
  354. package/dist/state/workspace-state.d.ts.map +1 -1
  355. package/dist/state/workspace-state.js +1 -1
  356. package/dist/state/workspace-state.js.map +1 -1
  357. package/dist/sync/workspace-sync-ignores.d.ts +4 -0
  358. package/dist/sync/workspace-sync-ignores.d.ts.map +1 -0
  359. package/dist/sync/workspace-sync-ignores.js +75 -0
  360. package/dist/sync/workspace-sync-ignores.js.map +1 -0
  361. package/dist/text/pages.d.ts.map +1 -1
  362. package/dist/text/pages.js +17 -4
  363. package/dist/text/pages.js.map +1 -1
  364. package/dist/text/transcript-fold.js +2 -2
  365. package/dist/text/transcript-fold.js.map +1 -1
  366. package/package.json +5 -5
  367. package/src/app-routes/app-pages.ts +3 -0
  368. package/src/app-routes/index.ts +1 -0
  369. package/src/app-routes/return-path.ts +16 -0
  370. package/src/contracts/accounts.contract.ts +3 -0
  371. package/src/contracts/agents.contract.ts +41 -5
  372. package/src/contracts/automations.contract.ts +2 -0
  373. package/src/contracts/capabilities.contract.ts +7 -2
  374. package/src/contracts/device-ci-runners.contract.ts +81 -0
  375. package/src/contracts/extensions.contract.ts +1 -1
  376. package/src/contracts/ports.contract.ts +6 -6
  377. package/src/contracts/runner.contract.ts +117 -3
  378. package/src/contracts/runners.contract.ts +19 -0
  379. package/src/contracts/safety.contract.ts +2 -0
  380. package/src/contracts/secrets.contract.ts +12 -0
  381. package/src/contracts/settings.contract.ts +2 -0
  382. package/src/contracts/system.contract.ts +20 -3
  383. package/src/events/agent-events.ts +3 -2
  384. package/src/events/agent-words.test.ts +19 -1
  385. package/src/events/agent-words.ts +33 -1
  386. package/src/events/refusal-incidents.ts +60 -19
  387. package/src/ids/conversation-ids.test.ts +3 -1
  388. package/src/ids/conversation-ids.ts +6 -4
  389. package/src/ids/project-dir.test.ts +1 -1
  390. package/src/ids/project-dir.ts +1 -1
  391. package/src/ids/project-id.test.ts +14 -0
  392. package/src/ids/project-id.ts +6 -4
  393. package/src/ids/run-row-ids.test.ts +38 -0
  394. package/src/ids/run-row-ids.ts +49 -0
  395. package/src/index.ts +3 -0
  396. package/src/models/agent-catalog.test.ts +7 -4
  397. package/src/models/agent-catalog.ts +3 -2
  398. package/src/models/agent-lanes.ts +8 -1
  399. package/src/models/agent-runtimes.ts +7 -6
  400. package/src/models/agent-standing.ts +13 -0
  401. package/src/models/provider-specs.test.ts +2 -2
  402. package/src/models/providers/provider-traits.test.ts +71 -0
  403. package/src/models/providers/provider-traits.ts +144 -0
  404. package/src/netd/browser-wire.ts +13 -0
  405. package/src/netd/generated/browser-wire.json +10 -0
  406. package/src/netd/generated/netd-wire.json +224 -1
  407. package/src/netd/generated/wire.ts +18 -6
  408. package/src/netd/wire-manifests.test.ts +16 -0
  409. package/src/policy/admin/admin-grant.ts +69 -0
  410. package/src/policy/capabilities/capability-kinds.test.ts +112 -0
  411. package/src/policy/capabilities/capability-kinds.ts +110 -0
  412. package/src/policy/command-classes.ts +5 -3
  413. package/src/policy/credential-material.ts +1 -1
  414. package/src/policy/device-programs.ts +29 -20
  415. package/src/policy/overlay-lint.ts +1 -1
  416. package/src/policy/reserved-servers.ts +5 -1
  417. package/src/policy/role-capability.ts +3 -1
  418. package/src/policy/shell/command-normalise.test.ts +72 -0
  419. package/src/policy/shell/command-normalise.ts +212 -0
  420. package/src/policy/tests/admin-grant.test.ts +35 -0
  421. package/src/policy/tests/command-classes.test.ts +41 -0
  422. package/src/protocol/doors/listener-protocol.ts +18 -1
  423. package/src/protocol/doors/loopback-proof.ts +34 -0
  424. package/src/protocol/doors/pass-scopes.ts +12 -0
  425. package/src/protocol/doors/runner-protocol.ts +133 -4
  426. package/src/protocol/doors/sandbox-pass.test.ts +33 -1
  427. package/src/protocol/doors/sandbox-pass.ts +92 -16
  428. package/src/protocol/ingress-contract.fixture.json +5 -1
  429. package/src/protocol/member-reach.test.ts +40 -1
  430. package/src/protocol/member-reach.ts +40 -0
  431. package/src/protocol/peer-mcp-server.ts +6 -0
  432. package/src/protocol/raw/raw-json-routes.ts +45 -1
  433. package/src/protocol/raw/raw-routes.ts +88 -36
  434. package/src/protocol/route-meta.ts +4 -1
  435. package/src/schemas/account-routes.ts +126 -0
  436. package/src/schemas/activity.ts +4 -3
  437. package/src/schemas/agent-background.ts +104 -0
  438. package/src/schemas/agent-land.ts +21 -2
  439. package/src/schemas/agents.ts +26 -65
  440. package/src/schemas/auto-approve.ts +31 -0
  441. package/src/schemas/automations.ts +26 -1
  442. package/src/schemas/bridge-heads.ts +33 -0
  443. package/src/schemas/capabilities.ts +23 -0
  444. package/src/schemas/checkout-hooks.ts +44 -0
  445. package/src/schemas/ci-fleet.ts +180 -0
  446. package/src/schemas/compose-overlay.test.ts +1 -1
  447. package/src/schemas/compose-overlay.ts +1 -1
  448. package/src/schemas/connection-hub.ts +4 -2
  449. package/src/schemas/context-continues.ts +6 -3
  450. package/src/schemas/data-protection.ts +1 -1
  451. package/src/schemas/device-swaps.test.ts +1 -1
  452. package/src/schemas/devices.ts +19 -1
  453. package/src/schemas/egress-private.test.ts +1 -1
  454. package/src/schemas/environment.ts +4 -0
  455. package/src/schemas/extension-updates.ts +8 -0
  456. package/src/schemas/git/git.ts +14 -14
  457. package/src/schemas/host-power.ts +79 -0
  458. package/src/schemas/hosts.ts +24 -2
  459. package/src/schemas/intentic-os.ts +2 -2
  460. package/src/schemas/issues.ts +14 -0
  461. package/src/schemas/keyring-native.test.ts +11 -3
  462. package/src/schemas/keyring-native.ts +3 -1
  463. package/src/schemas/keyring.ts +6 -1
  464. package/src/schemas/members.ts +4 -16
  465. package/src/schemas/metrics.test.ts +9 -1
  466. package/src/schemas/metrics.ts +8 -0
  467. package/src/schemas/needs.ts +68 -5
  468. package/src/schemas/offload.ts +6 -3
  469. package/src/schemas/ports.ts +5 -0
  470. package/src/schemas/providers/refusals.ts +9 -0
  471. package/src/schemas/remote-access.ts +3 -0
  472. package/src/schemas/run-targets.ts +2 -1
  473. package/src/schemas/runner-views.ts +27 -0
  474. package/src/schemas/sandbox-reach.ts +161 -0
  475. package/src/schemas/settings.test.ts +5 -4
  476. package/src/schemas/settings.ts +45 -10
  477. package/src/schemas/state-plan.test.ts +1 -1
  478. package/src/schemas/state-plan.ts +2 -2
  479. package/src/schemas/system.ts +16 -1
  480. package/src/schemas/terminal.ts +28 -0
  481. package/src/schemas/updates.test.ts +1 -1
  482. package/src/schemas/updates.ts +1 -1
  483. package/src/state/auth-state.ts +3 -0
  484. package/src/state/runtime-state.test.ts +3 -2
  485. package/src/state/runtime-state.ts +3 -1
  486. package/src/state/update-probation.ts +1 -1
  487. package/src/state/ways-back.test.ts +1 -1
  488. package/src/state/workspace-state.test.ts +2 -0
  489. package/src/state/workspace-state.ts +4 -4
  490. package/src/sync/workspace-sync-ignores.test.ts +48 -0
  491. package/src/sync/workspace-sync-ignores.ts +143 -0
  492. package/src/text/pages.ts +34 -7
  493. package/src/text/transcript-fold.test.ts +40 -2
  494. package/src/text/transcript-fold.ts +2 -2
@@ -1,13 +1,13 @@
1
1
  import { procedure } from "../protocol/route-meta.js";
2
2
  import {
3
+ PortForwardInputSchema,
3
4
  PortForwardResultSchema,
4
- PortParamSchema,
5
- PortsListSchema,
6
5
  PreviewGuardSchema,
7
6
  PreviewPassRequestSchema,
8
7
  PreviewPassSchema,
9
8
  } from "../schemas/ports.js";
10
9
  import { OkSchema } from "../schemas/shared.js";
10
+ import { SyncPortsListSchema } from "../schemas/bridge-heads.js";
11
11
 
12
12
  // Listening TCP ports in the sandbox + explicit forwarding through the preview proxy (see the ports section in
13
13
  // schemas/ports.ts). `forward` is idempotent, re-forwarding a port returns its existing slot's URL; `unforward`
@@ -23,16 +23,16 @@ export const portsContract = {
23
23
  // The desktop-sync watcher's poll, and the machine's check-in; and `devices ports`, an agent's answer to whose
24
24
  // server holds which port.
25
25
  .meta({ sync: "poll", agent: true })
26
- .output(PortsListSchema),
26
+ .output(SyncPortsListSchema),
27
27
  forward: procedure
28
28
  .route({
29
29
  method: "POST",
30
30
  path: "/ports/forward",
31
31
  summary: "Make a port reachable",
32
32
  description:
33
- "Gives one port an address on the outside. Asking twice is harmless: the second call hands back the address the first one made.",
33
+ "Gives one port an address on the outside. Asking twice is harmless: the second call hands back the address the first one made. Naming a runner forwards that runner's own port, for a conversation that runs there.",
34
34
  })
35
- .input(PortParamSchema)
35
+ .input(PortForwardInputSchema)
36
36
  .output(PortForwardResultSchema),
37
37
  unforward: procedure
38
38
  .route({
@@ -41,7 +41,7 @@ export const portsContract = {
41
41
  summary: "Stop exposing a port",
42
42
  description: "Frees the slot at once. The address keeps resolving; it simply stops leading anywhere.",
43
43
  })
44
- .input(PortParamSchema)
44
+ .input(PortForwardInputSchema)
45
45
  .output(OkSchema),
46
46
  // The owner's guard on previews (schemas/ports.ts): any member reads it, since the editor asks for a pass only where
47
47
  // it is on; only the owner changes it, like the passkey policy.
@@ -9,6 +9,10 @@ import {
9
9
  RunnerDefinitionAppliedSchema,
10
10
  RunnerFactsSchema,
11
11
  RunnerHeldTurnSchema,
12
+ RunnerFeedFrameSchema,
13
+ RunnerPresentationSchema,
14
+ RunnerRevokeSchema,
15
+ RunnerStoppedSchema,
12
16
  RunnerSyncLineSchema,
13
17
  RunnerSyncSchema,
14
18
  RunnerTurnSchema,
@@ -16,6 +20,17 @@ import {
16
20
  import { EditorContextSchema } from "../schemas/agent.js";
17
21
  import { AgentReplySchema } from "../schemas/providers/plan-limits.js";
18
22
  import { OkSchema } from "../schemas/shared.js";
23
+ import {
24
+ BrowserPageActionInputSchema,
25
+ MoveBrowserPageInputSchema,
26
+ ReopenBrowserPageInputSchema,
27
+ BrowserNameParamSchema,
28
+ BrowserPageParamSchema, BrowsersListSchema, DesktopStateSchema, OpenBrowserInputSchema, OpenBrowserResultSchema } from "../schemas/terminal.js";
29
+ import { PortParamSchema } from "../schemas/ports.js";
30
+ import { TurnErrandSchema } from "../schemas/speaker.js";
31
+
32
+ // Files a message names, as bytes: the runner resolves no path of the parent's. `path` is workspace-relative.
33
+ const RunnerFilesSchema = z.array(z.object({ path: z.string().min(1), bytesBase64: z.string() }));
19
34
 
20
35
  // What a runner can be asked, over the socket it opened; same inversion as deviceContract, the runner is the oRPC server,
21
36
  // the parent the client. No `.route()`: the procedure path is the address. Typed throughout, unlike deviceContract's
@@ -37,9 +52,64 @@ export const runnerContract = {
37
52
  // How many of the held turn's frames the parent has, said every few seconds while it relays them: the count a parent
38
53
  // that restarted mid-turn reads on from (`heldTurn().acked`), since its own count died with it.
39
54
  ackTurn: oc.input(RunnerAttachSchema).output(OkSchema),
40
- // Returns `applied` rather than throwing: a missing id is an ordinary race, same as local NOT_FOUND.
41
- reply: oc.input(AgentReplySchema).output(z.object({ applied: z.boolean() })),
42
- // Attachments/editor context travel uncomposed: the note must build against the runner's own workspace root.
55
+ // A page a turn here showed (`show_page`), by the workspace path its `page` frame names: the page is filed in the
56
+ // runner's own workspace, and the parent files a copy at the same path before relaying the frame, so the chat, which
57
+ // reads pages from the parent, can draw it. NOT_FOUND for a path that is not a stored page; an older runner lacks the
58
+ // procedure, and its pages stay on the runner.
59
+ readPage: oc.input(z.object({ path: z.string().min(1) })).output(z.object({ html: z.string() })),
60
+ // A picture a turn here showed (a screenshot, a generated image), by the workspace path its tool card names, read from
61
+ // the runner's artifacts folder: the parent files a copy before relaying the card, as it does a page, since the chat
62
+ // reads every picture from the parent and neither the relay nor the branch's push carries that folder. `have` is the
63
+ // sha256 of a file the parent already holds at that path; the answer then carries no bytes when the runner's file is
64
+ // the same. NOT_FOUND for a path outside the artifacts folder or no file there, PAYLOAD_TOO_LARGE past the cap; an
65
+ // older runner lacks the procedure, and its pictures stay on the runner.
66
+ // `conversationId` asks for a file in that conversation's checkout instead (a picture a turn Read from its own tree,
67
+ // `path` relative to the checkout), which the parent files under the artifacts folder's `runner/<id>/`; an older runner
68
+ // ignores it and answers NOT_FOUND, the path being outside its artifacts folder. `offset` and `length` ask for one
69
+ // piece of a file past a socket frame (up to 512 MiB in all), answered with the whole file's `size`; an older runner
70
+ // ignores them and answers the whole file, or PAYLOAD_TOO_LARGE. `have` is compared with the whole file either way.
71
+ // The first piece (offset 0) carries the whole file's `sha256`, which the parent checks the assembled copy against.
72
+ readArtifact: oc
73
+ .input(
74
+ z.object({
75
+ path: z.string().min(1),
76
+ have: z.string().optional(),
77
+ conversationId: z.string().min(1).optional(),
78
+ offset: z.number().int().nonnegative().optional(),
79
+ length: z.number().int().positive().optional(),
80
+ }),
81
+ )
82
+ .output(z.object({ bytesBase64: z.string().optional(), size: z.number().optional(), sha256: z.string().optional() })),
83
+ // The files in the runner's artifacts folder modified within the last `withinMs` (a duration, so neither machine's
84
+ // clock is read against the other's), the person's uploads and pages left out: what a turn here left there (a PDF, a
85
+ // video, a trace), swept home by the parent before it relays the turn's `done` and fetched with `readArtifact`. An
86
+ // older runner lacks the procedure (NOT_FOUND), and those files stay on the runner.
87
+ listArtifacts: oc
88
+ .input(z.object({ withinMs: z.number().int().positive() }))
89
+ .output(z.object({ files: z.array(z.object({ path: z.string().min(1), size: z.number(), mtimeMs: z.number() })) })),
90
+ // One piece of the `index`th video or audio file a stored page here streams (`show_page` media, agent/pages/page-media.ts),
91
+ // served only while the page's manifest verifies under this runner's own key and the file is still the one shown. The
92
+ // parent copies each into its artifacts folder and re-signs the manifest for its copies before filing the page.
93
+ // NOT_FOUND for anything else; an older runner lacks the procedure, and its pages' media plays nowhere, as before.
94
+ readPageMedia: oc
95
+ .input(
96
+ z.object({
97
+ page: z.string().min(1),
98
+ index: z.number().int().nonnegative(),
99
+ offset: z.number().int().nonnegative(),
100
+ length: z.number().int().positive(),
101
+ }),
102
+ )
103
+ // The first piece (offset 0) carries the file's `sha256`, as `readArtifact` does.
104
+ .output(z.object({ bytesBase64: z.string(), size: z.number(), sha256: z.string().optional() })),
105
+ // Returns `applied` rather than throwing: a missing id is an ordinary race, same as local NOT_FOUND. `files` carries
106
+ // the bytes of the files an answer attaches (a question's own-words answer), written at their workspace paths before
107
+ // the answer applies, since the runner resolves no path of the parent's; an older runner ignores it.
108
+ reply: oc.input(AgentReplySchema.and(z.object({ files: RunnerFilesSchema.optional() }))).output(z.object({ applied: z.boolean() })),
109
+ // Attachments/editor context travel uncomposed: the note must build against the runner's own workspace root. `files`
110
+ // carries the bytes of what attachments and mentions name, written before the steer applies. `voice` (default
111
+ // "person"), `outside` and `errand` say whose words they are when not the person's: an agent's message to a working
112
+ // child, a wake, a page's error report. An older runner ignores all four, and takes every steer as the person's.
43
113
  steer: oc
44
114
  .input(
45
115
  z.object({
@@ -48,11 +118,19 @@ export const runnerContract = {
48
118
  attachments: z.array(z.string()).optional(),
49
119
  mentions: z.array(z.string()).optional(),
50
120
  editorContext: EditorContextSchema.optional(),
121
+ voice: z.enum(["person", "sandbox", "agent"]).optional(),
122
+ outside: z.string().optional(),
123
+ errand: TurnErrandSchema.optional(),
124
+ files: RunnerFilesSchema.optional(),
51
125
  }),
52
126
  )
53
127
  .output(z.object({ applied: z.boolean(), invalid: z.string().optional() })),
54
128
  // REPLACE semantics: a key the definition omits returns to its default, unlike the owner apply's merge-beside.
55
129
  applyDefinition: oc.input(z.object({ toml: z.string() })).output(RunnerDefinitionAppliedSchema),
130
+ // What the runner calls itself on its machine and whose it is, said on every connect and after a rename; the runner
131
+ // keeps it where its machine's `ic sandbox list` reads a sandbox's name. An older runner lacks it (NOT_FOUND), and
132
+ // stays listed by its slug.
133
+ present: oc.input(RunnerPresentationSchema).output(OkSchema),
56
134
  // Stop the running turn; the parent's stop button reaching through.
57
135
  interrupt: oc.input(RunnerTurnSchema.pick({ conversationId: true })).output(OkSchema),
58
136
  // One shell line the parent offloaded (settings `offload`), run against a snapshot of the parent's tree; its output
@@ -63,4 +141,40 @@ export const runnerContract = {
63
141
  cancelCommand: oc.input(RunnerCommandSchema.pick({ runId: true })).output(OkSchema),
64
142
  // Liveness driven by the parent: keepalive and gone-detection in one.
65
143
  ping: oc.output(OkSchema),
144
+ // LIVE VIEWS (2026-11-23): what the parent's editor shows of a conversation running here, beside the views netd carries
145
+ // down the uplink (a terminal, a browser's or the desktop's picture). Each degrades on an older runner, which lacks the
146
+ // procedure (NOT_FOUND): the parent then shows what it has, as before.
147
+ // The stream the parent opens each time this runner connects: every conversation's jobs and watches, then each change,
148
+ // and a word when the browsers or the desktop changed (runner-protocol.ts RunnerFeedFrameSchema).
149
+ feed: oc.output(streamOf(RunnerFeedFrameSchema)),
150
+ // This runner's browser windows, as its own `system.browsers` lists them; the parent namespaces their names.
151
+ browsers: oc.output(BrowsersListSchema),
152
+ // The window acts the parent's browser routes forward for one of this runner's windows, by the runner's own name.
153
+ openBrowser: oc.input(OpenBrowserInputSchema).output(OpenBrowserResultSchema),
154
+ closeBrowser: oc.input(BrowserNameParamSchema).output(OkSchema),
155
+ closeBrowserPage: oc.input(BrowserPageParamSchema).output(OkSchema),
156
+ // This runner's desktop, as its own `system.desktop` says; starts nothing.
157
+ desktop: oc.output(DesktopStateSchema),
158
+ // A person's stops on a runner conversation's card, applied here where the job or watch lives; `stopped` false when
159
+ // nothing was left to stop. Naming no watch disarms them all.
160
+ stopJob: oc.input(z.object({ conversationId: z.string().min(1), jobId: z.string().min(1) })).output(RunnerStoppedSchema),
161
+ stopWatching: oc.input(z.object({ conversationId: z.string().min(1), watchId: z.string().optional() })).output(RunnerStoppedSchema),
162
+ // Whether a port here may be previewed through the parent: something listens on it, reachable on loopback, and it is
163
+ // not a browser's DevTools port. A refusal is answered, with the reason the parent's own forward would give, never
164
+ // thrown: a NOT_FOUND is only ever an older runner without the door.
165
+ vetPort: oc.input(PortParamSchema).output(z.object({ refused: z.string().optional() })),
166
+ // The parent revoked a member's access (or everyone's): the picture sockets and tokens this runner's castd holds are
167
+ // ended, as the parent's own are; the parent's netd already closed every view it carried for them.
168
+ revoke: oc.input(RunnerRevokeSchema).output(OkSchema),
169
+ // A tab's own menu and the strip's drag on one of this runner's windows, by its own name (`system.reopenBrowserPage`,
170
+ // `moveBrowserPage`, `browserPageAction` there): answers the tab acted on or opened, nothing for a move.
171
+ browserTab: oc
172
+ .input(
173
+ z.union([
174
+ ReopenBrowserPageInputSchema.extend({ op: z.literal("reopen") }),
175
+ MoveBrowserPageInputSchema.extend({ op: z.literal("move") }),
176
+ BrowserPageActionInputSchema.extend({ op: z.literal("action") }),
177
+ ]),
178
+ )
179
+ .output(OpenBrowserResultSchema.partial()),
66
180
  };
@@ -0,0 +1,19 @@
1
+ import { procedure } from "../protocol/route-meta.js";
2
+ import { RunnerOpenViewInputSchema, RunnerViewSchema } from "../schemas/runner-views.js";
3
+
4
+ // What the editor asks about a conversation that runs on one of this sandbox's runners (schemas/runner-views.ts); the
5
+ // runner's own procedures are runner.contract.ts, which only this daemon calls. Withheld from the panel and control
6
+ // tokens: a person opens a view, never a program.
7
+ export const runnersContract = {
8
+ openView: procedure
9
+ .route({
10
+ method: "POST",
11
+ path: "/system/conversations/{conversationId}/runner-view",
12
+ summary: "Open a live view of a conversation's runner",
13
+ description:
14
+ "Where a socket opens onto the terminal, a browser window or the desktop of the runner a conversation runs on, with a one-shot ticket. Maintainers only, for a conversation they may read, while its runner is connected.",
15
+ })
16
+ .meta({ panel: false, control: "never" })
17
+ .input(RunnerOpenViewInputSchema)
18
+ .output(RunnerViewSchema),
19
+ };
@@ -24,6 +24,8 @@ export const safetyContract = {
24
24
  description:
25
25
  "Replaces the document whole. Nothing in it can widen what the sandbox is structurally allowed to do: it decides which of the things an agent may already do are worth interrupting you about.",
26
26
  })
27
+ // The policy the command judge reads: never a panel process's to rewrite.
28
+ .meta({ panel: false })
27
29
  .input(z.object({ text: z.string().describe("The policy, as you want it written.") }))
28
30
  .output(OkSchema),
29
31
  // Verdicts teach the owner which policy line to add next; answers why you weren't asked about something.
@@ -47,6 +47,8 @@ export const secretsContract = {
47
47
  description:
48
48
  "Writes one name and value into the sandbox's own secret store, where the agent's references resolve it, without a restart.",
49
49
  })
50
+ // A value put in place of the owner's: withheld from the panel token every panel process holds.
51
+ .meta({ panel: false })
50
52
  .input(SecretSetSchema)
51
53
  .output(OkSchema),
52
54
  generate: secretRoute
@@ -69,6 +71,8 @@ export const secretsContract = {
69
71
  description:
70
72
  "Replaces the value of a secret a person set here (not a connection's or a computer's) with a random one, for a value too short to hide from the model. Answers the name and its length, never the value. Whatever checks the old value (a server, an account) has to be given the new one, or it stops working.",
71
73
  })
74
+ // Replaces a stored value, breaking whatever checks the old one: the owner's, never a panel process's.
75
+ .meta({ panel: false })
72
76
  .input(SecretRegenerateSchema)
73
77
  .output(SecretGeneratedSchema),
74
78
  list: secretRoute
@@ -86,6 +90,8 @@ export const secretsContract = {
86
90
  summary: "Delete a secret",
87
91
  description: "Removes one by name.",
88
92
  })
93
+ // Removing a stored value is the owner's, never a panel process's.
94
+ .meta({ panel: false })
89
95
  .input(SecretKeyParamSchema)
90
96
  .output(OkSchema),
91
97
  inventory: secretRoute
@@ -129,6 +135,8 @@ export const secretsContract = {
129
135
  description:
130
136
  "Names exactly who may release one secret or one connected account, and how far a single release goes. The owner's call alone. A signed-in browser or a mounted server cannot be released for one use, so those are always for the rest of the conversation.",
131
137
  })
138
+ // Who may release a credential is the owner's to say, never a panel process's.
139
+ .meta({ panel: false })
132
140
  .input(CredentialGateSchema)
133
141
  .output(OkSchema),
134
142
  removeGate: secretRoute
@@ -138,6 +146,8 @@ export const secretsContract = {
138
146
  summary: "Stop requiring approval for a credential",
139
147
  description: "Removes one gate, so the agent can use that credential the way it uses any other. The owner's call alone.",
140
148
  })
149
+ // Lifting a gate is the owner's, never a panel process's.
150
+ .meta({ panel: false })
141
151
  .input(CredentialGuardSubjectParamSchema)
142
152
  .output(OkSchema),
143
153
  // The host guard, the gate's second half: kept beside the gates, off the agent-editable config for the same reason. The
@@ -264,6 +274,8 @@ export const secretsContract = {
264
274
  description:
265
275
  "The owner's alone, and never the agent's: handing the agent the credential itself, or replacing what the gateway lets it do, is a decision about the credential, not a use of it.",
266
276
  })
277
+ // Hands the agent a credential or rewrites its rules: never a panel process's.
278
+ .meta({ panel: false })
267
279
  .input(CredentialPolicySetSchema)
268
280
  .output(CredentialPolicySchema),
269
281
  request: secretRoute
@@ -58,6 +58,8 @@ export const settingsContract = {
58
58
  summary: "Change the sandbox settings",
59
59
  description: "Writes the settings whole, so send the complete object rather than the fields you changed.",
60
60
  })
61
+ // The command judge, auto-approval and the rest of what holds the agent back: never a panel process's to change.
62
+ .meta({ panel: false })
61
63
  .input(SandboxSettingsWriteSchema)
62
64
  .output(OkSchema),
63
65
  savings: procedure
@@ -20,7 +20,9 @@ import {
20
20
  StackLogsSchema,
21
21
  StackOpResultSchema,
22
22
  } from "../schemas/device-stacks.js";
23
+ import { deviceCiRunnerRoutes } from "./device-ci-runners.contract.js";
23
24
  import { EgressOwnerKeysReadSchema } from "../schemas/egress.js";
25
+ import { SandboxReachSchema } from "../schemas/sandbox-reach.js";
24
26
  import { PresenceReportSchema } from "../schemas/logs.js";
25
27
  import {
26
28
  CheckoutPressInputSchema,
@@ -50,8 +52,8 @@ import {
50
52
  OpenBrowserInputSchema,
51
53
  OpenBrowserResultSchema,
52
54
  ReopenBrowserPageInputSchema,
53
- DesktopStateSchema,
54
55
  SubagentsListSchema,
56
+ SystemDesktopSchema,
55
57
  TerminalNameParamSchema,
56
58
  TerminalScrollbackQuerySchema,
57
59
  TerminalScrollbackSchema,
@@ -166,7 +168,8 @@ export const systemContract = {
166
168
  "Exchanges a verified sign-in, or a session that has not expired yet, for a fresh session the daemon minted. That session is the credential every other call carries, and calling this again with a live one renews it.",
167
169
  })
168
170
  // Staying signed in and on the roster is identity, not power, and needs nothing the boot chain builds.
169
- .meta({ beforeBoot: true, floor: "viewer", guest: true })
171
+ // The session it answers is a credential: never a panel process's.
172
+ .meta({ beforeBoot: true, floor: "viewer", guest: true, panel: false })
170
173
  .output(DaemonSessionSchema),
171
174
  events: procedure
172
175
  .route({
@@ -444,7 +447,7 @@ export const systemContract = {
444
447
  description:
445
448
  "Whether the sandbox's desktop is up, which display it is, and which windows are open on it. The live picture of it, or of one window on it, comes over a separate socket; this says whether there is anything to see.",
446
449
  })
447
- .output(DesktopStateSchema),
450
+ .output(SystemDesktopSchema),
448
451
  // In-process and spawned alike: the board draws each under the card of the conversation that started it, and a chat
449
452
  // draws it on the card of the call that started it. Pushed through the `subagents` runtime domain, never polled. A
450
453
  // subagent's work is read where it lives: an in-process one's on its delegation's card in its parent's record, a
@@ -470,6 +473,18 @@ export const systemContract = {
470
473
  "Every computer this sandbox can see, whether it reached it through desktop sync or through a connected device, in one row per machine: what it says about itself, which sandboxes it holds, and what stopped it answering when nothing came back.",
471
474
  })
472
475
  .output(DevicesListSchema),
476
+ // (2026-11-22) The account's access map asks every sandbox it reaches for this one answer and joins them
477
+ // (docs/architecture/accounts.md). Read from what the daemon stores and its live connections, never by calling a
478
+ // machine, so a map of ten sandboxes costs ten cheap reads; only the link cards' terms ask the far sandbox, briefly.
479
+ reach: systemRoute
480
+ .route({
481
+ method: "GET",
482
+ path: "/system/reach",
483
+ summary: "What this sandbox is tied to outside itself",
484
+ description:
485
+ "The other sandboxes this one hands work to and takes work from, with their terms; the computers, phones, browsers and servers its agents reach, with the switches each has on; whether it may create sandboxes on its owner's account; and, for each, whether the reader's own conversations may use it and how many other people's may. Shaped for the reader: inbound links and where it runs are Full access's, the counts of other people are for whoever runs people and access.",
486
+ })
487
+ .output(SandboxReachSchema),
473
488
  // One stream for every op; the daemon adds no judgment, a refusal is the machine's own `error` line.
474
489
  manageDeviceSandbox: systemRoute
475
490
  .route({
@@ -563,4 +578,6 @@ export const systemContract = {
563
578
  .meta({ panel: false })
564
579
  .input(DeviceStackDeployInputSchema)
565
580
  .output(DeviceStackDeployResultSchema),
581
+ // The self-hosted CI runners on a connected computer, for the Pipelines view (device-ci-runners.contract.ts).
582
+ ...deviceCiRunnerRoutes,
566
583
  };
@@ -228,9 +228,10 @@ export const AgentEventSchema = z.discriminatedUnion("kind", [
228
228
  }),
229
229
  // The agent started running Bash in its live `agent-<id>` tmux session; one per turn, reused across all of a turn's
230
230
  // commands including subagents'.
231
- z.object({ kind: z.literal("terminal"), session: z.string() }),
231
+ // `runner` (2026-11-23): stamped by the parent on a frame relayed from a runner, whose session lives there.
232
+ z.object({ kind: z.literal("terminal"), session: z.string(), runner: z.string().optional() }),
232
233
  // The agent used a browser tool; one per turn, since one Chromium serves every browser call the turn makes.
233
- z.object({ kind: z.literal("browser"), session: z.string() }),
234
+ z.object({ kind: z.literal("browser"), session: z.string(), runner: z.string().optional() }),
234
235
  // One frame per subagent a turn starts, whichever mechanism starts it, then `subagent_update` as it works, mirroring
235
236
  // `tool_call`/`tool_call_update`. `id` is its roster id: the spawning call's own id for an in-process subagent (the
236
237
  // runtime's Agent/Task tool), its own conversation id for a spawned one, whose card is the call whose result names
@@ -1,4 +1,4 @@
1
- import { agentWordsOf, agentWordsRow, childReportPrompt, peerMessagePrompt, unspokenPromptRow } from "./agent-words.js";
1
+ import { agentWordsBody, agentWordsOf, agentWordsRow, childReportPrompt, peerMessagePrompt, unspokenPromptRow } from "./agent-words.js";
2
2
  import { watchWakePrompt } from "./watch-wake.js";
3
3
 
4
4
  const peerTitled = (title: string | undefined): string => peerMessagePrompt({ from: "sharp-shale-htw8", title, message: "the sweep is done" });
@@ -73,6 +73,24 @@ describe("another agent's words", () => {
73
73
  expect(agentWordsOf(stored)).toMatchObject({ kind: "child", from: "sub-x7", title: "Port the parser" });
74
74
  });
75
75
 
76
+ it("hands back what the other agent said, without the lines the sandbox wraps it in", () => {
77
+ expect(agentWordsBody(peer())).toEqual({ said: "the sweep is done" });
78
+ const multi = report({ report: "Ported.\n\n- 12 tests pass\n- 1 skipped", machine: "omen", landing: "Held off your checkout." });
79
+ expect(agentWordsBody(multi)).toEqual({ said: "Ported.\n\n- 12 tests pass\n- 1 skipped" });
80
+ expect(agentWordsBody(report({ result: { json: '{"ok":true}' } }))?.said).toContain('{"ok":true}');
81
+ });
82
+
83
+ it("reads a child's verification state, and says nothing where it carried none", () => {
84
+ expect(agentWordsBody(report({ verification: { state: "failing", check: "pnpm test" } }))).toMatchObject({ verification: "failing" });
85
+ expect(agentWordsBody(report({ verification: { state: "no-code" } }))).toMatchObject({ verification: "no-code" });
86
+ expect(agentWordsBody(report()) ?? {}).not.toHaveProperty("verification");
87
+ });
88
+
89
+ it("says a report a child ended without as nothing, and answers no other prompt", () => {
90
+ expect(agentWordsBody(report({ report: " " }))).toEqual({ said: "" });
91
+ expect(agentWordsBody("fix the bug\n\nplease\n\nnow")).toBeUndefined();
92
+ });
93
+
76
94
  it("ignores every other prompt, so any reader can ask without checking first", () => {
77
95
  expect(agentWordsOf("fix the bug")).toBeUndefined();
78
96
  expect(agentWordsOf("Message from another conversation in this workspace: nobody")).toBeUndefined();
@@ -98,7 +98,7 @@ export const childReportPrompt = (fields: ChildReportFields): string => {
98
98
  ...(fields.machine === undefined ? [] : [`${MACHINE_OPENING}\`${fields.machine}\`, not this sandbox.`]),
99
99
  ...(verification === undefined ? [] : [verification]),
100
100
  "",
101
- fields.report.trim() === "" ? "(It ended without a closing report.)" : fields.report.trim(),
101
+ fields.report.trim() === "" ? NO_REPORT : fields.report.trim(),
102
102
  ...resultLines(fields.result),
103
103
  "",
104
104
  fields.review === undefined
@@ -115,6 +115,11 @@ const reviewClosing = (from: string, landing: string | undefined): string =>
115
115
  "finding it left open that holds, check its own edits rather than trusting them, and say plainly which findings you think are " +
116
116
  `wrong and why. If nothing is left open, say so in a line and stop. Ask it something with \`agents message ${from} '<text>'\`.`;
117
117
 
118
+ // What stands for a report a child ended without; read back by the parser, so it stays unchanged too.
119
+ const NO_REPORT = "(It ended without a closing report.)";
120
+ // The verification line's state, as `verificationLine` writes it.
121
+ const VERIFICATION_LINE = /^Verification: (verified|failing|unproven|no-code) —/u;
122
+
118
123
  // The report's second line for a child that ran on a runner; read back by the parser, so it stays unchanged too.
119
124
  const MACHINE_OPENING = "It ran on the runner ";
120
125
  const MACHINE_LINE = /^It ran on the runner `([^`]+)`/u;
@@ -165,6 +170,33 @@ const reviewOf = (first: string, prompt: string): TranscriptAgentWords | undefin
165
170
  };
166
171
  };
167
172
 
173
+ /** What the other agent itself said, out of a prompt `agentWordsOf` recognises: the words between the opening lines and
174
+ * the closing paragraph the sandbox adds to every such prompt (`said`, empty for a child that ended without a report),
175
+ * and a child's verification state where its report carries one. */
176
+ export interface AgentWordsBody {
177
+ readonly said: string;
178
+ readonly verification?: SubagentVerification["state"];
179
+ }
180
+
181
+ export const agentWordsBody = (prompt: string): AgentWordsBody | undefined => {
182
+ const lines = prompt.split("\n");
183
+ const opened = lines.indexOf("");
184
+ const closed = lines.lastIndexOf("");
185
+ if (opened === -1 || closed <= opened || agentWordsOf(prompt) === undefined) {
186
+ return undefined;
187
+ }
188
+ const said = lines.slice(opened + 1, closed).join("\n").trim();
189
+ const state = lines
190
+ .slice(1, opened)
191
+ .map((line) => VERIFICATION_LINE.exec(line)?.[1])
192
+ .find((found) => found !== undefined);
193
+ const words = said === NO_REPORT ? "" : said;
194
+ return isVerificationState(state) ? { said: words, verification: state } : { said: words };
195
+ };
196
+
197
+ const VERIFICATION_STATES: ReadonlySet<string> = new Set<SubagentVerification["state"]>(["verified", "failing", "unproven", "no-code"]);
198
+ const isVerificationState = (word: string | undefined): word is SubagentVerification["state"] => word !== undefined && VERIFICATION_STATES.has(word);
199
+
168
200
  /** Which other agent's words a stored prompt is; undefined for every other prompt. */
169
201
  export const agentWordsOf = (prompt: string): TranscriptAgentWords | undefined => {
170
202
  const first = prompt.split("\n", 1)[0] ?? "";
@@ -10,7 +10,13 @@ import { type SandboxNotice, sandboxNoticeOf } from "./sandbox-notice.js";
10
10
 
11
11
  The rows stay as they are in the record: the run is found again wherever it is drawn, so nothing about a stored
12
12
  transcript, a rewind index or a fork changes. Only rows next to each other fold. A row between them (the person's
13
- own message, a rebase, a different refusal) ends the run, since it is part of the story the reader is owed. */
13
+ own message, a rebase, a different refusal) ends the run, since it is part of the story the reader is owed.
14
+
15
+ A wake is the exception (another agent's words, a watch, an answered need: a prompt nobody typed). When one wall
16
+ stands while a fleet of subagents reports back, every report wakes the conversation and is turned away in turn, and
17
+ the run read as report, refusal, report, refusal: seven subagents left fourteen rows and seventy lines on 2026-11-23.
18
+ The wakes the wall turned away fold into its run, and the run names them (`wakes`), so the reader still learns who
19
+ reported. A wake after the run's last refusal is the attempt in flight, and stays a row of its own. */
14
20
 
15
21
  /** One refused attempt an incident folds: when it was refused, and the provider's own sentence for it. */
16
22
  export interface IncidentAttempt {
@@ -26,6 +32,8 @@ export interface TranscriptIncident {
26
32
  readonly attempts: readonly IncidentAttempt[];
27
33
  // The run ended on the move (or a person's switch) that got the turn through, rather than on a refusal or a re-send.
28
34
  readonly resolved: boolean;
35
+ // The wakes the wall turned away, by their index in the rows, oldest first: folded into the run, never drawn.
36
+ readonly wakes: readonly number[];
29
37
  }
30
38
 
31
39
  type Refusal = Extract<SandboxNotice, { code: "kept" | "undelivered" | "failed" }>;
@@ -68,40 +76,73 @@ const resent = (row: TranscriptRow): boolean => {
68
76
 
69
77
  const movedOn = (row: TranscriptRow): boolean => codeOf(row, MOVED) !== undefined;
70
78
 
79
+ // A prompt nobody at the composer typed: another agent's words, a watch's wake, an answered need.
80
+ const isWake = (row: TranscriptRow): boolean =>
81
+ row.role === "notice" && (row.agentWords !== undefined || row.watchWake !== undefined || row.needWake !== undefined);
82
+
71
83
  const attemptOf = (row: TranscriptRow, refusal: Refusal): IncidentAttempt =>
72
84
  row.openedAt === undefined ? { said: refusal.params.message } : { at: row.openedAt, said: refusal.params.message };
73
85
 
86
+ // The wakes right above a first refusal, down to `floor`, which met the same wall: the first of them is what it turned away.
87
+ const wakesAbove = (rows: readonly TranscriptRow[], index: number, floor: number): number[] => {
88
+ let start = index;
89
+ while (start > floor && isWake(rows[start - 1]!)) {
90
+ start -= 1;
91
+ }
92
+ return Array.from({ length: index - start }, (_, offset) => start + offset);
93
+ };
94
+
95
+ // How far the run that opens on the refusal at `index` reaches: every same refusal, re-send and wake after it, up to and
96
+ // including the move or switch that ended it. A wake is joined only once a row after it carries the run on, since one
97
+ // after the last refusal is the attempt still in flight.
98
+ const runFrom = <R extends TranscriptRow>(rows: readonly R[], index: number, first: Refusal, resolves: (row: R) => boolean) => {
99
+ const attempts = [attemptOf(rows[index]!, first)];
100
+ const wakes: number[] = [];
101
+ let pending: number[] = [];
102
+ let to = index;
103
+ let resolved = false;
104
+ for (let next = index + 1; next < rows.length && !resolved; next += 1) {
105
+ const row = rows[next]!;
106
+ const again = refusalOf(row);
107
+ if (isWake(row)) {
108
+ pending.push(next);
109
+ continue;
110
+ }
111
+ if (again !== undefined && sameRefusal(first, again)) {
112
+ attempts.push(attemptOf(row, again));
113
+ } else if (movedOn(row) || resolves(row)) {
114
+ resolved = true;
115
+ } else if (!resent(row)) {
116
+ break;
117
+ }
118
+ wakes.push(...pending);
119
+ pending = [];
120
+ to = next;
121
+ }
122
+ return { to, attempts, resolved, wakes };
123
+ };
124
+
74
125
  /**
75
126
  * Every run of rows that says one refusal, in order. `resolves` names the reader's own rows that end one (the editor's
76
127
  * line for an account a person switched to); the sandbox's own move (`accountMoved`) always does. A lone refusal is no
77
- * run, and is drawn as itself.
128
+ * run, and is drawn as itself, as is one wake and the refusal it met.
78
129
  */
79
130
  export const transcriptIncidents = <R extends TranscriptRow>(rows: readonly R[], resolves: (row: R) => boolean = () => false): TranscriptIncident[] => {
80
131
  const found: TranscriptIncident[] = [];
81
132
  let index = 0;
133
+ // The first row a run may reach back to: never into the run before it.
134
+ let floor = 0;
82
135
  while (index < rows.length) {
83
136
  const first = refusalOf(rows[index]!);
84
137
  if (first === undefined) {
85
138
  index += 1;
86
139
  continue;
87
140
  }
88
- const attempts = [attemptOf(rows[index]!, first)];
89
- let to = index;
90
- let resolved = false;
91
- for (let next = index + 1; next < rows.length && !resolved; next += 1) {
92
- const row = rows[next]!;
93
- const again = refusalOf(row);
94
- if (again !== undefined && sameRefusal(first, again)) {
95
- attempts.push(attemptOf(row, again));
96
- } else if (movedOn(row) || resolves(row)) {
97
- resolved = true;
98
- } else if (!resent(row)) {
99
- break;
100
- }
101
- to = next;
102
- }
103
- if (to > index) {
104
- found.push({ from: index, to, attempts, resolved });
141
+ const above = wakesAbove(rows, index, floor);
142
+ const { to, attempts, resolved, wakes } = runFrom(rows, index, first, resolves);
143
+ if (to > index || above.length > 1) {
144
+ found.push({ from: above[0] ?? index, to, attempts, resolved, wakes: [...above, ...wakes] });
145
+ floor = to + 1;
105
146
  }
106
147
  index = to + 1;
107
148
  }
@@ -5,6 +5,7 @@ import {
5
5
  LAND_FIX_PREFIX,
6
6
  LINKED_PREFIX,
7
7
  LINK_CONVERSATION_PREFIX,
8
+ ROUTE_CONVERSATION_PREFIX,
8
9
  looksDrawn,
9
10
  SUBAGENT_PREFIX,
10
11
  TAIL_ALPHABET,
@@ -79,6 +80,7 @@ test("no word collides with a derived id's prefix or a git name", () => {
79
80
  LAND_FIX_PREFIX,
80
81
  SUBAGENT_PREFIX,
81
82
  LINK_CONVERSATION_PREFIX,
83
+ ROUTE_CONVERSATION_PREFIX,
82
84
  LINKED_PREFIX,
83
85
  "a-",
84
86
  "wf-",
@@ -127,7 +129,7 @@ test("a drawn id, new or old, looks drawn; a route or a derived id does not", ()
127
129
  // A subagent's and a link's conversations are drawn ids under a prefix, and their tails carry no digit about a third
128
130
  // of the time, so the prefix must not hide them.
129
131
  test("a drawn id under a subagent or link prefix still looks drawn, in either generation", () => {
130
- for (const prefix of [SUBAGENT_PREFIX, LINK_CONVERSATION_PREFIX, LINKED_PREFIX]) {
132
+ for (const prefix of [SUBAGENT_PREFIX, LINK_CONVERSATION_PREFIX, ROUTE_CONVERSATION_PREFIX, LINKED_PREFIX]) {
131
133
  expect(looksDrawn(`${prefix}${newConversationId()}`)).toBe(true);
132
134
  expect(looksDrawn(`${prefix}otter-kmpq`)).toBe(true);
133
135
  expect(looksDrawn(`${prefix}keen-pine-tkjf`)).toBe(true);
@@ -52,13 +52,15 @@ const tail = (): string => Array.from({ length: TAIL_LENGTH }, () => pick(TAIL_S
52
52
  // A fresh id: `<word>-<tail>`, e.g. `otter-k7mq`; about ten characters against a UUID's thirty-six.
53
53
  export const newConversationId = (): string => `${pick(CONVERSATION_WORDS)}-${tail()}`;
54
54
 
55
- // A DRAWN ID WORN UNDER A PREFIX. Three kinds of conversation draw an id like any other and say what they are in front
56
- // of it: a spawned subagent (`sub-otter-k7mq`), a conversation a link opened here (`link-…`) and the roster entry for a
57
- // task running on a linked sandbox (`linked-…`). Kept here beside the word list, since no word may read as one of them.
55
+ // A DRAWN ID WORN UNDER A PREFIX. Four kinds of conversation draw an id like any other and say what they are in front
56
+ // of it: a spawned subagent (`sub-otter-k7mq`), a conversation a link opened here (`link-…`), one another sandbox opened
57
+ // here acting for one of its people (`route-…`, 2026-11-24) and the roster entry for a task running on another sandbox
58
+ // (`linked-…`). Kept here beside the word list, since no word may read as one of them.
58
59
  export const SUBAGENT_PREFIX = "sub-";
59
60
  export const LINK_CONVERSATION_PREFIX = "link-";
61
+ export const ROUTE_CONVERSATION_PREFIX = "route-";
60
62
  export const LINKED_PREFIX = "linked-";
61
- const WRAPPING_PREFIXES = [SUBAGENT_PREFIX, LINK_CONVERSATION_PREFIX, LINKED_PREFIX];
63
+ const WRAPPING_PREFIXES = [SUBAGENT_PREFIX, LINK_CONVERSATION_PREFIX, ROUTE_CONVERSATION_PREFIX, LINKED_PREFIX];
62
64
  const unwrapped = (id: string): string => {
63
65
  const prefix = WRAPPING_PREFIXES.find((candidate) => id.startsWith(candidate));
64
66
  return prefix === undefined ? id : id.slice(prefix.length);
@@ -3,7 +3,7 @@ import { MEMORY_FILE, PUBLIC_DIR, REFERENCE_DIR, WORKSPACE_ROOT } from "@intenti
3
3
  import { STARTER_REPO } from "../state/starter.js";
4
4
  import { isProjectDirName, projectDirCandidates, projectDirNameFor, projectDirNameOf, projectRemoteDir, RESERVED_PROJECT_DIR_NAMES } from "./project-dir.js";
5
5
 
6
- // The cases `ic` is held to as well (_sandbox/ic/src/sandbox/project_dir.rs), read from the one file both run.
6
+ // The cases `ic` is held to as well (_hosts/ic/src/sandbox/project_dir.rs), read from the one file both run.
7
7
  interface ProjectDirCases {
8
8
  readonly names: readonly { readonly name: string; readonly valid: boolean }[];
9
9
  readonly folders: readonly { readonly folder: string; readonly dirName: string }[];