feat(im): add at-chatter-ids filter to +messages-search#612
feat(im): add at-chatter-ids filter to +messages-search#612arnold9672 wants to merge 1 commit intolarksuite:mainfrom
Conversation
Add --at-chatter-ids flag to shortcuts/im/im_messages_search.go that passes filter.at_chatter_ids to the search API, restricting results to messages that @mention any of the given user open_ids. Messages that @ALL are included automatically. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
|
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughAdded a new CLI flag Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Add a new filter
--at-chatter-idsto theim +messages-searchshortcut so users can narrow search results to messages that@mentionspecific users. Matched results naturally include messages that@all.Changes
shortcuts/im/im_messages_search.go: register the--at-chatter-idsflag; parse comma-separatedou_*user IDs, validate viacommon.ValidateUserID, and pass asfilter.at_chatter_idsin the search bodyshortcuts/im/coverage_additional_test.go: add two table-driven sub-tests (valid IDs populate the filter; malformed ID returns a validation error)shortcuts/im/im_messages_search_execute_test.go: register the new flag in the execute-test runtime helperskills/lark-im/references/lark-im-messages-search.md: document the flag and add a usage exampleTest Plan
make unit-testpasses locallylark-cli im +messages-search --query "release" --at-chatter-ids ou_xxx,ou_yyy— confirm the request payload in--dry-runincludesfilter.at_chatter_ids: [ou_xxx, ou_yyy]lark-cli im +messages-search --at-chatter-ids bad_id— confirm it surfacesinvalid user ID formatRelated Issues
N/A
Summary by CodeRabbit
Release Notes
New Features
--at-chatter-idsflag to filter instant messages by explicitly mentioned user IDs (comma-separated format).Tests