home / mcp / baidu ai search proxy mcp server
Provides a RESTful API proxy for Baidu AI search with MCP integration and headless browser support.
Configuration
View docs{
"mcpServers": {
"huchundong-baidu-ai-search": {
"url": "http://localhost:3001/mcp",
"headers": {
"MCP_PORT": "3001"
}
}
}
}You can run a lightweight MCP server that exposes a Baidu AI search proxy via a RESTful API, built on a headless browser workflow. This server supports Model Context Protocol (MCP) so you can connect it to AI applications and orchestrate search tasks efficiently.
You will start an MCP-enabled Baidu AI search proxy server and connect your MCP client to its HTTP endpoint. The MCP interface exposes tools that let you list available capabilities and call the search function in a streaming fashion. Use the MCP client to initiate searches, read results as they stream, and handle results in your application workflow. Ensure your client points to the MCP URL when you want to leverage the search tools.
Prerequisites: You need Node.js and Docker unless you plan to run only the MCP HTTP interface via the local server. Ensure you have network access to pull images and install dependencies.
# 1) Install Node.js if not present (check https://nodejs.org for your platform)
# 2) Install dependencies
npm installMCP support exposes a local MCP server that starts on port 3001 by default. You can adjust this port with the MCP_PORT environment variable. The MCP server is intended to run alongside the main application and provides a dedicated endpoint for tooling and streaming search results.
# Production MCP server start (from project root)
npm run mcp
# Development MCP server start (auto-restart on changes)
npm run mcp:devIf you want a contained deployment, you can rely on Docker to run the MCP server alongside the main application. Use Docker Compose to bring up both the app and the browser container, then start the MCP service from the host as needed.
Lists available MCP tools exposed by the server, including search and related capabilities.
Calls a specific MCP tool (for example, performing a Baidu search) and streams the result back to the client.