deepseek-tool-search
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@deepseek-tool-search Search for recent news on DeepSeek's new search API and summarize it"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
@lphal/deepseek-tool-search
English | 中文
An npx-friendly DeepSeek MCP server exposing web_search and web_fetch to any MCP client.
The implementation follows DeepSeek Harness's web tool split:
The default path calls DeepSeek's dedicated Search API without an auxiliary model response.
web_fetchcalls the DeepSeek Fetch API and returns page Markdown directly.An optional Messages-compatible mode mirrors Harness's legacy
web_search_20250305server-tool flow.Multi-query results are merged by source rank, deduplicated by URL, and bounded by the total result limit.
The server includes local 5 QPS pacing, request timeouts, response validation, and credential-safe errors.
All web content is labeled as untrusted data so webpage text is not treated as instructions.
Requires Node.js 20.19 or newer.
The development toolchain is pinned to pnpm@10.23.0 and typescript@6.0.3.
Installation
After publishing to npm, an MCP client can use:
{
"mcpServers": {
"deepseek-search": {
"command": "npx",
"args": ["-y", "@lphal/deepseek-tool-search"],
"env": {
"DEEPSEEK_API_KEY": "sk-your-key"
}
}
}
}This is an MCP stdio configuration, not a DeepSeek REST URL for an HTTP/SSE endpoint. The MCP client starts the server through npx.
After publishing, register it with Codex CLI:
codex mcp add deepseek-search \
--env DEEPSEEK_API_KEY="$DEEPSEEK_API_KEY" \
-- npx -y @lphal/deepseek-tool-searchUse codex mcp list to inspect the configuration. --env writes the key into Codex's MCP configuration; use your client's preferred environment or secret-reference mechanism if local persistence is unsuitable.
Local development:
pnpm install
pnpm build
pnpm start -- --check
pnpm start--check prints sanitized configuration without making network requests.
The working directory's .env is loaded automatically; .env.example documents the supported variables.
Related MCP server: AIE7-hw13-mcp
Tools
web_search
{
"queries": ["DeepSeek API documentation", "DeepSeek web search API"],
"count": 10,
"original_question": "How do I connect the DeepSeek search API to MCP?"
}count is the total number of sources after merging, from 1 to 50. When omitted, DEEPSEEK_SEARCH_COUNT is used.
web_fetch
{
"url": "https://api-docs.deepseek.com/guides/search"
}Configuration
Variable | Default | Purpose |
| required | DeepSeek API key from the process environment or |
|
|
|
|
| Search API base URL; the program appends |
|
| Fetch API base URL; the program appends |
|
| Messages-compatible base URL; the program appends |
|
| Model used only by Messages mode. |
|
| Maximum output tokens for Messages mode. |
|
| Maximum server-tool searches in one Messages request. |
|
| Default total number of returned sources, from 1 to 50. |
|
| Maximum queries per |
|
| Per-process Search request pacing. |
|
| Timeout for one network request and any pacing wait. |
|
| Character limit for each source summary. |
|
| Output limit for one fetched page. |
Custom proxy URLs must use http(s) and must not embed credentials. The API key must be a raw ASCII string without quotes, spaces, or newlines.
Harness Mapping
Harness | This project |
| MCP |
| MCP |
|
|
|
|
|
|
|
|
|
|
Messages-compatible mode incurs the latency and token cost of a full model call for every search, making it slower and more expensive than the dedicated Search API. Use it only when a custom gateway does not provide /v1/tools/search.
Development
pnpm install
pnpm typecheck
pnpm test
pnpm test:live
pnpm packpnpm test uses local mocks. pnpm test:live calls the real DeepSeek Search and Fetch APIs and skips when DEEPSEEK_API_KEY is absent.
Available Tools
2 toolsweb_fetchDeepSeek Web FetchBRead-onlyIdempotent
Fetch a public web page through DeepSeek and return Markdown content. Intranet and loopback addresses are not reachable through this API.
Inputs: url (required). Returns: url, title, content, truncated
web_searchDeepSeek Web SearchARead-only
Search the live web through DeepSeek. Returns deduplicated source titles, URLs, snippets, summaries, and publication dates.
Inputs: queries (required), count, original_question. Returns: mode, queries, results, truncated
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 2 tools
web_search retrieves results from the live web while web_fetch retrieves the content of a specific URL; the descriptions make the search-then-fetch distinction unmistakable. There is no realistic scenario where an agent would confuse the two.
Both names follow the same 'web_<verb>' pattern with parallel structure (search/fetch). Short, predictable, and immediately readable.
Two tools is thin for the stated scope, though the pairing of search and fetch is a natural minimal set. It sits at the borderline of the 1-2 tool range flagged as under-scoped.
Search plus page fetch covers the core web-retrieval lifecycle with no dead ends for typical lookups. Minor gaps exist around pagination controls, multi-URL batch fetching, or result filtering, but agents can work around these.
Maintenance
Related MCP Connectors
Web search API and MCP server for developers building AI agents.
Unified 15-tool SEO, SERP, clean Markdown & GEO (LLM citation Share-of-Voice) MCP server.
Docs: https://docs.keenable.ai/mcp-server Keenable is a free, remote MCP server that gives agents access to the web index. Search the web with ranked results and date/site filters, then fetch any indexed page as clean markdown. Works out of the box with no account or API key.
Related MCP Servers
- AlicenseAqualityDmaintenanceA general MCP server providing web search capabilities using DeepSeek's native online search API.141 npm33MIT
- FlicenseBqualityDmaintenanceMCP server using Tavily API for web search, enabling web search queries via stdio transport.5-
- AlicenseAqualityDmaintenanceAn MCP server that provides web search powered by DeepSeek's native search API, returning AI-generated answers with source links. Integrates with MCP-compatible clients like Claude Code and Cursor.1MIT
- AlicenseAqualityCmaintenanceEnables MCP clients such as Claude Code to run real-time web searches and fetch public web pages as Markdown through DeepSeek's official search and fetch APIs, with result pagination and response caching. Runs over stdio and only requires a DeepSeek API key, needing no browser, Docker, or database.21MIT