Add get_task_comments_with_replies tool #91
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR adds a new
getTaskCommentsWithReplies
method to fetch both task comments and their threaded replies in a single call. It extends the existing task comments functionality by nesting replies within their parent comments under a replies array property. This should be far more usable to the end-users than having to perform N additional tool calls and trying to loop over comments and get their replies one by one.Changes
getTaskCommentsWithReplies
method toTaskServiceComments
classClickUpComment
interface to include optional replies propertyUsage
The new method can be called via the
get_task_comments_with_replies
tool, which takes ataskId
parameter and returns comments with their threaded replies nested under each comment'sreplies
property.Type of Change
MCP Server Impact
One tool added
Checklist
Testing
I used MCP Inspector and tested with a task that had 21 total comments and dozens of replies in total.
Screenshots (if applicable)
Additional Notes
Considered adding a call to get replies for a single comment to mirror the ClickUp API. Perhaps there is a use-case for that, but for my purposes, having all replies in one tool call is immensely more efficient. Also the API calls them threads, but the GUI calls them replies so I prefered to mirror the terminology of the GUI since it is what a user would be more likely to use in a natural language setting.