This repository provides a demo implementation of a Model Context Protocol (MCP) client using Web Workers and Server-Sent Events, built with Vite, React, and TypeScript, offering interactive testing.
Note: This project is a work in progress (WIP), subject to significant changes.
This repository hosts a demo implementation of a Model Context Protocol (MCP) client, leveraging Web Workers and Server-Sent Events (SSE) for communication. It provides an interactive UI for testing MCP functionality.
localhost:3020
.npm install
Start the development server: npm run dev
test.html
in your browser.src/
├── worker.ts # MCP client worker implementation
├── worker-test.ts # Worker test interface
├── types.ts # Type definitions
└── App.tsx # Main React application
The worker handles commands like connect
, disconnect
, listTools
, and callTool
, responding with status updates, results (ListToolsResult or CallToolResult), or error messages.
Build the project: npm run build
Run ESLint: npm run lint
Fork, branch, commit, push, and create a pull request.
yonaka15/mcp-client-demo
February 3, 2025
March 27, 2025
TypeScript