Repository navigation
feat(mcp): expose topic suggestions via list/accept/dismiss tools - #513
Merged
Merged
Conversation
gkhngyk
approved these changes
Jul 23, 2026
gkhngyk
left a comment
Contributor
There was a problem hiding this comment.
Clean work — all four acceptance criteria met, org isolation done right. Thanks!
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.
Summary
Agents connected via MCP could list topics and prompts but had no way to see
or act on the AI-generated topic suggestions added in #497 — accepting or
dismissing one required switching to the web dashboard.
This adds three MCP tools:
list_topic_suggestions,accept_topic_suggestion,and
dismiss_topic_suggestion, plus matching REST twins under/api/mcp/topic-suggestions/*(mirroring the pattern every other MCPcapability in this codebase already follows). Accept creates exactly one
topic via a singular insert (never a bulk replace) and both accept/dismiss
are scoped to
status = 'new', so acting on an already-decided suggestionreturns not-found instead of silently double-processing or creating a
duplicate topic. Generating new suggestions stays out of scope — that
remains plan-gated behind the UI's refresh button.
Verified end-to-end against a local Supabase instance: correct org isolation
(wrong-org calls return not-found), and a real MCP client (Claude Code)
connected over the Streamable HTTP endpoint successfully listed and accepted
a live suggestion.
Related issue
Closes #498
Type of change
feat— New featureChecklist
feature/,fix/,chore/,docs/)yarn lintpasses (run fromweb/)yarn typecheckpasses (run fromweb/)yarn format:checkpasses (run fromweb/)