Skip to content

feat: feishu_task 新增 add_members/remove_members + 创建返回 applink - #128

Merged
lishuceo merged 2 commits into
mainfrom
feat/task-add-remove-members
Mar 10, 2026
Merged

feat: feishu_task 新增 add_members/remove_members + 创建返回 applink#128
lishuceo merged 2 commits into
mainfrom
feat/task-add-remove-members

Conversation

@lishuceo

Copy link
Copy Markdown
Owner

Summary

  • 新增 add_membersremove_members action,支持创建任务后修改成员(执行者/关注者),解决之前只能在 create 时设置 members 的限制
  • task create 返回值中包含正确的 applink URL (https://applink.feishu.cn/client/todo/detail?guid=xxx),避免 agent 自行编造错误链接
  • 更新 system prompt 中 feishu_task 工具描述,标注新 action 和链接使用规则

Test plan

  • 新增 add_members 单元测试(成功添加、缺少参数、API 错误)
  • 新增 remove_members 单元测试(成功移除、缺少参数)
  • 更新 create 测试验证 applink URL 包含在返回中
  • 全量回归测试通过(964/965,1 个 memory quality 预存在 flaky 测试)

🤖 Generated with Claude Code

- 新增 add_members 和 remove_members action,支持创建后修改任务成员(执行者/关注者)
- task create 返回值中包含正确的 applink URL,避免 agent 自行编造链接
- 更新 system prompt 中 feishu_task 工具描述,标注新 action 和链接使用规则

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@claude

claude Bot commented Mar 10, 2026

Copy link
Copy Markdown

Claude finished @lishuceo's task in 1m 2s —— View job


PR Review: feishu_task add_members/remove_members + applink

  • Check previous review comments — no prior comments found
  • Read changed files and full context
  • Analyze code for bugs, security, and architecture issues
  • Post review summary

Verdict: ✅ Approved

Clean, well-structured PR. The new add_members/remove_members actions follow the existing patterns perfectly — input validation via validateMembers(), proper userTokenOpt passthrough, consistent error handling. The applink URL in create response is a good UX improvement. Test coverage is thorough (happy path + missing params + API errors for both new actions, plus applink assertion on create).

Minor suggestions (non-blocking)

  • 🟡 Stale comment (confidence: 80) — src/feishu/tools/task.ts:11 still says 支持操作: create / get / list / update but delete, add_members, remove_members are now supported. Consider updating to match.
  • 🟡 Stale comment (confidence: 80) — src/feishu/tools/task.ts:139 has // create 专用 above the members param, but members is now also used by add_members/remove_members. Consider updating to // create / add_members / remove_members.

Neither of these affect functionality — just documentation accuracy.

- 新增 list_tasklists action,动态查询可用的任务清单(返回 guid + name)
- create 时支持 tasklists 参数,将任务归入指定清单
- 新增 validateTasklists 校验函数
- 更新 system prompt 说明 list_tasklists 和 tasklists 用法

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@claude

claude Bot commented Mar 10, 2026

Copy link
Copy Markdown

Claude finished @lishuceo's task in 52s —— View job


PR Review: feishu_task add_members/remove_members + applink

  • Check and resolve previous review comments — no prior inline comments found
  • Read changed files and full context
  • Analyze code for bugs, security, and architecture issues
  • Post review summary

Verdict: ✅ Approved

No issues with confidence ≥ 75 found. This is a clean, well-structured PR.

What's good:

  • add_members / remove_members follow the exact same pattern as existing actions — validateMembers() reuse, userTokenOpt passthrough, consistent error handling with error codes in messages
  • The applink URL in create response (https://applink.feishu.cn/client/todo/detail?guid=xxx) is a nice UX improvement that prevents the agent from fabricating incorrect links
  • System prompt in executor.ts correctly documents all new actions and includes the "don't fabricate links" instruction
  • Test coverage is thorough: happy path + missing params + API errors for both new actions, plus applink assertion on create

Previous review notes (from first review comment): The two stale-comment suggestions (lines 11 and 139 in task.ts) from the prior review appear to still be present but are genuinely non-blocking documentation nits — line 11 comment says create / get / list / update but delete, add_members, remove_members are now also supported; line 171 members param comment says // create 专用 (resolved — I see the comment was already removed in this revision, members description now just says "成员 JSON 数组"). Line 11 header comment at task.ts:11 still lists the old subset — minor, but worth a quick update if convenient.

@lishuceo
lishuceo merged commit 847190c into main Mar 10, 2026
2 checks passed
@lishuceo
lishuceo deleted the feat/task-add-remove-members branch March 10, 2026 09:41
lishuceo added a commit that referenced this pull request Apr 8, 2026
* feat: feishu_task 新增 add_members/remove_members + 创建返回 applink

- 新增 add_members 和 remove_members action,支持创建后修改任务成员(执行者/关注者)
- task create 返回值中包含正确的 applink URL,避免 agent 自行编造链接
- 更新 system prompt 中 feishu_task 工具描述,标注新 action 和链接使用规则

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* feat: feishu_task 新增 list_tasklists + create 支持 tasklists 归属清单

- 新增 list_tasklists action,动态查询可用的任务清单(返回 guid + name)
- create 时支持 tasklists 参数,将任务归入指定清单
- 新增 validateTasklists 校验函数
- 更新 system prompt 说明 list_tasklists 和 tasklists 用法

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant