--- name: web-search-and-fetch description: How to search the web and fetch URL content using the WebX11 proxy API tags: [search, fetch, web, proxy, api] category: research --- ## Steps 1. **Search the web:** - Call web_search(query) — uses /api/search which queries SearXNG + DDG fallback - Results include: title, url, content snippet, source engine - Always available (same-origin, no CORS issues) - 5-minute server-side cache for repeated queries 2. **Fetch URL content:** - Call web_fetch(url) — uses /api/extract which strips HTML, extracts clean text - Returns: title, content (up to 4000 chars), word_count, extraction method - SSRF protection blocks internal network addresses - 15-minute server-side cache 3. **Search flags (via terminal search command):** - search --summarize — adds AI-generated overview via Ollama - search --fetch — fetches content snippets for top 3 results 4. **When to use:** - User asks about current events, facts, research → call web_search - User says "read this article" or provides a URL → call web_fetch - For in-depth analysis: search first, then fetch top results