web_search
Search the web for information using natural language queries through the Tavily API. Get answers to questions by performing web searches via the MCP protocol.
Instructions
Search the web for information about the given query
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes |
Implementation Reference
- server.py:17-21 (handler)The web_search tool handler function decorated with @mcp.tool(), which registers the tool and implements the logic using TavilyClient to search the web for the given query and return the results.@mcp.tool() def web_search(query: str) -> str: """Search the web for information about the given query""" search_results = client.get_search_context(query=query) return search_results