Repository navigation
MCP: create private items and change item visibility - #387
Open
sandervanhooft wants to merge 1 commit into
Open
sandervanhooft wants to merge 1 commit into
sandervanhooft wants to merge 1 commit into
Conversation
create-item accepts a private flag for admins and employees, so the item is private from the start and no new item notification goes out. The new set-item-visibility tool makes an existing item private or public again.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Through MCP, every item is created as a public item.
create-itemhas no private flag, so the new item notification goes out as soon as the item is saved. Making the item private afterwards is too late, and there was also no MCP tool to do that.Changes
create-itemaccepts an optionalprivateboolean. Admins and employees can create the item as private from the start, soItemObserver::created()sends no notification. Regular users who passprivate: trueget an error, the same waycomment-on-itemhandles private notes.set-item-visibilitytool (item,private) makes an existing item private or public. It's available to admins and employees only (hidden from other users viashouldRegister()) and idempotent: it reports when the item already has that visibility. The update goes through the observer, so the "made private"/"made public" activity is logged as usual.RoadmapServer::TOOLS.Tests
set-item-visibilitymakes an item private (admin and employee) and public againset-item-visibilityto employees only