
worker do websockets sse example
使用 Cloudflare Workers 和 Durable Objects 实现的 Model Context Protocol (MCP) 参考示例。
Repository Info
About This Server
使用 Cloudflare Workers 和 Durable Objects 实现的 Model Context Protocol (MCP) 参考示例。
Model Context Protocol (MCP) - This server can be integrated with AI applications to provide additional context and capabilities, enabling enhanced AI interactions and functionality.
Documentation
WebSockets MCP Math Demo
A reference implementation demonstrating the Model Context Protocol (MCP) using Cloudflare Workers and Durable Objects.
We create an MCP server in a Durable object using DurableMCP and expose a web frontend that can connect
call those endpoints.
Overview
This repository provides a reference implementation of MCP over WebSockets. It showcases:
- Complete MCP client-server architecture
- Tool discovery and invocation
- Deployment using Cloudflare Workers
Development
Install dependencies:
pnpm install
Start the development server with:
pnpm run dev
Your application will be available at http://localhost:5173.
Deployment
npx deploy
Quick Start
Clone the repository
git clone https://github.com/jmorrell-cloudflare/worker-do-websockets-sse-exampleInstall dependencies
cd worker-do-websockets-sse-example
npm installFollow the documentation
Check the repository's README.md file for specific installation and usage instructions.
Repository Details
Recommended MCP Servers
Discord MCP
Enable AI assistants to seamlessly interact with Discord servers, channels, and messages.
Knit MCP
Connect AI agents to 200+ SaaS applications and automate workflows.
Apify MCP Server
Deploy and interact with Apify actors for web scraping and data extraction.
BrowserStack MCP
BrowserStack MCP Server for automated testing across multiple browsers.
Zapier MCP
A Zapier server that provides automation capabilities for various apps.