MCP Analytics Middleware
A lightweight TypeScript middleware for MCP SDK servers that delivers analytics. Captures request metrics, performance data, and usage patterns with minimal overhead. Features real-time monitoring, configurable data collection, and detailed reporting - all with full type safety.
Overview
mcp-analytics-middleware is a lightweight TypeScript middleware designed for MCP SDK servers that provides analytics capabilities. It captures request metrics, performance data, and usage patterns with minimal overhead.
To use mcp-analytics-middleware, integrate it into your MCP SDK server setup. Configure the middleware to collect the desired metrics and enable real-time monitoring and reporting.
- Real-time monitoring of request metrics and performance data. - Configurable data collection to suit specific needs. - Detailed reporting with full type safety to ensure reliability.
- Monitoring the performance of web applications built on MCP SDK.
- Analyzing usage patterns to optimize server performance.
- Generating reports for performance audits and improvements.
Add to your AI client
Use these steps to connect MCP Analytics Middleware in Cursor, Claude, VS Code, and other MCP-compatible apps. The same JSON appears in the Use with menu above for one-click copy.
Cursor
Add this to your .cursor/mcp.json file in your project root, then restart Cursor.
.cursor/mcp.json
{
"mcpServers": {
"mcp-analytics-middleware-phillip-kemper": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-mcp-analytics-middleware-phillip-kemper"
]
}
}
}Claude Desktop
Add this server entry to the mcpServers object in your Claude Desktop config, then restart the app.
~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows)
{
"mcpServers": {
"mcp-analytics-middleware-phillip-kemper": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-mcp-analytics-middleware-phillip-kemper"
]
}
}
}Claude Code
Add this to your project's .mcp.json file. Claude Code will detect it automatically.
.mcp.json (project root)
{
"mcpServers": {
"mcp-analytics-middleware-phillip-kemper": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-mcp-analytics-middleware-phillip-kemper"
]
}
}
}VS Code (Copilot)
Add this to your .vscode/mcp.json file. Requires the GitHub Copilot extension with MCP support enabled.
.vscode/mcp.json
{
"servers": {
"mcp-analytics-middleware-phillip-kemper": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-mcp-analytics-middleware-phillip-kemper"
]
}
}
}Windsurf
Add this to your Windsurf MCP config file, then restart Windsurf.
~/.codeium/windsurf/mcp_config.json
{
"mcpServers": {
"mcp-analytics-middleware-phillip-kemper": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-mcp-analytics-middleware-phillip-kemper"
]
}
}
}Cline
Open Cline settings, navigate to MCP Servers, and add this server configuration.
Cline MCP Settings (via UI)
{
"mcpServers": {
"mcp-analytics-middleware-phillip-kemper": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-mcp-analytics-middleware-phillip-kemper"
]
}
}
}FAQ
What programming language is mcp-analytics-middleware written in?
It is written in TypeScript, ensuring type safety and better development experience.
Is there any overhead when using this middleware?
The middleware is designed to have minimal overhead, allowing for efficient performance monitoring without significant impact on server operations.
Can I customize the data collection?
Yes! The middleware allows for configurable data collection based on your specific requirements.