web_search
Search the web using multiple search engines to find current information, articles, or references. Merges results from DuckDuckGo and Bing by default, with optional API keys for higher quality.
Instructions
Search the web using multiple search engines. Use this tool when you need to find current information, articles, or references from the internet. Supports DuckDuckGo, Google, and Bing as free engines, with optional SerpAPI (requires SERPAPI_KEY env var) and Tavily (requires TAVILY_API_KEY env var) for higher-quality, more stable results. By default ('both'), queries DuckDuckGo and Bing concurrently and merges results, providing good coverage without any API keys. Each result includes title, URL, and description snippet. Rate limiting and caching are applied automatically.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | The search query string. Use specific keywords for best results. Supports natural language queries (e.g., 'best practices for Python async') as well as keyword-style queries (e.g., 'Python async await tutorial'). | |
| max_results | No | Maximum number of results to return per search engine. Default is 10. Range: 1-20. Higher values increase latency. Actual count may be lower if the engine returns fewer matches. | |
| search_engine | No | Which search engine(s) to query. Options: 'duckduckgo' (free, no API key needed), 'bing' (free), 'google' (free), 'serpapi' (requires SERPAPI_KEY), 'tavily' (requires TAVILY_API_KEY), 'both' (default — uses DuckDuckGo + Bing concurrently for broader coverage without API keys). Use 'serpapi' or 'tavily' when you need higher-quality results and have the API key configured. | both |