
AgentSearch (agentsearchhq.com)
io.github.agentsearchhq-coderv1.1.1更新于 Oct 3, 2026
AgentSearch web search, page extract and JS page render for agents. Self-hosted API via stdio.
概览
让助手通过你自建的 AgentSearch 兼容 API 执行网页搜索、页面提取和 JavaScript 页面渲染。
- 功能
- 通过 stdio 提供三个只读工具:agentsearch_web_search 用于搜索查询,agentsearch_extract 用于提取已有 URL 的页面内容,agentsearch_render 用无头 Chromium 渲染依赖 JavaScript 的页面,返回标题、状态、元数据以及 markdown、文本、HTML 或链接,并可选截图。三者都通过 HTTP 调用你自己的 AgentSearch 兼容后端。
- 适用场景
- 当你已经运行 AgentSearch 兼容后端,并希望 Cursor、Claude Desktop 或其他 MCP 宿主能够搜索网页、提取页面或渲染单页应用时使用。静态页面优先用 extract,当 extract 返回空或部分内容时改用 render。
- 运行要求
- 需要 Node.js 20 或更高版本,以及你自己的 AgentSearch 兼容 API。AGENTSEARCH_BASE_URL 为必填且没有默认值,缺失时进程会在启动时退出。AGENTSEARCH_API_KEY 可选,以 Bearer 令牌发送。需要能访问你的后端网络。
安装
在 SourceWeft 中
- 打开 控制台中的 AgentSearch (agentsearchhq.com),将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
agentsearch-mcp
MCP (Model Context Protocol) server for people running their own AgentSearch-compatible backend. It exposes web search, page extract, and JavaScript page rendering (headless browser) to Cursor, Claude Desktop, and other MCP hosts over stdio.
AGENTSEARCH_BASE_URL is required and points at that API. There is no built-in default host.
For pay-per-call access with no backend of your own, use Pocket's official MCP server instead:
That server calls agentsearch-web-search-v1 and agentsearch-web-extract-v1 at $0.005/call over x402. Details: https://agentsearchhq.com/?utm_source=github&utm_medium=readme&utm_campaign=mcp
This package calls your API directly:
- Search:
POST {AGENTSEARCH_BASE_URL}/v1/searchwith body{ "query": "...", "max_results": 5 } - Extract:
POST {AGENTSEARCH_BASE_URL}/v1/extract - Render:
POST {AGENTSEARCH_BASE_URL}/v1/render(headless Chromium; OpenAPI spec)
Tools
For agentsearch_render, target-site failures (DNS/TLS errors, timeouts, bot walls, robots.txt) come back as a normal result whose JSON has a non-null error object (code, message, retryable); bad input (400), oversize body (413), rate limits (429) and backend faults (500) are MCP errors. The backend enforces a ~4.2 s render deadline.
Requirements
- Node.js 20+
- Your own AgentSearch-compatible API. Set
AGENTSEARCH_BASE_URLto its base URL. The process exits at startup if that variable is missing.
Install
From a local checkout:
Scripts: build → tsc, start → node dist/index.js, test → build + node --test test/*.mjs, prepare → runs build.
Binary: agentsearch-mcp → dist/index.js
Environment variables
See .env.example. Never commit a real .env.
Cursor
Project (.cursor/mcp.json) or user (~/.cursor/mcp.json / Cursor Settings → MCP):
Optional API key:
Claude Desktop
Edit Claude Desktop config (claude_desktop_config.json):
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
Restart Claude Desktop after saving.
Local run
If AGENTSEARCH_BASE_URL is unset, the process prints an error and exits.
License
MIT
来源:README.md,提交 9654fc0
工具
0版本历史
1- v1.1.1最新Oct 3, 2026


