SoSearch API
A lightning-fast pseudo Web Search Engine API written in Rust â also works as an MCP server for AI agents. This project emulates popular APIs like SerpAPI or Tavily without needing official and expensive API keys, by multiplexing requests to popular engines directly and scraping the results concurrently.
Philosophy
- Performance: Powered by
tokiofor async concurrent I/O. - Bot Bypass: Leverages
rquestwith TLS impersonation (e.g., simulating a Chrome 124 browser footprint at the TLS/HTTP2 layer) to minimize blocking vs standard HTTP clients (the Rust equivalent ofcurl_cffi). - Standardized: Normalizes
DuckDuckGo,Yahoo, andBraveHTML results into a standardizedSearchResultJSON array.
Core Stack
đ Supported Search Engines
- DuckDuckGo (Primary standard search)
- Yahoo (Powered by Bing)
- Brave Search (Independent index)
đ Project Structure
src/ âââ main.rs # Entry point: HTTP server or MCP mode (--mcp) âââ search.rs # Shared concurrent search logic âââ mcp.rs # MCP stdio server (JSON-RPC 2.0) âââ models.rs # SearchResultItem, SearchResponse structs âââ engines/ âââ mod.rs # SearchEngine enum + trait dispatch âââ duckduckgo.rs # DuckDuckGo scraper âââ yahoo.rs # Yahoo scraper (Bing-powered) âââ brave.rs # Brave Search scraper examples/ âââ fetch_html.rs # Download raw HTML for offline debugging âââ test_parser.rs # Offline CSS selector iteration .gemini/ # Gemini CLI agent config âââ GEMINI.md # Project-level system prompt âââ settings.json # MCP server configuration âââ skills/ # Project-level agent skills âââ sosearch-engine-dev/ # Scraper development workflow âââ sosearch-api-ops/ # API operations & deployment .agents/ # Generic agent config (compatible with multiple AI tools) âââ skills/ # Same skills, alternative discovery path âââ sosearch-engine-dev/ âââ sosearch-api-ops/
đ€ Agent Skills & MCP Support
This project includes built-in AI agent support for both Gemini CLI and other tools that follow the .agents/ convention.
Available Skills
| Skill | Description |
|---|---|
sosearch-engine-dev | Full workflow for adding/debugging search engine scrapers: fetch HTML â test selectors offline â decode URLs â integrate |
sosearch-api-ops | Operations guide: build, run, test, deploy (local + Docker), troubleshoot |
MCP Servers
Configured in .gemini/settings.json:
| Server | Package | Purpose |
|---|---|---|
filesystem | @modelcontextprotocol/server-filesystem | Scoped file access to project directory |
Usage with Gemini CLI
bashcd /path/to/SoSearch gemini # Skills are auto-discovered. Ask: "How do I add a new search engine?"
đ MCP Server Mode
Run SoSearch as an MCP server for AI agents (Claude, Gemini, Cursor, etc.):
bash./SoSearch --mcp
Configuration
Claude Desktop (claude_desktop_config.json):
json{ "mcpServers": { "sosearch": { "command": "/path/to/SoSearch", "args": ["--mcp"] } } }
Gemini CLI (.gemini/settings.json):
json{ "mcpServers": { "sosearch": { "command": "/path/to/SoSearch", "args": ["--mcp"] } } }
This exposes a web_search tool that AI agents can call to search the web.
Windows Configuration
Claude Desktop (%APPDATA%\Claude\claude_desktop_config.json):
json{ "mcpServers": { "sosearch": { "command": "C:\\path\\to\\SoSearch.exe", "args": ["--mcp"] } } }
đ Quick Start
Linux / macOS
bash# Download pre-built binary or build from source cargo run --release curl "http://localhost:10080/search?q=hello+world"
Windows
äœżçšéąçŒèŻäșèżć¶ïŒ
ä» GitHub Releases äžèœœ SoSearch-windows-amd64.zipïŒè§ŁććïŒ
powershell# ćŻćš HTTP æćĄ .\SoSearch.exe # ćŠćŒäžäžȘç»ç«Żæ”èŻ Invoke-RestMethod "http://localhost:10080/search?q=hello+world" | ConvertTo-Json # æäœżçš curl curl.exe "http://localhost:10080/search?q=hello+world"
仿șç çŒèŻïŒéèŠćźèŁ RustăCMakeăNASMăLLVM/ClangïŒïŒ
powershell# ćźèŁ äŸè” (äœżçš Chocolatey) choco install cmake nasm llvm -y # çŒèŻèżèĄ cargo run --release
MCP æšĄćŒïŒ
powershell.\SoSearch.exe --mcp
Refer to QUICK_START.md for full instructions.
đ License
CC BY-NC 4.0 â éćäžçšéćŻèȘç±äœżçšăäżźæčćććă
đ Community
éŠćäș LINUX DO 瀟ćșïŒæŹąèż Star â ć PRïŒ




