@nexum-hub/agent 0.0.0-stage → 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (343) hide show
  1. package/README.md +129 -2
  2. package/contracts/v2/common.schema.json +262 -0
  3. package/contracts/v2/fixtures/inputs.json +244 -0
  4. package/contracts/v2/fixtures/wire.json +6493 -0
  5. package/contracts/v2/model/agent.close.input.schema.json +14 -0
  6. package/contracts/v2/model/agent.close.output.schema.json +101 -0
  7. package/contracts/v2/model/agent.list.input.schema.json +57 -0
  8. package/contracts/v2/model/agent.list.output.schema.json +220 -0
  9. package/contracts/v2/model/agent.open.input.schema.json +35 -0
  10. package/contracts/v2/model/agent.open.output.schema.json +41 -0
  11. package/contracts/v2/model/agent.run.cancel.input.schema.json +18 -0
  12. package/contracts/v2/model/agent.run.cancel.output.schema.json +100 -0
  13. package/contracts/v2/model/agent.run.get.input.schema.json +41 -0
  14. package/contracts/v2/model/agent.run.get.output.schema.json +100 -0
  15. package/contracts/v2/model/agent.run.input.input.schema.json +30 -0
  16. package/contracts/v2/model/agent.run.input.output.schema.json +100 -0
  17. package/contracts/v2/model/agent.run.list.input.schema.json +47 -0
  18. package/contracts/v2/model/agent.run.list.output.schema.json +41 -0
  19. package/contracts/v2/model/agent.run.start.input.schema.json +73 -0
  20. package/contracts/v2/model/agent.run.start.output.schema.json +100 -0
  21. package/contracts/v2/wire/bodies.schema.json +383 -0
  22. package/contracts/v2/wire/envelope.schema.json +2280 -0
  23. package/contracts/v2/wire/events.schema.json +242 -0
  24. package/contracts/v2/wire/maintenance.schema.json +308 -0
  25. package/contracts/v2/wire/operations.schema.json +1791 -0
  26. package/contracts/v2/wire/stream.schema.json +74 -0
  27. package/contracts/v2/wire/types.schema.json +2616 -0
  28. package/dist/adapters/mcp-http.d.ts +22 -0
  29. package/dist/adapters/mcp-http.js +472 -0
  30. package/dist/adapters/mcp-http.js.map +1 -0
  31. package/dist/adapters/mcp-oauth.d.ts +29 -0
  32. package/dist/adapters/mcp-oauth.js +653 -0
  33. package/dist/adapters/mcp-oauth.js.map +1 -0
  34. package/dist/adapters/mcp-wire.d.ts +21 -0
  35. package/dist/adapters/mcp-wire.js +307 -0
  36. package/dist/adapters/mcp-wire.js.map +1 -0
  37. package/dist/adapters/mcp.d.ts +56 -0
  38. package/dist/adapters/mcp.js +1989 -0
  39. package/dist/adapters/mcp.js.map +1 -0
  40. package/dist/adapters/openapi-http.d.ts +29 -0
  41. package/dist/adapters/openapi-http.js +504 -0
  42. package/dist/adapters/openapi-http.js.map +1 -0
  43. package/dist/adapters/openapi-request.d.ts +26 -0
  44. package/dist/adapters/openapi-request.js +597 -0
  45. package/dist/adapters/openapi-request.js.map +1 -0
  46. package/dist/adapters/openapi-schema.d.ts +22 -0
  47. package/dist/adapters/openapi-schema.js +471 -0
  48. package/dist/adapters/openapi-schema.js.map +1 -0
  49. package/dist/adapters/openapi-typegen.d.ts +11 -0
  50. package/dist/adapters/openapi-typegen.js +185 -0
  51. package/dist/adapters/openapi-typegen.js.map +1 -0
  52. package/dist/adapters/openapi-types.d.ts +99 -0
  53. package/dist/adapters/openapi-types.js +2 -0
  54. package/dist/adapters/openapi-types.js.map +1 -0
  55. package/dist/adapters/openapi.d.ts +7 -0
  56. package/dist/adapters/openapi.js +768 -0
  57. package/dist/adapters/openapi.js.map +1 -0
  58. package/dist/application/activation.d.ts +28 -0
  59. package/dist/application/activation.js +289 -0
  60. package/dist/application/activation.js.map +1 -0
  61. package/dist/application/attachments.d.ts +24 -0
  62. package/dist/application/attachments.js +87 -0
  63. package/dist/application/attachments.js.map +1 -0
  64. package/dist/application/authority.d.ts +32 -0
  65. package/dist/application/authority.js +213 -0
  66. package/dist/application/authority.js.map +1 -0
  67. package/dist/application/catalog.d.ts +11 -0
  68. package/dist/application/catalog.js +177 -0
  69. package/dist/application/catalog.js.map +1 -0
  70. package/dist/application/config.d.ts +24 -0
  71. package/dist/application/config.js +140 -0
  72. package/dist/application/config.js.map +1 -0
  73. package/dist/application/connection.d.ts +35 -0
  74. package/dist/application/connection.js +465 -0
  75. package/dist/application/connection.js.map +1 -0
  76. package/dist/application/data-plane.d.ts +35 -0
  77. package/dist/application/data-plane.js +437 -0
  78. package/dist/application/data-plane.js.map +1 -0
  79. package/dist/application/diagnostics.d.ts +4 -0
  80. package/dist/application/diagnostics.js +65 -0
  81. package/dist/application/diagnostics.js.map +1 -0
  82. package/dist/application/dispatcher.d.ts +4 -0
  83. package/dist/application/dispatcher.js +16 -0
  84. package/dist/application/dispatcher.js.map +1 -0
  85. package/dist/application/main.d.ts +12 -0
  86. package/dist/application/main.js +167 -0
  87. package/dist/application/main.js.map +1 -0
  88. package/dist/application/maintenance.d.ts +27 -0
  89. package/dist/application/maintenance.js +244 -0
  90. package/dist/application/maintenance.js.map +1 -0
  91. package/dist/application/packages.d.ts +25 -0
  92. package/dist/application/packages.js +208 -0
  93. package/dist/application/packages.js.map +1 -0
  94. package/dist/application/processes.d.ts +49 -0
  95. package/dist/application/processes.js +180 -0
  96. package/dist/application/processes.js.map +1 -0
  97. package/dist/application/run-view.d.ts +17 -0
  98. package/dist/application/run-view.js +286 -0
  99. package/dist/application/run-view.js.map +1 -0
  100. package/dist/application/runtime.d.ts +78 -0
  101. package/dist/application/runtime.js +1747 -0
  102. package/dist/application/runtime.js.map +1 -0
  103. package/dist/application/tasks.d.ts +38 -0
  104. package/dist/application/tasks.js +23 -0
  105. package/dist/application/tasks.js.map +1 -0
  106. package/dist/application/user-state.d.ts +20 -0
  107. package/dist/application/user-state.js +52 -0
  108. package/dist/application/user-state.js.map +1 -0
  109. package/dist/application/work-git.d.ts +14 -0
  110. package/dist/application/work-git.js +67 -0
  111. package/dist/application/work-git.js.map +1 -0
  112. package/dist/cli.d.ts +2 -0
  113. package/dist/cli.js +40 -0
  114. package/dist/cli.js.map +1 -0
  115. package/dist/contracts/caller.d.ts +51 -0
  116. package/dist/contracts/caller.js +95 -0
  117. package/dist/contracts/caller.js.map +1 -0
  118. package/dist/contracts/error-data.d.ts +6 -0
  119. package/dist/contracts/error-data.js +51 -0
  120. package/dist/contracts/error-data.js.map +1 -0
  121. package/dist/contracts/errors.d.ts +10 -0
  122. package/dist/contracts/errors.js +28 -0
  123. package/dist/contracts/errors.js.map +1 -0
  124. package/dist/contracts/json.d.ts +9 -0
  125. package/dist/contracts/json.js +104 -0
  126. package/dist/contracts/json.js.map +1 -0
  127. package/dist/contracts/types.d.ts +122 -0
  128. package/dist/contracts/types.js +19 -0
  129. package/dist/contracts/types.js.map +1 -0
  130. package/dist/contracts/validation.d.ts +4 -0
  131. package/dist/contracts/validation.js +157 -0
  132. package/dist/contracts/validation.js.map +1 -0
  133. package/dist/contracts/wire-validation.d.ts +9 -0
  134. package/dist/contracts/wire-validation.js +399 -0
  135. package/dist/contracts/wire-validation.js.map +1 -0
  136. package/dist/contracts/wire.d.ts +1083 -0
  137. package/dist/contracts/wire.js +62 -0
  138. package/dist/contracts/wire.js.map +1 -0
  139. package/dist/extension-api.d.ts +12 -0
  140. package/dist/extension-api.js +2 -0
  141. package/dist/extension-api.js.map +1 -0
  142. package/dist/extensions/api.d.ts +72 -0
  143. package/dist/extensions/api.js +2 -0
  144. package/dist/extensions/api.js.map +1 -0
  145. package/dist/extensions/host-requests.d.ts +23 -0
  146. package/dist/extensions/host-requests.js +60 -0
  147. package/dist/extensions/host-requests.js.map +1 -0
  148. package/dist/extensions/materials.d.ts +37 -0
  149. package/dist/extensions/materials.js +691 -0
  150. package/dist/extensions/materials.js.map +1 -0
  151. package/dist/extensions/package-loader.d.ts +28 -0
  152. package/dist/extensions/package-loader.js +177 -0
  153. package/dist/extensions/package-loader.js.map +1 -0
  154. package/dist/extensions/packages.d.ts +73 -0
  155. package/dist/extensions/packages.js +441 -0
  156. package/dist/extensions/packages.js.map +1 -0
  157. package/dist/extensions/registry.d.ts +92 -0
  158. package/dist/extensions/registry.js +1540 -0
  159. package/dist/extensions/registry.js.map +1 -0
  160. package/dist/extensions/resources.d.ts +105 -0
  161. package/dist/extensions/resources.js +595 -0
  162. package/dist/extensions/resources.js.map +1 -0
  163. package/dist/extensions/state.d.ts +25 -0
  164. package/dist/extensions/state.js +10 -0
  165. package/dist/extensions/state.js.map +1 -0
  166. package/dist/extensions/transfer.d.ts +81 -0
  167. package/dist/extensions/transfer.js +16 -0
  168. package/dist/extensions/transfer.js.map +1 -0
  169. package/dist/index.d.ts +7 -0
  170. package/dist/index.js +25 -0
  171. package/dist/index.js.map +1 -0
  172. package/dist/maintenance/configuration.d.ts +79 -0
  173. package/dist/maintenance/configuration.js +1503 -0
  174. package/dist/maintenance/configuration.js.map +1 -0
  175. package/dist/maintenance/credentials.d.ts +23 -0
  176. package/dist/maintenance/credentials.js +177 -0
  177. package/dist/maintenance/credentials.js.map +1 -0
  178. package/dist/maintenance/files.d.ts +2 -0
  179. package/dist/maintenance/files.js +40 -0
  180. package/dist/maintenance/files.js.map +1 -0
  181. package/dist/maintenance/npm.d.ts +71 -0
  182. package/dist/maintenance/npm.js +1013 -0
  183. package/dist/maintenance/npm.js.map +1 -0
  184. package/dist/maintenance/oauth.d.ts +45 -0
  185. package/dist/maintenance/oauth.js +686 -0
  186. package/dist/maintenance/oauth.js.map +1 -0
  187. package/dist/maintenance/requests.d.ts +347 -0
  188. package/dist/maintenance/requests.js +959 -0
  189. package/dist/maintenance/requests.js.map +1 -0
  190. package/dist/maintenance/work-git.d.ts +29 -0
  191. package/dist/maintenance/work-git.js +776 -0
  192. package/dist/maintenance/work-git.js.map +1 -0
  193. package/dist/process/backend.d.ts +54 -0
  194. package/dist/process/backend.js +39 -0
  195. package/dist/process/backend.js.map +1 -0
  196. package/dist/process/environment-windows.d.ts +15 -0
  197. package/dist/process/environment-windows.js +151 -0
  198. package/dist/process/environment-windows.js.map +1 -0
  199. package/dist/process/environment.d.ts +28 -0
  200. package/dist/process/environment.js +410 -0
  201. package/dist/process/environment.js.map +1 -0
  202. package/dist/process/launch.d.ts +31 -0
  203. package/dist/process/launch.js +281 -0
  204. package/dist/process/launch.js.map +1 -0
  205. package/dist/process/managed.d.ts +36 -0
  206. package/dist/process/managed.js +459 -0
  207. package/dist/process/managed.js.map +1 -0
  208. package/dist/process/output-log.d.ts +50 -0
  209. package/dist/process/output-log.js +552 -0
  210. package/dist/process/output-log.js.map +1 -0
  211. package/dist/process/pipes.d.ts +16 -0
  212. package/dist/process/pipes.js +588 -0
  213. package/dist/process/pipes.js.map +1 -0
  214. package/dist/process/pty.d.ts +22 -0
  215. package/dist/process/pty.js +512 -0
  216. package/dist/process/pty.js.map +1 -0
  217. package/dist/process/windows-conout-worker.d.ts +1 -0
  218. package/dist/process/windows-conout-worker.js +90 -0
  219. package/dist/process/windows-conout-worker.js.map +1 -0
  220. package/dist/process/windows-conout.d.ts +46 -0
  221. package/dist/process/windows-conout.js +140 -0
  222. package/dist/process/windows-conout.js.map +1 -0
  223. package/dist/process/windows-helper.d.ts +43 -0
  224. package/dist/process/windows-helper.js +255 -0
  225. package/dist/process/windows-helper.js.map +1 -0
  226. package/dist/process/windows-job.d.ts +39 -0
  227. package/dist/process/windows-job.js +224 -0
  228. package/dist/process/windows-job.js.map +1 -0
  229. package/dist/process/windows-pipes.d.ts +16 -0
  230. package/dist/process/windows-pipes.js +475 -0
  231. package/dist/process/windows-pipes.js.map +1 -0
  232. package/dist/results/artifacts.d.ts +118 -0
  233. package/dist/results/artifacts.js +873 -0
  234. package/dist/results/artifacts.js.map +1 -0
  235. package/dist/results/encoder.d.ts +57 -0
  236. package/dist/results/encoder.js +1179 -0
  237. package/dist/results/encoder.js.map +1 -0
  238. package/dist/results/mcp.d.ts +95 -0
  239. package/dist/results/mcp.js +656 -0
  240. package/dist/results/mcp.js.map +1 -0
  241. package/dist/results/media.d.ts +19 -0
  242. package/dist/results/media.js +301 -0
  243. package/dist/results/media.js.map +1 -0
  244. package/dist/results/normalize.d.ts +29 -0
  245. package/dist/results/normalize.js +464 -0
  246. package/dist/results/normalize.js.map +1 -0
  247. package/dist/runtime/control-scripts.d.ts +23 -0
  248. package/dist/runtime/control-scripts.js +242 -0
  249. package/dist/runtime/control-scripts.js.map +1 -0
  250. package/dist/runtime/engine.d.ts +177 -0
  251. package/dist/runtime/engine.js +1159 -0
  252. package/dist/runtime/engine.js.map +1 -0
  253. package/dist/runtime/globals.d.ts +1 -0
  254. package/dist/runtime/globals.js +31 -0
  255. package/dist/runtime/globals.js.map +1 -0
  256. package/dist/runtime/material-retention.d.ts +34 -0
  257. package/dist/runtime/material-retention.js +671 -0
  258. package/dist/runtime/material-retention.js.map +1 -0
  259. package/dist/runtime/modules.d.ts +50 -0
  260. package/dist/runtime/modules.js +320 -0
  261. package/dist/runtime/modules.js.map +1 -0
  262. package/dist/runtime/names.d.ts +2 -0
  263. package/dist/runtime/names.js +22 -0
  264. package/dist/runtime/names.js.map +1 -0
  265. package/dist/runtime/operations.d.ts +20 -0
  266. package/dist/runtime/operations.js +137 -0
  267. package/dist/runtime/operations.js.map +1 -0
  268. package/dist/runtime/paths.d.ts +3 -0
  269. package/dist/runtime/paths.js +38 -0
  270. package/dist/runtime/paths.js.map +1 -0
  271. package/dist/runtime/promises.d.ts +9 -0
  272. package/dist/runtime/promises.js +78 -0
  273. package/dist/runtime/promises.js.map +1 -0
  274. package/dist/runtime/retention.d.ts +88 -0
  275. package/dist/runtime/retention.js +735 -0
  276. package/dist/runtime/retention.js.map +1 -0
  277. package/dist/runtime/run-log.d.ts +30 -0
  278. package/dist/runtime/run-log.js +207 -0
  279. package/dist/runtime/run-log.js.map +1 -0
  280. package/dist/runtime/scripts.d.ts +84 -0
  281. package/dist/runtime/scripts.js +387 -0
  282. package/dist/runtime/scripts.js.map +1 -0
  283. package/dist/runtime/tasks.d.ts +54 -0
  284. package/dist/runtime/tasks.js +290 -0
  285. package/dist/runtime/tasks.js.map +1 -0
  286. package/dist/sdk/maintenance.d.ts +3 -0
  287. package/dist/sdk/maintenance.js +80 -0
  288. package/dist/sdk/maintenance.js.map +1 -0
  289. package/dist/sdk/output-extension.d.ts +3 -0
  290. package/dist/sdk/output-extension.js +44 -0
  291. package/dist/sdk/output-extension.js.map +1 -0
  292. package/dist/sdk/output.d.ts +52 -0
  293. package/dist/sdk/output.js +350 -0
  294. package/dist/sdk/output.js.map +1 -0
  295. package/dist/sdk/runtime.d.ts +3 -0
  296. package/dist/sdk/runtime.js +26 -0
  297. package/dist/sdk/runtime.js.map +1 -0
  298. package/dist/sdk/sh.d.ts +3 -0
  299. package/dist/sdk/sh.js +384 -0
  300. package/dist/sdk/sh.js.map +1 -0
  301. package/dist/sdk/state.d.ts +2 -0
  302. package/dist/sdk/state.js +69 -0
  303. package/dist/sdk/state.js.map +1 -0
  304. package/dist/sdk/transfer.d.ts +3 -0
  305. package/dist/sdk/transfer.js +141 -0
  306. package/dist/sdk/transfer.js.map +1 -0
  307. package/dist/services/extensions.d.ts +19 -0
  308. package/dist/services/extensions.js +183 -0
  309. package/dist/services/extensions.js.map +1 -0
  310. package/dist/services/state.d.ts +37 -0
  311. package/dist/services/state.js +125 -0
  312. package/dist/services/state.js.map +1 -0
  313. package/dist/services/transfer.d.ts +86 -0
  314. package/dist/services/transfer.js +948 -0
  315. package/dist/services/transfer.js.map +1 -0
  316. package/dist/storage/schema.d.ts +8 -0
  317. package/dist/storage/schema.js +241 -0
  318. package/dist/storage/schema.js.map +1 -0
  319. package/dist/storage/sqlite.d.ts +241 -0
  320. package/dist/storage/sqlite.js +1855 -0
  321. package/dist/storage/sqlite.js.map +1 -0
  322. package/dist/storage/transfers.d.ts +90 -0
  323. package/dist/storage/transfers.js +2 -0
  324. package/dist/storage/transfers.js.map +1 -0
  325. package/dist/transfer/io.d.ts +74 -0
  326. package/dist/transfer/io.js +425 -0
  327. package/dist/transfer/io.js.map +1 -0
  328. package/dist/transfer/offers.d.ts +72 -0
  329. package/dist/transfer/offers.js +380 -0
  330. package/dist/transfer/offers.js.map +1 -0
  331. package/dist/transfer/stream-slots.d.ts +12 -0
  332. package/dist/transfer/stream-slots.js +28 -0
  333. package/dist/transfer/stream-slots.js.map +1 -0
  334. package/dist/work/catalog.d.ts +43 -0
  335. package/dist/work/catalog.js +198 -0
  336. package/dist/work/catalog.js.map +1 -0
  337. package/dist/work/discovery.d.ts +70 -0
  338. package/dist/work/discovery.js +465 -0
  339. package/dist/work/discovery.js.map +1 -0
  340. package/dist/work/service.d.ts +83 -0
  341. package/dist/work/service.js +703 -0
  342. package/dist/work/service.js.map +1 -0
  343. package/package.json +66 -4
@@ -0,0 +1,2616 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://schemas.nexum.local/agent/v2/wire/types.schema.json",
4
+ "$defs": {
5
+ "Error": {
6
+ "type": "object",
7
+ "properties": {
8
+ "code": {
9
+ "type": "string",
10
+ "minLength": 1,
11
+ "maxLength": 256
12
+ },
13
+ "message": {
14
+ "type": "string",
15
+ "maxLength": 4096
16
+ },
17
+ "details": {
18
+ "type": "object"
19
+ }
20
+ },
21
+ "required": ["code", "message"],
22
+ "additionalProperties": false
23
+ },
24
+ "HostCapabilities": {
25
+ "type": "object",
26
+ "properties": {
27
+ "sampling": {
28
+ "type": "boolean"
29
+ },
30
+ "elicitation": {
31
+ "type": "boolean"
32
+ },
33
+ "roots": {
34
+ "type": "boolean"
35
+ }
36
+ },
37
+ "required": ["sampling", "elicitation", "roots"],
38
+ "additionalProperties": false
39
+ },
40
+ "Caller": {
41
+ "oneOf": [
42
+ {
43
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/McpCaller"
44
+ },
45
+ {
46
+ "$ref": "https://schemas.nexum.local/agent/v2/common.schema.json#/$defs/ownerSessionCaller"
47
+ }
48
+ ]
49
+ },
50
+ "Connection": {
51
+ "type": "object",
52
+ "properties": {
53
+ "agentId": {
54
+ "type": "string",
55
+ "minLength": 1,
56
+ "maxLength": 256
57
+ },
58
+ "profile": {
59
+ "enum": ["development", "production"]
60
+ },
61
+ "bootId": {
62
+ "type": "string",
63
+ "minLength": 1,
64
+ "maxLength": 256
65
+ },
66
+ "cloudEnvironment": {
67
+ "type": "string",
68
+ "minLength": 1,
69
+ "maxLength": 256
70
+ },
71
+ "connectionId": {
72
+ "type": "string",
73
+ "minLength": 1,
74
+ "maxLength": 256
75
+ }
76
+ },
77
+ "required": [
78
+ "agentId",
79
+ "profile",
80
+ "bootId",
81
+ "cloudEnvironment",
82
+ "connectionId"
83
+ ],
84
+ "additionalProperties": false
85
+ },
86
+ "Budgets": {
87
+ "type": "object",
88
+ "properties": {
89
+ "controlBytes": {
90
+ "type": "integer",
91
+ "minimum": 0,
92
+ "maximum": 9007199254740991
93
+ },
94
+ "textBytes": {
95
+ "type": "integer",
96
+ "minimum": 0,
97
+ "maximum": 9007199254740991
98
+ },
99
+ "imageBytes": {
100
+ "type": "integer",
101
+ "minimum": 0,
102
+ "maximum": 9007199254740991
103
+ },
104
+ "audioBytes": {
105
+ "type": "integer",
106
+ "minimum": 0,
107
+ "maximum": 9007199254740991
108
+ },
109
+ "inlineBytes": {
110
+ "type": "integer",
111
+ "minimum": 0,
112
+ "maximum": 9007199254740991
113
+ },
114
+ "responseBytes": {
115
+ "type": "integer",
116
+ "minimum": 0,
117
+ "maximum": 9007199254740991
118
+ },
119
+ "fileBytes": {
120
+ "type": "integer",
121
+ "minimum": 0,
122
+ "maximum": 9007199254740991
123
+ },
124
+ "attachmentBytes": {
125
+ "type": "integer",
126
+ "minimum": 0,
127
+ "maximum": 9007199254740991
128
+ },
129
+ "attachmentCount": {
130
+ "type": "integer",
131
+ "minimum": 0,
132
+ "maximum": 9007199254740991
133
+ },
134
+ "resourcePageLimit": {
135
+ "type": "integer",
136
+ "minimum": 0,
137
+ "maximum": 9007199254740991
138
+ }
139
+ },
140
+ "required": [],
141
+ "additionalProperties": false
142
+ },
143
+ "Visibility": {
144
+ "type": "object",
145
+ "properties": {
146
+ "disabledItems": {
147
+ "type": "array",
148
+ "items": {
149
+ "type": "object",
150
+ "properties": {
151
+ "kind": {
152
+ "enum": ["instruction", "skill"]
153
+ },
154
+ "key": {
155
+ "type": "string",
156
+ "minLength": 1,
157
+ "maxLength": 256
158
+ }
159
+ },
160
+ "required": ["kind", "key"],
161
+ "additionalProperties": false
162
+ },
163
+ "maxItems": 1000
164
+ }
165
+ },
166
+ "required": ["disabledItems"],
167
+ "additionalProperties": false
168
+ },
169
+ "Authorization": {
170
+ "type": "object",
171
+ "properties": {
172
+ "agentId": {
173
+ "type": "string",
174
+ "minLength": 1,
175
+ "maxLength": 256
176
+ },
177
+ "projectId": {
178
+ "type": "string",
179
+ "minLength": 1,
180
+ "maxLength": 256
181
+ },
182
+ "projectRoot": {
183
+ "type": "string",
184
+ "minLength": 1,
185
+ "maxLength": 8192
186
+ },
187
+ "projectName": {
188
+ "type": "string",
189
+ "minLength": 1,
190
+ "maxLength": 256
191
+ },
192
+ "projectDescription": {
193
+ "type": "string",
194
+ "maxLength": 1048576
195
+ },
196
+ "projectContextVisibility": {
197
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Visibility"
198
+ },
199
+ "allowedRoots": {
200
+ "type": "array",
201
+ "items": {
202
+ "type": "string",
203
+ "minLength": 1,
204
+ "maxLength": 8192
205
+ },
206
+ "maxItems": 1000
207
+ },
208
+ "budgets": {
209
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Budgets"
210
+ },
211
+ "revision": {
212
+ "type": "string",
213
+ "minLength": 1,
214
+ "maxLength": 256
215
+ },
216
+ "expiresAt": {
217
+ "type": "string",
218
+ "format": "date-time",
219
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
220
+ }
221
+ },
222
+ "required": [
223
+ "agentId",
224
+ "allowedRoots",
225
+ "budgets",
226
+ "revision",
227
+ "expiresAt"
228
+ ],
229
+ "additionalProperties": false,
230
+ "dependentRequired": {
231
+ "projectId": ["projectRoot", "projectName"],
232
+ "projectRoot": ["projectId", "projectName"],
233
+ "projectName": ["projectId", "projectRoot"],
234
+ "projectDescription": ["projectId"],
235
+ "projectContextVisibility": ["projectId"]
236
+ }
237
+ },
238
+ "InvocationContext": {
239
+ "type": "object",
240
+ "properties": {
241
+ "caller": {
242
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Caller"
243
+ },
244
+ "authorization": {
245
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Authorization"
246
+ },
247
+ "connection": {
248
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Connection"
249
+ }
250
+ },
251
+ "required": ["caller", "authorization", "connection"],
252
+ "additionalProperties": false
253
+ },
254
+ "Submission": {
255
+ "type": "object",
256
+ "properties": {
257
+ "issuedAt": {
258
+ "type": "integer",
259
+ "minimum": 0,
260
+ "maximum": 9007199254740991
261
+ },
262
+ "expiresAt": {
263
+ "type": "integer",
264
+ "minimum": 0,
265
+ "maximum": 9007199254740991
266
+ }
267
+ },
268
+ "required": ["issuedAt", "expiresAt"],
269
+ "additionalProperties": false
270
+ },
271
+ "Attachment": {
272
+ "oneOf": [
273
+ {
274
+ "type": "object",
275
+ "properties": {
276
+ "transferId": {
277
+ "type": "string",
278
+ "minLength": 1,
279
+ "maxLength": 256
280
+ }
281
+ },
282
+ "required": ["transferId"],
283
+ "additionalProperties": false
284
+ },
285
+ {
286
+ "type": "object",
287
+ "properties": {
288
+ "uri": {
289
+ "type": "string",
290
+ "minLength": 1,
291
+ "maxLength": 4096,
292
+ "pattern": "^nexum://agents/[^/?#]+/(?:resources|mcp)/"
293
+ }
294
+ },
295
+ "required": ["uri"],
296
+ "additionalProperties": false
297
+ },
298
+ {
299
+ "type": "object",
300
+ "properties": {
301
+ "sourceId": {
302
+ "type": "string",
303
+ "pattern": "^att_[0-9a-f]{64}$"
304
+ }
305
+ },
306
+ "required": ["sourceId"],
307
+ "additionalProperties": false
308
+ }
309
+ ]
310
+ },
311
+ "Origin": {
312
+ "type": "object",
313
+ "properties": {
314
+ "type": {
315
+ "enum": ["local", "platform", "extension"]
316
+ },
317
+ "owner": {
318
+ "type": "string",
319
+ "minLength": 1,
320
+ "maxLength": 256
321
+ },
322
+ "namespace": {
323
+ "anyOf": [
324
+ {
325
+ "type": "string",
326
+ "minLength": 1,
327
+ "maxLength": 256
328
+ },
329
+ {
330
+ "type": "null"
331
+ }
332
+ ]
333
+ },
334
+ "version": {
335
+ "anyOf": [
336
+ {
337
+ "type": "string",
338
+ "minLength": 1,
339
+ "maxLength": 256
340
+ },
341
+ {
342
+ "type": "null"
343
+ }
344
+ ]
345
+ },
346
+ "revision": {
347
+ "type": "string",
348
+ "minLength": 1,
349
+ "maxLength": 256
350
+ }
351
+ },
352
+ "required": ["type", "owner", "namespace", "version", "revision"],
353
+ "additionalProperties": false
354
+ },
355
+ "Run": {
356
+ "type": "object",
357
+ "properties": {
358
+ "runId": {
359
+ "type": "string",
360
+ "minLength": 1,
361
+ "maxLength": 256
362
+ },
363
+ "contextId": {
364
+ "type": "string",
365
+ "minLength": 1,
366
+ "maxLength": 256
367
+ },
368
+ "projectId": {
369
+ "anyOf": [
370
+ {
371
+ "type": "string",
372
+ "minLength": 1,
373
+ "maxLength": 256
374
+ },
375
+ {
376
+ "type": "null"
377
+ }
378
+ ]
379
+ },
380
+ "revision": {
381
+ "type": "integer",
382
+ "minimum": 1,
383
+ "maximum": 9007199254740991
384
+ },
385
+ "status": {
386
+ "enum": [
387
+ "accepted",
388
+ "preparing_inputs",
389
+ "running",
390
+ "waiting_input",
391
+ "cancelling",
392
+ "succeeded",
393
+ "failed",
394
+ "cancelled",
395
+ "interrupted"
396
+ ]
397
+ },
398
+ "scriptName": {
399
+ "anyOf": [
400
+ {
401
+ "type": "string",
402
+ "minLength": 1,
403
+ "maxLength": 256
404
+ },
405
+ {
406
+ "type": "null"
407
+ }
408
+ ]
409
+ },
410
+ "source": {
411
+ "enum": ["inline", "named", "history"]
412
+ },
413
+ "origin": {
414
+ "anyOf": [
415
+ {
416
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Origin"
417
+ },
418
+ {
419
+ "type": "null"
420
+ }
421
+ ]
422
+ },
423
+ "replayOfRunId": {
424
+ "anyOf": [
425
+ {
426
+ "type": "string",
427
+ "minLength": 1,
428
+ "maxLength": 256
429
+ },
430
+ {
431
+ "type": "null"
432
+ }
433
+ ]
434
+ },
435
+ "acceptedAt": {
436
+ "type": "string",
437
+ "format": "date-time",
438
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
439
+ },
440
+ "startedAt": {
441
+ "anyOf": [
442
+ {
443
+ "type": "string",
444
+ "format": "date-time",
445
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
446
+ },
447
+ {
448
+ "type": "null"
449
+ }
450
+ ]
451
+ },
452
+ "finishedAt": {
453
+ "anyOf": [
454
+ {
455
+ "type": "string",
456
+ "format": "date-time",
457
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
458
+ },
459
+ {
460
+ "type": "null"
461
+ }
462
+ ]
463
+ },
464
+ "deadlineAt": {
465
+ "type": "string",
466
+ "format": "date-time",
467
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
468
+ },
469
+ "updatedAt": {
470
+ "type": "string",
471
+ "format": "date-time",
472
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
473
+ },
474
+ "error": {
475
+ "anyOf": [
476
+ {
477
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Error"
478
+ },
479
+ {
480
+ "type": "null"
481
+ }
482
+ ]
483
+ },
484
+ "stop": {
485
+ "anyOf": [
486
+ {
487
+ "type": "object"
488
+ },
489
+ {
490
+ "type": "null"
491
+ }
492
+ ]
493
+ },
494
+ "cleanup": {
495
+ "type": "object"
496
+ },
497
+ "availability": {
498
+ "type": "object",
499
+ "properties": {
500
+ "code": {
501
+ "type": "boolean"
502
+ },
503
+ "input": {
504
+ "type": "boolean"
505
+ },
506
+ "result": {
507
+ "type": "boolean"
508
+ },
509
+ "logs": {
510
+ "type": "boolean"
511
+ }
512
+ },
513
+ "required": ["code", "input", "result", "logs"],
514
+ "additionalProperties": false
515
+ },
516
+ "scriptDesc": {
517
+ "anyOf": [
518
+ {
519
+ "type": "string",
520
+ "maxLength": 2048
521
+ },
522
+ {
523
+ "type": "null"
524
+ }
525
+ ]
526
+ },
527
+ "descriptionTruncated": {
528
+ "const": true
529
+ }
530
+ },
531
+ "required": [
532
+ "runId",
533
+ "contextId",
534
+ "projectId",
535
+ "revision",
536
+ "status",
537
+ "scriptName",
538
+ "source",
539
+ "origin",
540
+ "replayOfRunId",
541
+ "acceptedAt",
542
+ "startedAt",
543
+ "finishedAt",
544
+ "deadlineAt",
545
+ "updatedAt",
546
+ "error",
547
+ "stop",
548
+ "cleanup",
549
+ "availability"
550
+ ],
551
+ "additionalProperties": false
552
+ },
553
+ "Wait": {
554
+ "type": "object",
555
+ "properties": {
556
+ "waitId": {
557
+ "type": "string",
558
+ "minLength": 1,
559
+ "maxLength": 256
560
+ },
561
+ "revision": {
562
+ "type": "integer",
563
+ "minimum": 1,
564
+ "maximum": 9007199254740991
565
+ },
566
+ "status": {
567
+ "enum": ["waiting", "consumed", "expired", "cancelled"]
568
+ },
569
+ "deliveryState": {
570
+ "enum": ["none", "preparing", "failed", "consumed"]
571
+ },
572
+ "request": {
573
+ "type": "object"
574
+ },
575
+ "createdAt": {
576
+ "type": "string",
577
+ "format": "date-time",
578
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
579
+ },
580
+ "deadlineAt": {
581
+ "type": "string",
582
+ "format": "date-time",
583
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
584
+ },
585
+ "consumedAt": {
586
+ "anyOf": [
587
+ {
588
+ "type": "string",
589
+ "format": "date-time",
590
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
591
+ },
592
+ {
593
+ "type": "null"
594
+ }
595
+ ]
596
+ },
597
+ "error": {
598
+ "anyOf": [
599
+ {
600
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Error"
601
+ },
602
+ {
603
+ "type": "null"
604
+ }
605
+ ]
606
+ }
607
+ },
608
+ "required": [
609
+ "waitId",
610
+ "revision",
611
+ "status",
612
+ "deliveryState",
613
+ "request",
614
+ "createdAt",
615
+ "deadlineAt",
616
+ "consumedAt",
617
+ "error"
618
+ ],
619
+ "additionalProperties": false
620
+ },
621
+ "Artifact": {
622
+ "type": "object",
623
+ "properties": {
624
+ "uri": {
625
+ "type": "string",
626
+ "minLength": 1,
627
+ "maxLength": 4096,
628
+ "pattern": "^nexum://agents/[^/?#]+/resources/res_[0-9a-f]{32}$"
629
+ },
630
+ "name": {
631
+ "type": "string",
632
+ "minLength": 1,
633
+ "maxLength": 1024
634
+ },
635
+ "mimeType": {
636
+ "type": "string",
637
+ "minLength": 3,
638
+ "maxLength": 256,
639
+ "pattern": "^[^\\s/;]+/[^\\s;]+(?:;[^\\r\\n]+)?$"
640
+ },
641
+ "size": {
642
+ "type": "integer",
643
+ "minimum": 0,
644
+ "maximum": 9007199254740991
645
+ },
646
+ "sha256": {
647
+ "type": "string",
648
+ "pattern": "^[0-9a-f]{64}$"
649
+ },
650
+ "expiresAt": {
651
+ "type": "string",
652
+ "format": "date-time",
653
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
654
+ }
655
+ },
656
+ "required": ["uri", "name", "mimeType", "size", "sha256", "expiresAt"],
657
+ "additionalProperties": false
658
+ },
659
+ "ResourceEntry": {
660
+ "type": "object",
661
+ "properties": {
662
+ "uri": {
663
+ "type": "string",
664
+ "minLength": 1,
665
+ "maxLength": 4096,
666
+ "pattern": "^nexum://agents/[^/?#]+/(?:resources|mcp)/"
667
+ },
668
+ "name": {
669
+ "type": "string",
670
+ "minLength": 1,
671
+ "maxLength": 1024
672
+ },
673
+ "mimeType": {
674
+ "type": "string",
675
+ "minLength": 3,
676
+ "maxLength": 256,
677
+ "pattern": "^[^\\s/;]+/[^\\s;]+(?:;[^\\r\\n]+)?$"
678
+ },
679
+ "description": {
680
+ "type": "string",
681
+ "maxLength": 1048576
682
+ },
683
+ "size": {
684
+ "type": "integer",
685
+ "minimum": 0,
686
+ "maximum": 9007199254740991
687
+ },
688
+ "title": {
689
+ "type": "string",
690
+ "maxLength": 1048576
691
+ },
692
+ "icons": {
693
+ "type": "array",
694
+ "maxItems": 1000,
695
+ "items": {
696
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Icon"
697
+ }
698
+ },
699
+ "annotations": {
700
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Annotations"
701
+ }
702
+ },
703
+ "required": ["uri", "name"],
704
+ "additionalProperties": false
705
+ },
706
+ "Content": {
707
+ "oneOf": [
708
+ {
709
+ "type": "object",
710
+ "properties": {
711
+ "type": {
712
+ "const": "text"
713
+ },
714
+ "text": {
715
+ "type": "string",
716
+ "maxLength": 1048576
717
+ },
718
+ "annotations": {
719
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Annotations"
720
+ },
721
+ "description": {
722
+ "type": "string",
723
+ "maxLength": 1048576
724
+ }
725
+ },
726
+ "required": ["type", "text"],
727
+ "additionalProperties": false
728
+ },
729
+ {
730
+ "type": "object",
731
+ "properties": {
732
+ "type": {
733
+ "enum": ["image", "audio"]
734
+ },
735
+ "resource": {
736
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Artifact"
737
+ },
738
+ "mimeType": {
739
+ "type": "string",
740
+ "minLength": 3,
741
+ "maxLength": 256,
742
+ "pattern": "^[^\\s/;]+/[^\\s;]+(?:;[^\\r\\n]+)?$"
743
+ },
744
+ "annotations": {
745
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Annotations"
746
+ },
747
+ "description": {
748
+ "type": "string",
749
+ "maxLength": 1048576
750
+ }
751
+ },
752
+ "required": ["type", "resource", "mimeType"],
753
+ "additionalProperties": false
754
+ },
755
+ {
756
+ "type": "object",
757
+ "properties": {
758
+ "type": {
759
+ "const": "resource_link"
760
+ },
761
+ "uri": {
762
+ "type": "string",
763
+ "minLength": 1,
764
+ "maxLength": 4096,
765
+ "pattern": "^nexum://agents/[^/?#]+/(?:resources|mcp)/"
766
+ },
767
+ "name": {
768
+ "type": "string",
769
+ "minLength": 1,
770
+ "maxLength": 1024
771
+ },
772
+ "mimeType": {
773
+ "type": "string",
774
+ "minLength": 3,
775
+ "maxLength": 256,
776
+ "pattern": "^[^\\s/;]+/[^\\s;]+(?:;[^\\r\\n]+)?$"
777
+ },
778
+ "annotations": {
779
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Annotations"
780
+ },
781
+ "description": {
782
+ "type": "string",
783
+ "maxLength": 1048576
784
+ },
785
+ "title": {
786
+ "type": "string",
787
+ "maxLength": 1048576
788
+ },
789
+ "size": {
790
+ "type": "integer",
791
+ "minimum": 0,
792
+ "maximum": 9007199254740991
793
+ },
794
+ "icons": {
795
+ "type": "array",
796
+ "maxItems": 1000,
797
+ "items": {
798
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Icon"
799
+ }
800
+ }
801
+ },
802
+ "required": ["type", "uri", "name"],
803
+ "additionalProperties": false
804
+ },
805
+ {
806
+ "type": "object",
807
+ "properties": {
808
+ "type": {
809
+ "const": "resource"
810
+ },
811
+ "resource": {
812
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Artifact"
813
+ },
814
+ "uri": {
815
+ "type": "string",
816
+ "minLength": 1,
817
+ "maxLength": 4096,
818
+ "pattern": "^nexum://agents/[^/?#]+/(?:resources|mcp)/"
819
+ },
820
+ "encoding": {
821
+ "enum": ["text", "blob"]
822
+ },
823
+ "annotations": {
824
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Annotations"
825
+ },
826
+ "description": {
827
+ "type": "string",
828
+ "maxLength": 1048576
829
+ }
830
+ },
831
+ "required": ["type", "resource", "uri", "encoding"],
832
+ "additionalProperties": false
833
+ }
834
+ ]
835
+ },
836
+ "StreamRef": {
837
+ "type": "object",
838
+ "properties": {
839
+ "streamId": {
840
+ "type": "string",
841
+ "minLength": 1,
842
+ "maxLength": 256
843
+ },
844
+ "purpose": {
845
+ "enum": [
846
+ "resource",
847
+ "attachment",
848
+ "transfer",
849
+ "host-request",
850
+ "host-response",
851
+ "result-meta",
852
+ "maintenance"
853
+ ]
854
+ },
855
+ "direction": {
856
+ "enum": ["agent-to-cloud", "cloud-to-agent"]
857
+ },
858
+ "expiresAt": {
859
+ "type": "string",
860
+ "format": "date-time",
861
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
862
+ },
863
+ "maxBytes": {
864
+ "type": "integer",
865
+ "minimum": 1,
866
+ "maximum": 9007199254740991
867
+ },
868
+ "mimeType": {
869
+ "type": "string",
870
+ "minLength": 3,
871
+ "maxLength": 256,
872
+ "pattern": "^[^\\s/;]+/[^\\s;]+(?:;[^\\r\\n]+)?$"
873
+ },
874
+ "size": {
875
+ "type": "integer",
876
+ "minimum": 0,
877
+ "maximum": 9007199254740991
878
+ },
879
+ "sha256": {
880
+ "type": "string",
881
+ "pattern": "^[0-9a-f]{64}$"
882
+ }
883
+ },
884
+ "required": ["streamId", "purpose", "direction", "expiresAt", "maxBytes"],
885
+ "additionalProperties": false
886
+ },
887
+ "FixedStreamRef": {
888
+ "type": "object",
889
+ "properties": {
890
+ "streamId": {
891
+ "type": "string",
892
+ "minLength": 1,
893
+ "maxLength": 256
894
+ },
895
+ "purpose": {
896
+ "enum": [
897
+ "resource",
898
+ "attachment",
899
+ "transfer",
900
+ "host-request",
901
+ "host-response",
902
+ "result-meta",
903
+ "maintenance"
904
+ ]
905
+ },
906
+ "direction": {
907
+ "enum": ["agent-to-cloud", "cloud-to-agent"]
908
+ },
909
+ "expiresAt": {
910
+ "type": "string",
911
+ "format": "date-time",
912
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
913
+ },
914
+ "maxBytes": {
915
+ "type": "integer",
916
+ "minimum": 1,
917
+ "maximum": 9007199254740991
918
+ },
919
+ "mimeType": {
920
+ "type": "string",
921
+ "minLength": 3,
922
+ "maxLength": 256,
923
+ "pattern": "^[^\\s/;]+/[^\\s;]+(?:;[^\\r\\n]+)?$"
924
+ },
925
+ "size": {
926
+ "type": "integer",
927
+ "minimum": 0,
928
+ "maximum": 9007199254740991
929
+ },
930
+ "sha256": {
931
+ "type": "string",
932
+ "pattern": "^[0-9a-f]{64}$"
933
+ }
934
+ },
935
+ "required": [
936
+ "streamId",
937
+ "purpose",
938
+ "direction",
939
+ "expiresAt",
940
+ "maxBytes",
941
+ "mimeType",
942
+ "size",
943
+ "sha256"
944
+ ],
945
+ "additionalProperties": false
946
+ },
947
+ "ResultDelivery": {
948
+ "type": "object",
949
+ "properties": {
950
+ "complete": {
951
+ "const": false
952
+ },
953
+ "reason": {
954
+ "const": "context_budget"
955
+ },
956
+ "dataResource": {
957
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Artifact"
958
+ },
959
+ "textResource": {
960
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Artifact"
961
+ }
962
+ },
963
+ "required": ["complete", "reason"],
964
+ "additionalProperties": false
965
+ },
966
+ "ProtocolMeta": {
967
+ "oneOf": [
968
+ {
969
+ "type": "object",
970
+ "properties": {
971
+ "value": {
972
+ "type": "object"
973
+ }
974
+ },
975
+ "required": ["value"],
976
+ "additionalProperties": false
977
+ },
978
+ {
979
+ "type": "object",
980
+ "properties": {
981
+ "stream": {
982
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/FixedStreamRef"
983
+ }
984
+ },
985
+ "required": ["stream"],
986
+ "additionalProperties": false
987
+ }
988
+ ]
989
+ },
990
+ "Result": {
991
+ "type": "object",
992
+ "properties": {
993
+ "content": {
994
+ "type": "array",
995
+ "items": {
996
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Content"
997
+ },
998
+ "maxItems": 1000
999
+ },
1000
+ "data": {},
1001
+ "isError": {
1002
+ "type": "boolean"
1003
+ },
1004
+ "conversions": {
1005
+ "type": "array",
1006
+ "items": {
1007
+ "type": "object"
1008
+ },
1009
+ "maxItems": 1000
1010
+ },
1011
+ "delivery": {
1012
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/ResultDelivery"
1013
+ },
1014
+ "resultType": {
1015
+ "const": "complete"
1016
+ },
1017
+ "mcpResults": {
1018
+ "type": "array",
1019
+ "items": {
1020
+ "type": "object"
1021
+ },
1022
+ "maxItems": 1000
1023
+ },
1024
+ "protocolMeta": {
1025
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/ProtocolMeta"
1026
+ }
1027
+ },
1028
+ "required": ["content"],
1029
+ "additionalProperties": false
1030
+ },
1031
+ "TransferRequest": {
1032
+ "type": "object",
1033
+ "properties": {
1034
+ "method": {
1035
+ "enum": ["GET", "PUT"]
1036
+ },
1037
+ "url": {
1038
+ "type": "string",
1039
+ "format": "uri",
1040
+ "maxLength": 8192,
1041
+ "pattern": "^https?://"
1042
+ },
1043
+ "headers": {
1044
+ "type": "object",
1045
+ "maxProperties": 100,
1046
+ "additionalProperties": {
1047
+ "type": "string",
1048
+ "maxLength": 8192
1049
+ }
1050
+ },
1051
+ "expiresAt": {
1052
+ "type": "string",
1053
+ "format": "date-time",
1054
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
1055
+ }
1056
+ },
1057
+ "required": ["method", "url", "headers", "expiresAt"],
1058
+ "additionalProperties": false
1059
+ },
1060
+ "TransferDelivery": {
1061
+ "oneOf": [
1062
+ {
1063
+ "type": "object",
1064
+ "properties": {
1065
+ "transferId": {
1066
+ "type": "string",
1067
+ "minLength": 1,
1068
+ "maxLength": 256
1069
+ },
1070
+ "available": {
1071
+ "const": true
1072
+ },
1073
+ "request": {
1074
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/TransferRequest"
1075
+ }
1076
+ },
1077
+ "required": ["transferId", "available", "request"],
1078
+ "additionalProperties": false
1079
+ },
1080
+ {
1081
+ "type": "object",
1082
+ "properties": {
1083
+ "transferId": {
1084
+ "type": "string",
1085
+ "minLength": 1,
1086
+ "maxLength": 256
1087
+ },
1088
+ "available": {
1089
+ "const": false
1090
+ },
1091
+ "reason": {
1092
+ "type": "string",
1093
+ "minLength": 1,
1094
+ "maxLength": 256
1095
+ }
1096
+ },
1097
+ "required": ["transferId", "available", "reason"],
1098
+ "additionalProperties": false
1099
+ }
1100
+ ]
1101
+ },
1102
+ "TextPage": {
1103
+ "type": "object",
1104
+ "properties": {
1105
+ "text": {
1106
+ "type": "string",
1107
+ "maxLength": 1048576
1108
+ },
1109
+ "complete": {
1110
+ "type": "boolean"
1111
+ },
1112
+ "nextCursor": {
1113
+ "anyOf": [
1114
+ {
1115
+ "type": "string",
1116
+ "minLength": 1,
1117
+ "maxLength": 4096
1118
+ },
1119
+ {
1120
+ "type": "null"
1121
+ }
1122
+ ]
1123
+ }
1124
+ },
1125
+ "required": ["text", "complete", "nextCursor"],
1126
+ "additionalProperties": false
1127
+ },
1128
+ "Items": {
1129
+ "type": "object",
1130
+ "properties": {
1131
+ "items": {
1132
+ "type": "array",
1133
+ "items": {
1134
+ "type": "object"
1135
+ },
1136
+ "maxItems": 1000
1137
+ },
1138
+ "complete": {
1139
+ "type": "boolean"
1140
+ }
1141
+ },
1142
+ "required": ["items", "complete"],
1143
+ "additionalProperties": false
1144
+ },
1145
+ "RunView": {
1146
+ "type": "object",
1147
+ "properties": {
1148
+ "run": {
1149
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Run"
1150
+ },
1151
+ "wait": {
1152
+ "anyOf": [
1153
+ {
1154
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Wait"
1155
+ },
1156
+ {
1157
+ "type": "null"
1158
+ }
1159
+ ]
1160
+ },
1161
+ "result": {
1162
+ "anyOf": [
1163
+ {
1164
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/DeliveredResult"
1165
+ },
1166
+ {
1167
+ "type": "null"
1168
+ }
1169
+ ]
1170
+ },
1171
+ "observedAt": {
1172
+ "type": "string",
1173
+ "format": "date-time",
1174
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
1175
+ },
1176
+ "operations": {
1177
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Items"
1178
+ },
1179
+ "resources": {
1180
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Items"
1181
+ },
1182
+ "unavailable": {
1183
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Error"
1184
+ },
1185
+ "code": {
1186
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/TextPage"
1187
+ },
1188
+ "input": {},
1189
+ "logs": {
1190
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/TextPage"
1191
+ },
1192
+ "transient": {
1193
+ "type": "object",
1194
+ "properties": {
1195
+ "transfers": {
1196
+ "type": "array",
1197
+ "items": {
1198
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/TransferDelivery"
1199
+ },
1200
+ "maxItems": 100
1201
+ }
1202
+ },
1203
+ "required": ["transfers"],
1204
+ "additionalProperties": false
1205
+ }
1206
+ },
1207
+ "required": [
1208
+ "run",
1209
+ "wait",
1210
+ "result",
1211
+ "observedAt",
1212
+ "operations",
1213
+ "resources"
1214
+ ],
1215
+ "additionalProperties": false
1216
+ },
1217
+ "TransferTarget": {
1218
+ "type": "object",
1219
+ "properties": {
1220
+ "path": {
1221
+ "type": "string",
1222
+ "minLength": 1,
1223
+ "maxLength": 8192
1224
+ },
1225
+ "resourceUri": {
1226
+ "type": "string",
1227
+ "minLength": 1,
1228
+ "maxLength": 4096,
1229
+ "pattern": "^nexum://agents/[^/?#]+/resources/res_[0-9a-f]{32}$"
1230
+ },
1231
+ "name": {
1232
+ "type": "string",
1233
+ "minLength": 1,
1234
+ "maxLength": 256
1235
+ },
1236
+ "mimeType": {
1237
+ "type": "string",
1238
+ "minLength": 3,
1239
+ "maxLength": 256,
1240
+ "pattern": "^[^\\s/;]+/[^\\s;]+(?:;[^\\r\\n]+)?$"
1241
+ },
1242
+ "size": {
1243
+ "type": "integer",
1244
+ "minimum": 0,
1245
+ "maximum": 9007199254740991
1246
+ },
1247
+ "sha256": {
1248
+ "type": "string",
1249
+ "pattern": "^[0-9a-f]{64}$"
1250
+ },
1251
+ "expectedSize": {
1252
+ "type": "integer",
1253
+ "minimum": 0,
1254
+ "maximum": 9007199254740991
1255
+ },
1256
+ "expectedSha256": {
1257
+ "type": "string",
1258
+ "pattern": "^[0-9a-f]{64}$"
1259
+ }
1260
+ },
1261
+ "required": [],
1262
+ "additionalProperties": false
1263
+ },
1264
+ "TransferStop": {
1265
+ "type": "object",
1266
+ "properties": {
1267
+ "kind": {
1268
+ "enum": ["cancel", "expired", "timeout", "permission", "failure"]
1269
+ },
1270
+ "code": {
1271
+ "type": "string",
1272
+ "minLength": 1,
1273
+ "maxLength": 256
1274
+ }
1275
+ },
1276
+ "required": ["kind", "code"],
1277
+ "additionalProperties": false
1278
+ },
1279
+ "TransferFile": {
1280
+ "type": "object",
1281
+ "properties": {
1282
+ "path": {
1283
+ "type": "string",
1284
+ "minLength": 1,
1285
+ "maxLength": 8192
1286
+ },
1287
+ "name": {
1288
+ "type": "string",
1289
+ "minLength": 1,
1290
+ "maxLength": 256
1291
+ },
1292
+ "size": {
1293
+ "type": "integer",
1294
+ "minimum": 0,
1295
+ "maximum": 9007199254740991
1296
+ },
1297
+ "mimeType": {
1298
+ "type": "string",
1299
+ "minLength": 3,
1300
+ "maxLength": 256,
1301
+ "pattern": "^[^\\s/;]+/[^\\s;]+(?:;[^\\r\\n]+)?$"
1302
+ },
1303
+ "sha256": {
1304
+ "type": "string",
1305
+ "pattern": "^[0-9a-f]{64}$"
1306
+ },
1307
+ "revision": {
1308
+ "type": "string",
1309
+ "minLength": 1,
1310
+ "maxLength": 256
1311
+ }
1312
+ },
1313
+ "required": ["path", "name", "size", "mimeType", "sha256", "revision"],
1314
+ "additionalProperties": false
1315
+ },
1316
+ "TransferSnapshot": {
1317
+ "type": "object",
1318
+ "properties": {
1319
+ "transferId": {
1320
+ "type": "string",
1321
+ "minLength": 1,
1322
+ "maxLength": 256
1323
+ },
1324
+ "direction": {
1325
+ "enum": ["upload", "download"]
1326
+ },
1327
+ "status": {
1328
+ "enum": [
1329
+ "preparing",
1330
+ "pending",
1331
+ "transferring",
1332
+ "cancelling",
1333
+ "succeeded",
1334
+ "failed",
1335
+ "cancelled",
1336
+ "expired",
1337
+ "interrupted"
1338
+ ]
1339
+ },
1340
+ "runId": {
1341
+ "anyOf": [
1342
+ {
1343
+ "type": "string",
1344
+ "minLength": 1,
1345
+ "maxLength": 256
1346
+ },
1347
+ {
1348
+ "type": "null"
1349
+ }
1350
+ ]
1351
+ },
1352
+ "contextId": {
1353
+ "anyOf": [
1354
+ {
1355
+ "type": "string",
1356
+ "minLength": 1,
1357
+ "maxLength": 256
1358
+ },
1359
+ {
1360
+ "type": "null"
1361
+ }
1362
+ ]
1363
+ },
1364
+ "projectId": {
1365
+ "anyOf": [
1366
+ {
1367
+ "type": "string",
1368
+ "minLength": 1,
1369
+ "maxLength": 256
1370
+ },
1371
+ {
1372
+ "type": "null"
1373
+ }
1374
+ ]
1375
+ },
1376
+ "path": {
1377
+ "type": "string",
1378
+ "minLength": 1,
1379
+ "maxLength": 8192
1380
+ },
1381
+ "resource": {
1382
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/ResourceEntry"
1383
+ },
1384
+ "maxBytes": {
1385
+ "anyOf": [
1386
+ {
1387
+ "type": "integer",
1388
+ "minimum": 1,
1389
+ "maximum": 9007199254740991
1390
+ },
1391
+ {
1392
+ "type": "null"
1393
+ }
1394
+ ]
1395
+ },
1396
+ "progress": {
1397
+ "type": "object",
1398
+ "properties": {
1399
+ "bytesTransferred": {
1400
+ "type": "integer",
1401
+ "minimum": 0,
1402
+ "maximum": 9007199254740991
1403
+ },
1404
+ "totalBytes": {
1405
+ "anyOf": [
1406
+ {
1407
+ "type": "integer",
1408
+ "minimum": 0,
1409
+ "maximum": 9007199254740991
1410
+ },
1411
+ {
1412
+ "type": "null"
1413
+ }
1414
+ ]
1415
+ }
1416
+ },
1417
+ "required": ["bytesTransferred", "totalBytes"],
1418
+ "additionalProperties": false
1419
+ },
1420
+ "createdAt": {
1421
+ "type": "string",
1422
+ "format": "date-time",
1423
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
1424
+ },
1425
+ "expiresAt": {
1426
+ "anyOf": [
1427
+ {
1428
+ "type": "string",
1429
+ "format": "date-time",
1430
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
1431
+ },
1432
+ {
1433
+ "type": "null"
1434
+ }
1435
+ ]
1436
+ },
1437
+ "startedAt": {
1438
+ "anyOf": [
1439
+ {
1440
+ "type": "string",
1441
+ "format": "date-time",
1442
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
1443
+ },
1444
+ {
1445
+ "type": "null"
1446
+ }
1447
+ ]
1448
+ },
1449
+ "deadlineAt": {
1450
+ "anyOf": [
1451
+ {
1452
+ "type": "string",
1453
+ "format": "date-time",
1454
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
1455
+ },
1456
+ {
1457
+ "type": "null"
1458
+ }
1459
+ ]
1460
+ },
1461
+ "finishedAt": {
1462
+ "anyOf": [
1463
+ {
1464
+ "type": "string",
1465
+ "format": "date-time",
1466
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
1467
+ },
1468
+ {
1469
+ "type": "null"
1470
+ }
1471
+ ]
1472
+ },
1473
+ "file": {
1474
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/TransferFile"
1475
+ },
1476
+ "error": {
1477
+ "anyOf": [
1478
+ {
1479
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Error"
1480
+ },
1481
+ {
1482
+ "type": "null"
1483
+ }
1484
+ ]
1485
+ }
1486
+ },
1487
+ "required": [
1488
+ "transferId",
1489
+ "direction",
1490
+ "status",
1491
+ "runId",
1492
+ "contextId",
1493
+ "projectId",
1494
+ "progress",
1495
+ "createdAt",
1496
+ "expiresAt",
1497
+ "startedAt",
1498
+ "deadlineAt",
1499
+ "finishedAt",
1500
+ "error"
1501
+ ],
1502
+ "additionalProperties": false
1503
+ },
1504
+ "MaintenanceSummary": {
1505
+ "type": "object",
1506
+ "properties": {
1507
+ "title": {
1508
+ "type": "string",
1509
+ "minLength": 1,
1510
+ "maxLength": 256
1511
+ },
1512
+ "changeKinds": {
1513
+ "type": "array",
1514
+ "items": {
1515
+ "enum": [
1516
+ "package",
1517
+ "dependency",
1518
+ "lockfile",
1519
+ "extension",
1520
+ "capability",
1521
+ "script",
1522
+ "instruction",
1523
+ "docs",
1524
+ "skill",
1525
+ "connection",
1526
+ "authentication",
1527
+ "api",
1528
+ "permissions",
1529
+ "configuration",
1530
+ "remove"
1531
+ ]
1532
+ },
1533
+ "maxItems": 32
1534
+ },
1535
+ "permissions": {
1536
+ "type": "array",
1537
+ "items": {
1538
+ "type": "string",
1539
+ "minLength": 1,
1540
+ "maxLength": 256,
1541
+ "pattern": "^[^\\x00\\r\\n]+$"
1542
+ },
1543
+ "maxItems": 256
1544
+ },
1545
+ "version": {
1546
+ "anyOf": [
1547
+ {
1548
+ "type": "string",
1549
+ "minLength": 1,
1550
+ "maxLength": 256
1551
+ },
1552
+ {
1553
+ "type": "null"
1554
+ }
1555
+ ]
1556
+ },
1557
+ "namespace": {
1558
+ "anyOf": [
1559
+ {
1560
+ "type": "string",
1561
+ "pattern": "^[A-Za-z_$][A-Za-z0-9_$]{0,63}$"
1562
+ },
1563
+ {
1564
+ "type": "null"
1565
+ }
1566
+ ]
1567
+ },
1568
+ "restartMayBeRequired": {
1569
+ "type": "boolean"
1570
+ }
1571
+ },
1572
+ "required": [
1573
+ "title",
1574
+ "changeKinds",
1575
+ "permissions",
1576
+ "version",
1577
+ "namespace",
1578
+ "restartMayBeRequired"
1579
+ ],
1580
+ "additionalProperties": false
1581
+ },
1582
+ "MaintenanceCandidate": {
1583
+ "type": "object",
1584
+ "properties": {
1585
+ "target": {
1586
+ "enum": ["package", "extension", "mcp", "api"]
1587
+ },
1588
+ "action": {
1589
+ "type": "string",
1590
+ "minLength": 1,
1591
+ "maxLength": 256
1592
+ },
1593
+ "name": {
1594
+ "type": "string",
1595
+ "minLength": 1,
1596
+ "maxLength": 256
1597
+ },
1598
+ "objectId": {
1599
+ "anyOf": [
1600
+ {
1601
+ "type": "string",
1602
+ "minLength": 1,
1603
+ "maxLength": 256
1604
+ },
1605
+ {
1606
+ "type": "null"
1607
+ }
1608
+ ]
1609
+ },
1610
+ "baseRevision": {
1611
+ "anyOf": [
1612
+ {
1613
+ "type": "string",
1614
+ "minLength": 1,
1615
+ "maxLength": 256
1616
+ },
1617
+ {
1618
+ "type": "null"
1619
+ }
1620
+ ]
1621
+ },
1622
+ "candidateRevision": {
1623
+ "type": "string",
1624
+ "pattern": "^[0-9a-f]{64}$"
1625
+ },
1626
+ "summary": {
1627
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/MaintenanceSummary"
1628
+ },
1629
+ "authStatus": {
1630
+ "enum": ["not_required", "required", "ready", "failed"]
1631
+ }
1632
+ },
1633
+ "required": [
1634
+ "target",
1635
+ "action",
1636
+ "name",
1637
+ "objectId",
1638
+ "baseRevision",
1639
+ "candidateRevision",
1640
+ "summary",
1641
+ "authStatus"
1642
+ ],
1643
+ "additionalProperties": false
1644
+ },
1645
+ "MaintenanceCreate": {
1646
+ "type": "object",
1647
+ "properties": {
1648
+ "requestKey": {
1649
+ "type": "string",
1650
+ "minLength": 1,
1651
+ "maxLength": 256
1652
+ },
1653
+ "originRunId": {
1654
+ "type": "string",
1655
+ "minLength": 1,
1656
+ "maxLength": 256
1657
+ },
1658
+ "target": {
1659
+ "enum": ["package", "extension", "mcp", "api"]
1660
+ },
1661
+ "action": {
1662
+ "type": "string",
1663
+ "minLength": 1,
1664
+ "maxLength": 256
1665
+ },
1666
+ "name": {
1667
+ "type": "string",
1668
+ "minLength": 1,
1669
+ "maxLength": 256
1670
+ },
1671
+ "objectId": {
1672
+ "anyOf": [
1673
+ {
1674
+ "type": "string",
1675
+ "minLength": 1,
1676
+ "maxLength": 256
1677
+ },
1678
+ {
1679
+ "type": "null"
1680
+ }
1681
+ ]
1682
+ },
1683
+ "baseRevision": {
1684
+ "anyOf": [
1685
+ {
1686
+ "type": "string",
1687
+ "minLength": 1,
1688
+ "maxLength": 256
1689
+ },
1690
+ {
1691
+ "type": "null"
1692
+ }
1693
+ ]
1694
+ },
1695
+ "candidateRevision": {
1696
+ "type": "string",
1697
+ "pattern": "^[0-9a-f]{64}$"
1698
+ },
1699
+ "summary": {
1700
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/MaintenanceSummary"
1701
+ },
1702
+ "authStatus": {
1703
+ "enum": ["not_required", "required", "ready", "failed"]
1704
+ }
1705
+ },
1706
+ "required": [
1707
+ "requestKey",
1708
+ "originRunId",
1709
+ "target",
1710
+ "action",
1711
+ "name",
1712
+ "objectId",
1713
+ "baseRevision",
1714
+ "candidateRevision",
1715
+ "summary",
1716
+ "authStatus"
1717
+ ],
1718
+ "additionalProperties": false
1719
+ },
1720
+ "MaintenanceDecision": {
1721
+ "type": "object",
1722
+ "properties": {
1723
+ "status": {
1724
+ "enum": ["approved", "denied"]
1725
+ },
1726
+ "revision": {
1727
+ "type": "integer",
1728
+ "minimum": 1,
1729
+ "maximum": 9007199254740991
1730
+ },
1731
+ "candidateRevision": {
1732
+ "type": "string",
1733
+ "pattern": "^[0-9a-f]{64}$"
1734
+ },
1735
+ "decidedAt": {
1736
+ "type": "string",
1737
+ "format": "date-time",
1738
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
1739
+ },
1740
+ "decisionId": {
1741
+ "type": "string",
1742
+ "minLength": 1,
1743
+ "maxLength": 256
1744
+ }
1745
+ },
1746
+ "required": [
1747
+ "status",
1748
+ "revision",
1749
+ "candidateRevision",
1750
+ "decidedAt",
1751
+ "decisionId"
1752
+ ],
1753
+ "additionalProperties": false
1754
+ },
1755
+ "MaintenanceResult": {
1756
+ "type": "object",
1757
+ "properties": {
1758
+ "changed": {
1759
+ "type": "boolean"
1760
+ },
1761
+ "restartRequired": {
1762
+ "type": "boolean"
1763
+ },
1764
+ "package": {
1765
+ "type": "object",
1766
+ "properties": {
1767
+ "name": {
1768
+ "type": "string",
1769
+ "minLength": 1,
1770
+ "maxLength": 256
1771
+ },
1772
+ "declared": {
1773
+ "type": "boolean"
1774
+ },
1775
+ "installedVersion": {
1776
+ "anyOf": [
1777
+ {
1778
+ "type": "string",
1779
+ "minLength": 1,
1780
+ "maxLength": 256
1781
+ },
1782
+ {
1783
+ "type": "null"
1784
+ }
1785
+ ]
1786
+ }
1787
+ },
1788
+ "required": ["name", "declared", "installedVersion"],
1789
+ "additionalProperties": false
1790
+ },
1791
+ "extension": {
1792
+ "anyOf": [
1793
+ {
1794
+ "type": "object",
1795
+ "properties": {
1796
+ "namespace": {
1797
+ "type": "string",
1798
+ "minLength": 1,
1799
+ "maxLength": 256
1800
+ },
1801
+ "desiredEnabled": {
1802
+ "type": "boolean"
1803
+ },
1804
+ "state": {
1805
+ "type": "string",
1806
+ "minLength": 1,
1807
+ "maxLength": 256
1808
+ },
1809
+ "activeVersion": {
1810
+ "anyOf": [
1811
+ {
1812
+ "type": "string",
1813
+ "minLength": 1,
1814
+ "maxLength": 256
1815
+ },
1816
+ {
1817
+ "type": "null"
1818
+ }
1819
+ ]
1820
+ }
1821
+ },
1822
+ "required": [
1823
+ "namespace",
1824
+ "desiredEnabled",
1825
+ "state",
1826
+ "activeVersion"
1827
+ ],
1828
+ "additionalProperties": false
1829
+ },
1830
+ {
1831
+ "type": "null"
1832
+ }
1833
+ ]
1834
+ },
1835
+ "connection": {
1836
+ "anyOf": [
1837
+ {
1838
+ "type": "object",
1839
+ "properties": {
1840
+ "name": {
1841
+ "type": "string",
1842
+ "minLength": 1,
1843
+ "maxLength": 256
1844
+ },
1845
+ "state": {
1846
+ "type": "string",
1847
+ "minLength": 1,
1848
+ "maxLength": 256
1849
+ },
1850
+ "revision": {
1851
+ "anyOf": [
1852
+ {
1853
+ "type": "string",
1854
+ "minLength": 1,
1855
+ "maxLength": 256
1856
+ },
1857
+ {
1858
+ "type": "null"
1859
+ }
1860
+ ]
1861
+ }
1862
+ },
1863
+ "required": ["name", "state", "revision"],
1864
+ "additionalProperties": false
1865
+ },
1866
+ {
1867
+ "type": "null"
1868
+ }
1869
+ ]
1870
+ },
1871
+ "api": {
1872
+ "anyOf": [
1873
+ {
1874
+ "type": "object",
1875
+ "properties": {
1876
+ "name": {
1877
+ "type": "string",
1878
+ "minLength": 1,
1879
+ "maxLength": 256
1880
+ },
1881
+ "state": {
1882
+ "type": "string",
1883
+ "minLength": 1,
1884
+ "maxLength": 256
1885
+ },
1886
+ "revision": {
1887
+ "anyOf": [
1888
+ {
1889
+ "type": "string",
1890
+ "minLength": 1,
1891
+ "maxLength": 256
1892
+ },
1893
+ {
1894
+ "type": "null"
1895
+ }
1896
+ ]
1897
+ }
1898
+ },
1899
+ "required": ["name", "state", "revision"],
1900
+ "additionalProperties": false
1901
+ },
1902
+ {
1903
+ "type": "null"
1904
+ }
1905
+ ]
1906
+ }
1907
+ },
1908
+ "required": ["changed", "restartRequired"],
1909
+ "additionalProperties": false
1910
+ },
1911
+ "MaintenanceExecution": {
1912
+ "type": "object",
1913
+ "properties": {
1914
+ "operationId": {
1915
+ "type": "string",
1916
+ "minLength": 1,
1917
+ "maxLength": 256
1918
+ },
1919
+ "startedAt": {
1920
+ "type": "string",
1921
+ "format": "date-time",
1922
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
1923
+ },
1924
+ "status": {
1925
+ "type": "string",
1926
+ "minLength": 1,
1927
+ "maxLength": 256
1928
+ },
1929
+ "result": {
1930
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/MaintenanceResult"
1931
+ },
1932
+ "error": {
1933
+ "type": "object",
1934
+ "properties": {
1935
+ "code": {
1936
+ "type": "string",
1937
+ "minLength": 1,
1938
+ "maxLength": 256,
1939
+ "pattern": "^[^\\x00\\r\\n]+$"
1940
+ },
1941
+ "message": {
1942
+ "type": "string",
1943
+ "maxLength": 4096,
1944
+ "pattern": "^[^\\x00]*$"
1945
+ }
1946
+ },
1947
+ "required": ["code", "message"],
1948
+ "additionalProperties": false
1949
+ }
1950
+ },
1951
+ "required": ["operationId", "startedAt"],
1952
+ "additionalProperties": false
1953
+ },
1954
+ "MaintenanceView": {
1955
+ "type": "object",
1956
+ "properties": {
1957
+ "requestId": {
1958
+ "type": "string",
1959
+ "pattern": "^maint_req_[A-Za-z0-9_-]{1,128}$"
1960
+ },
1961
+ "agentId": {
1962
+ "type": "string",
1963
+ "minLength": 1,
1964
+ "maxLength": 256
1965
+ },
1966
+ "profile": {
1967
+ "enum": ["development", "production"]
1968
+ },
1969
+ "target": {
1970
+ "enum": ["package", "extension", "mcp", "api"]
1971
+ },
1972
+ "action": {
1973
+ "type": "string",
1974
+ "minLength": 1,
1975
+ "maxLength": 256
1976
+ },
1977
+ "name": {
1978
+ "type": "string",
1979
+ "minLength": 1,
1980
+ "maxLength": 256
1981
+ },
1982
+ "objectId": {
1983
+ "anyOf": [
1984
+ {
1985
+ "type": "string",
1986
+ "minLength": 1,
1987
+ "maxLength": 256
1988
+ },
1989
+ {
1990
+ "type": "null"
1991
+ }
1992
+ ]
1993
+ },
1994
+ "baseRevision": {
1995
+ "anyOf": [
1996
+ {
1997
+ "type": "string",
1998
+ "minLength": 1,
1999
+ "maxLength": 256
2000
+ },
2001
+ {
2002
+ "type": "null"
2003
+ }
2004
+ ]
2005
+ },
2006
+ "candidateRevision": {
2007
+ "type": "string",
2008
+ "pattern": "^[0-9a-f]{64}$"
2009
+ },
2010
+ "summary": {
2011
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/MaintenanceSummary"
2012
+ },
2013
+ "authStatus": {
2014
+ "enum": ["not_required", "required", "ready", "failed"]
2015
+ },
2016
+ "status": {
2017
+ "enum": ["pending", "approved", "denied", "cancelled", "expired"]
2018
+ },
2019
+ "revision": {
2020
+ "type": "integer",
2021
+ "minimum": 1,
2022
+ "maximum": 9007199254740991
2023
+ },
2024
+ "createdAt": {
2025
+ "type": "string",
2026
+ "format": "date-time",
2027
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
2028
+ },
2029
+ "expiresAt": {
2030
+ "type": "string",
2031
+ "format": "date-time",
2032
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
2033
+ },
2034
+ "approvalUrl": {
2035
+ "type": "string",
2036
+ "format": "uri",
2037
+ "maxLength": 8192,
2038
+ "pattern": "^https?://"
2039
+ },
2040
+ "decidedAt": {
2041
+ "type": "string",
2042
+ "format": "date-time",
2043
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
2044
+ },
2045
+ "decision": {
2046
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/MaintenanceDecision"
2047
+ },
2048
+ "execution": {
2049
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/MaintenanceExecution"
2050
+ },
2051
+ "agentName": {
2052
+ "type": "string",
2053
+ "minLength": 1,
2054
+ "maxLength": 255
2055
+ },
2056
+ "source": {
2057
+ "type": "object",
2058
+ "properties": {
2059
+ "name": {
2060
+ "type": "string",
2061
+ "minLength": 1,
2062
+ "maxLength": 255
2063
+ }
2064
+ },
2065
+ "additionalProperties": false
2066
+ }
2067
+ },
2068
+ "required": [
2069
+ "requestId",
2070
+ "agentId",
2071
+ "profile",
2072
+ "target",
2073
+ "action",
2074
+ "name",
2075
+ "objectId",
2076
+ "baseRevision",
2077
+ "candidateRevision",
2078
+ "summary",
2079
+ "authStatus",
2080
+ "status",
2081
+ "revision",
2082
+ "createdAt",
2083
+ "expiresAt"
2084
+ ],
2085
+ "additionalProperties": false
2086
+ },
2087
+ "MaintenanceListOptions": {
2088
+ "type": "object",
2089
+ "properties": {
2090
+ "target": {
2091
+ "enum": ["package", "extension", "mcp", "api"]
2092
+ },
2093
+ "name": {
2094
+ "type": "string",
2095
+ "minLength": 1,
2096
+ "maxLength": 256
2097
+ },
2098
+ "status": {
2099
+ "enum": ["pending", "approved", "denied", "cancelled", "expired"]
2100
+ },
2101
+ "limit": {
2102
+ "type": "integer",
2103
+ "minimum": 1,
2104
+ "maximum": 100
2105
+ },
2106
+ "cursor": {
2107
+ "type": "string",
2108
+ "minLength": 1,
2109
+ "maxLength": 4096
2110
+ }
2111
+ },
2112
+ "required": [],
2113
+ "additionalProperties": false
2114
+ },
2115
+ "MaintenancePage": {
2116
+ "type": "object",
2117
+ "properties": {
2118
+ "requests": {
2119
+ "type": "array",
2120
+ "items": {
2121
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/MaintenanceView"
2122
+ },
2123
+ "maxItems": 100
2124
+ },
2125
+ "nextCursor": {
2126
+ "anyOf": [
2127
+ {
2128
+ "type": "string",
2129
+ "minLength": 1,
2130
+ "maxLength": 4096
2131
+ },
2132
+ {
2133
+ "type": "null"
2134
+ }
2135
+ ]
2136
+ }
2137
+ },
2138
+ "required": ["requests"],
2139
+ "additionalProperties": false
2140
+ },
2141
+ "MaintenanceBeginExecution": {
2142
+ "type": "object",
2143
+ "properties": {
2144
+ "requestId": {
2145
+ "type": "string",
2146
+ "pattern": "^maint_req_[A-Za-z0-9_-]{1,128}$"
2147
+ },
2148
+ "approvedRevision": {
2149
+ "type": "string",
2150
+ "pattern": "^[0-9a-f]{64}$"
2151
+ },
2152
+ "decisionRevision": {
2153
+ "type": "integer",
2154
+ "minimum": 1,
2155
+ "maximum": 9007199254740991
2156
+ },
2157
+ "operationId": {
2158
+ "type": "string",
2159
+ "minLength": 1,
2160
+ "maxLength": 256
2161
+ }
2162
+ },
2163
+ "required": [
2164
+ "requestId",
2165
+ "approvedRevision",
2166
+ "decisionRevision",
2167
+ "operationId"
2168
+ ],
2169
+ "additionalProperties": false
2170
+ },
2171
+ "MCPDelivery": {
2172
+ "type": "object",
2173
+ "properties": {
2174
+ "complete": {
2175
+ "const": false
2176
+ },
2177
+ "reason": {
2178
+ "const": "context_budget"
2179
+ },
2180
+ "dataResource": {
2181
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Artifact"
2182
+ },
2183
+ "textResource": {
2184
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Artifact"
2185
+ },
2186
+ "transfers": {
2187
+ "type": "array",
2188
+ "maxItems": 100,
2189
+ "items": {
2190
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/TransferDelivery"
2191
+ }
2192
+ }
2193
+ },
2194
+ "minProperties": 1,
2195
+ "additionalProperties": false,
2196
+ "dependentRequired": {
2197
+ "complete": ["reason"],
2198
+ "reason": ["complete"],
2199
+ "dataResource": ["complete"],
2200
+ "textResource": ["complete"]
2201
+ }
2202
+ },
2203
+ "Icon": {
2204
+ "type": "object",
2205
+ "properties": {
2206
+ "src": {
2207
+ "type": "string",
2208
+ "maxLength": 1048576,
2209
+ "not": {
2210
+ "pattern": "^[\\x00-\\x20]*[Dd][\\t\\n\\r]*[Aa][\\t\\n\\r]*[Tt][\\t\\n\\r]*[Aa][\\t\\n\\r]*:"
2211
+ }
2212
+ },
2213
+ "mimeType": {
2214
+ "type": "string",
2215
+ "minLength": 3,
2216
+ "maxLength": 256,
2217
+ "pattern": "^[^\\s/;]+/[^\\s;]+(?:;[^\\r\\n]+)?$"
2218
+ },
2219
+ "sizes": {
2220
+ "type": "array",
2221
+ "maxItems": 1000,
2222
+ "items": {
2223
+ "type": "string",
2224
+ "maxLength": 256
2225
+ }
2226
+ },
2227
+ "theme": {
2228
+ "enum": ["light", "dark"]
2229
+ }
2230
+ },
2231
+ "required": ["src"],
2232
+ "additionalProperties": false
2233
+ },
2234
+ "Annotations": {
2235
+ "type": "object",
2236
+ "properties": {
2237
+ "audience": {
2238
+ "type": "array",
2239
+ "maxItems": 1000,
2240
+ "items": {
2241
+ "enum": ["user", "assistant"]
2242
+ }
2243
+ },
2244
+ "priority": {
2245
+ "type": "number",
2246
+ "minimum": 0,
2247
+ "maximum": 1
2248
+ },
2249
+ "lastModified": {
2250
+ "type": "string",
2251
+ "format": "date-time"
2252
+ }
2253
+ },
2254
+ "additionalProperties": true
2255
+ },
2256
+ "ResultBody": {
2257
+ "type": "object",
2258
+ "properties": {
2259
+ "body": {
2260
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/FixedStreamRef"
2261
+ },
2262
+ "protocolMeta": {
2263
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/ProtocolMeta"
2264
+ }
2265
+ },
2266
+ "required": ["body"],
2267
+ "additionalProperties": false
2268
+ },
2269
+ "DeliveredResult": {
2270
+ "oneOf": [
2271
+ {
2272
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Result"
2273
+ },
2274
+ {
2275
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/ResultBody"
2276
+ }
2277
+ ]
2278
+ },
2279
+ "StateValue": {
2280
+ "type": "object",
2281
+ "properties": {
2282
+ "value": {},
2283
+ "version": {
2284
+ "type": "integer",
2285
+ "minimum": 1,
2286
+ "maximum": 9007199254740991
2287
+ },
2288
+ "updatedAt": {
2289
+ "type": "integer",
2290
+ "minimum": 0,
2291
+ "maximum": 9007199254740991
2292
+ }
2293
+ },
2294
+ "required": ["value", "version", "updatedAt"],
2295
+ "additionalProperties": false
2296
+ },
2297
+ "HostFeatures": {
2298
+ "$ref": "https://schemas.nexum.local/agent/v2/common.schema.json#/$defs/hostFeatures"
2299
+ },
2300
+ "TaskId": {
2301
+ "type": "string",
2302
+ "minLength": 9,
2303
+ "maxLength": 1024,
2304
+ "pattern": "^nx_task_[A-Za-z0-9_-]+$"
2305
+ },
2306
+ "TaskError": {
2307
+ "type": "object",
2308
+ "properties": {
2309
+ "code": {
2310
+ "type": "integer",
2311
+ "minimum": -9007199254740991,
2312
+ "maximum": 9007199254740991
2313
+ },
2314
+ "message": {
2315
+ "type": "string",
2316
+ "maxLength": 4096
2317
+ },
2318
+ "data": {}
2319
+ },
2320
+ "required": ["code", "message"],
2321
+ "additionalProperties": false
2322
+ },
2323
+ "TaskBinding": {
2324
+ "type": "object",
2325
+ "properties": {
2326
+ "taskId": {
2327
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/TaskId"
2328
+ },
2329
+ "agentId": {
2330
+ "$ref": "https://schemas.nexum.local/agent/v2/common.schema.json#/$defs/id"
2331
+ },
2332
+ "runId": {
2333
+ "$ref": "https://schemas.nexum.local/agent/v2/common.schema.json#/$defs/id"
2334
+ },
2335
+ "status": {
2336
+ "enum": [
2337
+ "working",
2338
+ "input_required",
2339
+ "completed",
2340
+ "cancelled",
2341
+ "failed"
2342
+ ]
2343
+ },
2344
+ "createdAt": {
2345
+ "type": "string",
2346
+ "format": "date-time",
2347
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
2348
+ },
2349
+ "lastUpdatedAt": {
2350
+ "type": "string",
2351
+ "format": "date-time",
2352
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
2353
+ },
2354
+ "expiresAt": {
2355
+ "type": "string",
2356
+ "format": "date-time",
2357
+ "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-5][0-9](?:\\.[0-9]+)?Z$"
2358
+ },
2359
+ "ttlMs": {
2360
+ "type": "integer",
2361
+ "minimum": 1,
2362
+ "maximum": 9007199254740991
2363
+ },
2364
+ "error": {
2365
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/TaskError"
2366
+ }
2367
+ },
2368
+ "required": [
2369
+ "taskId",
2370
+ "agentId",
2371
+ "runId",
2372
+ "status",
2373
+ "createdAt",
2374
+ "lastUpdatedAt",
2375
+ "expiresAt",
2376
+ "ttlMs"
2377
+ ],
2378
+ "additionalProperties": false,
2379
+ "allOf": [
2380
+ {
2381
+ "if": {
2382
+ "properties": {
2383
+ "status": {
2384
+ "const": "failed"
2385
+ }
2386
+ },
2387
+ "required": ["status"]
2388
+ },
2389
+ "then": {
2390
+ "properties": { "error": {} },
2391
+ "required": ["error"]
2392
+ },
2393
+ "else": {
2394
+ "not": {
2395
+ "properties": { "error": {} },
2396
+ "required": ["error"]
2397
+ }
2398
+ }
2399
+ }
2400
+ ]
2401
+ },
2402
+ "TaskView": {
2403
+ "type": "object",
2404
+ "properties": {
2405
+ "task": {
2406
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/TaskBinding"
2407
+ },
2408
+ "view": {
2409
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/RunView"
2410
+ }
2411
+ },
2412
+ "required": ["task", "view"],
2413
+ "additionalProperties": false
2414
+ },
2415
+ "TaskCancelOutput": {
2416
+ "type": "object",
2417
+ "properties": {
2418
+ "task": {
2419
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/TaskBinding"
2420
+ },
2421
+ "view": {
2422
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/RunView"
2423
+ },
2424
+ "accepted": {
2425
+ "type": "boolean"
2426
+ }
2427
+ },
2428
+ "required": ["task", "view", "accepted"],
2429
+ "additionalProperties": false
2430
+ },
2431
+ "McpCaller": {
2432
+ "type": "object",
2433
+ "properties": {
2434
+ "principalId": {
2435
+ "type": "string",
2436
+ "minLength": 1,
2437
+ "maxLength": 256
2438
+ },
2439
+ "clientId": {
2440
+ "type": "string",
2441
+ "minLength": 1,
2442
+ "maxLength": 256
2443
+ },
2444
+ "grantId": {
2445
+ "type": "string",
2446
+ "minLength": 1,
2447
+ "maxLength": 256
2448
+ },
2449
+ "host": {
2450
+ "type": "string",
2451
+ "maxLength": 256
2452
+ },
2453
+ "model": {
2454
+ "type": "string",
2455
+ "maxLength": 256
2456
+ },
2457
+ "hostRef": {
2458
+ "type": "string",
2459
+ "minLength": 1,
2460
+ "maxLength": 256
2461
+ },
2462
+ "hostCapabilities": {
2463
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/HostCapabilities"
2464
+ },
2465
+ "hostFeatures": {
2466
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/HostFeatures"
2467
+ },
2468
+ "source": {
2469
+ "const": "mcp"
2470
+ }
2471
+ },
2472
+ "required": ["principalId", "clientId", "grantId"],
2473
+ "additionalProperties": false,
2474
+ "dependentRequired": {
2475
+ "hostRef": ["hostCapabilities"],
2476
+ "hostCapabilities": ["hostRef"],
2477
+ "hostFeatures": ["hostRef", "hostCapabilities"]
2478
+ }
2479
+ },
2480
+ "McpInvocationContext": {
2481
+ "type": "object",
2482
+ "properties": {
2483
+ "caller": {
2484
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/McpCaller"
2485
+ },
2486
+ "authorization": {
2487
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Authorization"
2488
+ },
2489
+ "connection": {
2490
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Connection"
2491
+ }
2492
+ },
2493
+ "required": ["caller", "authorization", "connection"],
2494
+ "additionalProperties": false
2495
+ },
2496
+ "OwnerSessionInvocationContext": {
2497
+ "type": "object",
2498
+ "properties": {
2499
+ "caller": {
2500
+ "$ref": "https://schemas.nexum.local/agent/v2/common.schema.json#/$defs/ownerSessionCaller"
2501
+ },
2502
+ "authorization": {
2503
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Authorization"
2504
+ },
2505
+ "connection": {
2506
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/Connection"
2507
+ }
2508
+ },
2509
+ "required": ["caller", "authorization", "connection"],
2510
+ "additionalProperties": false
2511
+ },
2512
+ "ProcessId": {
2513
+ "type": "string",
2514
+ "pattern": "^res_[0-9a-f]{32}$"
2515
+ },
2516
+ "ProcessSnapshot": {
2517
+ "type": "object",
2518
+ "properties": {
2519
+ "processId": {
2520
+ "$ref": "https://schemas.nexum.local/agent/v2/wire/types.schema.json#/$defs/ProcessId"
2521
+ },
2522
+ "originRunId": {
2523
+ "anyOf": [
2524
+ {
2525
+ "$ref": "https://schemas.nexum.local/agent/v2/common.schema.json#/$defs/id"
2526
+ },
2527
+ {
2528
+ "type": "null"
2529
+ }
2530
+ ]
2531
+ },
2532
+ "contextId": {
2533
+ "anyOf": [
2534
+ {
2535
+ "$ref": "https://schemas.nexum.local/agent/v2/common.schema.json#/$defs/id"
2536
+ },
2537
+ {
2538
+ "type": "null"
2539
+ }
2540
+ ]
2541
+ },
2542
+ "projectId": {
2543
+ "anyOf": [
2544
+ {
2545
+ "$ref": "https://schemas.nexum.local/agent/v2/common.schema.json#/$defs/id"
2546
+ },
2547
+ {
2548
+ "type": "null"
2549
+ }
2550
+ ]
2551
+ },
2552
+ "status": {
2553
+ "type": "string",
2554
+ "minLength": 1,
2555
+ "maxLength": 256
2556
+ },
2557
+ "lifetime": {
2558
+ "enum": [
2559
+ "run",
2560
+ "background",
2561
+ "instance"
2562
+ ]
2563
+ },
2564
+ "createdAt": {
2565
+ "type": "integer",
2566
+ "minimum": 0,
2567
+ "maximum": 9007199254740991
2568
+ },
2569
+ "closedAt": {
2570
+ "anyOf": [
2571
+ {
2572
+ "type": "integer",
2573
+ "minimum": 0,
2574
+ "maximum": 9007199254740991
2575
+ },
2576
+ {
2577
+ "type": "null"
2578
+ }
2579
+ ]
2580
+ },
2581
+ "handedOffAt": {
2582
+ "anyOf": [
2583
+ {
2584
+ "type": "integer",
2585
+ "minimum": 0,
2586
+ "maximum": 9007199254740991
2587
+ },
2588
+ {
2589
+ "type": "null"
2590
+ }
2591
+ ]
2592
+ },
2593
+ "controlAvailable": {
2594
+ "type": "boolean"
2595
+ },
2596
+ "details": {
2597
+ "type": "object"
2598
+ }
2599
+ },
2600
+ "required": [
2601
+ "processId",
2602
+ "originRunId",
2603
+ "contextId",
2604
+ "projectId",
2605
+ "status",
2606
+ "lifetime",
2607
+ "createdAt",
2608
+ "closedAt",
2609
+ "handedOffAt",
2610
+ "controlAvailable",
2611
+ "details"
2612
+ ],
2613
+ "additionalProperties": false
2614
+ }
2615
+ }
2616
+ }