Unlist get_merge_request_notes

What does this MR do and why?

This MR marks the get_merge_request_notes MCP tool as unlisted.

An unlisted tool no longer shows up in the MCP tools/list response or in the AI Catalog tool picker. It still works when called directly through tools/call. So any existing caller keeps working.

Use get_merge_request with include: ["notes"] instead. This follows the same pattern as !254299 (merged), which unlisted get_workitem_notes.

We could not do this before, because the notes facet was missing some data. !258219 (merged) (merged) closed that gap. It added backward paging (notes_last, notes_before), each note's position and discussion, and the resolvedDiscussionsCount / resolvableDiscussionsCount counts. The facet now returns everything the old tool returned.

Changes in this MR:

  • Add an unlisted? override on the service.
  • Update docs: add a history entry, add a "superseded" note on the tool, and point the list_merge_requests notes paragraph to include: ["notes"].
  • Update CE and EE list_tools request specs: drop the tool from the listed tools, and check it still can be called. One alias spec now uses the list_merge_requests alias, because the notes tool is no longer listed.
  • Add the tool to the expected unlisted set in the AI Catalog mcp_tool_spec.
  • Add a service spec check for unlisted?.

References

Screenshots or screen recordings

Not applicable. This change is backend and docs only. There is no UI.

How to set up and validate locally

Run these specs:

bundle exec rspec spec/requests/api/mcp/handlers/list_tools_spec.rb ee/spec/requests/api/mcp/handlers/list_tools_spec.rb ee/spec/models/ai/catalog/mcp_tool_spec.rb spec/services/mcp/tools/merge_requests/get_merge_request_notes_service_spec.rb

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Alex Filatov

Merge request reports

Loading
Loading