@desplega.ai/agent-swarm 2.4.2 → 2.4.4

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 (183) hide show
  1. package/dist/{acp-adapter-dv7hmx4r.js → acp-adapter-thq04adh.js} +4 -5
  2. package/dist/{actions-51nc1gny.js → actions-j6ywh6x5.js} +18 -18
  3. package/dist/{amp-adapter-abp5tdx8.js → amp-adapter-k8b5xmj8.js} +3 -3
  4. package/dist/{app-9h14qvr6.js → app-rb7vc02s.js} +3 -3
  5. package/dist/{assistant-wv1gz3mt.js → assistant-ftta1zjf.js} +20 -20
  6. package/dist/{boot-reembed-6yn53ms9.js → boot-reembed-srp6v6af.js} +1 -1
  7. package/dist/{boot-reembed-7fcka4z5.js → boot-reembed-xns7h5h9.js} +1 -1
  8. package/dist/{boot-scrub-sweep-pm1580ax.js → boot-scrub-sweep-3qqrh2mz.js} +3 -3
  9. package/dist/{boot-seeds-g5hfc1x8.js → boot-seeds-9ks8hce7.js} +4 -4
  10. package/dist/{claude-adapter-gf3kxhf0.js → claude-adapter-k5ksyres.js} +4 -4
  11. package/dist/{claude-managed-setup-h00hsgtz.js → claude-managed-setup-n5a5eqks.js} +1 -1
  12. package/dist/{claude-sdk-session-s2k1qd8y.js → claude-sdk-session-2j3j4kwn.js} +9822 -9749
  13. package/dist/{cli-pkht5hap.js → cli-1d70crsy.js} +2 -2
  14. package/dist/{cli-r99kc9yq.js → cli-1ephgwnq.js} +3 -3
  15. package/dist/{cli-7225gwj7.js → cli-1m17dc9d.js} +1 -1
  16. package/dist/{cli-bcj753sq.js → cli-2v045xyf.js} +3 -3
  17. package/dist/{cli-h38rjv87.js → cli-2y91wnbh.js} +12 -7
  18. package/dist/{cli-sv5gb0yb.js → cli-2zqpkvtt.js} +1 -1
  19. package/dist/{cli-xbzvet96.js → cli-36ckw0wx.js} +5 -4
  20. package/dist/{cli-8sxqsbbq.js → cli-37yb7307.js} +1 -1
  21. package/dist/{cli-hyfw2j1e.js → cli-3cgngyd8.js} +11 -11
  22. package/dist/{cli-a4gvwttf.js → cli-44159k28.js} +2 -2
  23. package/dist/{cli-7awf1fp8.js → cli-4dg55wsk.js} +3 -3
  24. package/dist/{cli-mhywgrrz.js → cli-4sydckyj.js} +1 -1
  25. package/dist/{cli-y2x52gs2.js → cli-51y09c6p.js} +20 -17
  26. package/dist/{cli-ahtpy9kf.js → cli-55qmbp6z.js} +10 -5
  27. package/dist/{cli-pw7v69vp.js → cli-625tb7aq.js} +1 -1
  28. package/dist/{cli-x5mq1fyq.js → cli-74c1wpm0.js} +3 -3
  29. package/dist/{cli-b1dfr1m4.js → cli-7a6p4e65.js} +1 -1
  30. package/dist/{cli-hqhzg1qq.js → cli-82d3nkc3.js} +1 -1
  31. package/dist/{cli-nmqdc2t3.js → cli-9fhkkpj5.js} +78 -12
  32. package/dist/{cli-h93c9vb3.js → cli-amyhm3gj.js} +1 -1
  33. package/dist/{cli-0qvtffe9.js → cli-b8k7epj1.js} +6 -6
  34. package/dist/{cli-1pa3rz69.js → cli-ba8ne1es.js} +6 -1
  35. package/dist/{cli-g0hgtz4p.js → cli-bnz0r3kc.js} +3 -3
  36. package/dist/{cli-0hyhdkdk.js → cli-cebvbc9t.js} +4 -1
  37. package/dist/{cli-efaqv1c7.js → cli-cynvc9fj.js} +35 -7
  38. package/dist/{cli-8zwe9mpk.js → cli-dqb4n629.js} +10 -10
  39. package/dist/{cli-7a91w22y.js → cli-e8xyjvfc.js} +1 -1
  40. package/dist/{cli-s6vr7r2d.js → cli-esxerzg7.js} +1 -1
  41. package/dist/{cli-w9g4sz81.js → cli-gf2850q7.js} +1 -1
  42. package/dist/{cli-10hhg0km.js → cli-gqvh8d8a.js} +7 -7
  43. package/dist/{cli-t30yj95q.js → cli-hj3debgw.js} +1 -1
  44. package/dist/{cli-fpmsqq59.js → cli-nc35pxb7.js} +3 -3
  45. package/dist/{cli-d3qqdy4c.js → cli-p20r8w42.js} +16 -14
  46. package/dist/{cli-shvfedvm.js → cli-pccfmtb5.js} +5 -5
  47. package/dist/{cli-02qm7src.js → cli-q6r7t299.js} +1037 -299
  48. package/dist/{cli-2wag8973.js → cli-qeaq3j6t.js} +1 -1
  49. package/dist/{cli-nn47d7e8.js → cli-qkhc5aqy.js} +15 -15
  50. package/dist/{cli-faypxz7q.js → cli-t7cyef5g.js} +4 -4
  51. package/dist/{cli-z4wd2ftv.js → cli-te6b5wvg.js} +149 -184
  52. package/dist/{cli-5rk36sjf.js → cli-v3yr2gbg.js} +119 -44
  53. package/dist/{cli-239yjk27.js → cli-vdm20wej.js} +5 -5
  54. package/dist/{cli-zfg9enh9.js → cli-vfha21c9.js} +6 -1
  55. package/dist/{cli-rdyw3mct.js → cli-vq97g1jq.js} +6 -5
  56. package/dist/{cli-n85dqg6d.js → cli-w6nadkh4.js} +4 -4
  57. package/dist/{cli-99jez72r.js → cli-w9etnnxk.js} +6 -1
  58. package/dist/{cli-saw9a6f6.js → cli-xc27fwzg.js} +2 -2
  59. package/dist/{cli-ftyypbg5.js → cli-xj0re5tm.js} +1 -1
  60. package/dist/{cli-fyzjmseb.js → cli-zrk6jxv8.js} +1 -1
  61. package/dist/{cli-y8n5k515.js → cli-zrwpctp4.js} +28 -28
  62. package/dist/cli.js +44 -19
  63. package/dist/{codex-adapter-ttygw382.js → codex-adapter-968xwfy7.js} +2 -2
  64. package/dist/{codex-hook-x7nejyrr.js → codex-hook-e2he7aca.js} +2 -2
  65. package/dist/{codex-session-runner-60b58vv3.js → codex-session-runner-ht4z99fa.js} +2 -2
  66. package/dist/{commands-edmdwa4x.js → commands-pcymaeg9.js} +3 -3
  67. package/dist/{controller-m263fg43.js → controller-fpjyk46r.js} +3 -3
  68. package/dist/{controllers-connect-5fym8sw1.js → controllers-connect-mwzx1fh6.js} +19 -19
  69. package/dist/{cursor-adapter-cz6nm6mj.js → cursor-adapter-cp4s2e2f.js} +2 -2
  70. package/dist/{db-2y0mgstc.js → db-sgd12bt9.js} +3 -3
  71. package/dist/{db-nn0hcmx5.js → db-xsjg9jqq.js} +2 -2
  72. package/dist/{dispatcher-0a9wwjcx.js → dispatcher-x0jfw2c9.js} +17 -17
  73. package/dist/{dsh-adapter-3n3net33.js → dsh-adapter-jrq7ma7h.js} +2 -2
  74. package/dist/{e2b-thdcxtjd.js → e2b-16d6ch39.js} +1 -1
  75. package/dist/{e2b-7am6tmq6.js → e2b-zn0b4w5w.js} +1 -1
  76. package/dist/{external-channel-zhvt95n3.js → external-channel-8njj4h3b.js} +2 -2
  77. package/dist/{grok-adapter-qnr1hp2y.js → grok-adapter-kkr97v2f.js} +5 -6
  78. package/dist/handlers-0pvee9nw.js +39 -0
  79. package/dist/{heartbeat-gz97r7ac.js → heartbeat-wd03zhn0.js} +20 -20
  80. package/dist/{hook-1mmdgjqs.js → hook-f0vghj42.js} +10 -5
  81. package/dist/{hook-x8rthca4.js → hook-xzj2ts2p.js} +2 -2
  82. package/dist/{http-r8f85xr9.js → http-4hwxv62p.js} +261 -123
  83. package/dist/{index-va3y63es.js → index-6srwvd5b.js} +1 -2
  84. package/dist/{index-y7rbcrc1.js → index-97q4xn03.js} +20 -11
  85. package/dist/{index-s98037v0.js → index-cbxkmfc5.js} +1 -2
  86. package/dist/{index-vzvfqzfj.js → index-gdh8jrdm.js} +17 -17
  87. package/dist/{index-aex0eba9.js → index-hg0x2cdv.js} +17 -17
  88. package/dist/index-thm0y6a8.js +41 -0
  89. package/dist/{index-smxyk04s.js → index-ww2vznkp.js} +1 -1
  90. package/dist/{keepalive-64c0f34c.js → keepalive-hrh7xnr9.js} +3 -3
  91. package/dist/{lead-b1da0f97.js → lead-ee8vazz2.js} +30 -31
  92. package/dist/{maintenance-mnxpar12.js → maintenance-e8wnwnqx.js} +1 -1
  93. package/dist/{oauth-refresh-sweep-36hs2v4h.js → oauth-refresh-sweep-zm0yj4sj.js} +2 -2
  94. package/dist/{onboard-xes8de61.js → onboard-dtwcq603.js} +3 -3
  95. package/dist/{opencode-adapter-3s7ax02e.js → opencode-adapter-x4tqzhkh.js} +3 -3
  96. package/dist/{otel-impl-fzc57kcq.js → otel-impl-w3fbhpn0.js} +1 -1
  97. package/dist/{pi-mono-adapter-ytp7gz8b.js → pi-mono-adapter-mcfkn9vf.js} +3 -3
  98. package/dist/{pricing-refresh-1nek2w7b.js → pricing-refresh-j38dehfs.js} +3 -3
  99. package/dist/{rbac-roles-ttyfaep2.js → rbac-roles-ae8yttq4.js} +3 -3
  100. package/dist/{rbac-roles-sqefb5hw.js → rbac-roles-ejxx9b35.js} +2 -2
  101. package/dist/{render-v2-vb527jwn.js → render-v2-n16n0phe.js} +3 -3
  102. package/dist/{resume-jcdzg1bn.js → resume-z0fgjc38.js} +5 -5
  103. package/dist/{session-access-zsp4wsp0.js → session-access-cv3mq6mc.js} +6 -4
  104. package/dist/{setup-1nb2zqd3.js → setup-mafhj3yt.js} +1 -1
  105. package/dist/{work-objects-61w08fwr.js → work-objects-8b86mgjp.js} +21 -21
  106. package/dist/{worker-c1e68hpa.js → worker-16s75hm5.js} +30 -31
  107. package/dist/worker-token-xf11yyds.js +136 -0
  108. package/openapi.json +295 -12
  109. package/package.json +5 -5
  110. package/src/apps/action-runner.ts +4 -0
  111. package/src/apps/catalog.generated.json +3 -0
  112. package/src/apps/page-validator.ts +8 -2
  113. package/src/be/db.ts +7 -4
  114. package/src/be/migrations/231_slack_tasks_last_updated_index.sql +5 -0
  115. package/src/be/migrations/232_agent_session_tokens.sql +41 -0
  116. package/src/be/seed-scripts/catalog/heartbeat-jev-gate.ts +10 -1
  117. package/src/be/swarm-config-guard.ts +16 -0
  118. package/src/be/users.ts +169 -12
  119. package/src/cli.tsx +24 -0
  120. package/src/commands/worker-token.ts +164 -0
  121. package/src/github/handlers.ts +6 -5
  122. package/src/hooks/hook.ts +2 -1
  123. package/src/http/apps.ts +43 -5
  124. package/src/http/codex-oauth-keep-warm.ts +27 -9
  125. package/src/http/config.ts +5 -3
  126. package/src/http/core.ts +2 -0
  127. package/src/http/session-access.ts +51 -2
  128. package/src/http/sessions.ts +249 -10
  129. package/src/http/tasks.ts +4 -32
  130. package/src/providers/acp-adapter.ts +33 -13
  131. package/src/providers/acp-swarm-events.ts +1 -1
  132. package/src/providers/amp-adapter.ts +1 -1
  133. package/src/providers/codex-adapter.ts +4 -4
  134. package/src/providers/codex-oauth/storage.ts +1 -1
  135. package/src/providers/opencode-adapter.ts +2 -2
  136. package/src/providers/pi-mono-extension.ts +2 -1
  137. package/src/rbac/legacy-policy.ts +3 -1
  138. package/src/rbac/permissions.ts +4 -0
  139. package/src/tests/acp-adapter.test.ts +10 -23
  140. package/src/tests/acp-fake-agent.ts +36 -0
  141. package/src/tests/acp-swarm-events.test.ts +1 -1
  142. package/src/tests/agent-session-tokens.test.ts +452 -0
  143. package/src/tests/apps-action-parent-task.test.ts +295 -0
  144. package/src/tests/claude-stop-hook.test.ts +47 -0
  145. package/src/tests/codex-adapter.test.ts +42 -0
  146. package/src/tests/codex-oauth-keep-warm.test.ts +85 -1
  147. package/src/tests/config-session-auth.test.ts +14 -0
  148. package/src/tests/docs-index-footprint.test.js +2 -2
  149. package/src/tests/env-flag.test.ts +15 -1
  150. package/src/tests/github-handlers-cancel-config.test.ts +29 -8
  151. package/src/tests/github-handlers-inline-comments.test.ts +9 -2
  152. package/src/tests/grok-adapter.test.ts +3 -3
  153. package/src/tests/heartbeat-jev-gate.test.ts +23 -0
  154. package/src/tests/migration-232-agent-session-tokens.test.ts +67 -0
  155. package/src/tests/rbac-engine.test.ts +1 -0
  156. package/src/tests/runtime-child-token-cleanup.test.ts +3 -3
  157. package/src/tests/script-connections.test.ts +4 -0
  158. package/src/tests/session-route-posture.test.ts +2 -0
  159. package/src/tests/skill-script-refs.test.ts +63 -0
  160. package/src/tests/slack-render-v2-query-plans.test.ts +147 -0
  161. package/src/tests/worker-token-cli.test.ts +76 -0
  162. package/src/tests/workflow-executors.test.ts +4 -2
  163. package/src/tests/workflow-system-one-extraction.test.ts +805 -0
  164. package/src/types.ts +2 -1
  165. package/src/utils/env-flag.ts +9 -0
  166. package/src/utils/request-auth-context.ts +2 -1
  167. package/src/workflows/definition.ts +7 -1
  168. package/src/workflows/engine.ts +18 -12
  169. package/src/workflows/executors/index.ts +1 -0
  170. package/src/workflows/executors/registry.ts +2 -0
  171. package/src/workflows/executors/system-one-decision.ts +56 -255
  172. package/src/workflows/executors/system-one-extract-wire.ts +57 -0
  173. package/src/workflows/executors/system-one-extraction.ts +830 -0
  174. package/src/workflows/executors/system-one-providers.ts +277 -110
  175. package/src/workflows/executors/system-one-transport.ts +264 -0
  176. package/templates/official/lead/HEARTBEAT.md +1 -1
  177. package/templates/skills/apps/SKILL.md +4 -1
  178. package/templates/skills/apps/content.md +4 -1
  179. package/templates/skills/code-quality/content.md +9 -14
  180. package/templates/skills/heartbeat-runbook/content.md +3 -3
  181. package/dist/cli-v1sjhn52.js +0 -7
  182. package/dist/handlers-dkcarkd0.js +0 -39
  183. package/dist/index-5jecgp3n.js +0 -41
@@ -2,7 +2,7 @@ import {
2
2
  isGrokOpenRouterModel,
3
3
  grokTargetProfile,
4
4
  ACPAdapter2
5
- } from "./cli-z4wd2ftv.js";
5
+ } from "./cli-te6b5wvg.js";
6
6
  import {
7
7
  getOpenRouterBaseUrl,
8
8
  getOpenRouterAttributionHeaders,
@@ -20,7 +20,7 @@ import {
20
20
  renderMemoriesPrompt,
21
21
  isUnknownModelError,
22
22
  writeSkillsToFilesystem
23
- } from "./cli-ftyypbg5.js";
23
+ } from "./cli-xj0re5tm.js";
24
24
  import {
25
25
  isPollTracingEnabled,
26
26
  initOtel,
@@ -30,7 +30,7 @@ import {
30
30
  injectTraceContext2,
31
31
  initialize,
32
32
  ensure
33
- } from "./cli-nn47d7e8.js";
33
+ } from "./cli-qkhc5aqy.js";
34
34
  import {
35
35
  getContextWindowSize
36
36
  } from "./cli-a5ebc95n.js";
@@ -51,7 +51,7 @@ import {
51
51
  canonicalAzureDevOpsRepoUrl,
52
52
  parseAzureDevOpsRepoUrl,
53
53
  resolveScriptsOnlyMode
54
- } from "./cli-5rk36sjf.js";
54
+ } from "./cli-v3yr2gbg.js";
55
55
  import {
56
56
  ACP_TARGET_IDS,
57
57
  isAcpTarget
@@ -59,32 +59,32 @@ import {
59
59
  import {
60
60
  checkAmpCredentials2,
61
61
  liveTestAmpCredentials2
62
- } from "./cli-r99kc9yq.js";
62
+ } from "./cli-1ephgwnq.js";
63
63
  import {
64
64
  checkClaudeCredentials2
65
- } from "./cli-239yjk27.js";
65
+ } from "./cli-vdm20wej.js";
66
66
  import {
67
67
  checkClaudeManagedCredentials2
68
68
  } from "./cli-a0kcty51.js";
69
69
  import {
70
70
  codexUserHome,
71
71
  checkCodexCredentials2
72
- } from "./cli-rdyw3mct.js";
72
+ } from "./cli-vq97g1jq.js";
73
73
  import {
74
74
  checkCursorCredentials2
75
- } from "./cli-g0hgtz4p.js";
75
+ } from "./cli-bnz0r3kc.js";
76
76
  import {
77
77
  checkDevinCredentials2
78
78
  } from "./cli-s95dknxh.js";
79
79
  import {
80
80
  checkDshCredentials2
81
- } from "./cli-a4gvwttf.js";
81
+ } from "./cli-44159k28.js";
82
82
  import {
83
83
  checkOpencodeCredentials2
84
- } from "./cli-xbzvet96.js";
84
+ } from "./cli-36ckw0wx.js";
85
85
  import {
86
86
  checkGrokCredentials2
87
- } from "./cli-fyzjmseb.js";
87
+ } from "./cli-zrk6jxv8.js";
88
88
  import {
89
89
  CODEX_OAUTH_POOL_SLOTS_ENV,
90
90
  isCodexOAuthConfigKey,
@@ -93,7 +93,7 @@ import {
93
93
  } from "./cli-j4bwnpkm.js";
94
94
  import {
95
95
  validateJsonSchema
96
- } from "./cli-y2x52gs2.js";
96
+ } from "./cli-51y09c6p.js";
97
97
  import {
98
98
  mapTriggerSurface,
99
99
  init_telemetry_context,
@@ -111,7 +111,7 @@ import {
111
111
  init_vcs_repo_match,
112
112
  isApiDrainingResponse,
113
113
  init_api_drain
114
- } from "./cli-d3qqdy4c.js";
114
+ } from "./cli-p20r8w42.js";
115
115
  import {
116
116
  parseWorkerModelTierOverrides,
117
117
  resolveTaskModelSelection,
@@ -119,7 +119,7 @@ import {
119
119
  ProviderNameSchema,
120
120
  WorkerNudgeSchema,
121
121
  init_types
122
- } from "./cli-fpmsqq59.js";
122
+ } from "./cli-nc35pxb7.js";
123
123
  import {
124
124
  generateDefaultClaudeMd2,
125
125
  generateDefaultSoulMd2,
@@ -143,11 +143,11 @@ import {
143
143
  resolveClaudeMdPath,
144
144
  syncProfileFilesToServer,
145
145
  init_profile_sync
146
- } from "./cli-x5mq1fyq.js";
146
+ } from "./cli-74c1wpm0.js";
147
147
  import {
148
148
  isSteeringEnabled2,
149
149
  init_steering_enabled
150
- } from "./cli-mhywgrrz.js";
150
+ } from "./cli-4sydckyj.js";
151
151
  import {
152
152
  normalizeProviderKeyAliases,
153
153
  ModelWindowExhaustedError,
@@ -190,11 +190,11 @@ import {
190
190
  import {
191
191
  getMcpBaseUrl,
192
192
  init_constants2
193
- } from "./cli-w9g4sz81.js";
193
+ } from "./cli-gf2850q7.js";
194
194
  import {
195
195
  isEnvFlagEnabled,
196
196
  init_env_flag
197
- } from "./cli-0hyhdkdk.js";
197
+ } from "./cli-cebvbc9t.js";
198
198
  import {
199
199
  getApiKey,
200
200
  init_api_key
@@ -246,15 +246,15 @@ async function materializeCodexAuthJson(_slot, creds, deps = {}) {
246
246
  async function createProviderAdapter(provider) {
247
247
  switch (provider) {
248
248
  case "claude": {
249
- const { ClaudeAdapter } = await import("./claude-adapter-gf3kxhf0.js");
249
+ const { ClaudeAdapter } = await import("./claude-adapter-k5ksyres.js");
250
250
  return new ClaudeAdapter;
251
251
  }
252
252
  case "pi": {
253
- const { PiMonoAdapter } = await import("./pi-mono-adapter-ytp7gz8b.js");
253
+ const { PiMonoAdapter } = await import("./pi-mono-adapter-mcfkn9vf.js");
254
254
  return new PiMonoAdapter;
255
255
  }
256
256
  case "codex": {
257
- const { CodexAdapter } = await import("./codex-adapter-ttygw382.js");
257
+ const { CodexAdapter } = await import("./codex-adapter-968xwfy7.js");
258
258
  return new CodexAdapter;
259
259
  }
260
260
  case "claude-managed": {
@@ -266,27 +266,27 @@ async function createProviderAdapter(provider) {
266
266
  return new DevinAdapter;
267
267
  }
268
268
  case "opencode": {
269
- const { OpencodeAdapter } = await import("./opencode-adapter-3s7ax02e.js");
269
+ const { OpencodeAdapter } = await import("./opencode-adapter-x4tqzhkh.js");
270
270
  return new OpencodeAdapter;
271
271
  }
272
272
  case "dsh": {
273
- const { DshAdapter } = await import("./dsh-adapter-3n3net33.js");
273
+ const { DshAdapter } = await import("./dsh-adapter-jrq7ma7h.js");
274
274
  return new DshAdapter;
275
275
  }
276
276
  case "amp": {
277
- const { AmpAdapter } = await import("./amp-adapter-abp5tdx8.js");
277
+ const { AmpAdapter } = await import("./amp-adapter-k8b5xmj8.js");
278
278
  return new AmpAdapter;
279
279
  }
280
280
  case "cursor": {
281
- const { CursorAdapter } = await import("./cursor-adapter-cz6nm6mj.js");
281
+ const { CursorAdapter } = await import("./cursor-adapter-cp4s2e2f.js");
282
282
  return new CursorAdapter;
283
283
  }
284
284
  case "grok": {
285
- const { GrokAdapter } = await import("./grok-adapter-qnr1hp2y.js");
285
+ const { GrokAdapter } = await import("./grok-adapter-kkr97v2f.js");
286
286
  return new GrokAdapter;
287
287
  }
288
288
  case "acp": {
289
- const { ACPAdapter } = await import("./acp-adapter-dv7hmx4r.js");
289
+ const { ACPAdapter } = await import("./acp-adapter-thq04adh.js");
290
290
  return new ACPAdapter;
291
291
  }
292
292
  default:
@@ -1205,7 +1205,7 @@ var CREDENTIAL_PROVIDER_CHECKERS = {
1205
1205
  devin: (env) => checkDevinCredentials2(env),
1206
1206
  opencode: (env, opts) => checkOpencodeCredentials2(env, opts),
1207
1207
  pi: async (env, opts) => {
1208
- const { checkPiMonoCredentials, listPiOpencodeGoModelIds } = await import("./pi-mono-adapter-ytp7gz8b.js");
1208
+ const { checkPiMonoCredentials, listPiOpencodeGoModelIds } = await import("./pi-mono-adapter-mcfkn9vf.js");
1209
1209
  return {
1210
1210
  ...await checkPiMonoCredentials(env, opts),
1211
1211
  opencodeGoModels: listPiOpencodeGoModelIds()
@@ -1477,7 +1477,7 @@ async function validateProviderCredentials(provider, env = process.env, presence
1477
1477
  latency_ms: Date.now() - startedAt
1478
1478
  };
1479
1479
  }
1480
- const { liveTestCursorKey } = await import("./cursor-adapter-cz6nm6mj.js");
1480
+ const { liveTestCursorKey } = await import("./cursor-adapter-cp4s2e2f.js");
1481
1481
  const result = await liveTestCursorKey(apiKey);
1482
1482
  return result.ok ? { ok: true, latency_ms: Date.now() - startedAt } : { ok: false, error: result.error, latency_ms: Date.now() - startedAt };
1483
1483
  }
package/dist/cli.js CHANGED
@@ -51,7 +51,7 @@ var import_react = __toESM(require_react(), 1);
51
51
  // package.json
52
52
  var package_default = {
53
53
  name: "@desplega.ai/agent-swarm",
54
- version: "2.4.2",
54
+ version: "2.4.4",
55
55
  description: "agent-swarm.dev — an open-source operating system for AI work: a lead agent breaks goals into tasks, routes them to specialized workers such as Claude Code or Codex, runs each worker in an isolated container, and preserves shared memory, tools, schedules, and review gates so delegated work compounds across sessions.",
56
56
  keywords: [
57
57
  "agent-swarm.dev",
@@ -230,8 +230,8 @@ var package_default = {
230
230
  "@desplega/model-catalog": "workspace:*",
231
231
  "@desplega/model-routing": "workspace:*",
232
232
  "@faker-js/faker": "^10.4.0",
233
- "@opencode/plugin": "2.0.32",
234
- "@opencode/sdk": "2.0.32",
233
+ "@opencode/plugin": "2.1.1",
234
+ "@opencode/sdk": "2.1.1",
235
235
  "@oxlint/plugins": "1.78.0",
236
236
  "@types/bun": "latest",
237
237
  "dependency-cruiser": "^18.0.0",
@@ -249,9 +249,9 @@ var package_default = {
249
249
  bun: ">=1.3.12"
250
250
  },
251
251
  dependencies: {
252
- "@agentclientprotocol/sdk": "1.9.0",
252
+ "@agentclientprotocol/sdk": "2.0.0",
253
253
  "@ai-sdk/openai": "^3.0.41",
254
- "@anthropic-ai/claude-agent-sdk": "0.3.303",
254
+ "@anthropic-ai/claude-agent-sdk": "0.3.304",
255
255
  "@anthropic-ai/sdk": "^0.135.0",
256
256
  "@asteasolutions/zod-to-openapi": "^8.0.0",
257
257
  "@aws-sdk/client-bedrock": "3.1048.0",
@@ -695,6 +695,26 @@ Prompts interactively for the target API URL and a best-effort masked API key, t
695
695
  ` ${binName} claude-managed-setup --force`,
696
696
  ` ${binName} claude-managed-setup --api-url https://swarm.example.com`
697
697
  ].join(`
698
+ `)
699
+ },
700
+ "worker-token": {
701
+ usage: `${binName} worker-token <create|rotate|revoke> (--agent-id <id> | --name <name>) [options]`,
702
+ description: "Manage the agent-bound token a worker runs on in place of the swarm API key. The token acts only as its agent. create and rotate print the new token to stdout once; messages go to stderr. Uses your operator swarm API key.",
703
+ options: [
704
+ " --agent-id <id> Agent the token is bound to",
705
+ " --name <name> Agent name; create makes the agent when no agent has this name",
706
+ " --ttl-days <n> Token lifetime (create, rotate). Default: no expiry",
707
+ " --grace-sec <n> How long the old token keeps working after rotate (default 300)",
708
+ " --api-url <url> Swarm API URL (default: MCP_BASE_URL or http://localhost:3013)",
709
+ " --api-key <key> Operator swarm API key (default: AGENT_SWARM_API_KEY or API_KEY, falling back to 123123)",
710
+ " -h, --help Show this help"
711
+ ].join(`
712
+ `),
713
+ examples: [
714
+ ` ${binName} worker-token create --name worker-1`,
715
+ ` ${binName} worker-token rotate --agent-id <agent-id> --grace-sec 600`,
716
+ ` ${binName} worker-token revoke --agent-id <agent-id>`
717
+ ].join(`
698
718
  `)
699
719
  },
700
720
  e2b: {
@@ -792,6 +812,7 @@ ${binName} v${package_default.version}`);
792
812
  ["docs", "Open documentation (--open to launch in browser)"],
793
813
  ["codex-login", "Authenticate Codex via ChatGPT OAuth"],
794
814
  ["claude-managed-setup", "Bootstrap Anthropic Managed Agents (agent + env + skills)"],
815
+ ["worker-token", "Mint, rotate, or revoke an agent-bound worker token"],
795
816
  ["e2b", "Build templates and start E2B API/worker sandboxes"],
796
817
  ["version", "Show version number"],
797
818
  ["help", "Show this help message"]
@@ -812,7 +833,7 @@ function McpServer({ port, apiKey, dbPath }) {
812
833
  if (dbPath) {
813
834
  process.env.DATABASE_PATH = dbPath;
814
835
  }
815
- import("./http-r8f85xr9.js").then(() => {
836
+ import("./http-4hwxv62p.js").then(() => {
816
837
  setStatus("running");
817
838
  }).catch((err) => {
818
839
  setStatus("error");
@@ -899,7 +920,7 @@ function WorkerRunner({
899
920
  const { exit } = use_app_default();
900
921
  import_react.useEffect(() => {
901
922
  installConsoleScrub();
902
- import("./worker-c1e68hpa.js").then(({ runWorker }) => runWorker({
923
+ import("./worker-16s75hm5.js").then(({ runWorker }) => runWorker({
903
924
  prompt: prompt || undefined,
904
925
  yolo,
905
926
  systemPrompt: systemPrompt || undefined,
@@ -917,7 +938,7 @@ function LeadRunner({ prompt, yolo, systemPrompt, systemPromptFile, additionalAr
917
938
  const { exit } = use_app_default();
918
939
  import_react.useEffect(() => {
919
940
  installConsoleScrub();
920
- import("./lead-b1da0f97.js").then(({ runLead }) => runLead({
941
+ import("./lead-ee8vazz2.js").then(({ runLead }) => runLead({
921
942
  prompt: prompt || undefined,
922
943
  yolo,
923
944
  systemPrompt: systemPrompt || undefined,
@@ -957,8 +978,8 @@ function LazyComponent({
957
978
  }
958
979
  return import_react.createElement(Component, props);
959
980
  }
960
- var loadOnboard = () => import("./onboard-xes8de61.js").then(({ Onboard }) => Onboard);
961
- var loadConnect = () => import("./setup-1nb2zqd3.js").then(({ Setup }) => Setup);
981
+ var loadOnboard = () => import("./onboard-dtwcq603.js").then(({ Onboard }) => Onboard);
982
+ var loadConnect = () => import("./setup-mafhj3yt.js").then(({ Setup }) => Setup);
962
983
  function UnknownCommand({ command }) {
963
984
  const { exit } = use_app_default();
964
985
  import_react.useEffect(() => {
@@ -1088,14 +1109,14 @@ ${binName} docs \u2014 v${package_default.version}
1088
1109
  }
1089
1110
  process.exit(0);
1090
1111
  } else if (args.command === "hook") {
1091
- const { runHook } = await import("./hook-x8rthca4.js");
1112
+ const { runHook } = await import("./hook-xzj2ts2p.js");
1092
1113
  await runHook();
1093
1114
  } else if (args.command === "codex-hook") {
1094
- const { handleCodexHook } = await import("./codex-hook-x7nejyrr.js");
1115
+ const { handleCodexHook } = await import("./codex-hook-e2he7aca.js");
1095
1116
  await handleCodexHook();
1096
1117
  process.exit(process.exitCode ?? 0);
1097
1118
  } else if (args.command === "session-summary-stdin") {
1098
- const { runSessionSummaryFromStdin } = await import("./hook-1mmdgjqs.js");
1119
+ const { runSessionSummaryFromStdin } = await import("./hook-f0vghj42.js");
1099
1120
  await runSessionSummaryFromStdin();
1100
1121
  process.exit(process.exitCode ?? 0);
1101
1122
  } else if (args.command === "x") {
@@ -1108,7 +1129,7 @@ ${binName} docs \u2014 v${package_default.version}
1108
1129
  printHelp("scripts");
1109
1130
  process.exit(scriptsArgs[0] === "reembed" || args.showHelp ? 0 : 1);
1110
1131
  }
1111
- const { runScriptsMaintenanceCommand } = await import("./maintenance-mnxpar12.js");
1132
+ const { runScriptsMaintenanceCommand } = await import("./maintenance-e8wnwnqx.js");
1112
1133
  await runScriptsMaintenanceCommand(scriptsArgs);
1113
1134
  console.log("Scripts re-embedded.");
1114
1135
  } else if (args.command === "rbac") {
@@ -1118,25 +1139,29 @@ ${binName} docs \u2014 v${package_default.version}
1118
1139
  printHelp("rbac");
1119
1140
  process.exit(args.showHelp ? 0 : 1);
1120
1141
  }
1121
- const { runRbacCliCommand } = await import("./rbac-roles-ttyfaep2.js");
1142
+ const { runRbacCliCommand } = await import("./rbac-roles-ae8yttq4.js");
1122
1143
  await runRbacCliCommand(rbacArgs);
1123
1144
  } else if (args.command === "codex-login") {
1124
1145
  const { runCodexLogin } = await import("./codex-login-m819c41r.js");
1125
1146
  const codexLoginArgs = process.argv.slice(process.argv.indexOf("codex-login") + 1);
1126
1147
  await runCodexLogin(codexLoginArgs);
1127
1148
  } else if (args.command === "codex-session-runner") {
1128
- const { runCodexSessionRunner } = await import("./codex-session-runner-60b58vv3.js");
1149
+ const { runCodexSessionRunner } = await import("./codex-session-runner-ht4z99fa.js");
1129
1150
  await runCodexSessionRunner();
1130
1151
  } else if (args.command === "claude-managed-setup") {
1131
- const { runClaudeManagedSetup } = await import("./claude-managed-setup-h00hsgtz.js");
1152
+ const { runClaudeManagedSetup } = await import("./claude-managed-setup-n5a5eqks.js");
1132
1153
  const setupArgs = process.argv.slice(process.argv.indexOf("claude-managed-setup") + 1);
1133
1154
  await runClaudeManagedSetup(setupArgs);
1155
+ } else if (args.command === "worker-token") {
1156
+ const { runWorkerToken } = await import("./worker-token-xf11yyds.js");
1157
+ const tokenArgs = process.argv.slice(process.argv.indexOf("worker-token") + 1);
1158
+ process.exit(await runWorkerToken(tokenArgs));
1134
1159
  } else if (args.command === "e2b") {
1135
- const { runE2BCommand } = await import("./e2b-thdcxtjd.js");
1160
+ const { runE2BCommand } = await import("./e2b-16d6ch39.js");
1136
1161
  const e2bArgs = process.argv.slice(process.argv.indexOf("e2b") + 1);
1137
1162
  await runE2BCommand(e2bArgs);
1138
1163
  } else if (args.command === "controller") {
1139
- const { runController } = await import("./controller-m263fg43.js");
1164
+ const { runController } = await import("./controller-fpjyk46r.js");
1140
1165
  await runController(process.argv.slice(process.argv.indexOf("controller") + 1));
1141
1166
  } else {
1142
1167
  render_default(/* @__PURE__ */ jsx_dev_runtime.jsxDEV(App, {
@@ -2,7 +2,7 @@ import {
2
2
  checkCodexCredentials2,
3
3
  createInProcessCodexSession2,
4
4
  CodexAdapter2
5
- } from "./cli-rdyw3mct.js";
5
+ } from "./cli-vq97g1jq.js";
6
6
  import"./cli-4zsenjhy.js";
7
7
  import"./cli-kr5tjjtz.js";
8
8
  import"./cli-vbhgkw9h.js";
@@ -14,7 +14,7 @@ import"./cli-0726awxw.js";
14
14
  import"./cli-gx4rm0qx.js";
15
15
  import"./cli-bn0rewsy.js";
16
16
  import"./cli-3h26v7yj.js";
17
- import"./cli-7a91w22y.js";
17
+ import"./cli-e8xyjvfc.js";
18
18
  import"./cli-3ggwdtb0.js";
19
19
  import"./cli-8nyhf7za.js";
20
20
  import"./cli-ejs3m1sx.js";
@@ -9,11 +9,11 @@ import {
9
9
  import {
10
10
  isSteeringEnabled2,
11
11
  init_steering_enabled
12
- } from "./cli-mhywgrrz.js";
12
+ } from "./cli-4sydckyj.js";
13
13
  import {
14
14
  getMcpBaseUrl,
15
15
  init_constants2
16
- } from "./cli-w9g4sz81.js";
16
+ } from "./cli-gf2850q7.js";
17
17
  import {
18
18
  getApiKey,
19
19
  init_api_key
@@ -6,11 +6,11 @@ import"./cli-8nyhf7za.js";
6
6
  import"./cli-kvzgak7c.js";
7
7
  import"./cli-ejs3m1sx.js";
8
8
  import"./cli-pnp2j5zg.js";
9
- import"./cli-7a91w22y.js";
9
+ import"./cli-e8xyjvfc.js";
10
10
  import"./cli-3ggwdtb0.js";
11
11
  import {
12
12
  createInProcessCodexSession2
13
- } from "./cli-rdyw3mct.js";
13
+ } from "./cli-vq97g1jq.js";
14
14
  import"./cli-jc1g9ndz.js";
15
15
  import"./cli-0726awxw.js";
16
16
  import"./cli-4bd1rck6.js";
@@ -2,15 +2,15 @@ import {
2
2
  getAllAgents2,
3
3
  getAllTasks2,
4
4
  init_db3
5
- } from "./cli-d3qqdy4c.js";
5
+ } from "./cli-p20r8w42.js";
6
6
  import {
7
7
  EXTERNAL_CHANNEL_BLOCKED_REPLY2,
8
8
  shouldBlockChannel2
9
- } from "./cli-pkht5hap.js";
9
+ } from "./cli-1d70crsy.js";
10
10
  import {
11
11
  isEnvFlagEnabled,
12
12
  init_env_flag
13
- } from "./cli-0hyhdkdk.js";
13
+ } from "./cli-cebvbc9t.js";
14
14
 
15
15
  // src/slack/commands.ts
16
16
  init_db3();
@@ -2,15 +2,15 @@ import {
2
2
  BuiltinController,
3
3
  CONTROLLER_PROTOCOL_VERSION,
4
4
  ControllerServerMessageSchema
5
- } from "./cli-hqhzg1qq.js";
5
+ } from "./cli-82d3nkc3.js";
6
6
  import {
7
7
  createRuntimeProvider,
8
8
  init_runtime_providers
9
- } from "./cli-pw7v69vp.js";
9
+ } from "./cli-625tb7aq.js";
10
10
  import {
11
11
  RuntimeProviderKindSchema,
12
12
  init_types
13
- } from "./cli-fpmsqq59.js";
13
+ } from "./cli-nc35pxb7.js";
14
14
  import {
15
15
  scrubSecrets,
16
16
  registerVolatileSecret,
@@ -6,20 +6,20 @@ import {
6
6
  isRuntimePoolsEnabled,
7
7
  init_runtime_pools_flag,
8
8
  init_db3
9
- } from "./cli-d3qqdy4c.js";
9
+ } from "./cli-p20r8w42.js";
10
10
  import {
11
11
  CONTROLLER_PROTOCOL_VERSION,
12
12
  CONTROLLER_PING_INTERVAL_MS,
13
13
  ControllerClientMessageSchema
14
- } from "./cli-hqhzg1qq.js";
15
- import"./cli-7a91w22y.js";
14
+ } from "./cli-82d3nkc3.js";
15
+ import"./cli-e8xyjvfc.js";
16
16
  import {
17
17
  resolveHttpRequestAuth
18
- } from "./cli-5rk36sjf.js";
18
+ } from "./cli-v3yr2gbg.js";
19
19
  import {
20
20
  getRuntimeController2,
21
21
  init_db
22
- } from "./cli-n85dqg6d.js";
22
+ } from "./cli-w6nadkh4.js";
23
23
  import {
24
24
  remoteControllerSession,
25
25
  installRemoteController,
@@ -28,29 +28,29 @@ import {
28
28
  ensureRuntimeOwnerId,
29
29
  reconcileRemoteProvisions,
30
30
  reconcileControllerOrphans
31
- } from "./cli-8zwe9mpk.js";
32
- import"./cli-y2x52gs2.js";
33
- import"./cli-h38rjv87.js";
34
- import"./cli-s6vr7r2d.js";
31
+ } from "./cli-dqb4n629.js";
32
+ import"./cli-51y09c6p.js";
33
+ import"./cli-2y91wnbh.js";
34
+ import"./cli-esxerzg7.js";
35
35
  import"./cli-3ggwdtb0.js";
36
- import"./cli-nn47d7e8.js";
37
- import"./cli-pkht5hap.js";
38
- import"./cli-02qm7src.js";
36
+ import"./cli-qkhc5aqy.js";
37
+ import"./cli-1d70crsy.js";
38
+ import"./cli-q6r7t299.js";
39
39
  import"./cli-8nyhf7za.js";
40
40
  import"./cli-kvzgak7c.js";
41
41
  import"./cli-445c1vp7.js";
42
42
  import"./cli-ejs3m1sx.js";
43
43
  import"./cli-wt645v7q.js";
44
- import"./cli-sv5gb0yb.js";
45
- import"./cli-h93c9vb3.js";
46
- import"./cli-saw9a6f6.js";
44
+ import"./cli-2zqpkvtt.js";
45
+ import"./cli-amyhm3gj.js";
46
+ import"./cli-xc27fwzg.js";
47
47
  import"./cli-qz93y3x5.js";
48
- import"./cli-7awf1fp8.js";
49
- import"./cli-faypxz7q.js";
48
+ import"./cli-4dg55wsk.js";
49
+ import"./cli-t7cyef5g.js";
50
50
  import"./cli-qje9k2nh.js";
51
51
  import {
52
52
  route
53
- } from "./cli-efaqv1c7.js";
53
+ } from "./cli-cynvc9fj.js";
54
54
  import"./cli-3h26v7yj.js";
55
55
  import"./cli-smvcw9z5.js";
56
56
  import"./cli-13p25grh.js";
@@ -58,7 +58,7 @@ import"./cli-0adyhvq2.js";
58
58
  import {
59
59
  registerSessionTokenConnection,
60
60
  init_session_token_connections
61
- } from "./cli-nmqdc2t3.js";
61
+ } from "./cli-9fhkkpj5.js";
62
62
  import {
63
63
  getApiKey,
64
64
  init_api_key
@@ -2,11 +2,11 @@ import {
2
2
  checkCursorCredentials2,
3
3
  liveTestCursorKey2,
4
4
  CursorAdapter2
5
- } from "./cli-g0hgtz4p.js";
5
+ } from "./cli-bnz0r3kc.js";
6
6
  import"./cli-jc1g9ndz.js";
7
7
  import"./cli-a5ebc95n.js";
8
8
  import"./cli-bn0rewsy.js";
9
- import"./cli-7a91w22y.js";
9
+ import"./cli-e8xyjvfc.js";
10
10
  export {
11
11
  CursorAdapter2 as CursorAdapter,
12
12
  checkCursorCredentials2 as checkCursorCredentials,
@@ -19,9 +19,9 @@ import {
19
19
  createPoolAgent2,
20
20
  loadRuntimeControllerSecrets2,
21
21
  init_db
22
- } from "./cli-n85dqg6d.js";
23
- import"./cli-nmqdc2t3.js";
24
- import"./cli-d3qqdy4c.js";
22
+ } from "./cli-w6nadkh4.js";
23
+ import"./cli-9fhkkpj5.js";
24
+ import"./cli-p20r8w42.js";
25
25
  init_db();
26
26
 
27
27
  export {
@@ -503,13 +503,13 @@ import {
503
503
  countScriptRunJournalSteps2,
504
504
  countScriptRunJournalAgentTaskSteps2,
505
505
  init_db3
506
- } from "./cli-d3qqdy4c.js";
506
+ } from "./cli-p20r8w42.js";
507
507
  import {
508
508
  generateDefaultClaudeMd2,
509
509
  generateDefaultSoulMd2,
510
510
  generateDefaultIdentityMd2,
511
511
  generateDefaultToolsMd2
512
- } from "./cli-x5mq1fyq.js";
512
+ } from "./cli-74c1wpm0.js";
513
513
  init_db3();
514
514
 
515
515
  export {
@@ -11,34 +11,34 @@ import {
11
11
  listRegistered2,
12
12
  dispatchPre2,
13
13
  dispatchPost2
14
- } from "./cli-5rk36sjf.js";
14
+ } from "./cli-v3yr2gbg.js";
15
15
  import"./cli-smvcw9z5.js";
16
- import"./cli-sv5gb0yb.js";
16
+ import"./cli-2zqpkvtt.js";
17
17
  import"./cli-qz93y3x5.js";
18
18
  import"./cli-3h26v7yj.js";
19
- import"./cli-7a91w22y.js";
20
- import"./cli-saw9a6f6.js";
21
- import"./cli-h38rjv87.js";
19
+ import"./cli-e8xyjvfc.js";
20
+ import"./cli-xc27fwzg.js";
21
+ import"./cli-2y91wnbh.js";
22
22
  import"./cli-3ggwdtb0.js";
23
- import"./cli-s6vr7r2d.js";
24
- import"./cli-faypxz7q.js";
25
- import"./cli-h93c9vb3.js";
23
+ import"./cli-esxerzg7.js";
24
+ import"./cli-t7cyef5g.js";
25
+ import"./cli-amyhm3gj.js";
26
26
  import"./cli-qje9k2nh.js";
27
- import"./cli-y2x52gs2.js";
28
- import"./cli-02qm7src.js";
27
+ import"./cli-51y09c6p.js";
28
+ import"./cli-q6r7t299.js";
29
29
  import"./cli-8nyhf7za.js";
30
30
  import"./cli-ejs3m1sx.js";
31
- import"./cli-efaqv1c7.js";
31
+ import"./cli-cynvc9fj.js";
32
32
  import"./cli-13p25grh.js";
33
33
  import"./cli-0adyhvq2.js";
34
- import"./cli-nn47d7e8.js";
35
- import"./cli-pkht5hap.js";
36
- import"./cli-n85dqg6d.js";
37
- import"./cli-nmqdc2t3.js";
34
+ import"./cli-qkhc5aqy.js";
35
+ import"./cli-1d70crsy.js";
36
+ import"./cli-w6nadkh4.js";
37
+ import"./cli-9fhkkpj5.js";
38
38
  import"./cli-445c1vp7.js";
39
39
  import"./cli-kvzgak7c.js";
40
- import"./cli-7awf1fp8.js";
41
- import"./cli-d3qqdy4c.js";
40
+ import"./cli-4dg55wsk.js";
41
+ import"./cli-p20r8w42.js";
42
42
  import"./cli-wt645v7q.js";
43
43
  export {
44
44
  ExtensionAbortedError2 as ExtensionAbortedError,
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  checkDshCredentials2,
3
3
  DshAdapter2
4
- } from "./cli-a4gvwttf.js";
4
+ } from "./cli-44159k28.js";
5
5
  import"./cli-jc1g9ndz.js";
6
6
  import"./cli-a5ebc95n.js";
7
7
  import"./cli-bn0rewsy.js";
8
- import"./cli-7a91w22y.js";
8
+ import"./cli-e8xyjvfc.js";
9
9
  import"./cli-3ggwdtb0.js";
10
10
  export {
11
11
  DshAdapter2 as DshAdapter,
@@ -30,7 +30,7 @@ import {
30
30
  import {
31
31
  getAppUrl,
32
32
  init_constants2
33
- } from "./cli-w9g4sz81.js";
33
+ } from "./cli-gf2850q7.js";
34
34
  import {
35
35
  DEFAULT_E2B_API_BASE,
36
36
  DEFAULT_E2B_TEMPLATE_NAMES,
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  resolveWorkerApiUrl,
3
3
  init_worker_api_url
4
- } from "./cli-b1dfr1m4.js";
4
+ } from "./cli-7a6p4e65.js";
5
5
  import {
6
6
  e2bSdkConnectionOptions,
7
7
  E2BApiError,