eMCP
@joeymeere
About eMCP
A framework for building simple MCP servers with custom middleware
Config
Add this server to your MCP-compatible client using the configuration below.
{
"mcpServers": {
"emcp": {
"command": "bun",
"args": [
"run",
"example:basic"
]
}
}
}Tools
No tools detected
We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.
Overview
What is eMCP?
eMCP is a fork of the LiteMCP TypeScript library that adds built-in authentication handling and custom layered middleware support. It is designed as a near drop-in replacement for LiteMCP, with all added features being optional.
How to use eMCP?
Install via npm or Bun (npm i emcp or bun add emcp). You can run provided examples (bun run example:basic, bun run example:auth, etc.). Create a server instance by passing an authenticationHandler function and use server.use() to add custom middleware that runs before and after the standard MCP handler.
Key features of eMCP
- All existing LiteMCP features preserved
- Built‑in authentication handler for requests
- Custom layered middleware support (runs in registration order)
- Near drop‑in replacement for LiteMCP
Use cases of eMCP
- Add authentication checks to every tool, resource, or prompt call
- Log request‑response cycles with timing via middleware
- Build complex MCP servers with reusable middleware layers
- Migrate existing LiteMCP projects without major code changes
FAQ from eMCP
How is eMCP different from LiteMCP?
eMCP extends LiteMCP with an optional built‑in authentication handler and a custom middleware system, while remaining a near drop‑in replacement.
How does middleware execution work?
Middleware runs in the order it was registered. Each middleware calls next(), then the standard MCP handler runs. After the handler completes, middleware code after next() executes in reverse order.
What runtime or dependencies are required?
eMCP is a TypeScript library that requires Node.js with npm or Bun. It is installed via npm i emcp or bun add emcp.
Is authentication mandatory?
No, the authentication handler is optional. If not set, requests proceed without authentication.
Does eMCP support custom transports?
The README does not mention specific transports; it inherits the transport capabilities of LiteMCP (e.g., stdio, SSE).
Frequently asked questions
How is eMCP different from LiteMCP?
eMCP extends LiteMCP with an optional built‑in authentication handler and a custom middleware system, while remaining a near drop‑in replacement.
How does middleware execution work?
Middleware runs in the order it was registered. Each middleware calls `next()`, then the standard MCP handler runs. After the handler completes, middleware code after `next()` executes in reverse order.
What runtime or dependencies are required?
eMCP is a TypeScript library that requires Node.js with npm or Bun. It is installed via `npm i emcp` or `bun add emcp`.
Is authentication mandatory?
No, the authentication handler is optional. If not set, requests proceed without authentication.
Does eMCP support custom transports?
The README does not mention specific transports; it inherits the transport capabilities of LiteMCP (e.g., stdio, SSE).
Basic information
More Other MCP servers
MaxKB
1Panel-dev🔥 MaxKB is an open-source platform for building enterprise-grade agents. 强大易用的开源企业级智能体平台。

YOUB
Connect your AI assistant to your own YOUB endurance training account. Read recorded activities with full analysis, planned sessions, race goals, wellness (HRV, sleep, resting HR) and your athletic profile. Create or mov
AutoBrowser MCP
autobrowser-aiBrowser MCP is a Model Context Provider (MCP) server that allows AI applications to control your browser
Inbox Zero AI
elie222The world's best AI personal assistant for email. Open source app to help you reach inbox zero fast.
Activepieces
activepiecesAI Agents & MCPs & AI Workflow Automation • (~400 MCP servers for AI agents) • AI Automation / AI Agent with MCPs • AI Workflows & AI Agents • MCPs for AI Agents
Comments