Tavily MCP Server with Proxy Support

Tavily MCP Server with Proxy Support

Enables LLMs to perform sophisticated web searches through proxy servers using Tavily's API, supporting comprehensive web searches, direct question answering, and recent news article retrieval with AI-extracted content.

tulong66

Search
Browser Automation
Python
Visit Server

README

Tavily MCP Server with Proxy Support

A Model Context Protocol server that provides AI-powered web search capabilities using Tavily's search API, with added support for HTTP/HTTPS proxy configurations. This server enables LLMs to perform sophisticated web searches through proxy servers, get direct answers to questions, and search recent news articles with AI-extracted relevant content.

Features

  • All original Tavily MCP Server features
  • HTTP/HTTPS proxy support through environment variables
  • Enhanced logging for proxy configurations
  • Robust error handling for proxy-related issues

Available Tools

  • tavily_web_search - Performs comprehensive web searches with AI-powered content extraction.

    • query (string, required): Search query
    • max_results (integer, optional): Maximum number of results to return (default: 5, max: 20)
    • search_depth (string, optional): Either "basic" or "advanced" search depth (default: "basic")
  • tavily_answer_search - Performs web searches and generates direct answers with supporting evidence.

    • query (string, required): Search query
    • max_results (integer, optional): Maximum number of results to return (default: 5, max: 20)
    • search_depth (string, optional): Either "basic" or "advanced" search depth (default: "advanced")
  • tavily_news_search - Searches recent news articles with publication dates.

    • query (string, required): Search query
    • max_results (integer, optional): Maximum number of results to return (default: 5, max: 20)
    • days (integer, optional): Number of days back to search (default: 3)

Installation

Use pip

pip install mcp-tavily-proxy

or if you have uv installed:

uv pip install mcp-tavily-proxy

Build from Source

Clone this repository and build and install the program:

git clone https://github.com/tulong66/mcp-tavily-proxy.git
cd mcp-tavily-proxy
uv build
uv pip install .

Configuration

API Key and Proxy Settings

The server requires a Tavily API key and supports proxy configuration through environment variables:

  1. Set required environment variables:
# Tavily API Key
export TAVILY_API_KEY=your_api_key_here

# Proxy Settings (if needed)
export HTTP_PROXY=http://your-proxy:port
export HTTPS_PROXY=http://your-proxy:port
  1. Or provide API key as a command-line argument:
python -m mcp_server_tavily --api-key=your_api_key_here

Configure for Claude.app

Add to your Claude settings:

{
  "mcpServers": {
    "tavily": {
      "command": "python",
      "args": ["-m", "mcp_server_tavily"]
    },
    "env": {
      "TAVILY_API_KEY": "your_api_key_here",
      "HTTP_PROXY": "http://your-proxy:port",
      "HTTPS_PROXY": "http://your-proxy:port"
    }
  }
}

Examples

For a regular search:

Tell me about Anthropic's newly released MCP protocol

To generate a report with explicit exclusions:

Tell me about redwood trees. Please use MLA format in markdown syntax and include the URLs in the citations. Exclude Wikipedia sources.

For news search:

Give me the top 10 AI-related news in the last 5 days

Debugging

Enable debug logging to see detailed proxy configuration information:

export TAVILY_LOG_LEVEL=DEBUG
python -m mcp_server_tavily

You can also use the MCP inspector:

npx @modelcontextprotocol/inspector python -m mcp_server_tavily

Contributing

Contributions are welcome! Please feel free to submit pull requests to help improve the proxy support or add new features.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Acknowledgments

This project is based on the original mcp-tavily with added proxy support functionality.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Playwright MCP Server

Playwright MCP Server

Provides a server utilizing Model Context Protocol to enable human-like browser automation with Playwright, allowing control over browser actions such as navigation, element interaction, and scrolling.

Featured
Local
TypeScript
@kazuph/mcp-fetch

@kazuph/mcp-fetch

Model Context Protocol server for fetching web content and processing images. This allows Claude Desktop (or any MCP client) to fetch web content and handle images appropriately.

Featured
Local
JavaScript
DuckDuckGo MCP Server

DuckDuckGo MCP Server

A Model Context Protocol (MCP) server that provides web search capabilities through DuckDuckGo, with additional features for content fetching and parsing.

Featured
Python
YouTube Transcript MCP Server

YouTube Transcript MCP Server

This server retrieves transcripts for given YouTube video URLs, enabling integration with Goose CLI or Goose Desktop for transcript extraction and processing.

Featured
Python
serper-search-scrape-mcp-server

serper-search-scrape-mcp-server

This Serper MCP Server supports search and webpage scraping, and all the most recent parameters introduced by the Serper API, like location.

Featured
TypeScript
The Verge News MCP Server

The Verge News MCP Server

Provides tools to fetch and search news from The Verge's RSS feed, allowing users to get today's news, retrieve random articles from the past week, and search for specific keywords in recent Verge content.

Featured
TypeScript
Google Search Console MCP Server

Google Search Console MCP Server

A server that provides access to Google Search Console data through the Model Context Protocol, allowing users to retrieve and analyze search analytics data with customizable dimensions and reporting periods.

Featured
TypeScript