@desplega.ai/agent-swarm 1.75.0 → 1.76.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/README.md +1 -1
- package/openapi.json +973 -36
- package/package.json +2 -2
- package/src/be/db.ts +527 -9
- package/src/be/memory/providers/openai-embedding.ts +17 -5
- package/src/be/memory/raters/llm-summarizer.ts +218 -0
- package/src/be/memory/raters/llm.ts +56 -75
- package/src/be/memory/retrieval-store.ts +21 -0
- package/src/be/migrations/054_agent_harness_provider.sql +21 -0
- package/src/be/migrations/055_agent_cred_status.sql +15 -0
- package/src/be/migrations/056_drop_agent_tasks_source_check.sql +139 -0
- package/src/be/migrations/057_inbox_item_state.sql +27 -0
- package/src/be/migrations/058_task_templates.sql +31 -0
- package/src/be/swarm-config-guard.ts +24 -0
- package/src/commands/credential-wait.ts +1 -1
- package/src/commands/provider-credentials.ts +434 -0
- package/src/commands/runner.ts +229 -42
- package/src/hooks/hook.ts +115 -95
- package/src/http/agents.ts +82 -2
- package/src/http/config.ts +11 -1
- package/src/http/inbox-state.ts +89 -0
- package/src/http/index.ts +10 -0
- package/src/http/sessions.ts +86 -0
- package/src/http/status.ts +665 -0
- package/src/http/task-templates.ts +51 -0
- package/src/http/tasks.ts +85 -5
- package/src/http/users.ts +134 -0
- package/src/providers/claude-adapter.ts +5 -0
- package/src/providers/codex-adapter.ts +1 -1
- package/src/providers/index.ts +1 -1
- package/src/slack/handlers.ts +0 -1
- package/src/tests/agents-harness-provider.test.ts +333 -0
- package/src/tests/credential-check.test.ts +32 -1
- package/src/tests/credential-status-api.test.ts +42 -0
- package/src/tests/harness-provider-resolution.test.ts +242 -0
- package/src/tests/jira-sync.test.ts +1 -1
- package/src/tests/memory-rater-llm-summarizer.test.ts +317 -0
- package/src/tests/memory-rater-llm.test.ts +265 -107
- package/src/tests/migration-runner-regressions.test.ts +17 -2
- package/src/tests/sessions.test.ts +141 -0
- package/src/tests/status.test.ts +843 -0
- package/src/tests/stop-hook-task-resolution.test.ts +98 -0
- package/src/tests/template-recommendations.test.ts +148 -0
- package/src/tests/use-dismissible-card.test.ts +140 -0
- package/src/tools/swarm-config/set-config.ts +17 -1
- package/src/types.ts +117 -0
- package/src/utils/harness-provider.ts +32 -0
- package/tsconfig.json +0 -2
- package/src/providers/credentials.ts +0 -74
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.
|
|
5
|
+
"version": "1.76.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": [
|
|
@@ -326,6 +326,17 @@
|
|
|
326
326
|
"claude-managed",
|
|
327
327
|
"opencode"
|
|
328
328
|
]
|
|
329
|
+
},
|
|
330
|
+
"harness_provider": {
|
|
331
|
+
"type": "string",
|
|
332
|
+
"enum": [
|
|
333
|
+
"claude",
|
|
334
|
+
"codex",
|
|
335
|
+
"pi",
|
|
336
|
+
"devin",
|
|
337
|
+
"claude-managed",
|
|
338
|
+
"opencode"
|
|
339
|
+
]
|
|
329
340
|
}
|
|
330
341
|
},
|
|
331
342
|
"required": [
|
|
@@ -377,6 +388,66 @@
|
|
|
377
388
|
}
|
|
378
389
|
}
|
|
379
390
|
},
|
|
391
|
+
"/api/agents/{id}/harness-provider": {
|
|
392
|
+
"patch": {
|
|
393
|
+
"summary": "Re-assign an agent's harness_provider (live)",
|
|
394
|
+
"description": "Updates `agents.harness_provider` and upserts `swarm_config` (scope=agent, key=HARNESS_PROVIDER) so the worker's poll-loop reconciliation picks up the new provider within ~10s. No restart required. The swarm_config row is what actually drives the worker; the column mirrors the latest set value for dashboards.",
|
|
395
|
+
"tags": [
|
|
396
|
+
"Agents"
|
|
397
|
+
],
|
|
398
|
+
"security": [
|
|
399
|
+
{
|
|
400
|
+
"bearerAuth": []
|
|
401
|
+
}
|
|
402
|
+
],
|
|
403
|
+
"parameters": [
|
|
404
|
+
{
|
|
405
|
+
"schema": {
|
|
406
|
+
"type": "string"
|
|
407
|
+
},
|
|
408
|
+
"required": true,
|
|
409
|
+
"name": "id",
|
|
410
|
+
"in": "path"
|
|
411
|
+
}
|
|
412
|
+
],
|
|
413
|
+
"requestBody": {
|
|
414
|
+
"content": {
|
|
415
|
+
"application/json": {
|
|
416
|
+
"schema": {
|
|
417
|
+
"type": "object",
|
|
418
|
+
"properties": {
|
|
419
|
+
"harness_provider": {
|
|
420
|
+
"type": "string",
|
|
421
|
+
"enum": [
|
|
422
|
+
"claude",
|
|
423
|
+
"codex",
|
|
424
|
+
"pi",
|
|
425
|
+
"devin",
|
|
426
|
+
"claude-managed",
|
|
427
|
+
"opencode"
|
|
428
|
+
]
|
|
429
|
+
}
|
|
430
|
+
},
|
|
431
|
+
"required": [
|
|
432
|
+
"harness_provider"
|
|
433
|
+
]
|
|
434
|
+
}
|
|
435
|
+
}
|
|
436
|
+
}
|
|
437
|
+
},
|
|
438
|
+
"responses": {
|
|
439
|
+
"200": {
|
|
440
|
+
"description": "Updated agent row"
|
|
441
|
+
},
|
|
442
|
+
"400": {
|
|
443
|
+
"description": "Validation error (unknown provider)"
|
|
444
|
+
},
|
|
445
|
+
"404": {
|
|
446
|
+
"description": "Agent not found"
|
|
447
|
+
}
|
|
448
|
+
}
|
|
449
|
+
}
|
|
450
|
+
},
|
|
380
451
|
"/api/agents/{id}/name": {
|
|
381
452
|
"put": {
|
|
382
453
|
"summary": "Update agent name",
|
|
@@ -659,6 +730,89 @@
|
|
|
659
730
|
"items": {
|
|
660
731
|
"type": "string"
|
|
661
732
|
}
|
|
733
|
+
},
|
|
734
|
+
"cred_status": {
|
|
735
|
+
"type": [
|
|
736
|
+
"object",
|
|
737
|
+
"null"
|
|
738
|
+
],
|
|
739
|
+
"properties": {
|
|
740
|
+
"ready": {
|
|
741
|
+
"type": "boolean"
|
|
742
|
+
},
|
|
743
|
+
"missing": {
|
|
744
|
+
"type": "array",
|
|
745
|
+
"items": {
|
|
746
|
+
"type": "string"
|
|
747
|
+
},
|
|
748
|
+
"default": []
|
|
749
|
+
},
|
|
750
|
+
"satisfiedBy": {
|
|
751
|
+
"type": [
|
|
752
|
+
"string",
|
|
753
|
+
"null"
|
|
754
|
+
],
|
|
755
|
+
"enum": [
|
|
756
|
+
"env",
|
|
757
|
+
"file",
|
|
758
|
+
"side-effect-pending",
|
|
759
|
+
null
|
|
760
|
+
],
|
|
761
|
+
"default": null
|
|
762
|
+
},
|
|
763
|
+
"hint": {
|
|
764
|
+
"type": [
|
|
765
|
+
"string",
|
|
766
|
+
"null"
|
|
767
|
+
],
|
|
768
|
+
"default": null
|
|
769
|
+
},
|
|
770
|
+
"liveTest": {
|
|
771
|
+
"type": [
|
|
772
|
+
"object",
|
|
773
|
+
"null"
|
|
774
|
+
],
|
|
775
|
+
"properties": {
|
|
776
|
+
"ok": {
|
|
777
|
+
"type": "boolean"
|
|
778
|
+
},
|
|
779
|
+
"error": {
|
|
780
|
+
"type": [
|
|
781
|
+
"string",
|
|
782
|
+
"null"
|
|
783
|
+
],
|
|
784
|
+
"default": null
|
|
785
|
+
},
|
|
786
|
+
"latency_ms": {
|
|
787
|
+
"type": "number"
|
|
788
|
+
},
|
|
789
|
+
"testedAt": {
|
|
790
|
+
"type": "number"
|
|
791
|
+
}
|
|
792
|
+
},
|
|
793
|
+
"default": null,
|
|
794
|
+
"required": [
|
|
795
|
+
"ok",
|
|
796
|
+
"latency_ms",
|
|
797
|
+
"testedAt"
|
|
798
|
+
]
|
|
799
|
+
},
|
|
800
|
+
"reportedAt": {
|
|
801
|
+
"type": "number"
|
|
802
|
+
},
|
|
803
|
+
"reportKind": {
|
|
804
|
+
"type": "string",
|
|
805
|
+
"enum": [
|
|
806
|
+
"boot",
|
|
807
|
+
"post_task"
|
|
808
|
+
],
|
|
809
|
+
"default": "boot"
|
|
810
|
+
}
|
|
811
|
+
},
|
|
812
|
+
"required": [
|
|
813
|
+
"ready",
|
|
814
|
+
"reportedAt"
|
|
815
|
+
]
|
|
662
816
|
}
|
|
663
817
|
},
|
|
664
818
|
"required": [
|
|
@@ -2852,6 +3006,138 @@
|
|
|
2852
3006
|
}
|
|
2853
3007
|
}
|
|
2854
3008
|
},
|
|
3009
|
+
"/api/inbox-state": {
|
|
3010
|
+
"get": {
|
|
3011
|
+
"summary": "List inbox-item state rows for a user",
|
|
3012
|
+
"tags": [
|
|
3013
|
+
"Inbox State"
|
|
3014
|
+
],
|
|
3015
|
+
"security": [
|
|
3016
|
+
{
|
|
3017
|
+
"bearerAuth": []
|
|
3018
|
+
}
|
|
3019
|
+
],
|
|
3020
|
+
"parameters": [
|
|
3021
|
+
{
|
|
3022
|
+
"schema": {
|
|
3023
|
+
"type": "string"
|
|
3024
|
+
},
|
|
3025
|
+
"required": true,
|
|
3026
|
+
"name": "userId",
|
|
3027
|
+
"in": "query"
|
|
3028
|
+
},
|
|
3029
|
+
{
|
|
3030
|
+
"schema": {
|
|
3031
|
+
"type": "string",
|
|
3032
|
+
"enum": [
|
|
3033
|
+
"open",
|
|
3034
|
+
"snoozed",
|
|
3035
|
+
"dismissed",
|
|
3036
|
+
"done"
|
|
3037
|
+
]
|
|
3038
|
+
},
|
|
3039
|
+
"required": false,
|
|
3040
|
+
"name": "status",
|
|
3041
|
+
"in": "query"
|
|
3042
|
+
},
|
|
3043
|
+
{
|
|
3044
|
+
"schema": {
|
|
3045
|
+
"type": "string",
|
|
3046
|
+
"enum": [
|
|
3047
|
+
"approval",
|
|
3048
|
+
"credential_missing",
|
|
3049
|
+
"broken_task",
|
|
3050
|
+
"to_read",
|
|
3051
|
+
"to_start_template"
|
|
3052
|
+
]
|
|
3053
|
+
},
|
|
3054
|
+
"required": false,
|
|
3055
|
+
"name": "itemType",
|
|
3056
|
+
"in": "query"
|
|
3057
|
+
}
|
|
3058
|
+
],
|
|
3059
|
+
"responses": {
|
|
3060
|
+
"200": {
|
|
3061
|
+
"description": "Inbox state rows"
|
|
3062
|
+
},
|
|
3063
|
+
"400": {
|
|
3064
|
+
"description": "Validation error"
|
|
3065
|
+
},
|
|
3066
|
+
"401": {
|
|
3067
|
+
"description": "Unauthorized"
|
|
3068
|
+
}
|
|
3069
|
+
}
|
|
3070
|
+
},
|
|
3071
|
+
"patch": {
|
|
3072
|
+
"summary": "Upsert per-user dismiss/snooze/done state for an inbox item",
|
|
3073
|
+
"tags": [
|
|
3074
|
+
"Inbox State"
|
|
3075
|
+
],
|
|
3076
|
+
"security": [
|
|
3077
|
+
{
|
|
3078
|
+
"bearerAuth": []
|
|
3079
|
+
}
|
|
3080
|
+
],
|
|
3081
|
+
"requestBody": {
|
|
3082
|
+
"content": {
|
|
3083
|
+
"application/json": {
|
|
3084
|
+
"schema": {
|
|
3085
|
+
"type": "object",
|
|
3086
|
+
"properties": {
|
|
3087
|
+
"userId": {
|
|
3088
|
+
"type": "string"
|
|
3089
|
+
},
|
|
3090
|
+
"itemType": {
|
|
3091
|
+
"type": "string",
|
|
3092
|
+
"enum": [
|
|
3093
|
+
"approval",
|
|
3094
|
+
"credential_missing",
|
|
3095
|
+
"broken_task",
|
|
3096
|
+
"to_read",
|
|
3097
|
+
"to_start_template"
|
|
3098
|
+
]
|
|
3099
|
+
},
|
|
3100
|
+
"itemId": {
|
|
3101
|
+
"type": "string",
|
|
3102
|
+
"minLength": 1
|
|
3103
|
+
},
|
|
3104
|
+
"status": {
|
|
3105
|
+
"type": "string",
|
|
3106
|
+
"enum": [
|
|
3107
|
+
"open",
|
|
3108
|
+
"snoozed",
|
|
3109
|
+
"dismissed",
|
|
3110
|
+
"done"
|
|
3111
|
+
]
|
|
3112
|
+
},
|
|
3113
|
+
"snoozeUntil": {
|
|
3114
|
+
"type": "string",
|
|
3115
|
+
"format": "date-time"
|
|
3116
|
+
}
|
|
3117
|
+
},
|
|
3118
|
+
"required": [
|
|
3119
|
+
"userId",
|
|
3120
|
+
"itemType",
|
|
3121
|
+
"itemId",
|
|
3122
|
+
"status"
|
|
3123
|
+
]
|
|
3124
|
+
}
|
|
3125
|
+
}
|
|
3126
|
+
}
|
|
3127
|
+
},
|
|
3128
|
+
"responses": {
|
|
3129
|
+
"200": {
|
|
3130
|
+
"description": "Upserted inbox state row"
|
|
3131
|
+
},
|
|
3132
|
+
"400": {
|
|
3133
|
+
"description": "Validation error"
|
|
3134
|
+
},
|
|
3135
|
+
"401": {
|
|
3136
|
+
"description": "Unauthorized"
|
|
3137
|
+
}
|
|
3138
|
+
}
|
|
3139
|
+
}
|
|
3140
|
+
},
|
|
2855
3141
|
"/api/integrations/claude-managed/test": {
|
|
2856
3142
|
"post": {
|
|
2857
3143
|
"summary": "Test the claude-managed integration: resolves ANTHROPIC_API_KEY + MANAGED_AGENT_ID from swarm_config and calls beta.agents.retrieve.",
|
|
@@ -5584,11 +5870,11 @@
|
|
|
5584
5870
|
}
|
|
5585
5871
|
}
|
|
5586
5872
|
},
|
|
5587
|
-
"/api/
|
|
5873
|
+
"/api/sessions": {
|
|
5588
5874
|
"get": {
|
|
5589
|
-
"summary": "List
|
|
5875
|
+
"summary": "List recent task sessions (root tasks + chain summary)",
|
|
5590
5876
|
"tags": [
|
|
5591
|
-
"
|
|
5877
|
+
"Sessions"
|
|
5592
5878
|
],
|
|
5593
5879
|
"security": [
|
|
5594
5880
|
{
|
|
@@ -5598,26 +5884,24 @@
|
|
|
5598
5884
|
"parameters": [
|
|
5599
5885
|
{
|
|
5600
5886
|
"schema": {
|
|
5601
|
-
"type":
|
|
5602
|
-
|
|
5603
|
-
|
|
5604
|
-
|
|
5605
|
-
"in": "query"
|
|
5606
|
-
},
|
|
5607
|
-
{
|
|
5608
|
-
"schema": {
|
|
5609
|
-
"type": "string"
|
|
5887
|
+
"type": [
|
|
5888
|
+
"integer",
|
|
5889
|
+
"null"
|
|
5890
|
+
]
|
|
5610
5891
|
},
|
|
5611
5892
|
"required": false,
|
|
5612
|
-
"name": "
|
|
5893
|
+
"name": "limit",
|
|
5613
5894
|
"in": "query"
|
|
5614
5895
|
},
|
|
5615
5896
|
{
|
|
5616
5897
|
"schema": {
|
|
5617
|
-
"type":
|
|
5898
|
+
"type": [
|
|
5899
|
+
"integer",
|
|
5900
|
+
"null"
|
|
5901
|
+
]
|
|
5618
5902
|
},
|
|
5619
5903
|
"required": false,
|
|
5620
|
-
"name": "
|
|
5904
|
+
"name": "offset",
|
|
5621
5905
|
"in": "query"
|
|
5622
5906
|
},
|
|
5623
5907
|
{
|
|
@@ -5625,7 +5909,7 @@
|
|
|
5625
5909
|
"type": "string"
|
|
5626
5910
|
},
|
|
5627
5911
|
"required": false,
|
|
5628
|
-
"name": "
|
|
5912
|
+
"name": "source",
|
|
5629
5913
|
"in": "query"
|
|
5630
5914
|
},
|
|
5631
5915
|
{
|
|
@@ -5633,38 +5917,135 @@
|
|
|
5633
5917
|
"type": "string"
|
|
5634
5918
|
},
|
|
5635
5919
|
"required": false,
|
|
5636
|
-
"name": "
|
|
5920
|
+
"name": "q",
|
|
5637
5921
|
"in": "query"
|
|
5638
5922
|
}
|
|
5639
5923
|
],
|
|
5640
5924
|
"responses": {
|
|
5641
5925
|
"200": {
|
|
5642
|
-
"description": "
|
|
5926
|
+
"description": "Recent sessions ordered by chain-wide last activity"
|
|
5927
|
+
},
|
|
5928
|
+
"401": {
|
|
5929
|
+
"description": "Unauthorized"
|
|
5643
5930
|
}
|
|
5644
5931
|
}
|
|
5645
|
-
}
|
|
5646
|
-
|
|
5647
|
-
|
|
5932
|
+
}
|
|
5933
|
+
},
|
|
5934
|
+
"/api/sessions/{rootTaskId}": {
|
|
5935
|
+
"get": {
|
|
5936
|
+
"summary": "Get a session — root task + the entire descendant chain",
|
|
5648
5937
|
"tags": [
|
|
5649
|
-
"
|
|
5938
|
+
"Sessions"
|
|
5650
5939
|
],
|
|
5651
5940
|
"security": [
|
|
5652
5941
|
{
|
|
5653
5942
|
"bearerAuth": []
|
|
5654
5943
|
}
|
|
5655
5944
|
],
|
|
5656
|
-
"
|
|
5657
|
-
|
|
5658
|
-
"
|
|
5659
|
-
"
|
|
5660
|
-
|
|
5661
|
-
|
|
5662
|
-
|
|
5663
|
-
|
|
5664
|
-
|
|
5665
|
-
|
|
5666
|
-
|
|
5667
|
-
|
|
5945
|
+
"parameters": [
|
|
5946
|
+
{
|
|
5947
|
+
"schema": {
|
|
5948
|
+
"type": "string"
|
|
5949
|
+
},
|
|
5950
|
+
"required": true,
|
|
5951
|
+
"name": "rootTaskId",
|
|
5952
|
+
"in": "path"
|
|
5953
|
+
}
|
|
5954
|
+
],
|
|
5955
|
+
"responses": {
|
|
5956
|
+
"200": {
|
|
5957
|
+
"description": "Root task + chain (ordered by createdAt)"
|
|
5958
|
+
},
|
|
5959
|
+
"401": {
|
|
5960
|
+
"description": "Unauthorized"
|
|
5961
|
+
},
|
|
5962
|
+
"404": {
|
|
5963
|
+
"description": "Root task not found"
|
|
5964
|
+
}
|
|
5965
|
+
}
|
|
5966
|
+
}
|
|
5967
|
+
},
|
|
5968
|
+
"/api/skills": {
|
|
5969
|
+
"get": {
|
|
5970
|
+
"summary": "List skills with optional filters",
|
|
5971
|
+
"tags": [
|
|
5972
|
+
"Skills"
|
|
5973
|
+
],
|
|
5974
|
+
"security": [
|
|
5975
|
+
{
|
|
5976
|
+
"bearerAuth": []
|
|
5977
|
+
}
|
|
5978
|
+
],
|
|
5979
|
+
"parameters": [
|
|
5980
|
+
{
|
|
5981
|
+
"schema": {
|
|
5982
|
+
"type": "string"
|
|
5983
|
+
},
|
|
5984
|
+
"required": false,
|
|
5985
|
+
"name": "type",
|
|
5986
|
+
"in": "query"
|
|
5987
|
+
},
|
|
5988
|
+
{
|
|
5989
|
+
"schema": {
|
|
5990
|
+
"type": "string"
|
|
5991
|
+
},
|
|
5992
|
+
"required": false,
|
|
5993
|
+
"name": "scope",
|
|
5994
|
+
"in": "query"
|
|
5995
|
+
},
|
|
5996
|
+
{
|
|
5997
|
+
"schema": {
|
|
5998
|
+
"type": "string"
|
|
5999
|
+
},
|
|
6000
|
+
"required": false,
|
|
6001
|
+
"name": "agentId",
|
|
6002
|
+
"in": "query"
|
|
6003
|
+
},
|
|
6004
|
+
{
|
|
6005
|
+
"schema": {
|
|
6006
|
+
"type": "string"
|
|
6007
|
+
},
|
|
6008
|
+
"required": false,
|
|
6009
|
+
"name": "enabled",
|
|
6010
|
+
"in": "query"
|
|
6011
|
+
},
|
|
6012
|
+
{
|
|
6013
|
+
"schema": {
|
|
6014
|
+
"type": "string"
|
|
6015
|
+
},
|
|
6016
|
+
"required": false,
|
|
6017
|
+
"name": "search",
|
|
6018
|
+
"in": "query"
|
|
6019
|
+
}
|
|
6020
|
+
],
|
|
6021
|
+
"responses": {
|
|
6022
|
+
"200": {
|
|
6023
|
+
"description": "Skill list"
|
|
6024
|
+
}
|
|
6025
|
+
}
|
|
6026
|
+
},
|
|
6027
|
+
"post": {
|
|
6028
|
+
"summary": "Create a new skill",
|
|
6029
|
+
"tags": [
|
|
6030
|
+
"Skills"
|
|
6031
|
+
],
|
|
6032
|
+
"security": [
|
|
6033
|
+
{
|
|
6034
|
+
"bearerAuth": []
|
|
6035
|
+
}
|
|
6036
|
+
],
|
|
6037
|
+
"requestBody": {
|
|
6038
|
+
"content": {
|
|
6039
|
+
"application/json": {
|
|
6040
|
+
"schema": {
|
|
6041
|
+
"type": "object",
|
|
6042
|
+
"properties": {
|
|
6043
|
+
"content": {
|
|
6044
|
+
"type": "string",
|
|
6045
|
+
"minLength": 1
|
|
6046
|
+
},
|
|
6047
|
+
"type": {
|
|
6048
|
+
"type": "string"
|
|
5668
6049
|
},
|
|
5669
6050
|
"scope": {
|
|
5670
6051
|
"type": "string"
|
|
@@ -6938,6 +7319,294 @@
|
|
|
6938
7319
|
}
|
|
6939
7320
|
}
|
|
6940
7321
|
},
|
|
7322
|
+
"/status": {
|
|
7323
|
+
"get": {
|
|
7324
|
+
"summary": "Identity + setup readiness + live activity for the swarm dashboard",
|
|
7325
|
+
"description": "Single source of truth consumed by the UI home page. Identity comes from SWARM_* envs; the 7 setup milestones each emit `unverified | configured | verified`; activity counts agents alive in the last 5 min and tasks created in the last 24h; agent_fs reports whether AGENT_FS_API_URL is set.",
|
|
7326
|
+
"tags": [
|
|
7327
|
+
"Status"
|
|
7328
|
+
],
|
|
7329
|
+
"security": [
|
|
7330
|
+
{
|
|
7331
|
+
"bearerAuth": []
|
|
7332
|
+
}
|
|
7333
|
+
],
|
|
7334
|
+
"responses": {
|
|
7335
|
+
"200": {
|
|
7336
|
+
"description": "Status payload",
|
|
7337
|
+
"content": {
|
|
7338
|
+
"application/json": {
|
|
7339
|
+
"schema": {
|
|
7340
|
+
"type": "object",
|
|
7341
|
+
"properties": {
|
|
7342
|
+
"identity": {
|
|
7343
|
+
"type": "object",
|
|
7344
|
+
"properties": {
|
|
7345
|
+
"name": {
|
|
7346
|
+
"type": "string"
|
|
7347
|
+
},
|
|
7348
|
+
"logo_url": {
|
|
7349
|
+
"type": [
|
|
7350
|
+
"string",
|
|
7351
|
+
"null"
|
|
7352
|
+
]
|
|
7353
|
+
},
|
|
7354
|
+
"brand_color": {
|
|
7355
|
+
"type": [
|
|
7356
|
+
"string",
|
|
7357
|
+
"null"
|
|
7358
|
+
]
|
|
7359
|
+
},
|
|
7360
|
+
"is_cloud": {
|
|
7361
|
+
"type": "boolean"
|
|
7362
|
+
},
|
|
7363
|
+
"marketing_url": {
|
|
7364
|
+
"type": [
|
|
7365
|
+
"string",
|
|
7366
|
+
"null"
|
|
7367
|
+
]
|
|
7368
|
+
},
|
|
7369
|
+
"hide_cloud_promo": {
|
|
7370
|
+
"type": "boolean"
|
|
7371
|
+
}
|
|
7372
|
+
},
|
|
7373
|
+
"required": [
|
|
7374
|
+
"name",
|
|
7375
|
+
"logo_url",
|
|
7376
|
+
"brand_color",
|
|
7377
|
+
"is_cloud",
|
|
7378
|
+
"marketing_url",
|
|
7379
|
+
"hide_cloud_promo"
|
|
7380
|
+
]
|
|
7381
|
+
},
|
|
7382
|
+
"setup": {
|
|
7383
|
+
"type": "array",
|
|
7384
|
+
"items": {
|
|
7385
|
+
"type": "object",
|
|
7386
|
+
"properties": {
|
|
7387
|
+
"id": {
|
|
7388
|
+
"type": "string",
|
|
7389
|
+
"enum": [
|
|
7390
|
+
"harness",
|
|
7391
|
+
"slack",
|
|
7392
|
+
"github",
|
|
7393
|
+
"linear",
|
|
7394
|
+
"jira",
|
|
7395
|
+
"workers",
|
|
7396
|
+
"first_task"
|
|
7397
|
+
]
|
|
7398
|
+
},
|
|
7399
|
+
"label": {
|
|
7400
|
+
"type": "string"
|
|
7401
|
+
},
|
|
7402
|
+
"state": {
|
|
7403
|
+
"type": "string",
|
|
7404
|
+
"enum": [
|
|
7405
|
+
"unverified",
|
|
7406
|
+
"configured",
|
|
7407
|
+
"verified"
|
|
7408
|
+
]
|
|
7409
|
+
},
|
|
7410
|
+
"hint": {
|
|
7411
|
+
"type": "string"
|
|
7412
|
+
},
|
|
7413
|
+
"action_url": {
|
|
7414
|
+
"type": "string"
|
|
7415
|
+
},
|
|
7416
|
+
"provider": {
|
|
7417
|
+
"type": "string",
|
|
7418
|
+
"enum": [
|
|
7419
|
+
"claude",
|
|
7420
|
+
"codex",
|
|
7421
|
+
"pi",
|
|
7422
|
+
"devin",
|
|
7423
|
+
"claude-managed",
|
|
7424
|
+
"opencode"
|
|
7425
|
+
]
|
|
7426
|
+
},
|
|
7427
|
+
"providers": {
|
|
7428
|
+
"type": "array",
|
|
7429
|
+
"items": {
|
|
7430
|
+
"type": "object",
|
|
7431
|
+
"properties": {
|
|
7432
|
+
"provider": {
|
|
7433
|
+
"type": "string",
|
|
7434
|
+
"enum": [
|
|
7435
|
+
"claude",
|
|
7436
|
+
"codex",
|
|
7437
|
+
"pi",
|
|
7438
|
+
"devin",
|
|
7439
|
+
"claude-managed",
|
|
7440
|
+
"opencode"
|
|
7441
|
+
]
|
|
7442
|
+
},
|
|
7443
|
+
"state": {
|
|
7444
|
+
"type": "string",
|
|
7445
|
+
"enum": [
|
|
7446
|
+
"unverified",
|
|
7447
|
+
"configured",
|
|
7448
|
+
"verified"
|
|
7449
|
+
]
|
|
7450
|
+
},
|
|
7451
|
+
"workers": {
|
|
7452
|
+
"type": "integer",
|
|
7453
|
+
"minimum": 0
|
|
7454
|
+
}
|
|
7455
|
+
},
|
|
7456
|
+
"required": [
|
|
7457
|
+
"provider",
|
|
7458
|
+
"state",
|
|
7459
|
+
"workers"
|
|
7460
|
+
]
|
|
7461
|
+
}
|
|
7462
|
+
}
|
|
7463
|
+
},
|
|
7464
|
+
"required": [
|
|
7465
|
+
"id",
|
|
7466
|
+
"label",
|
|
7467
|
+
"state"
|
|
7468
|
+
]
|
|
7469
|
+
}
|
|
7470
|
+
},
|
|
7471
|
+
"activity": {
|
|
7472
|
+
"type": "object",
|
|
7473
|
+
"properties": {
|
|
7474
|
+
"agents_online": {
|
|
7475
|
+
"type": "integer",
|
|
7476
|
+
"minimum": 0
|
|
7477
|
+
},
|
|
7478
|
+
"leads_online": {
|
|
7479
|
+
"type": "integer",
|
|
7480
|
+
"minimum": 0
|
|
7481
|
+
},
|
|
7482
|
+
"recent_tasks_count": {
|
|
7483
|
+
"type": "integer",
|
|
7484
|
+
"minimum": 0
|
|
7485
|
+
}
|
|
7486
|
+
},
|
|
7487
|
+
"required": [
|
|
7488
|
+
"agents_online",
|
|
7489
|
+
"leads_online",
|
|
7490
|
+
"recent_tasks_count"
|
|
7491
|
+
]
|
|
7492
|
+
},
|
|
7493
|
+
"agent_fs": {
|
|
7494
|
+
"type": "object",
|
|
7495
|
+
"properties": {
|
|
7496
|
+
"configured": {
|
|
7497
|
+
"type": "boolean"
|
|
7498
|
+
},
|
|
7499
|
+
"base_url": {
|
|
7500
|
+
"type": [
|
|
7501
|
+
"string",
|
|
7502
|
+
"null"
|
|
7503
|
+
]
|
|
7504
|
+
}
|
|
7505
|
+
},
|
|
7506
|
+
"required": [
|
|
7507
|
+
"configured",
|
|
7508
|
+
"base_url"
|
|
7509
|
+
]
|
|
7510
|
+
},
|
|
7511
|
+
"health": {
|
|
7512
|
+
"type": "string",
|
|
7513
|
+
"enum": [
|
|
7514
|
+
"ok",
|
|
7515
|
+
"degraded",
|
|
7516
|
+
"broken"
|
|
7517
|
+
]
|
|
7518
|
+
}
|
|
7519
|
+
},
|
|
7520
|
+
"required": [
|
|
7521
|
+
"identity",
|
|
7522
|
+
"setup",
|
|
7523
|
+
"activity",
|
|
7524
|
+
"agent_fs",
|
|
7525
|
+
"health"
|
|
7526
|
+
]
|
|
7527
|
+
}
|
|
7528
|
+
}
|
|
7529
|
+
}
|
|
7530
|
+
},
|
|
7531
|
+
"401": {
|
|
7532
|
+
"description": "Unauthorized"
|
|
7533
|
+
}
|
|
7534
|
+
}
|
|
7535
|
+
}
|
|
7536
|
+
},
|
|
7537
|
+
"/status/test-connection": {
|
|
7538
|
+
"post": {
|
|
7539
|
+
"summary": "Live-test the harness provider's credentials",
|
|
7540
|
+
"description": "Issues a real upstream call (Anthropic /v1/models, OpenAI /v1/models, etc.) for the given provider. Updates an in-memory cache so the next GET /status reports `harness.state = 'verified'` for SWARM_VERIFY_TTL_MS (default 1h).",
|
|
7541
|
+
"tags": [
|
|
7542
|
+
"Status"
|
|
7543
|
+
],
|
|
7544
|
+
"security": [
|
|
7545
|
+
{
|
|
7546
|
+
"bearerAuth": []
|
|
7547
|
+
}
|
|
7548
|
+
],
|
|
7549
|
+
"requestBody": {
|
|
7550
|
+
"content": {
|
|
7551
|
+
"application/json": {
|
|
7552
|
+
"schema": {
|
|
7553
|
+
"type": "object",
|
|
7554
|
+
"properties": {
|
|
7555
|
+
"provider": {
|
|
7556
|
+
"type": "string",
|
|
7557
|
+
"enum": [
|
|
7558
|
+
"claude",
|
|
7559
|
+
"codex",
|
|
7560
|
+
"pi",
|
|
7561
|
+
"devin",
|
|
7562
|
+
"claude-managed",
|
|
7563
|
+
"opencode"
|
|
7564
|
+
]
|
|
7565
|
+
}
|
|
7566
|
+
},
|
|
7567
|
+
"required": [
|
|
7568
|
+
"provider"
|
|
7569
|
+
]
|
|
7570
|
+
}
|
|
7571
|
+
}
|
|
7572
|
+
}
|
|
7573
|
+
},
|
|
7574
|
+
"responses": {
|
|
7575
|
+
"200": {
|
|
7576
|
+
"description": "Live-test result",
|
|
7577
|
+
"content": {
|
|
7578
|
+
"application/json": {
|
|
7579
|
+
"schema": {
|
|
7580
|
+
"type": "object",
|
|
7581
|
+
"properties": {
|
|
7582
|
+
"ok": {
|
|
7583
|
+
"type": "boolean"
|
|
7584
|
+
},
|
|
7585
|
+
"error": {
|
|
7586
|
+
"type": "string"
|
|
7587
|
+
},
|
|
7588
|
+
"latency_ms": {
|
|
7589
|
+
"type": "integer",
|
|
7590
|
+
"minimum": 0
|
|
7591
|
+
}
|
|
7592
|
+
},
|
|
7593
|
+
"required": [
|
|
7594
|
+
"ok",
|
|
7595
|
+
"latency_ms"
|
|
7596
|
+
]
|
|
7597
|
+
}
|
|
7598
|
+
}
|
|
7599
|
+
}
|
|
7600
|
+
},
|
|
7601
|
+
"400": {
|
|
7602
|
+
"description": "Validation error"
|
|
7603
|
+
},
|
|
7604
|
+
"401": {
|
|
7605
|
+
"description": "Unauthorized"
|
|
7606
|
+
}
|
|
7607
|
+
}
|
|
7608
|
+
}
|
|
7609
|
+
},
|
|
6941
7610
|
"/api/tasks": {
|
|
6942
7611
|
"get": {
|
|
6943
7612
|
"summary": "List tasks with filters",
|
|
@@ -6994,6 +7663,23 @@
|
|
|
6994
7663
|
"name": "includeHeartbeat",
|
|
6995
7664
|
"in": "query"
|
|
6996
7665
|
},
|
|
7666
|
+
{
|
|
7667
|
+
"schema": {
|
|
7668
|
+
"type": "string",
|
|
7669
|
+
"format": "date-time"
|
|
7670
|
+
},
|
|
7671
|
+
"required": false,
|
|
7672
|
+
"name": "createdAfter",
|
|
7673
|
+
"in": "query"
|
|
7674
|
+
},
|
|
7675
|
+
{
|
|
7676
|
+
"schema": {
|
|
7677
|
+
"type": "string"
|
|
7678
|
+
},
|
|
7679
|
+
"required": false,
|
|
7680
|
+
"name": "source",
|
|
7681
|
+
"in": "query"
|
|
7682
|
+
},
|
|
6997
7683
|
{
|
|
6998
7684
|
"schema": {
|
|
6999
7685
|
"type": [
|
|
@@ -7020,6 +7706,9 @@
|
|
|
7020
7706
|
"responses": {
|
|
7021
7707
|
"200": {
|
|
7022
7708
|
"description": "Paginated task list"
|
|
7709
|
+
},
|
|
7710
|
+
"400": {
|
|
7711
|
+
"description": "Validation error (e.g. unknown status token)"
|
|
7023
7712
|
}
|
|
7024
7713
|
}
|
|
7025
7714
|
},
|
|
@@ -7074,7 +7763,21 @@
|
|
|
7074
7763
|
"type": "string"
|
|
7075
7764
|
},
|
|
7076
7765
|
"source": {
|
|
7077
|
-
"type": "string"
|
|
7766
|
+
"type": "string",
|
|
7767
|
+
"enum": [
|
|
7768
|
+
"mcp",
|
|
7769
|
+
"slack",
|
|
7770
|
+
"api",
|
|
7771
|
+
"ui",
|
|
7772
|
+
"github",
|
|
7773
|
+
"gitlab",
|
|
7774
|
+
"agentmail",
|
|
7775
|
+
"system",
|
|
7776
|
+
"schedule",
|
|
7777
|
+
"workflow",
|
|
7778
|
+
"linear",
|
|
7779
|
+
"jira"
|
|
7780
|
+
]
|
|
7078
7781
|
},
|
|
7079
7782
|
"outputSchema": {
|
|
7080
7783
|
"type": "object",
|
|
@@ -7082,6 +7785,9 @@
|
|
|
7082
7785
|
},
|
|
7083
7786
|
"contextKey": {
|
|
7084
7787
|
"type": "string"
|
|
7788
|
+
},
|
|
7789
|
+
"requestedByUserId": {
|
|
7790
|
+
"type": "string"
|
|
7085
7791
|
}
|
|
7086
7792
|
},
|
|
7087
7793
|
"required": [
|
|
@@ -7547,6 +8253,58 @@
|
|
|
7547
8253
|
}
|
|
7548
8254
|
}
|
|
7549
8255
|
},
|
|
8256
|
+
"/api/task-templates": {
|
|
8257
|
+
"get": {
|
|
8258
|
+
"summary": "List task templates ('To start' bucket)",
|
|
8259
|
+
"tags": [
|
|
8260
|
+
"Task Templates"
|
|
8261
|
+
],
|
|
8262
|
+
"security": [
|
|
8263
|
+
{
|
|
8264
|
+
"bearerAuth": []
|
|
8265
|
+
}
|
|
8266
|
+
],
|
|
8267
|
+
"parameters": [
|
|
8268
|
+
{
|
|
8269
|
+
"schema": {
|
|
8270
|
+
"type": "string"
|
|
8271
|
+
},
|
|
8272
|
+
"required": false,
|
|
8273
|
+
"name": "category",
|
|
8274
|
+
"in": "query"
|
|
8275
|
+
},
|
|
8276
|
+
{
|
|
8277
|
+
"schema": {
|
|
8278
|
+
"type": "string",
|
|
8279
|
+
"enum": [
|
|
8280
|
+
"task",
|
|
8281
|
+
"workflow",
|
|
8282
|
+
"schedule"
|
|
8283
|
+
]
|
|
8284
|
+
},
|
|
8285
|
+
"required": false,
|
|
8286
|
+
"name": "kind",
|
|
8287
|
+
"in": "query"
|
|
8288
|
+
},
|
|
8289
|
+
{
|
|
8290
|
+
"schema": {
|
|
8291
|
+
"type": "string"
|
|
8292
|
+
},
|
|
8293
|
+
"required": false,
|
|
8294
|
+
"name": "query",
|
|
8295
|
+
"in": "query"
|
|
8296
|
+
}
|
|
8297
|
+
],
|
|
8298
|
+
"responses": {
|
|
8299
|
+
"200": {
|
|
8300
|
+
"description": "Task template list"
|
|
8301
|
+
},
|
|
8302
|
+
"401": {
|
|
8303
|
+
"description": "Unauthorized"
|
|
8304
|
+
}
|
|
8305
|
+
}
|
|
8306
|
+
}
|
|
8307
|
+
},
|
|
7550
8308
|
"/api/trackers/jira/authorize": {
|
|
7551
8309
|
"get": {
|
|
7552
8310
|
"summary": "Redirect to Atlassian OAuth consent screen",
|
|
@@ -7922,6 +8680,185 @@
|
|
|
7922
8680
|
}
|
|
7923
8681
|
}
|
|
7924
8682
|
},
|
|
8683
|
+
"/api/users": {
|
|
8684
|
+
"get": {
|
|
8685
|
+
"summary": "List all users",
|
|
8686
|
+
"tags": [
|
|
8687
|
+
"Users"
|
|
8688
|
+
],
|
|
8689
|
+
"security": [
|
|
8690
|
+
{
|
|
8691
|
+
"bearerAuth": []
|
|
8692
|
+
}
|
|
8693
|
+
],
|
|
8694
|
+
"responses": {
|
|
8695
|
+
"200": {
|
|
8696
|
+
"description": "List of users"
|
|
8697
|
+
},
|
|
8698
|
+
"401": {
|
|
8699
|
+
"description": "Unauthorized"
|
|
8700
|
+
}
|
|
8701
|
+
}
|
|
8702
|
+
},
|
|
8703
|
+
"post": {
|
|
8704
|
+
"summary": "Create a new user",
|
|
8705
|
+
"tags": [
|
|
8706
|
+
"Users"
|
|
8707
|
+
],
|
|
8708
|
+
"security": [
|
|
8709
|
+
{
|
|
8710
|
+
"bearerAuth": []
|
|
8711
|
+
}
|
|
8712
|
+
],
|
|
8713
|
+
"requestBody": {
|
|
8714
|
+
"content": {
|
|
8715
|
+
"application/json": {
|
|
8716
|
+
"schema": {
|
|
8717
|
+
"type": "object",
|
|
8718
|
+
"properties": {
|
|
8719
|
+
"name": {
|
|
8720
|
+
"type": "string",
|
|
8721
|
+
"minLength": 1
|
|
8722
|
+
},
|
|
8723
|
+
"email": {
|
|
8724
|
+
"type": "string"
|
|
8725
|
+
},
|
|
8726
|
+
"role": {
|
|
8727
|
+
"type": "string"
|
|
8728
|
+
},
|
|
8729
|
+
"notes": {
|
|
8730
|
+
"type": "string"
|
|
8731
|
+
},
|
|
8732
|
+
"slackUserId": {
|
|
8733
|
+
"type": "string"
|
|
8734
|
+
},
|
|
8735
|
+
"linearUserId": {
|
|
8736
|
+
"type": "string"
|
|
8737
|
+
},
|
|
8738
|
+
"githubUsername": {
|
|
8739
|
+
"type": "string"
|
|
8740
|
+
},
|
|
8741
|
+
"gitlabUsername": {
|
|
8742
|
+
"type": "string"
|
|
8743
|
+
},
|
|
8744
|
+
"emailAliases": {
|
|
8745
|
+
"type": "array",
|
|
8746
|
+
"items": {
|
|
8747
|
+
"type": "string"
|
|
8748
|
+
}
|
|
8749
|
+
},
|
|
8750
|
+
"preferredChannel": {
|
|
8751
|
+
"type": "string"
|
|
8752
|
+
},
|
|
8753
|
+
"timezone": {
|
|
8754
|
+
"type": "string"
|
|
8755
|
+
}
|
|
8756
|
+
},
|
|
8757
|
+
"required": [
|
|
8758
|
+
"name"
|
|
8759
|
+
]
|
|
8760
|
+
}
|
|
8761
|
+
}
|
|
8762
|
+
}
|
|
8763
|
+
},
|
|
8764
|
+
"responses": {
|
|
8765
|
+
"200": {
|
|
8766
|
+
"description": "User created"
|
|
8767
|
+
},
|
|
8768
|
+
"400": {
|
|
8769
|
+
"description": "Validation error"
|
|
8770
|
+
},
|
|
8771
|
+
"401": {
|
|
8772
|
+
"description": "Unauthorized"
|
|
8773
|
+
}
|
|
8774
|
+
}
|
|
8775
|
+
}
|
|
8776
|
+
},
|
|
8777
|
+
"/api/users/{id}": {
|
|
8778
|
+
"put": {
|
|
8779
|
+
"summary": "Update an existing user (partial — at least one field required)",
|
|
8780
|
+
"tags": [
|
|
8781
|
+
"Users"
|
|
8782
|
+
],
|
|
8783
|
+
"security": [
|
|
8784
|
+
{
|
|
8785
|
+
"bearerAuth": []
|
|
8786
|
+
}
|
|
8787
|
+
],
|
|
8788
|
+
"parameters": [
|
|
8789
|
+
{
|
|
8790
|
+
"schema": {
|
|
8791
|
+
"type": "string"
|
|
8792
|
+
},
|
|
8793
|
+
"required": true,
|
|
8794
|
+
"name": "id",
|
|
8795
|
+
"in": "path"
|
|
8796
|
+
}
|
|
8797
|
+
],
|
|
8798
|
+
"requestBody": {
|
|
8799
|
+
"content": {
|
|
8800
|
+
"application/json": {
|
|
8801
|
+
"schema": {
|
|
8802
|
+
"type": "object",
|
|
8803
|
+
"properties": {
|
|
8804
|
+
"name": {
|
|
8805
|
+
"type": "string",
|
|
8806
|
+
"minLength": 1
|
|
8807
|
+
},
|
|
8808
|
+
"email": {
|
|
8809
|
+
"type": "string"
|
|
8810
|
+
},
|
|
8811
|
+
"role": {
|
|
8812
|
+
"type": "string"
|
|
8813
|
+
},
|
|
8814
|
+
"notes": {
|
|
8815
|
+
"type": "string"
|
|
8816
|
+
},
|
|
8817
|
+
"slackUserId": {
|
|
8818
|
+
"type": "string"
|
|
8819
|
+
},
|
|
8820
|
+
"linearUserId": {
|
|
8821
|
+
"type": "string"
|
|
8822
|
+
},
|
|
8823
|
+
"githubUsername": {
|
|
8824
|
+
"type": "string"
|
|
8825
|
+
},
|
|
8826
|
+
"gitlabUsername": {
|
|
8827
|
+
"type": "string"
|
|
8828
|
+
},
|
|
8829
|
+
"emailAliases": {
|
|
8830
|
+
"type": "array",
|
|
8831
|
+
"items": {
|
|
8832
|
+
"type": "string"
|
|
8833
|
+
}
|
|
8834
|
+
},
|
|
8835
|
+
"preferredChannel": {
|
|
8836
|
+
"type": "string"
|
|
8837
|
+
},
|
|
8838
|
+
"timezone": {
|
|
8839
|
+
"type": "string"
|
|
8840
|
+
}
|
|
8841
|
+
}
|
|
8842
|
+
}
|
|
8843
|
+
}
|
|
8844
|
+
}
|
|
8845
|
+
},
|
|
8846
|
+
"responses": {
|
|
8847
|
+
"200": {
|
|
8848
|
+
"description": "User updated"
|
|
8849
|
+
},
|
|
8850
|
+
"400": {
|
|
8851
|
+
"description": "Validation error or empty body"
|
|
8852
|
+
},
|
|
8853
|
+
"401": {
|
|
8854
|
+
"description": "Unauthorized"
|
|
8855
|
+
},
|
|
8856
|
+
"404": {
|
|
8857
|
+
"description": "User not found"
|
|
8858
|
+
}
|
|
8859
|
+
}
|
|
8860
|
+
}
|
|
8861
|
+
},
|
|
7925
8862
|
"/api/github/webhook": {
|
|
7926
8863
|
"post": {
|
|
7927
8864
|
"summary": "Handle GitHub webhook events",
|