@desplega.ai/agent-swarm 1.129.0 → 1.131.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (226) hide show
  1. package/README.md +2 -2
  2. package/dist/{actions-kfv2dawe.js → actions-w53mbns9.js} +11 -11
  3. package/dist/{anthropic-messages-3xgme8my.js → anthropic-messages-rjmd2e7n.js} +5 -5
  4. package/dist/{app-q8vjk6e8.js → app-m9gwqsqv.js} +8 -8
  5. package/dist/{artifact-hg4t1nx7.js → artifact-jysj3wrg.js} +2 -2
  6. package/dist/{assistant-g037r345.js → assistant-bp65m6f3.js} +13 -13
  7. package/dist/{azure-openai-responses-xa4sh9f6.js → azure-openai-responses-c0yjmbfd.js} +8 -5
  8. package/dist/{boot-reembed-18pzsrxa.js → boot-reembed-62p0at2k.js} +6 -6
  9. package/dist/{boot-reembed-wpks2cj8.js → boot-reembed-xmfp6wdh.js} +7 -7
  10. package/dist/{boot-scrub-logs-n7szd57r.js → boot-scrub-logs-rr8q2dms.js} +5 -5
  11. package/dist/{claude-adapter-qz4r0ajt.js → claude-adapter-2y47mrkd.js} +9 -9
  12. package/dist/{cli-mhjnbgb6.js → cli-0rcyq6d9.js} +450 -186
  13. package/dist/{cli-ttkmehy0.js → cli-2q72qz2s.js} +274 -25
  14. package/dist/{cli-gztgc3hz.js → cli-2wadx7p2.js} +2 -2
  15. package/dist/cli-3fj60etf.js +153 -0
  16. package/dist/{cli-7ecgm5v0.js → cli-3kf51j15.js} +1 -1
  17. package/dist/{cli-vgexpfsr.js → cli-57khth04.js} +6 -3
  18. package/dist/{cli-2mbe7vk0.js → cli-5dsbcjjw.js} +1 -1
  19. package/dist/{cli-etr62zy6.js → cli-5kx36evn.js} +2 -2
  20. package/dist/{cli-v2tr6amf.js → cli-5n6e5yfn.js} +30 -8
  21. package/dist/{cli-hx02s9zq.js → cli-5v4rw6yd.js} +2 -2
  22. package/dist/{cli-v37yr6mf.js → cli-5ze9rv97.js} +4 -4
  23. package/dist/{cli-ch7t5v7n.js → cli-6map995v.js} +9 -4
  24. package/dist/{cli-h0457a67.js → cli-70xqj0z3.js} +3 -3
  25. package/dist/{cli-kk4f9r17.js → cli-72q8m8gk.js} +8 -6
  26. package/dist/{cli-7padk69a.js → cli-78xwvkhj.js} +2 -2
  27. package/dist/{cli-dxtxacy7.js → cli-9dr5qzc0.js} +45 -8
  28. package/dist/{cli-17zxdgsq.js → cli-a40rnf71.js} +6 -6
  29. package/dist/{cli-t53vnnxz.js → cli-a4jzdpa3.js} +2514 -1055
  30. package/dist/{cli-w10fkrf1.js → cli-akdvwc9v.js} +354 -115
  31. package/dist/{cli-1qkk5er0.js → cli-bmze986d.js} +1 -1
  32. package/dist/{cli-ga12dc1d.js → cli-bqw0mt1n.js} +3 -3
  33. package/dist/{cli-0sf92efp.js → cli-cdeg08wx.js} +1 -1
  34. package/dist/{cli-a8ynhkyj.js → cli-cvgjwnh1.js} +17 -15
  35. package/dist/{cli-9fxg3v5m.js → cli-d2tfkcga.js} +4 -4
  36. package/dist/{cli-nhcd7x43.js → cli-d3x3x1c9.js} +2 -2
  37. package/dist/{cli-6nh2qxvh.js → cli-darcwax3.js} +1 -1
  38. package/dist/{cli-yjbgmysx.js → cli-e7ckcg4v.js} +12 -12
  39. package/dist/{cli-4n2gcjpd.js → cli-efxfnq6q.js} +4 -3
  40. package/dist/{cli-z9xqqhfk.js → cli-er3a4bb0.js} +1 -1
  41. package/dist/{cli-xg2eezyv.js → cli-f1am9szv.js} +1 -1
  42. package/dist/{cli-xy4cwsm9.js → cli-fywms69x.js} +1 -1
  43. package/dist/{cli-33jj76y8.js → cli-g6b8x1h8.js} +1 -1
  44. package/dist/{cli-epsvdckx.js → cli-gm9cbhbq.js} +20 -10
  45. package/dist/{cli-rkndnn90.js → cli-k9qkf1hw.js} +6 -4
  46. package/dist/{cli-zejvt395.js → cli-kh3ba2zf.js} +1 -1
  47. package/dist/{cli-gb25p1h2.js → cli-nm5gtp1x.js} +2 -2
  48. package/dist/{cli-akxnpx17.js → cli-pm6xbh84.js} +1829 -1629
  49. package/dist/{cli-2k0ztbfp.js → cli-psh3c4va.js} +1 -1
  50. package/dist/{cli-39vgrsep.js → cli-qv61hp37.js} +2 -2
  51. package/dist/{cli-hv2fndhm.js → cli-r6kqqbj0.js} +6 -4
  52. package/dist/{cli-1y1cm570.js → cli-rzbpmxdr.js} +1 -1
  53. package/dist/{cli-mmrk00vp.js → cli-t1xze5qh.js} +1 -1
  54. package/dist/{cli-g252a9ky.js → cli-t55yw3a1.js} +2 -2
  55. package/dist/{cli-7bz8dzqa.js → cli-t76vw5db.js} +1184 -1522
  56. package/dist/{cli-4n4mdv21.js → cli-xpxde7rm.js} +7 -3
  57. package/dist/{cli-fpaa5k2q.js → cli-yw8vghx2.js} +54 -18
  58. package/dist/cli-zsspvvm2.js +490 -0
  59. package/dist/cli.js +27 -25
  60. package/dist/{codex-adapter-7v6t7ff6.js → codex-adapter-d24q75wk.js} +7 -7
  61. package/dist/{codex-hook-amndawyb.js → codex-hook-hq54t9ft.js} +2 -2
  62. package/dist/{codex-session-runner-e7j4khe2.js → codex-session-runner-g50vcsex.js} +7 -7
  63. package/dist/{commands-ex0k5tbf.js → commands-c3nrc5hg.js} +5 -5
  64. package/dist/{db-df7jatfc.js → db-nt7fg3tw.js} +5 -5
  65. package/dist/{google-generative-ai-y42hnw9p.js → google-generative-ai-hysrd8qx.js} +7 -5
  66. package/dist/{google-vertex-4sg66gb6.js → google-vertex-p5arrga0.js} +7 -5
  67. package/dist/{handlers-1j2cfqt2.js → handlers-fkr6swat.js} +13 -13
  68. package/dist/{hook-nx9a0mj3.js → hook-77wpvnjc.js} +7 -7
  69. package/dist/{hook-w6yaf6sy.js → hook-g019yehy.js} +8 -8
  70. package/dist/{http-4tz5h8wg.js → http-jewj0syk.js} +2993 -716
  71. package/dist/{index-0bpkzb09.js → index-070v4eyb.js} +3 -3
  72. package/dist/{index-0s67qv7h.js → index-6gm5he8h.js} +11 -11
  73. package/dist/{index-35gtv6gj.js → index-7n2xpbd4.js} +310 -40
  74. package/dist/{index-ker3gccb.js → index-9znhar3x.js} +4 -4
  75. package/dist/{index-5n2c8yay.js → index-hase6zbe.js} +2 -2
  76. package/dist/{index-kcf3tm9h.js → index-hfvggd0z.js} +12 -12
  77. package/dist/{index-7c0jqna0.js → index-hp1kdbjj.js} +13 -13
  78. package/dist/{keepalive-3j4a9168.js → keepalive-j0fjvqfd.js} +7 -7
  79. package/dist/{lead-6kpevymb.js → lead-1n8x30xe.js} +33 -33
  80. package/dist/{maintenance-m1k82ean.js → maintenance-gvev11sa.js} +7 -7
  81. package/dist/{mistral-conversations-bjkdfb6z.js → mistral-conversations-81fwav0j.js} +6 -6
  82. package/dist/{oauth-refresh-sweep-881k8e4q.js → oauth-refresh-sweep-s9ecsvh0.js} +6 -6
  83. package/dist/{onboard-c0ykffjn.js → onboard-pvm5b38w.js} +2 -2
  84. package/dist/{openai-codex-responses-xetseqvt.js → openai-codex-responses-5g27pd6f.js} +43 -23
  85. package/dist/{openai-completions-5r2g5axa.js → openai-completions-3vkmfz2a.js} +55 -11
  86. package/dist/{openai-responses-ce67hd23.js → openai-responses-dg4t7j7a.js} +8 -5
  87. package/dist/{openrouter-images-pzfp22jb.js → openrouter-images-g3gm8931.js} +1 -1
  88. package/dist/{otel-impl-sqagjerv.js → otel-impl-p6jvgd9c.js} +6 -4
  89. package/dist/{otel-3mp81ppd.js → otel-nqa12wf3.js} +2 -2
  90. package/dist/{pi-mono-adapter-k584k16g.js → pi-mono-adapter-t091s27g.js} +17117 -7517
  91. package/dist/{pricing-refresh-y82whbf9.js → pricing-refresh-k49rcyed.js} +7 -7
  92. package/dist/{rbac-roles-nvkqmzyd.js → rbac-roles-30pspvy7.js} +7 -7
  93. package/dist/{rbac-roles-4ht8gegc.js → rbac-roles-cr80g96t.js} +6 -6
  94. package/dist/{render-v2-wvqdgvvp.js → render-v2-xm457ng1.js} +8 -8
  95. package/dist/{seed-pricing-fy3rxhde.js → seed-pricing-yhpv35fr.js} +6 -6
  96. package/dist/{setup-ak5cnc6f.js → setup-nytnmwwr.js} +2 -2
  97. package/dist/{worker-d8769q8a.js → worker-msytr2cw.js} +33 -33
  98. package/openapi.json +34039 -11036
  99. package/package.json +8 -6
  100. package/src/apps/definition.ts +368 -26
  101. package/src/apps/row-store.ts +66 -10
  102. package/src/apps/schema-migrate.ts +95 -1
  103. package/src/apps/store.ts +13 -4
  104. package/src/apps/sync-run-as.ts +18 -0
  105. package/src/apps/sync.ts +934 -0
  106. package/src/apps/version.ts +16 -2
  107. package/src/assets/key.ts +8 -1
  108. package/src/be/asset-key-audit.ts +3 -1
  109. package/src/be/db-queries/mcp-oauth.ts +297 -24
  110. package/src/be/db.ts +42 -1
  111. package/src/be/migrations/129_asset_keys_apps_scripts.sql +161 -0
  112. package/src/be/scripts/db.ts +5 -2
  113. package/src/be/scripts/typecheck.ts +1 -0
  114. package/src/be/seed-scripts/catalog/app-sync-run.ts +32 -0
  115. package/src/be/seed-scripts/catalog/github-issues-pull.ts +102 -0
  116. package/src/be/seed-scripts/index.ts +18 -0
  117. package/src/be/seed-skills/index.ts +7 -0
  118. package/src/http/active-sessions.ts +26 -18
  119. package/src/http/agents.ts +94 -27
  120. package/src/http/api-keys.ts +91 -17
  121. package/src/http/approval-requests.ts +87 -10
  122. package/src/http/apps.ts +361 -53
  123. package/src/http/assets.ts +165 -31
  124. package/src/http/budgets.ts +7 -5
  125. package/src/http/codex-oauth-keep-warm.ts +21 -3
  126. package/src/http/config.ts +46 -16
  127. package/src/http/context.ts +33 -6
  128. package/src/http/ecosystem.ts +20 -6
  129. package/src/http/events.ts +24 -9
  130. package/src/http/favorites.ts +20 -6
  131. package/src/http/fs.ts +60 -17
  132. package/src/http/heartbeat.ts +18 -4
  133. package/src/http/inbox-state.ts +12 -6
  134. package/src/http/integrations.ts +25 -5
  135. package/src/http/kv.ts +36 -15
  136. package/src/http/mcp-bridge.ts +5 -1
  137. package/src/http/mcp-oauth.ts +332 -17
  138. package/src/http/mcp-servers.ts +56 -18
  139. package/src/http/memory.ts +282 -29
  140. package/src/http/metrics.ts +80 -17
  141. package/src/http/oauth-callback.ts +10 -4
  142. package/src/http/oauth-generic.ts +5 -1
  143. package/src/http/oauth-locks.ts +6 -3
  144. package/src/http/openapi.ts +57 -9
  145. package/src/http/page-proxy.ts +25 -5
  146. package/src/http/pages-public.ts +37 -20
  147. package/src/http/pages.ts +93 -28
  148. package/src/http/poll.ts +89 -5
  149. package/src/http/pricing.ts +9 -6
  150. package/src/http/prompt-templates.ts +85 -21
  151. package/src/http/route-def.ts +67 -4
  152. package/src/http/schedules.ts +63 -14
  153. package/src/http/script-connection-proxy.ts +30 -4
  154. package/src/http/script-connections.ts +393 -43
  155. package/src/http/script-runs.ts +73 -19
  156. package/src/http/scripts.ts +257 -39
  157. package/src/http/session-data.ts +87 -14
  158. package/src/http/sessions.ts +80 -5
  159. package/src/http/skills.ts +115 -35
  160. package/src/http/stats.ts +94 -13
  161. package/src/http/task-templates.ts +6 -4
  162. package/src/http/tasks.ts +230 -61
  163. package/src/http/trackers/jira.ts +90 -30
  164. package/src/http/trackers/linear.ts +46 -12
  165. package/src/http/users.ts +162 -25
  166. package/src/http/utils.ts +12 -2
  167. package/src/http/webhooks.ts +30 -16
  168. package/src/http/workflow-events.ts +18 -5
  169. package/src/http/workflows.ts +128 -39
  170. package/src/http/x.ts +37 -6
  171. package/src/oauth/ensure-mcp-token.ts +16 -1
  172. package/src/oauth/mcp-wrapper.ts +281 -26
  173. package/src/providers/pi-mono-adapter.ts +1 -1
  174. package/src/scripts-runtime/credential-broker/README.md +1 -1
  175. package/src/scripts-runtime/credential-broker/fetch-patch.ts +12 -2
  176. package/src/scripts-runtime/sdk-allowlist.ts +1 -0
  177. package/src/scripts-runtime/stdlib/fetch.ts +6 -0
  178. package/src/scripts-runtime/types/stdlib.d.ts +1 -0
  179. package/src/scripts-runtime/types/swarm-sdk.d.ts +1 -0
  180. package/src/server.ts +2 -0
  181. package/src/tests/apps-rbac.test.ts +110 -0
  182. package/src/tests/apps-spike2.test.ts +4 -1
  183. package/src/tests/apps-sync-engine.test.ts +2540 -0
  184. package/src/tests/apps-sync.test.ts +1627 -0
  185. package/src/tests/asset-key-api.test.ts +48 -2
  186. package/src/tests/asset-key-invariants.test.ts +92 -0
  187. package/src/tests/asset-key-migration.test.ts +174 -8
  188. package/src/tests/asset-key-normalization.test.ts +2 -0
  189. package/src/tests/credential-broker.test.ts +27 -2
  190. package/src/tests/mcp-oauth-dcr-reuse.test.ts +743 -0
  191. package/src/tests/mcp-oauth-ensure-token.test.ts +45 -0
  192. package/src/tests/mcp-oauth-manual-client.test.ts +135 -2
  193. package/src/tests/mcp-oauth-queries.test.ts +153 -0
  194. package/src/tests/mcp-oauth-wrapper.test.ts +432 -0
  195. package/src/tests/memory-http-recall-gating.test.ts +2 -0
  196. package/src/tests/openapi-response-contract.test.ts +138 -0
  197. package/src/tests/rbac-admission-e2e.test.ts +68 -0
  198. package/src/tests/script-connections.test.ts +3 -0
  199. package/src/tests/scripts-runtime-fetch.test.ts +121 -0
  200. package/src/tests/scripts-runtime-secret-egress.test.ts +4 -2
  201. package/src/tests/seed-scripts.test.ts +2 -2
  202. package/src/tests/swarm-tool-result-gate.test.ts +32 -0
  203. package/src/tests/task-working-dir.test.ts +8 -4
  204. package/src/tests/whoami-route.test.ts +127 -0
  205. package/src/tests/workflow-engine-v2.test.ts +80 -7
  206. package/src/tests/workflow-swarm-script.test.ts +104 -0
  207. package/src/tools/app-get.ts +10 -2
  208. package/src/tools/app-rollback.ts +1 -0
  209. package/src/tools/app-sync.ts +112 -0
  210. package/src/tools/script-common.ts +20 -0
  211. package/src/tools/tool-config.ts +2 -1
  212. package/src/tools/utils.ts +11 -0
  213. package/src/tools/workflows/create-workflow.ts +4 -1
  214. package/src/types.ts +1394 -1206
  215. package/src/utils/template.ts +8 -1
  216. package/src/utils/zod-openapi.ts +11 -0
  217. package/src/workflows/engine.ts +27 -4
  218. package/src/workflows/executors/swarm-script.ts +28 -0
  219. package/src/workflows/retry-poller.ts +19 -2
  220. package/templates/skills/apps/content.md +94 -5
  221. package/templates/skills/asset-namespaces/content.md +2 -2
  222. package/templates/skills/scheduled-task-resilience/SKILL.md +102 -0
  223. package/templates/skills/scheduled-task-resilience/config.json +14 -0
  224. package/templates/skills/scheduled-task-resilience/content.md +97 -0
  225. package/dist/cli-7wmybrt5.js +0 -115
  226. package/dist/cli-d91pvmq1.js +0 -14
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  init_external
3
- } from "./cli-2mbe7vk0.js";
3
+ } from "./cli-5dsbcjjw.js";
4
4
 
5
5
  // node_modules/zod/v4/classic/index.js
6
6
  init_external();
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  init_env_flag,
3
3
  isEnvFlagEnabled
4
- } from "./cli-4n4mdv21.js";
4
+ } from "./cli-xpxde7rm.js";
5
5
  import {
6
6
  init_zod
7
- } from "./cli-d91pvmq1.js";
7
+ } from "./cli-zsspvvm2.js";
8
8
  import {
9
9
  _enum
10
- } from "./cli-2mbe7vk0.js";
10
+ } from "./cli-5dsbcjjw.js";
11
11
 
12
12
  // src/rbac/permissions.ts
13
13
  init_zod();
@@ -3,7 +3,7 @@ import {
3
3
  getAgentById,
4
4
  getInProgressTasksByContextKey,
5
5
  init_db
6
- } from "./cli-t53vnnxz.js";
6
+ } from "./cli-a4jzdpa3.js";
7
7
 
8
8
  // src/tasks/sibling-awareness.ts
9
9
  init_db();
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  require_follow_redirects
3
- } from "./cli-rkndnn90.js";
3
+ } from "./cli-k9qkf1hw.js";
4
4
  import {
5
5
  require_jws,
6
6
  require_p_retry
@@ -37,11 +37,11 @@ import {
37
37
  setSlackMessageTracking,
38
38
  slackContextKey,
39
39
  updateSlackMessageRecord
40
- } from "./cli-t53vnnxz.js";
40
+ } from "./cli-a4jzdpa3.js";
41
41
  import {
42
42
  init_env_flag,
43
43
  isEnvFlagEnabled
44
- } from "./cli-4n4mdv21.js";
44
+ } from "./cli-xpxde7rm.js";
45
45
  import {
46
46
  getAppUrl,
47
47
  init_constants
@@ -54,11 +54,13 @@ import {
54
54
  require_websocket_server
55
55
  } from "./cli-e15jhafb.js";
56
56
  import {
57
- require_supports_color
58
- } from "./cli-7wmybrt5.js";
57
+ exports_supports_color,
58
+ init_supports_color
59
+ } from "./cli-3fj60etf.js";
59
60
  import {
60
61
  __commonJS,
61
62
  __require,
63
+ __toCommonJS,
62
64
  __toESM
63
65
  } from "./cli-p9swy5t3.js";
64
66
 
@@ -33570,7 +33572,7 @@ var require_node = __commonJS((exports, module) => {
33570
33572
  exports.destroy = util.deprecate(() => {}, "Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");
33571
33573
  exports.colors = [6, 2, 3, 4, 5, 1];
33572
33574
  try {
33573
- const supportsColor = require_supports_color();
33575
+ const supportsColor = (init_supports_color(), __toCommonJS(exports_supports_color));
33574
33576
  if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) {
33575
33577
  exports.colors = [
33576
33578
  20,
@@ -46108,7 +46110,7 @@ var require_node2 = __commonJS((exports, module) => {
46108
46110
  exports.destroy = util.deprecate(() => {}, "Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");
46109
46111
  exports.colors = [6, 2, 3, 4, 5, 1];
46110
46112
  try {
46111
- const supportsColor = require_supports_color();
46113
+ const supportsColor = (init_supports_color(), __toCommonJS(exports_supports_color));
46112
46114
  if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) {
46113
46115
  exports.colors = [
46114
46116
  20,
@@ -47021,7 +47023,7 @@ var require_node3 = __commonJS((exports, module) => {
47021
47023
  exports.destroy = util.deprecate(() => {}, "Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");
47022
47024
  exports.colors = [6, 2, 3, 4, 5, 1];
47023
47025
  try {
47024
- const supportsColor = require_supports_color();
47026
+ const supportsColor = (init_supports_color(), __toCommonJS(exports_supports_color));
47025
47027
  if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) {
47026
47028
  exports.colors = [
47027
47029
  20,
@@ -48834,7 +48836,7 @@ var require_node4 = __commonJS((exports, module) => {
48834
48836
  exports.destroy = util.deprecate(() => {}, "Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");
48835
48837
  exports.colors = [6, 2, 3, 4, 5, 1];
48836
48838
  try {
48837
- const supportsColor = require_supports_color();
48839
+ const supportsColor = (init_supports_color(), __toCommonJS(exports_supports_color));
48838
48840
  if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) {
48839
48841
  exports.colors = [
48840
48842
  20,
@@ -51672,7 +51674,7 @@ var require_node5 = __commonJS((exports, module) => {
51672
51674
  exports.destroy = util.deprecate(() => {}, "Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");
51673
51675
  exports.colors = [6, 2, 3, 4, 5, 1];
51674
51676
  try {
51675
- const supportsColor = require_supports_color();
51677
+ const supportsColor = (init_supports_color(), __toCommonJS(exports_supports_color));
51676
51678
  if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) {
51677
51679
  exports.colors = [
51678
51680
  20,
@@ -55418,13 +55420,13 @@ async function initSlackApp() {
55418
55420
  socketMode: true,
55419
55421
  logLevel: import_bolt.LogLevel.DEBUG
55420
55422
  });
55421
- const { registerMessageHandler } = await import("./handlers-1j2cfqt2.js");
55422
- const { registerCommandHandler } = await import("./commands-ex0k5tbf.js");
55423
- const { registerActionHandlers } = await import("./actions-kfv2dawe.js");
55423
+ const { registerMessageHandler } = await import("./handlers-fkr6swat.js");
55424
+ const { registerCommandHandler } = await import("./commands-c3nrc5hg.js");
55425
+ const { registerActionHandlers } = await import("./actions-w53mbns9.js");
55424
55426
  registerMessageHandler(app);
55425
55427
  registerCommandHandler(app);
55426
55428
  registerActionHandlers(app);
55427
- const { createAssistant } = await import("./assistant-g037r345.js");
55429
+ const { createAssistant } = await import("./assistant-bp65m6f3.js");
55428
55430
  app.assistant(createAssistant());
55429
55431
  return app;
55430
55432
  }
@@ -55433,7 +55435,7 @@ async function startSlackApp() {
55433
55435
  await initSlackApp();
55434
55436
  }
55435
55437
  if (app) {
55436
- const { isSlackRenderV2Enabled: isSlackRenderV2Enabled2 } = await import("./render-v2-wvqdgvvp.js");
55438
+ const { isSlackRenderV2Enabled: isSlackRenderV2Enabled2 } = await import("./render-v2-xm457ng1.js");
55437
55439
  if (isSlackRenderV2Enabled2())
55438
55440
  ensureSlackRenderV2Activation();
55439
55441
  await app.start();
@@ -7,11 +7,11 @@ import {
7
7
  getPinCandidateAgent,
8
8
  getResumeGeneration,
9
9
  repointTrackerSyncBySwarmId
10
- } from "./cli-gb25p1h2.js";
10
+ } from "./cli-nm5gtp1x.js";
11
11
  import {
12
12
  getExecutorRegistry,
13
13
  recoverIncompleteRuns
14
- } from "./cli-fpaa5k2q.js";
14
+ } from "./cli-yw8vghx2.js";
15
15
  import {
16
16
  MAX_EMPTY_POLLS,
17
17
  assignUnassignedTaskPending,
@@ -51,13 +51,13 @@ import {
51
51
  releaseStaleReviewingTasks,
52
52
  supersedeTask,
53
53
  updateAgentStatus
54
- } from "./cli-t53vnnxz.js";
54
+ } from "./cli-a4jzdpa3.js";
55
55
  import {
56
56
  init_registry,
57
57
  init_resolver,
58
58
  registerTemplate,
59
59
  resolveTemplate
60
- } from "./cli-4n4mdv21.js";
60
+ } from "./cli-xpxde7rm.js";
61
61
  import {
62
62
  init_secret_scrubber,
63
63
  scrubSecrets
@@ -3,11 +3,11 @@ import {
3
3
  getAgentWorkingOnThread,
4
4
  getAllAgents,
5
5
  init_db
6
- } from "./cli-t53vnnxz.js";
6
+ } from "./cli-a4jzdpa3.js";
7
7
  import {
8
8
  init_env_flag,
9
9
  isEnvFlagEnabled
10
- } from "./cli-4n4mdv21.js";
10
+ } from "./cli-xpxde7rm.js";
11
11
 
12
12
  // src/slack/router.ts
13
13
  init_db();
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  lazyApi
3
- } from "./cli-w10fkrf1.js";
3
+ } from "./cli-akdvwc9v.js";
4
4
 
5
5
  // node_modules/@earendil-works/pi-ai/dist/api/bedrock-converse-stream.lazy.js
6
6
  var __rewriteRelativeImportExtension = function(path, preserveJsx) {
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  renderSteeringDelivery
3
- } from "./cli-xg2eezyv.js";
3
+ } from "./cli-f1am9szv.js";
4
4
  import {
5
5
  checkCodexCredentials
6
- } from "./cli-etr62zy6.js";
6
+ } from "./cli-5kx36evn.js";
7
7
  import {
8
8
  checkClaudeManagedCredentials
9
9
  } from "./cli-qmdnhpej.js";
@@ -15,7 +15,7 @@ import {
15
15
  } from "./cli-n6h8qt8n.js";
16
16
  import {
17
17
  checkClaudeCredentials
18
- } from "./cli-7ecgm5v0.js";
18
+ } from "./cli-3kf51j15.js";
19
19
  import {
20
20
  MAX_RATE_LIMIT_RESET_MS,
21
21
  isCodexCreditsExhaustedMessage,
@@ -35,7 +35,7 @@ import {
35
35
  withSpan,
36
36
  withSpanContext,
37
37
  writeSkillsToFilesystem
38
- } from "./cli-7bz8dzqa.js";
38
+ } from "./cli-t76vw5db.js";
39
39
  import {
40
40
  authJsonToCredentialSelection,
41
41
  credentialsToAuthJson,
@@ -44,10 +44,10 @@ import {
44
44
  import {
45
45
  ensure,
46
46
  initialize
47
- } from "./cli-v37yr6mf.js";
47
+ } from "./cli-5ze9rv97.js";
48
48
  import {
49
49
  validateJsonSchema
50
- } from "./cli-fpaa5k2q.js";
50
+ } from "./cli-yw8vghx2.js";
51
51
  import {
52
52
  getOpenRouterBaseUrl
53
53
  } from "./cli-3dpj7atn.js";
@@ -78,7 +78,7 @@ import {
78
78
  init_types,
79
79
  resolveTaskModelSelection,
80
80
  telemetry
81
- } from "./cli-t53vnnxz.js";
81
+ } from "./cli-a4jzdpa3.js";
82
82
  import {
83
83
  configureHttpResolver,
84
84
  init_resolver,
@@ -88,7 +88,7 @@ import {
88
88
  interpolate,
89
89
  isSteeringEnabled,
90
90
  resolveTemplateAsync
91
- } from "./cli-4n4mdv21.js";
91
+ } from "./cli-xpxde7rm.js";
92
92
  import {
93
93
  getMcpBaseUrl,
94
94
  init_constants
@@ -495,15 +495,15 @@ async function materializeCodexAuthJson(_slot, creds, deps = {}) {
495
495
  async function createProviderAdapter(provider) {
496
496
  switch (provider) {
497
497
  case "claude": {
498
- const { ClaudeAdapter } = await import("./claude-adapter-qz4r0ajt.js");
498
+ const { ClaudeAdapter } = await import("./claude-adapter-2y47mrkd.js");
499
499
  return new ClaudeAdapter;
500
500
  }
501
501
  case "pi": {
502
- const { PiMonoAdapter } = await import("./pi-mono-adapter-k584k16g.js");
502
+ const { PiMonoAdapter } = await import("./pi-mono-adapter-t091s27g.js");
503
503
  return new PiMonoAdapter;
504
504
  }
505
505
  case "codex": {
506
- const { CodexAdapter } = await import("./codex-adapter-7v6t7ff6.js");
506
+ const { CodexAdapter } = await import("./codex-adapter-d24q75wk.js");
507
507
  return new CodexAdapter;
508
508
  }
509
509
  case "claude-managed": {
@@ -1201,7 +1201,7 @@ async function checkProviderCredentials(provider, env, opts) {
1201
1201
  case "opencode":
1202
1202
  return checkOpencodeCredentials(env, opts);
1203
1203
  case "pi": {
1204
- const { checkPiMonoCredentials } = await import("./pi-mono-adapter-k584k16g.js");
1204
+ const { checkPiMonoCredentials } = await import("./pi-mono-adapter-t091s27g.js");
1205
1205
  return checkPiMonoCredentials(env, opts);
1206
1206
  }
1207
1207
  default:
@@ -1,12 +1,12 @@
1
1
  import {
2
2
  SYSTEM_COLUMN_KINDS,
3
3
  listAppRecords
4
- } from "./cli-ttkmehy0.js";
4
+ } from "./cli-2q72qz2s.js";
5
5
  import {
6
6
  getScriptApiTypes,
7
7
  getScriptMcpTypes,
8
8
  require_typescript
9
- } from "./cli-akxnpx17.js";
9
+ } from "./cli-pm6xbh84.js";
10
10
  import {
11
11
  deleteSwarmConfigByKey,
12
12
  getAgentById,
@@ -15,7 +15,7 @@ import {
15
15
  getSwarmConfigs,
16
16
  init_db,
17
17
  upsertSwarmConfig
18
- } from "./cli-t53vnnxz.js";
18
+ } from "./cli-a4jzdpa3.js";
19
19
  import {
20
20
  init_secret_scrubber,
21
21
  scrubSecrets
@@ -859,6 +859,7 @@ export interface SwarmSdk {
859
859
  migration?: Record<string, unknown>;
860
860
  forceElementBreak?: string[];
861
861
  }): Promise<unknown>;
862
+ app_sync(args: { appId: string; model?: string; source?: string }): Promise<unknown>;
862
863
  app_upsert(args: {
863
864
  name: string;
864
865
  description?: string;
@@ -4,7 +4,7 @@ import {
4
4
  import {
5
5
  safeParseAsync1 as safeParseAsync,
6
6
  toJSONSchema
7
- } from "./cli-2mbe7vk0.js";
7
+ } from "./cli-5dsbcjjw.js";
8
8
 
9
9
  // node_modules/@ai-sdk/provider/dist/index.mjs
10
10
  var marker = "vercel.ai.error";
@@ -2,7 +2,7 @@ import {
2
2
  init_resolver,
3
3
  init_session_templates,
4
4
  resolveTemplateAsync
5
- } from "./cli-4n4mdv21.js";
5
+ } from "./cli-xpxde7rm.js";
6
6
 
7
7
  // src/prompts/steering-delivery.ts
8
8
  init_session_templates();
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  init_package,
3
3
  package_default
4
- } from "./cli-kk4f9r17.js";
4
+ } from "./cli-72q8m8gk.js";
5
5
 
6
6
  // src/commands/shared/client-config.ts
7
7
  init_package();
@@ -7,7 +7,7 @@ import {
7
7
  init_date_utils,
8
8
  init_db,
9
9
  normalizeDateRequired
10
- } from "./cli-t53vnnxz.js";
10
+ } from "./cli-a4jzdpa3.js";
11
11
  import {
12
12
  init_secret_scrubber,
13
13
  registerVolatileSecret,
@@ -10,13 +10,13 @@ import {
10
10
  resolveGrammarConstrainedSampling,
11
11
  resolveJsonSchemaStrictSampling,
12
12
  transformMessages
13
- } from "./cli-vgexpfsr.js";
13
+ } from "./cli-57khth04.js";
14
14
  import {
15
15
  sanitizeSurrogates
16
16
  } from "./cli-y2apkfe2.js";
17
17
  import {
18
18
  calculateCost
19
- } from "./cli-w10fkrf1.js";
19
+ } from "./cli-akdvwc9v.js";
20
20
 
21
21
  // node_modules/@earendil-works/pi-ai/dist/api/openai-responses-shared.js
22
22
  function encodeTextSignatureV1(id, phase) {
@@ -418,8 +418,12 @@ async function processResponsesStream(openaiStream, output, stream, model, optio
418
418
  options.applyServiceTierPricing(output.usage, serviceTier);
419
419
  }
420
420
  const status = response?.status;
421
- output.rawStopReason = status;
422
- output.stopReason = mapStopReason(status);
421
+ const incompleteDetails = response?.incomplete_details;
422
+ const incompleteReason = typeof incompleteDetails?.reason === "string" ? incompleteDetails.reason : undefined;
423
+ output.rawStopReason = incompleteReason ? `${status}.${incompleteReason}` : status;
424
+ const mappedStop = mapStopReason(status, incompleteReason);
425
+ output.stopReason = mappedStop.stopReason;
426
+ output.errorMessage = mappedStop.errorMessage;
423
427
  if (output.content.some((b) => b.type === "toolCall") && output.stopReason === "stop") {
424
428
  output.stopReason = "toolUse";
425
429
  }
@@ -586,20 +590,26 @@ async function processResponsesStream(openaiStream, output, stream, model, optio
586
590
  throw new Error("OpenAI Responses stream ended before a terminal response event");
587
591
  }
588
592
  }
589
- function mapStopReason(status) {
593
+ function mapStopReason(status, incompleteReason) {
590
594
  if (!status)
591
- return "stop";
595
+ return { stopReason: "stop" };
592
596
  switch (status) {
593
597
  case "completed":
594
- return "stop";
598
+ return { stopReason: "stop" };
595
599
  case "incomplete":
596
- return "length";
600
+ if (incompleteReason === "max_output_tokens") {
601
+ return { stopReason: "length" };
602
+ }
603
+ return {
604
+ stopReason: "error",
605
+ errorMessage: incompleteReason ? `Response incomplete: ${incompleteReason}` : "Response incomplete without a provider reason"
606
+ };
597
607
  case "failed":
598
608
  case "cancelled":
599
- return "error";
609
+ return { stopReason: "error" };
600
610
  case "in_progress":
601
611
  case "queued":
602
- return "stop";
612
+ return { stopReason: "stop" };
603
613
  default: {
604
614
  const _exhaustive = status;
605
615
  throw new Error(`Unhandled stop reason: ${_exhaustive}`);
@@ -1,9 +1,11 @@
1
1
  import {
2
- require_supports_color
3
- } from "./cli-7wmybrt5.js";
2
+ exports_supports_color,
3
+ init_supports_color
4
+ } from "./cli-3fj60etf.js";
4
5
  import {
5
6
  __commonJS,
6
- __require
7
+ __require,
8
+ __toCommonJS
7
9
  } from "./cli-p9swy5t3.js";
8
10
 
9
11
  // node_modules/ms/index.js
@@ -449,7 +451,7 @@ var require_node = __commonJS((exports, module) => {
449
451
  exports.destroy = util.deprecate(() => {}, "Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");
450
452
  exports.colors = [6, 2, 3, 4, 5, 1];
451
453
  try {
452
- const supportsColor = require_supports_color();
454
+ const supportsColor = (init_supports_color(), __toCommonJS(exports_supports_color));
453
455
  if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) {
454
456
  exports.colors = [
455
457
  20,
@@ -14,7 +14,7 @@ import {
14
14
  string,
15
15
  union,
16
16
  unknown
17
- } from "./cli-2mbe7vk0.js";
17
+ } from "./cli-5dsbcjjw.js";
18
18
 
19
19
  // node_modules/@mistralai/mistralai/esm/lib/primitives.js
20
20
  function remap(inp, mappings) {
@@ -16,13 +16,13 @@ import {
16
16
  init_db,
17
17
  init_templates1 as init_templates,
18
18
  normalizeDateRequired
19
- } from "./cli-t53vnnxz.js";
19
+ } from "./cli-a4jzdpa3.js";
20
20
  import {
21
21
  init_env_flag,
22
22
  init_resolver,
23
23
  isEnvFlagEnabled,
24
24
  resolveTemplate
25
- } from "./cli-4n4mdv21.js";
25
+ } from "./cli-xpxde7rm.js";
26
26
 
27
27
  // src/be/db-queries/tracker.ts
28
28
  init_date_utils();