Add meta field passthrough for MCP Apps support#624
Merged
Conversation
Adds the `meta` parameter to the tool definition pipeline so tools can
declare associated UI resources via `meta={"ui": {"resourceUri": "ui://..."}}`.
This is the plumbing needed to support MCP Apps without adding any features.
Also adds CLAUDE.md, tool authoring docs in CONTRIBUTING.md, and tests
for the meta passthrough.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
816bf8e to
bcc5d9e
Compare
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
DevonFulcher
reviewed
Mar 4, 2026
- Rename "MCP App tool" to "tool with interactive UI" - Clarify why structured_output=True is needed - Recommend Pydantic models for return types Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
jairus-m
reviewed
Mar 5, 2026
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
b-per
reviewed
Mar 18, 2026
| # We haven't strictly defined our tool contracts yet. | ||
| # So we're setting this to False by default for now. | ||
| structured_output: bool | None = False | ||
| meta: dict[str, Any] | None = None |
Collaborator
There was a problem hiding this comment.
Isn't there a risk to confuse ourselves/people between the MCP tool meta and the concept of meta in dbt that we already rely on in the MCP server?
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
meta: dict[str, Any] | None = NonetoGenericToolDefinition, the@dbt_mcp_tooldecorator, andregister_tools()passthrough toFastMCP.add_tool()metadefaults toNone)meta={"ui": {"resourceUri": "ui://..."}}CLAUDE.mdwith project architecture overview for AI-assisted developmentCONTRIBUTING.mdMockFastMCPin test conftest to capturetool_kwargsfor future test assertionsTest plan
uv run pytest tests/ --ignore=tests/integration -x -q)adapt_context(),to_fastmcp_internal_tool(), andgeneric_register_tools()for bothmeta=valueandmeta=None🤖 Generated with Claude Code