Skip to content
This repository was archived by the owner on Jul 8, 2026. It is now read-only.

Add tool for listing label stories. - #159

Merged
andreasmcdermott merged 1 commit into
mainfrom
amcd/list-label-stories
Feb 26, 2026
Merged

andreasmcdermott merged 1 commit into
mainfrom
amcd/list-label-stories

Conversation

@andreasmcdermott

@andreasmcdermott andreasmcdermott commented Feb 26, 2026

Copy link
Copy Markdown
Member

Summary by CodeRabbit

  • New Features
    • Added the ability to retrieve all stories associated with a specific label, enabling better filtering and organization of label-based tasks in your workspace

@coderabbitai

coderabbitai Bot commented Feb 26, 2026

Copy link
Copy Markdown

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ee68bfb and 0f03840.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (6)
  • README.md
  • manifest.json
  • package.json
  • src/client/shortcut.ts
  • src/tools/labels.test.ts
  • src/tools/labels.ts

📝 Walkthrough

Walkthrough

This PR introduces a new tool capability to retrieve stories associated with a specific label. The implementation adds a new method to the Shortcut client wrapper, creates a corresponding tool implementation with comprehensive tests, and updates documentation and manifest files accordingly.

Changes

Cohort / File(s) Summary
Documentation & Configuration
README.md, manifest.json, package.json
Added new "labels-get-stories" tool entry to manifest and README. Bumped package version from 0.22.0 to 0.23.0.
Client Wrapper
src/client/shortcut.ts
Added new public async method listLabelStories(labelPublicId: number) that delegates to underlying client and returns StorySlim[] or empty array.
Label Tools Implementation
src/tools/labels.ts
Introduced new public method getLabelStories(labelPublicId: number) that retrieves stories for a label, registers the tool with server, and formats results with related entities. Returns "No stories found" message when label has no stories.
Label Tools Tests
src/tools/labels.test.ts
Added Story type import, mock story data, and comprehensive test suite for getLabelStories method. Tests verify correct formatting of returned stories and proper "No stories found" messaging. Updated create method test to expect additional read-tool registration.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

🐰 Hop hop, new stories now in sight,
Labels reveal their tales so bright,
With every query, tales unfold,
New tools to fetch each story bold!
The warren's wisdom grows anew! 🌟

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The pull request title accurately and specifically describes the main change: adding a new tool to retrieve stories associated with labels.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch amcd/list-label-stories

Tip

Try Coding Plans. Let us write the prompt for your AI agent so you can ship faster (with fewer bugs).
Share your feedback on Discord.


Comment @coderabbitai help to get the list of available commands and usage tips.

@andreasmcdermott
andreasmcdermott merged commit 5b63ed2 into main Feb 26, 2026
2 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant