@desplega.ai/agent-swarm 1.149.0 → 1.149.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.
- package/dist/{acp-adapter-4jncb126.js → acp-adapter-vhkzfpjg.js} +1 -1
- package/dist/{actions-31vp3ae7.js → actions-9d2694yk.js} +6 -6
- package/dist/{app-1hh67x8w.js → app-fq2ggynt.js} +3 -3
- package/dist/{assistant-z66dmz6p.js → assistant-edb6n9nn.js} +8 -8
- package/dist/{boot-reembed-wxa8ya0s.js → boot-reembed-msweabbp.js} +4 -4
- package/dist/{boot-reembed-fqzxxzjh.js → boot-reembed-q5wd3tha.js} +3 -3
- package/dist/{boot-scrub-logs-jnyndh79.js → boot-scrub-logs-3g1az933.js} +2 -2
- package/dist/{claude-adapter-3qpa9w0j.js → claude-adapter-v3rnzsdc.js} +3 -3
- package/dist/{claude-sdk-session-2yxgjs5d.js → claude-sdk-session-qxrpsna1.js} +3 -3
- package/dist/{cli-nye12xk5.js → cli-01g3x1ca.js} +3 -3
- package/dist/{cli-qaacms9y.js → cli-1c94wvcw.js} +5 -5
- package/dist/{cli-d8ftsp62.js → cli-3sysyjve.js} +7 -7
- package/dist/{cli-2qts1hys.js → cli-3z634pqe.js} +2 -2
- package/dist/{cli-n3dz2942.js → cli-4260r1tg.js} +3 -3
- package/dist/{cli-9fy6nk6g.js → cli-5m0qmvdp.js} +1 -1
- package/dist/{cli-k0cr4kat.js → cli-6skz3rk8.js} +1 -1
- package/dist/{cli-e95cx1eb.js → cli-73gq0zxn.js} +1 -1
- package/dist/{cli-phsxnkp6.js → cli-7evafqvy.js} +9 -9
- package/dist/{cli-ygweqcn4.js → cli-7fehefdf.js} +5 -5
- package/dist/{cli-sd5pv3b1.js → cli-7xx10h0a.js} +2 -2
- package/dist/{cli-ykxrnd1q.js → cli-9br8ypfv.js} +2 -2
- package/dist/{cli-q50ef8g0.js → cli-ayvy5kde.js} +1 -1
- package/dist/{cli-9hspd3dp.js → cli-cd60fv6j.js} +1 -1
- package/dist/{cli-yb9qhqam.js → cli-cv7s5zdq.js} +18 -18
- package/dist/{cli-6pqcb4q0.js → cli-ddfw1mc4.js} +8 -8
- package/dist/{cli-kjwt6hdf.js → cli-e06a8a7y.js} +1 -1
- package/dist/{cli-19f354qr.js → cli-hzqmgcm2.js} +2 -2
- package/dist/{cli-gv88e1vf.js → cli-j4d4f6hv.js} +1 -1
- package/dist/{cli-3q5ejx9p.js → cli-jezx9b9c.js} +1 -1
- package/dist/{cli-7smrsr25.js → cli-k351hv5k.js} +2 -2
- package/dist/{cli-yab68w40.js → cli-qgd4sqz5.js} +2 -1
- package/dist/{cli-kgz4np97.js → cli-sdzq01t9.js} +2 -2
- package/dist/{cli-aae6hz6a.js → cli-svbrpf5q.js} +3 -3
- package/dist/{cli-cr12paw2.js → cli-tg8qj8ee.js} +1 -1
- package/dist/{cli-gjhjfeeg.js → cli-wby1xnnb.js} +1 -1
- package/dist/{cli-mnmsfd1w.js → cli-y3pq4v9g.js} +1 -1
- package/dist/cli.js +11 -11
- package/dist/{codex-adapter-8meawydj.js → codex-adapter-jyw7a91z.js} +2 -2
- package/dist/{codex-session-runner-gjgxyp5j.js → codex-session-runner-bmngj0s5.js} +2 -2
- package/dist/{commands-hz3nb95f.js → commands-n755g391.js} +2 -2
- package/dist/{db-ggz97zbm.js → db-s1cgh5gv.js} +2 -2
- package/dist/{handlers-nbzdzn9k.js → handlers-nsg0bcye.js} +8 -8
- package/dist/{hook-bks2q1f6.js → hook-h9cqrm8q.js} +1 -1
- package/dist/{hook-kq9wp0ep.js → hook-jf0xe8zh.js} +2 -2
- package/dist/{http-hrf77v87.js → http-nc6pydw5.js} +34 -34
- package/dist/{index-cqtebbhb.js → index-0wdy6gwc.js} +9 -9
- package/dist/{index-8hmeg8j1.js → index-769nc012.js} +10 -10
- package/dist/{index-6nsbg88z.js → index-ezxkds2n.js} +173 -49
- package/dist/{index-n28pw1zt.js → index-x1zcj09z.js} +11 -11
- package/dist/{keepalive-dxc12gvg.js → keepalive-nesm3xb6.js} +4 -4
- package/dist/{lead-yckfn18d.js → lead-bwy6t2za.js} +22 -22
- package/dist/{maintenance-6kfb2m5e.js → maintenance-8w393zf0.js} +4 -4
- package/dist/{oauth-refresh-sweep-1x1ac722.js → oauth-refresh-sweep-sh8xjy08.js} +3 -3
- package/dist/{onboard-dcyt1609.js → onboard-25ps29h1.js} +2 -2
- package/dist/{otel-impl-tbk3e5dr.js → otel-impl-b93gxnz5.js} +1 -1
- package/dist/{pricing-refresh-kaqg567e.js → pricing-refresh-5v56x7gb.js} +4 -4
- package/dist/{rbac-roles-cf97v1vd.js → rbac-roles-0p0s6pbj.js} +3 -3
- package/dist/{rbac-roles-ammq6rd2.js → rbac-roles-x55cnezn.js} +2 -2
- package/dist/{render-v2-80w603vy.js → render-v2-hyd45w8b.js} +3 -3
- package/dist/{seed-pricing-zbrn83xv.js → seed-pricing-49gbgn96.js} +3 -3
- package/dist/{setup-fe66kczs.js → setup-qvq64vzq.js} +2 -2
- package/dist/{worker-qmb2d1e2.js → worker-scj60cxg.js} +22 -22
- package/openapi.json +1 -1
- package/package.json +1 -1
- package/src/be/seed/automation-toggle.ts +69 -0
- package/src/be/seed/schedules-seeder.ts +28 -6
- package/src/be/seed/workflows-seeder.ts +18 -6
- package/src/be/swarm-config-guard.ts +1 -0
- package/src/tests/seed-registry.test.ts +2 -2
- package/src/tests/seed-schedules.test.ts +99 -3
- package/src/tests/seed-workflows.test.ts +74 -0
- package/templates/schedules/daily-blocker-digest/config.json +6 -1
- package/templates/schedules/daily-compounding-reflection/config.json +1 -0
- package/templates/schedules/daily-status-report/config.json +6 -1
- package/templates/schedules/daily-swarm-update-check/config.json +19 -0
- package/templates/schedules/daily-swarm-update-check/content.md +49 -0
- package/templates/schedules/daily-workflow-health-audit/config.json +6 -1
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
reembedAllScripts
|
|
3
|
-
} from "./cli-
|
|
4
|
-
import"./cli-
|
|
3
|
+
} from "./cli-3z634pqe.js";
|
|
4
|
+
import"./cli-jezx9b9c.js";
|
|
5
5
|
import"./cli-zvz62chv.js";
|
|
6
6
|
import"./cli-aehm1rbq.js";
|
|
7
7
|
import"./cli-9d8ntetj.js";
|
|
8
|
-
import"./cli-
|
|
8
|
+
import"./cli-qgd4sqz5.js";
|
|
9
9
|
import"./cli-08b07b4r.js";
|
|
10
10
|
import"./cli-3apbzgyk.js";
|
|
11
11
|
import"./cli-e29gmdmw.js";
|
|
@@ -13,7 +13,7 @@ import"./cli-c2mk1kgf.js";
|
|
|
13
13
|
import"./cli-ej6gbxfb.js";
|
|
14
14
|
import"./cli-sd0mxa3c.js";
|
|
15
15
|
import"./cli-w5e1d1vv.js";
|
|
16
|
-
import"./cli-
|
|
16
|
+
import"./cli-e06a8a7y.js";
|
|
17
17
|
import"./cli-r2ap2czm.js";
|
|
18
18
|
import"./cli-zf8jjwex.js";
|
|
19
19
|
import"./cli-bc05qbss.js";
|
|
@@ -2,8 +2,8 @@ import {
|
|
|
2
2
|
forceRefreshAuthorizationOrThrow,
|
|
3
3
|
getAuthorizationById,
|
|
4
4
|
listAuthorizationSweepRows
|
|
5
|
-
} from "./cli-
|
|
6
|
-
import"./cli-
|
|
5
|
+
} from "./cli-cd60fv6j.js";
|
|
6
|
+
import"./cli-qgd4sqz5.js";
|
|
7
7
|
import"./cli-08b07b4r.js";
|
|
8
8
|
import"./cli-3apbzgyk.js";
|
|
9
9
|
import"./cli-e29gmdmw.js";
|
|
@@ -11,7 +11,7 @@ import"./cli-c2mk1kgf.js";
|
|
|
11
11
|
import"./cli-ej6gbxfb.js";
|
|
12
12
|
import"./cli-sd0mxa3c.js";
|
|
13
13
|
import"./cli-w5e1d1vv.js";
|
|
14
|
-
import"./cli-
|
|
14
|
+
import"./cli-e06a8a7y.js";
|
|
15
15
|
import {
|
|
16
16
|
init_secret_scrubber,
|
|
17
17
|
scrubSecrets
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
createDefaultMcpJson,
|
|
4
4
|
createDefaultSettingsLocal,
|
|
5
5
|
createHooksConfig
|
|
6
|
-
} from "./cli-
|
|
6
|
+
} from "./cli-wby1xnnb.js";
|
|
7
7
|
import {
|
|
8
8
|
require_jsx_dev_runtime
|
|
9
9
|
} from "./cli-s2qjdd6z.js";
|
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
import {
|
|
14
14
|
init_package,
|
|
15
15
|
package_default
|
|
16
|
-
} from "./cli-
|
|
16
|
+
} from "./cli-e06a8a7y.js";
|
|
17
17
|
import {
|
|
18
18
|
Box_default,
|
|
19
19
|
Select,
|
|
@@ -2,9 +2,9 @@ import {
|
|
|
2
2
|
PRICING_REFRESH_INTERVAL_MS,
|
|
3
3
|
refreshPricingFromModelsDev,
|
|
4
4
|
startPricingRefreshLoop
|
|
5
|
-
} from "./cli-
|
|
6
|
-
import"./cli-
|
|
7
|
-
import"./cli-
|
|
5
|
+
} from "./cli-7xx10h0a.js";
|
|
6
|
+
import"./cli-5m0qmvdp.js";
|
|
7
|
+
import"./cli-qgd4sqz5.js";
|
|
8
8
|
import"./cli-08b07b4r.js";
|
|
9
9
|
import"./cli-3apbzgyk.js";
|
|
10
10
|
import"./cli-e29gmdmw.js";
|
|
@@ -12,7 +12,7 @@ import"./cli-c2mk1kgf.js";
|
|
|
12
12
|
import"./cli-ej6gbxfb.js";
|
|
13
13
|
import"./cli-sd0mxa3c.js";
|
|
14
14
|
import"./cli-w5e1d1vv.js";
|
|
15
|
-
import"./cli-
|
|
15
|
+
import"./cli-e06a8a7y.js";
|
|
16
16
|
import"./cli-r2ap2czm.js";
|
|
17
17
|
import"./cli-zf8jjwex.js";
|
|
18
18
|
import"./cli-bc05qbss.js";
|
|
@@ -7,9 +7,9 @@ import {
|
|
|
7
7
|
getUserGrant,
|
|
8
8
|
listUserRoles,
|
|
9
9
|
runRbacCliCommand
|
|
10
|
-
} from "./cli-
|
|
10
|
+
} from "./cli-6skz3rk8.js";
|
|
11
11
|
import"./cli-cmp8g3sw.js";
|
|
12
|
-
import"./cli-
|
|
12
|
+
import"./cli-qgd4sqz5.js";
|
|
13
13
|
import"./cli-08b07b4r.js";
|
|
14
14
|
import"./cli-3apbzgyk.js";
|
|
15
15
|
import"./cli-e29gmdmw.js";
|
|
@@ -17,7 +17,7 @@ import"./cli-c2mk1kgf.js";
|
|
|
17
17
|
import"./cli-ej6gbxfb.js";
|
|
18
18
|
import"./cli-sd0mxa3c.js";
|
|
19
19
|
import"./cli-w5e1d1vv.js";
|
|
20
|
-
import"./cli-
|
|
20
|
+
import"./cli-e06a8a7y.js";
|
|
21
21
|
import"./cli-r2ap2czm.js";
|
|
22
22
|
import"./cli-zf8jjwex.js";
|
|
23
23
|
import"./cli-bc05qbss.js";
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
getDb,
|
|
6
6
|
getDbClient,
|
|
7
7
|
init_db
|
|
8
|
-
} from "./cli-
|
|
8
|
+
} from "./cli-qgd4sqz5.js";
|
|
9
9
|
import"./cli-08b07b4r.js";
|
|
10
10
|
import"./cli-3apbzgyk.js";
|
|
11
11
|
import"./cli-e29gmdmw.js";
|
|
@@ -13,7 +13,7 @@ import"./cli-c2mk1kgf.js";
|
|
|
13
13
|
import"./cli-ej6gbxfb.js";
|
|
14
14
|
import"./cli-sd0mxa3c.js";
|
|
15
15
|
import"./cli-w5e1d1vv.js";
|
|
16
|
-
import"./cli-
|
|
16
|
+
import"./cli-e06a8a7y.js";
|
|
17
17
|
import"./cli-r2ap2czm.js";
|
|
18
18
|
import"./cli-zf8jjwex.js";
|
|
19
19
|
import"./cli-bc05qbss.js";
|
|
@@ -9,11 +9,11 @@ import {
|
|
|
9
9
|
processSlackRenderV2,
|
|
10
10
|
renderThreadTree,
|
|
11
11
|
streamOutcomeCard
|
|
12
|
-
} from "./cli-
|
|
12
|
+
} from "./cli-3sysyjve.js";
|
|
13
13
|
import"./cli-q51yprfq.js";
|
|
14
14
|
import"./cli-9d8ntetj.js";
|
|
15
15
|
import"./cli-yatxqynm.js";
|
|
16
|
-
import"./cli-
|
|
16
|
+
import"./cli-qgd4sqz5.js";
|
|
17
17
|
import"./cli-08b07b4r.js";
|
|
18
18
|
import"./cli-3apbzgyk.js";
|
|
19
19
|
import"./cli-e29gmdmw.js";
|
|
@@ -21,7 +21,7 @@ import"./cli-c2mk1kgf.js";
|
|
|
21
21
|
import"./cli-ej6gbxfb.js";
|
|
22
22
|
import"./cli-sd0mxa3c.js";
|
|
23
23
|
import"./cli-w5e1d1vv.js";
|
|
24
|
-
import"./cli-
|
|
24
|
+
import"./cli-e06a8a7y.js";
|
|
25
25
|
import"./cli-r2ap2czm.js";
|
|
26
26
|
import"./cli-pzxba7gw.js";
|
|
27
27
|
import"./cli-zf8jjwex.js";
|
|
@@ -2,8 +2,8 @@ import {
|
|
|
2
2
|
buildModelsDevSeedRows,
|
|
3
3
|
buildPricingSeedRows,
|
|
4
4
|
seedPricingFromModelsDev
|
|
5
|
-
} from "./cli-
|
|
6
|
-
import"./cli-
|
|
5
|
+
} from "./cli-5m0qmvdp.js";
|
|
6
|
+
import"./cli-qgd4sqz5.js";
|
|
7
7
|
import"./cli-08b07b4r.js";
|
|
8
8
|
import"./cli-3apbzgyk.js";
|
|
9
9
|
import"./cli-e29gmdmw.js";
|
|
@@ -11,7 +11,7 @@ import"./cli-c2mk1kgf.js";
|
|
|
11
11
|
import"./cli-ej6gbxfb.js";
|
|
12
12
|
import"./cli-sd0mxa3c.js";
|
|
13
13
|
import"./cli-w5e1d1vv.js";
|
|
14
|
-
import"./cli-
|
|
14
|
+
import"./cli-e06a8a7y.js";
|
|
15
15
|
import"./cli-r2ap2czm.js";
|
|
16
16
|
import"./cli-zf8jjwex.js";
|
|
17
17
|
import"./cli-bc05qbss.js";
|
|
@@ -4,14 +4,14 @@ import {
|
|
|
4
4
|
createDefaultMcpJson,
|
|
5
5
|
createDefaultSettingsLocal,
|
|
6
6
|
createHooksConfig
|
|
7
|
-
} from "./cli-
|
|
7
|
+
} from "./cli-wby1xnnb.js";
|
|
8
8
|
import {
|
|
9
9
|
require_jsx_dev_runtime
|
|
10
10
|
} from "./cli-s2qjdd6z.js";
|
|
11
11
|
import {
|
|
12
12
|
getApiKey
|
|
13
13
|
} from "./cli-f14fvzag.js";
|
|
14
|
-
import"./cli-
|
|
14
|
+
import"./cli-e06a8a7y.js";
|
|
15
15
|
import {
|
|
16
16
|
Box_default,
|
|
17
17
|
Spinner,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import {
|
|
2
2
|
runAgent
|
|
3
|
-
} from "./cli-
|
|
3
|
+
} from "./cli-7evafqvy.js";
|
|
4
4
|
import"./cli-xm87hzbw.js";
|
|
5
|
-
import"./cli-
|
|
5
|
+
import"./cli-73gq0zxn.js";
|
|
6
6
|
import"./cli-6664w7y4.js";
|
|
7
7
|
import"./cli-hsxj0yar.js";
|
|
8
8
|
import"./cli-9b13ggd1.js";
|
|
@@ -12,11 +12,11 @@ import"./cli-r94z9p1z.js";
|
|
|
12
12
|
import"./cli-2djtr51b.js";
|
|
13
13
|
import {
|
|
14
14
|
getEnabledCapabilities
|
|
15
|
-
} from "./cli-
|
|
15
|
+
} from "./cli-cv7s5zdq.js";
|
|
16
16
|
import"./cli-0z2v4nhw.js";
|
|
17
17
|
import"./cli-j490egb5.js";
|
|
18
|
-
import"./cli-
|
|
19
|
-
import"./cli-
|
|
18
|
+
import"./cli-k351hv5k.js";
|
|
19
|
+
import"./cli-tg8qj8ee.js";
|
|
20
20
|
import"./cli-4wtq5jjv.js";
|
|
21
21
|
import"./cli-b5b30yzk.js";
|
|
22
22
|
import"./cli-jecc01cb.js";
|
|
@@ -27,40 +27,40 @@ import"./cli-s25avqg9.js";
|
|
|
27
27
|
import"./cli-eree7rnv.js";
|
|
28
28
|
import"./cli-xvkmedgn.js";
|
|
29
29
|
import"./cli-4yc5d8fk.js";
|
|
30
|
-
import"./cli-
|
|
31
|
-
import"./cli-
|
|
32
|
-
import"./cli-
|
|
33
|
-
import"./cli-
|
|
30
|
+
import"./cli-7fehefdf.js";
|
|
31
|
+
import"./cli-7xx10h0a.js";
|
|
32
|
+
import"./cli-5m0qmvdp.js";
|
|
33
|
+
import"./cli-6skz3rk8.js";
|
|
34
34
|
import"./cli-cmp8g3sw.js";
|
|
35
|
-
import"./cli-
|
|
35
|
+
import"./cli-hzqmgcm2.js";
|
|
36
36
|
import"./cli-qgm2pfpq.js";
|
|
37
|
-
import"./cli-
|
|
37
|
+
import"./cli-y3pq4v9g.js";
|
|
38
38
|
import"./cli-07jd68a1.js";
|
|
39
|
-
import"./cli-
|
|
39
|
+
import"./cli-ddfw1mc4.js";
|
|
40
40
|
import"./cli-1ebpar1q.js";
|
|
41
41
|
import"./cli-e7d20cty.js";
|
|
42
42
|
import"./cli-3dpj7atn.js";
|
|
43
|
-
import"./cli-
|
|
43
|
+
import"./cli-svbrpf5q.js";
|
|
44
44
|
import"./cli-epan13p1.js";
|
|
45
|
-
import"./cli-
|
|
46
|
-
import"./cli-
|
|
45
|
+
import"./cli-3z634pqe.js";
|
|
46
|
+
import"./cli-jezx9b9c.js";
|
|
47
47
|
import"./cli-y89t4nca.js";
|
|
48
48
|
import"./cli-f14fvzag.js";
|
|
49
49
|
import"./cli-zvz62chv.js";
|
|
50
|
-
import"./cli-
|
|
50
|
+
import"./cli-cd60fv6j.js";
|
|
51
51
|
import"./cli-fad8m16k.js";
|
|
52
52
|
import"./cli-aehm1rbq.js";
|
|
53
53
|
import"./cli-bsakbbkm.js";
|
|
54
54
|
import"./cli-51tf7ac3.js";
|
|
55
|
-
import"./cli-
|
|
55
|
+
import"./cli-sdzq01t9.js";
|
|
56
56
|
import"./cli-jsp14b6c.js";
|
|
57
|
-
import"./cli-
|
|
58
|
-
import"./cli-
|
|
59
|
-
import"./cli-
|
|
57
|
+
import"./cli-j4d4f6hv.js";
|
|
58
|
+
import"./cli-ayvy5kde.js";
|
|
59
|
+
import"./cli-3sysyjve.js";
|
|
60
60
|
import"./cli-q51yprfq.js";
|
|
61
61
|
import"./cli-9d8ntetj.js";
|
|
62
62
|
import"./cli-yatxqynm.js";
|
|
63
|
-
import"./cli-
|
|
63
|
+
import"./cli-qgd4sqz5.js";
|
|
64
64
|
import"./cli-08b07b4r.js";
|
|
65
65
|
import"./cli-3apbzgyk.js";
|
|
66
66
|
import"./cli-e29gmdmw.js";
|
|
@@ -68,7 +68,7 @@ import"./cli-c2mk1kgf.js";
|
|
|
68
68
|
import"./cli-ej6gbxfb.js";
|
|
69
69
|
import"./cli-sd0mxa3c.js";
|
|
70
70
|
import"./cli-w5e1d1vv.js";
|
|
71
|
-
import"./cli-
|
|
71
|
+
import"./cli-e06a8a7y.js";
|
|
72
72
|
import"./cli-r2ap2czm.js";
|
|
73
73
|
import"./cli-pzxba7gw.js";
|
|
74
74
|
import"./cli-f7kvq46p.js";
|
package/openapi.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"openapi": "3.1.0",
|
|
3
3
|
"info": {
|
|
4
4
|
"title": "Agent Swarm API",
|
|
5
|
-
"version": "1.149.
|
|
5
|
+
"version": "1.149.1",
|
|
6
6
|
"description": "Multi-agent orchestration API for Claude Code, Codex, and Gemini CLI. Enables task distribution, agent communication, and service discovery.\n\nMCP tools are documented separately in [MCP.md](./MCP.md)."
|
|
7
7
|
},
|
|
8
8
|
"servers": [
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@desplega.ai/agent-swarm",
|
|
3
|
-
"version": "1.149.
|
|
3
|
+
"version": "1.149.1",
|
|
4
4
|
"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.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"agent-swarm.dev",
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared "arrive enabled" policy for seeded workflows and schedules.
|
|
3
|
+
*
|
|
4
|
+
* Boot seeding always inventories every candidate automation (see
|
|
5
|
+
* {@link ./workflows-seeder} / {@link ./schedules-seeder}). Whether a freshly
|
|
6
|
+
* created item also arrives *enabled* is governed by four independent gates,
|
|
7
|
+
* all of which must pass:
|
|
8
|
+
*
|
|
9
|
+
* 1. The operator switch (`SEED_AUTOMATIONS_ENABLED`) is on.
|
|
10
|
+
* 2. The item is zero-config: no required integration (`requires`) and no
|
|
11
|
+
* required param/placeholder. An item needing a credential or a param it
|
|
12
|
+
* doesn't have would just fail on a stranger's cluster.
|
|
13
|
+
* 3. The template's own `config.json` explicitly opts in via
|
|
14
|
+
* `autoEnableCandidate: true`. This is a deliberate, reviewed
|
|
15
|
+
* declaration on each template — a new zero-config template does NOT
|
|
16
|
+
* auto-activate just by omitting `requires`/`placeholders`; an author
|
|
17
|
+
* has to add this field, which is a visible line in the PR that adds
|
|
18
|
+
* the template.
|
|
19
|
+
* 4. The template's JSON payload doesn't recommend staying off (its
|
|
20
|
+
* `enabled` field is not explicitly `false`) — a secondary safety valve
|
|
21
|
+
* an operator or template author can still pull even on an opted-in
|
|
22
|
+
* template.
|
|
23
|
+
*
|
|
24
|
+
* An item that fails any gate stays disabled and inventoried, exactly as
|
|
25
|
+
* before this switch existed.
|
|
26
|
+
*/
|
|
27
|
+
|
|
28
|
+
import type { AutomationIntegrationId } from "../../types";
|
|
29
|
+
|
|
30
|
+
const SEED_AUTOMATIONS_ENABLED_ENV = "SEED_AUTOMATIONS_ENABLED";
|
|
31
|
+
|
|
32
|
+
// Flip this to change the shipped default for every install path (Helm,
|
|
33
|
+
// docker-compose, bare `bun run start:http`) in one place. The Helm chart's
|
|
34
|
+
// `config.seedAutomationsEnabled` default should track this value.
|
|
35
|
+
const SEED_AUTOMATIONS_ENABLED_DEFAULT = true;
|
|
36
|
+
|
|
37
|
+
/** Gate 1: is the operator switch on? Env var wins; unset falls back to the shipped default. */
|
|
38
|
+
export function isSeedAutomationsEnabled(env: NodeJS.ProcessEnv = process.env): boolean {
|
|
39
|
+
const raw = env[SEED_AUTOMATIONS_ENABLED_ENV];
|
|
40
|
+
if (raw === undefined || raw === "") return SEED_AUTOMATIONS_ENABLED_DEFAULT;
|
|
41
|
+
return raw.toLowerCase() === "true" || raw === "1";
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
/** Gate 2: no required integration and no required param/placeholder. */
|
|
45
|
+
export function isZeroConfigAutomation(
|
|
46
|
+
requires: readonly AutomationIntegrationId[],
|
|
47
|
+
requiredParams: readonly string[],
|
|
48
|
+
): boolean {
|
|
49
|
+
return requires.length === 0 && requiredParams.length === 0;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* Combine all four gates into the `enabled` value a seeded item should be
|
|
54
|
+
* created/updated with.
|
|
55
|
+
*/
|
|
56
|
+
export function resolveSeededEnabled(params: {
|
|
57
|
+
requires: readonly AutomationIntegrationId[];
|
|
58
|
+
requiredParams: readonly string[];
|
|
59
|
+
autoEnableCandidate: boolean;
|
|
60
|
+
templateRecommendsEnabled: boolean;
|
|
61
|
+
env?: NodeJS.ProcessEnv;
|
|
62
|
+
}): boolean {
|
|
63
|
+
return (
|
|
64
|
+
isSeedAutomationsEnabled(params.env) &&
|
|
65
|
+
isZeroConfigAutomation(params.requires, params.requiredParams) &&
|
|
66
|
+
params.autoEnableCandidate &&
|
|
67
|
+
params.templateRecommendsEnabled
|
|
68
|
+
);
|
|
69
|
+
}
|
|
@@ -17,6 +17,12 @@ import dailyStatusReportConfig from "../../../templates/schedules/daily-status-r
|
|
|
17
17
|
import dailyStatusReportContent from "../../../templates/schedules/daily-status-report/content.md" with {
|
|
18
18
|
type: "text",
|
|
19
19
|
};
|
|
20
|
+
import dailySwarmUpdateCheckConfig from "../../../templates/schedules/daily-swarm-update-check/config.json" with {
|
|
21
|
+
type: "text",
|
|
22
|
+
};
|
|
23
|
+
import dailySwarmUpdateCheckContent from "../../../templates/schedules/daily-swarm-update-check/content.md" with {
|
|
24
|
+
type: "text",
|
|
25
|
+
};
|
|
20
26
|
import dailyWorkflowHealthAuditConfig from "../../../templates/schedules/daily-workflow-health-audit/config.json" with {
|
|
21
27
|
type: "text",
|
|
22
28
|
};
|
|
@@ -54,6 +60,7 @@ import {
|
|
|
54
60
|
getScheduledTaskByName,
|
|
55
61
|
updateScheduledTask,
|
|
56
62
|
} from "../db";
|
|
63
|
+
import { resolveSeededEnabled } from "./automation-toggle";
|
|
57
64
|
import type { Seeder, SeedItem } from "./types";
|
|
58
65
|
import { canonicalJson } from "./workflows-seeder";
|
|
59
66
|
|
|
@@ -64,6 +71,8 @@ type ScheduleTemplateConfig = {
|
|
|
64
71
|
placeholders?: string[];
|
|
65
72
|
requires?: AutomationIntegrationId[];
|
|
66
73
|
runAllSeedersCandidate?: boolean;
|
|
74
|
+
/** Explicit, reviewed opt-in into the auto-enable policy — see ./automation-toggle. */
|
|
75
|
+
autoEnableCandidate?: boolean;
|
|
67
76
|
tags?: string[];
|
|
68
77
|
};
|
|
69
78
|
|
|
@@ -99,6 +108,10 @@ const BUILT_IN_SCHEDULE_SOURCES: readonly ScheduleTemplateSource[] = [
|
|
|
99
108
|
content: asText(dailyCompoundingReflectionContent),
|
|
100
109
|
},
|
|
101
110
|
{ config: asText(dailyStatusReportConfig), content: asText(dailyStatusReportContent) },
|
|
111
|
+
{
|
|
112
|
+
config: asText(dailySwarmUpdateCheckConfig),
|
|
113
|
+
content: asText(dailySwarmUpdateCheckContent),
|
|
114
|
+
},
|
|
102
115
|
{
|
|
103
116
|
config: asText(dailyWorkflowHealthAuditConfig),
|
|
104
117
|
content: asText(dailyWorkflowHealthAuditContent),
|
|
@@ -134,21 +147,30 @@ function parseScheduleSource(source: ScheduleTemplateSource): SeedSchedule | nul
|
|
|
134
147
|
.trim();
|
|
135
148
|
if (!taskTemplate) throw new Error(`Schedule template ${config.name} has no task prompt`);
|
|
136
149
|
|
|
150
|
+
const requires = config.requires ?? [];
|
|
151
|
+
const requiredParams = config.placeholders ?? [];
|
|
137
152
|
return {
|
|
138
153
|
name: config.name,
|
|
139
154
|
description: config.description,
|
|
140
155
|
cronExpression: block.cron,
|
|
141
156
|
timezone: block.timezone ?? "UTC",
|
|
142
|
-
// Boot seeding inventories the automation
|
|
143
|
-
//
|
|
144
|
-
//
|
|
145
|
-
|
|
157
|
+
// Boot seeding always inventories the automation. Whether it also arrives
|
|
158
|
+
// enabled is gated by the operator switch (SEED_AUTOMATIONS_ENABLED), the
|
|
159
|
+
// item being zero-config (no requires/placeholders), the template's own
|
|
160
|
+
// explicit autoEnableCandidate opt-in, and the template not explicitly
|
|
161
|
+
// recommending it stay off. See ./automation-toggle.
|
|
162
|
+
enabled: resolveSeededEnabled({
|
|
163
|
+
requires,
|
|
164
|
+
requiredParams,
|
|
165
|
+
autoEnableCandidate: config.autoEnableCandidate === true,
|
|
166
|
+
templateRecommendsEnabled: block.enabled !== false,
|
|
167
|
+
}),
|
|
146
168
|
taskTemplate,
|
|
147
169
|
taskType: config.title,
|
|
148
170
|
tags: config.tags ?? [],
|
|
149
171
|
params: {},
|
|
150
|
-
requiredParams
|
|
151
|
-
requires
|
|
172
|
+
requiredParams,
|
|
173
|
+
requires,
|
|
152
174
|
};
|
|
153
175
|
}
|
|
154
176
|
|
|
@@ -56,6 +56,7 @@ import type {
|
|
|
56
56
|
} from "../../types";
|
|
57
57
|
import { validateDefinition } from "../../workflows/definition";
|
|
58
58
|
import { computeContentHash, createWorkflow, listWorkflows, updateWorkflow } from "../db";
|
|
59
|
+
import { resolveSeededEnabled } from "./automation-toggle";
|
|
59
60
|
import type { Seeder, SeedItem } from "./types";
|
|
60
61
|
|
|
61
62
|
type AutomationTemplateConfig = {
|
|
@@ -64,6 +65,8 @@ type AutomationTemplateConfig = {
|
|
|
64
65
|
placeholders?: string[];
|
|
65
66
|
requires?: AutomationIntegrationId[];
|
|
66
67
|
runAllSeedersCandidate?: boolean;
|
|
68
|
+
/** Explicit, reviewed opt-in into the auto-enable policy — see ./automation-toggle. */
|
|
69
|
+
autoEnableCandidate?: boolean;
|
|
67
70
|
};
|
|
68
71
|
|
|
69
72
|
type WorkflowTemplatePayload = {
|
|
@@ -130,13 +133,22 @@ function parseWorkflowSource(source: WorkflowTemplateSource): SeedWorkflow | nul
|
|
|
130
133
|
if (!match?.[1]) throw new Error(`Workflow template ${config.name} has no JSON definition`);
|
|
131
134
|
const payload = JSON.parse(match[1]) as WorkflowTemplatePayload;
|
|
132
135
|
|
|
136
|
+
const requires = config.requires ?? [];
|
|
137
|
+
const requiredParams = config.placeholders ?? [];
|
|
133
138
|
return {
|
|
134
139
|
name: config.name,
|
|
135
140
|
description: config.description,
|
|
136
|
-
// Boot seeding inventories the automation
|
|
137
|
-
//
|
|
138
|
-
//
|
|
139
|
-
|
|
141
|
+
// Boot seeding always inventories the automation. Whether it also arrives
|
|
142
|
+
// enabled is gated by the operator switch (SEED_AUTOMATIONS_ENABLED), the
|
|
143
|
+
// item being zero-config (no requires/placeholders), the template's own
|
|
144
|
+
// explicit autoEnableCandidate opt-in, and the template not explicitly
|
|
145
|
+
// recommending it stay off. See ./automation-toggle.
|
|
146
|
+
enabled: resolveSeededEnabled({
|
|
147
|
+
requires,
|
|
148
|
+
requiredParams,
|
|
149
|
+
autoEnableCandidate: config.autoEnableCandidate === true,
|
|
150
|
+
templateRecommendsEnabled: payload.enabled !== false,
|
|
151
|
+
}),
|
|
140
152
|
definition: {
|
|
141
153
|
nodes: payload.nodes,
|
|
142
154
|
onNodeFailure: payload.onNodeFailure ?? "fail",
|
|
@@ -146,8 +158,8 @@ function parseWorkflowSource(source: WorkflowTemplateSource): SeedWorkflow | nul
|
|
|
146
158
|
input: payload.input,
|
|
147
159
|
triggerSchema: payload.triggerSchema,
|
|
148
160
|
params: {},
|
|
149
|
-
requiredParams
|
|
150
|
-
requires
|
|
161
|
+
requiredParams,
|
|
162
|
+
requires,
|
|
151
163
|
};
|
|
152
164
|
}
|
|
153
165
|
|
|
@@ -274,6 +274,7 @@ const VALIDATED_KEYS: Record<string, ConfigValidator> = {
|
|
|
274
274
|
"ADDITIVE_SLACK",
|
|
275
275
|
"SLACK_THREAD_FOLLOWUP_REQUIRE_MENTION",
|
|
276
276
|
"RBAC_ENABLED",
|
|
277
|
+
"SEED_AUTOMATIONS_ENABLED",
|
|
277
278
|
"RBAC_AUDIT_DISABLED",
|
|
278
279
|
"BUDGET_ADMISSION_DISABLED",
|
|
279
280
|
"MCP_OAUTH_ALLOW_PRIVATE_HOSTS",
|
|
@@ -40,7 +40,7 @@ describe("seeder registry", () => {
|
|
|
40
40
|
|
|
41
41
|
test("the built-in catalogs expose the expected candidate counts", () => {
|
|
42
42
|
expect(workflowsSeeder.items()).toHaveLength(5);
|
|
43
|
-
expect(schedulesSeeder.items()).toHaveLength(
|
|
43
|
+
expect(schedulesSeeder.items()).toHaveLength(5);
|
|
44
44
|
});
|
|
45
45
|
|
|
46
46
|
test("seeds all starter workflow and schedule rows on a fresh database", async () => {
|
|
@@ -48,7 +48,7 @@ describe("seeder registry", () => {
|
|
|
48
48
|
const scheduleResult = await runSeeder(schedulesSeeder, { quiet: true });
|
|
49
49
|
|
|
50
50
|
expect(workflowResult).toMatchObject({ created: 5, failed: [] });
|
|
51
|
-
expect(scheduleResult).toMatchObject({ created:
|
|
51
|
+
expect(scheduleResult).toMatchObject({ created: 5, failed: [] });
|
|
52
52
|
expect(await listWorkflows()).toHaveLength(5);
|
|
53
53
|
});
|
|
54
54
|
});
|