Implements an MCP server using Express.js as the HTTP framework for handling MCP JSON-RPC requests and responses, with support for Streamable HTTP transport.
Built with TypeScript to provide type safety throughout the MCP server implementation, enhancing code quality and developer experience.
Express MCP Server
A stateless Model Context Protocol (MCP) server built with Express and TypeScript.
Features
- Stateless MCP server implementation with modern Streamable HTTP transport
- TypeScript for type safety
- Express.js for HTTP handling
Requirements
- Node.js 18+
- npm or yarn
Installation
Development
Server Structure
Available Functionality
This server implements a simple echo endpoint with three MCP components:
- Resource:
echo://{message}
- Returns the message as a resource - Tool:
echo
- Echoes the provided message back as a tool response - Prompt:
echo
- Creates a user prompt with the provided message
MCP Protocol
This server implements the Model Context Protocol (MCP), a standardized way for LLMs to interact with external data and functionality. It exposes a stateless API endpoint that responds to JSON-RPC requests.
API Usage
Send a POST request to /mcp
with a JSON-RPC payload:
Initialize
Call Echo Tool
License
This server cannot be installed
remote-capable server
The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.
A stateless Model Context Protocol server that implements a simple echo functionality with resource, tool, and prompt components, enabling LLMs to echo back messages through standardized MCP interactions.
Related MCP Servers
- -securityFlicense-qualityA Model Context Protocol server that allows LLMs to execute shell commands and receive their output in a controlled manner.Last updated -Python
- AsecurityAlicenseAqualityA Model Context Protocol server that gives LLMs the ability to interact with Ethereum networks, manage wallets, query blockchain data, and execute smart contract operations through a standardized interface.Last updated -313232TypeScriptMIT License
- AsecurityAlicenseAqualityAn educational implementation of a Model Context Protocol server that demonstrates how to build a functional MCP server for integrating with various LLM clients like Claude Desktop.Last updated -188PythonMIT License
- AsecurityAlicenseAqualityA simple server implementing the Model Context Protocol (MCP) that echoes messages back, designed for testing MCP clients.Last updated -1PythonMIT License