MCP: clarify search_message_bodies tool schema#14
Closed
endolith wants to merge 3 commits into
Closed
Conversation
Clarify in the tool and query parameter descriptions that space-separated terms are ANDed, double-quoted strings match exact phrases, and OR/NOT are unsupported. Add a schema contract test. Co-authored-by: endolith <endolith@gmail.com>
Document that Gmail operators are metadata filters (not body search terms) and that unrecognized word:value tokens are literal text. Expand the filter-only error message and add schema contract tests. Co-authored-by: endolith <endolith@gmail.com>
Explain in the tool description that the flag means more than five match excerpts were found and callers should use search_in_message or get_message for the full body. Add a handler test and schema contract test. Co-authored-by: endolith <endolith@gmail.com>
Owner
Author
|
Close in favor of #15 |
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.
Documents
search_message_bodiesMCP tool behavior so agents interpret queries and responses correctly.Changes (one commit each)
from:,subject:, etc.) are metadata filters and do not satisfy the free-text requirement; unrecognizedword:valuetokens (e.g.RXD2:V2) are literal body text. Error message expanded accordingly.context_snippets_truncated— when true, more than five match excerpts were returned; usesearch_in_messageorget_messagefor the full body.Each change includes schema contract tests in
internal/mcp/server_test.go.