feat: add group repair and dispatch rejection flows

This commit is contained in:
kris
2026-03-31 03:56:28 +08:00
parent 9c02ebb574
commit 4336dc22a7
21 changed files with 832 additions and 83 deletions

View File

@@ -347,6 +347,20 @@
- `isGroup`
- `threadMeta`
- `participants[]`
- `repairRequired`
- `repairReason`
- `validParticipantCount`
- `invalidParticipantCount`
#### `POST /api/v1/projects/[projectId]/participants`
- 用途:修复或重设群聊成员
- 输入:
- `memberProjectIds[]`
- 当前行为:
- 只允许把真实可下发的线程会话加入群聊
- 至少要求 2 个线程成员
- 成功后会重写群成员列表,并追加一条 `kind=system_notice` 的“已更新群成员”消息
#### `POST /api/v1/projects/[projectId]/rename`
@@ -398,6 +412,14 @@
- 会写入一条 `kind=system_notice` 的群聊系统消息
- 同时会为每个执行单创建 `taskType=dispatch_execution` 的主 Agent 任务,等待对应设备的 local-agent 认领
#### `POST /api/v1/projects/[projectId]/dispatch-plans/[planId]/reject`
- 用途:拒绝主 Agent 推荐的线程下发方案
- 当前行为:
- 会把 dispatch plan 标记为 `rejected`
-`approval_required` 群聊会把项目审批状态写成 `rejected`
- 会追加一条 `kind=system_notice` 的“已拒绝主 Agent 推荐”消息
#### `GET /api/v1/accounts`
- 用途:返回 AI 账号列表、当前主控身份和切换历史