Skip to main content
Glama
MCP2Tavily

MCP2Tavily

MCP2Tavily

A MCP protocol server that implements web search functionality using the Tavily API.

Prerequisites

  • Python 3.11+

  • UV package manager

  • Tavily API key

Related MCP server: All-Search MCP Server

Installation

  1. Clone the repository

git clone <repository-url>
cd mcp2tavily
  1. Create and edit the .env file

# Create .env file
touch .env
# Add your Tavily API key to .env
echo "TAVILY_API_KEY=your_api_key_here" > .env
  1. Set up virtual environment with UV

# Create and activate virtual environment
uv venv
source .venv/bin/activate  # On Windows use: .venv\Scripts\activate
  1. Install dependencies

uv sync

Usage

Install as Claude extension

fastmcp install mcp2tavily.py

Development mode with MCP Inspector

To test the functionality using MCP Inspector:

fastmcp dev mcp2tavily.py

Once running, you can access the MCP Inspector at: http://localhost:5173

Available Tools

  • search_web(query: str): Search the web using Tavily API

  • search_web_info(query: str): Same as above, with Chinese description

Environment Variables

  • TAVILY_API_KEY: Your Tavily API key (required)

Step-by-Step Guide

手动添加Cline Continue Claude

Cline Continue Claude的MCP JSON FILE


"mcp2tavily": {
      "command": "uv",
      "args": [
        "run",
        "--with",
        "fastmcp",
        "--with",
        "python-dotenv",
        "--with",
        "tavily-python",
        "fastmcp",
        "run",
        "C:\\Users\\你的真实路径\\mcp2tavily.py"
      ],
      "env": {
        "TAVILY_API_KEY": "API密钥"
      }
    }

Cline

配置

Cline

配置

Cline

配置

EXAMPLE

搜索示例

Available Tools

4 tools
get_url_contentC

Get the content from a specific URL using Tavily API

Args:
    url (str): The URL to extract content from
    
Returns:
    str: The extracted content from the URL

Inputs: url (required).

get_url_content_infoC

从指定URL获取网页内容

参数:
    url (str): 需要提取内容的网页地址
    
返回:
    str: 从URL提取的网页内容

Inputs: url (required).

search_webC

Search the web for information using Tavily API

Inputs: query (required).

search_web_infoC

从网络搜索用户查询的信息

Inputs: query (required).

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    C2.5/5.0

    Scored across 4 tools

    Disambiguation1/5

    The tool set has severe ambiguity issues, with two pairs of tools that appear to be exact duplicates in different languages. get_url_content and get_url_content_info seem to perform identical functions (extracting content from a URL), as do search_web and search_web_info (searching the web). An agent would have no reliable way to choose between these overlapping tools.

    Naming Consistency3/5

    The naming follows a mixed convention with some consistency issues. While all tools use snake_case, the pattern is inconsistent: two tools use simple verb_noun format (get_url_content, search_web) while two others add '_info' suffix (get_url_content_info, search_web_info). This creates confusion about whether the '_info' tools are different operations or just translations.

    Tool Count2/5

    With only 4 tools, this feels thin for a web search/content extraction server, but the real problem is that these represent only 2 distinct operations duplicated across languages. The effective tool count is just 2, which is insufficient for comprehensive web interaction capabilities that might include filtering, advanced search parameters, or content analysis.

    Completeness2/5

    For a web search/content extraction server, there are significant gaps in the surface. While basic URL content fetching and web search are covered, there's no support for filtering search results, specifying search parameters, handling different content types, or any advanced web interaction features. The duplication across languages doesn't add functional coverage, leaving the tool set incomplete for sophisticated web tasks.

    Related MCP Connectors

    Related MCP Servers