MCP Create Enhanced

MCP Create Enhanced

An enhanced dynamic MCP server management service that creates, runs, and manages Model Context Protocol servers with multi-language support and strict parameter validation.

Category
Visit Server

README

MCP Create Enhanced

An enhanced version of the dynamic MCP server management service that creates, runs, and manages Model Context Protocol (MCP) servers dynamically. This service runs as an MCP server itself and spawns/manages other MCP servers as child processes, enabling a robust and flexible MCP ecosystem.

๐Ÿ”„ Enhanced Version

This is an enhanced and improved version of tesla0225/mcp-create with significant improvements and new features.

<a href="https://glama.ai/mcp/servers/lnl6xjkkeq"> <img width="380" height="200" src="https://glama.ai/mcp/servers/lnl6xjkkeq/badge" alt="Create Server MCP server" /> </a>

๐ŸŒŸ Key Features

  • Dynamic MCP Server Creation: Create and run MCP server code on-the-fly
  • Multi-Language Support: TypeScript, JavaScript, and Python server templates
  • Parameter Validation: Strict JSON Schema validation with proper MCP error codes (-32602)
  • Server Persistence: Save/load/delete servers to/from disk
  • Tool Execution: Execute tools on child MCP servers with validation
  • Server Management: Update, restart, and delete servers as needed
  • Robust Python Support: Fixed Python server stability issues

๐Ÿ”ง Recent Improvements

โœจ New Features

  • MCP Parameter Validation: Strict validation with proper error codes (-32602 for invalid parameters)
  • Server Persistence: Save servers to disk and reload them later
  • Enhanced Python Support: Fixed Python server stability and closure issues
  • Better Error Handling: Improved error messages and MCP compliance

๐Ÿ› Bug Fixes

  • Fixed Python servers closing immediately after creation
  • Corrected pip installation to use python3 -m pip
  • Fixed duplicate process spawning issues
  • Improved EOF handling in Python templates
  • Better signal handling and graceful shutdown

๐Ÿ”„ Differences from Original

This enhanced version provides significant improvements over the original mcp-create:

Feature Original Enhanced
Parameter Validation โŒ Default values for missing params โœ… Strict JSON Schema validation with MCP errors
Python Support โš ๏ธ Unstable, immediate closure โœ… Robust, fixed stability issues
Server Persistence โŒ Not available โœ… Save/load/delete servers to/from disk
Error Handling โš ๏ธ Basic error messages โœ… Proper MCP error codes (-32602, -32601)
Process Management โš ๏ธ Duplicate process spawning โœ… Clean single process management
Documentation โš ๏ธ French comments, basic docs โœ… Full English docs with examples

Original Project: tesla0225/mcp-create

๐Ÿ“ฆ Installation

Note: Docker is the recommended method for running this service

Docker Installation (Recommended)

# Build the Docker image
docker build -t mcp-create .

# Run the Docker container
docker run -it --rm mcp-create

Manual Installation

# Clone the repository
git clone https://github.com/PlumyCat/mcp-create-enhanced.git
cd mcp-create-enhanced

# Install dependencies
npm install

# Build
npm run build

# Run
npm start

Testing Local Installation

After making changes to the code, you can test locally:

# Rebuild after changes
npm run build

# Test the server directly (it will wait for MCP protocol input)
npm start

# Or test with a simple echo command
echo '{"jsonrpc":"2.0","id":1,"method":"tools/list","params":{}}' | npm start

Using Local Version with Claude Desktop

To use your modified local version with Claude Desktop, update your claude_desktop_config.json:

{
  "mcpServers": {
    "mcp-create-local": {
      "command": "node",
      "args": ["./build/index.js"],
      "cwd": "/path/to/your/mcp-create-enhanced"
    }
  }
}

Note: Replace /path/to/your/mcp-create-enhanced with the actual path to your local repository.

Building Docker Image with Local Changes

To create a Docker image with your local changes:

# Build Docker image with your changes
docker build -t mcp-create-local .

# Test the Docker image
docker run -it --rm mcp-create-local

# Use with Claude Desktop
# Update claude_desktop_config.json:
{
  "mcpServers": {
    "mcp-create-local": {
      "command": "docker",
      "args": ["run", "-i", "--rm", "mcp-create-local"]
    }
  }
}

๐Ÿค– Claude Desktop Integration

Add the following to your Claude Desktop configuration file (claude_desktop_config.json):

{
  "mcpServers": {
    "mcp-create": {
      "command": "docker",
      "args": ["run", "-i", "--rm", "mcp-create"]
    }
  }
}

๐Ÿ› ๏ธ Available Tools

Tool Name Description Input Parameters Output
create-server-from-template Create an MCP server from template language: string<br>code?: string<br>dependencies?: object { serverId: string, message: string }
execute-tool Execute a tool on the server serverId: string<br>toolName: string<br>args: object Tool execution result
get-server-tools Get list of server tools serverId: string { tools: ToolDefinition[] }
delete-server Delete a server serverId: string { success: boolean, message: string }
list-servers Get list of running servers none { servers: string[] }
save-server Save a server to disk serverId: string<br>name: string Success message
list-saved-servers List saved servers none Array of saved servers
load-saved-server Load a saved server savedServerId: string New server ID
delete-saved-server Delete a saved server savedServerId: string Success message

๐Ÿ“‹ Usage Examples

Creating a New Server

{
  "name": "create-server-from-template",
  "arguments": {
    "language": "python",
    "code": "# Custom Python MCP server code here"
  }
}

Executing a Tool with Validation

{
  "name": "execute-tool",
  "arguments": {
    "serverId": "ba7c9a4f-6ba8-4cad-8ec8-a41a08c19fac",
    "toolName": "echo",
    "args": {
      "message": "Hello, dynamic MCP server!"
    }
  }
}

Parameter Validation Example

If you try to execute a tool with missing required parameters:

{
  "name": "execute-tool",
  "arguments": {
    "serverId": "ba7c9a4f-6ba8-4cad-8ec8-a41a08c19fac",
    "toolName": "echo",
    "args": {}
  }
}

You'll get a proper MCP error response:

{
  "jsonrpc": "2.0",
  "error": {
    "code": -32602,
    "message": "Invalid parameters: Missing required parameter: 'message'"
  }
}

๐Ÿ”„ Complete Workflow After Modifications

  1. Make your changes in the source code
  2. Rebuild Docker: docker build -t mcp-create-local .
  3. Test: docker run -it --rm mcp-create-local
  4. Update Claude Desktop configuration if needed

๐Ÿ’ก Practical Tips

  • Different tag: If you want to keep the old version, use a different tag:

    docker build -t mcp-create-local:v2 .
    
  • Cleanup: Remove unused old images:

    docker image prune
    
  • Verification: List your images to confirm:

    docker images | grep mcp-create
    

๐Ÿ—๏ธ Technical Specifications

  • Node.js 18 or higher
  • TypeScript (required)
  • Dependencies:
    • @modelcontextprotocol/sdk: MCP client/server implementation
    • child_process (Node.js built-in): Child process management
    • fs/promises (Node.js built-in): File operations
    • uuid: Unique server ID generation
    • zod: JSON schema validation

๐Ÿ”’ Security Considerations

  • Code Execution Restrictions: Consider sandboxing as the service executes arbitrary code
  • Resource Limitations: Set limits on memory, CPU usage, file count, etc.
  • Process Monitoring: Monitor and forcefully terminate zombie or runaway processes
  • Path Validation: Properly validate file paths to prevent directory traversal attacks
  • Parameter Validation: All tool parameters are validated against JSON schemas before execution

๐Ÿงช Testing

The project includes comprehensive validation for MCP parameters:

  • โœ… Valid parameters: Normal execution
  • โœ… Missing required parameters: Returns MCP error -32602 with explicit message
  • โœ… Wrong parameter types: Returns MCP error -32602 with type details
  • โœ… Unknown tools: Returns MCP error -32601
  • โœ… Optional parameters: Handled correctly

๐Ÿ“„ License

MIT

๐Ÿค Contributing

Feel free to submit issues and pull requests. This project has been enhanced with Claude Code assistance to provide robust MCP server management capabilities.


๐Ÿงช Generated with Claude Code

Co-Authored-By: Claude noreply@anthropic.com

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured