MCP SSE Client-Server
@flyingcloud-code
关于 MCP SSE Client-Server
using sse in client and server
基本信息
配置
使用下面的配置,将此服务器添加到你的 MCP 客户端。
{
"mcpServers": {
"mcp-sse-client-server": {
"command": "uv",
"args": [
"venv"
]
}
}
}工具
未检测到工具
工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。
概览
What is MCP SSE Client-Server?
A Python implementation of an MCP client and server that communicates using Server-Sent Events (SSE). It integrates with MCP platform tools for web search, content retrieval, and date/weather utilities, and is intended for developers building asynchronous AI assistants.
How to use MCP SSE Client-Server?
Clone the repository, create a virtual environment, and install dependencies with uv sync .. Configure API keys in a .env file (OpenAI or OpenRouter). Start the server first with uv run mcp-server-search.py, then run the client with uv run mcp-client-sse.py --server http://localhost:8081/sse --verbose. Use --help for full options.
Key features of MCP SSE Client-Server
- SSE-based communication between client and server
- Integration with MCP platform tools (google_search, get_web_content)
- Asynchronous processing using Python's asyncio
- Comprehensive logging and error handling
- OpenAI API integration with fallback to OpenRouter
- Environment variable configuration support
Use cases of MCP SSE Client-Server
- Perform web searches via the google_search MCP tool
- Fetch full content of web pages with get_web_content
- Retrieve the weekday for a given date
- Get weather information for a specific date
- Build real-time streaming AI assistants with MCP
FAQ from MCP SSE Client-Server
What runtime is required?
Python 3.10 or higher. Dependencies include httpx, python-dotenv, openai, and mcp[cli].
How do I configure API keys?
Create a .env file in the project root with either OPENAI_API_KEY or OPENROUTER_API_KEY. Optionally set custom base URLs.
What transport does the server use?
The server uses Server-Sent Events (SSE) over HTTP. The default server URL is http://localhost:8081/sse.
Where are logs stored?
The client writes logs to mcp-client.log with timestamps and detailed information.
Can I use OpenRouter instead of OpenAI?
Yes. If you set OPENROUTER_API_KEY in your .env file, the client will fall back to OpenRouter. You can also specify a custom base URL.
其他 分类下的更多 MCP 服务器
🚀 Model Context Protocol (MCP) Curriculum for Beginners
microsoftThis open-source curriculum introduces the fundamentals of Model Context Protocol (MCP) through real-world, cross-language examples in .NET, Java, TypeScript, JavaScript, Rust and Python. Designed for developers, it focuses on practical techniques for building modular, scalable,
Inbox Zero AI
elie222The world's best AI personal assistant for email. Open source app to help you reach inbox zero fast.
XcodeBuildMCP
cameroncookeA Model Context Protocol (MCP) server and CLI that provides tools for agent use when working on iOS and macOS projects.
Mobile Mcp
mobile-nextModel Context Protocol Server for Mobile Automation and Scraping (iOS, Android, Emulators, Simulators and Real Devices)
Codelf
unbugA search tool helps dev to solve the naming things problem.
评论