@mcpkit/mcpm v0.1.1
mcpm - Instantly Generate a MCP Server
mcpm is a CLI tool leveraging the MCP TypeScript SDK to quickly scaffold and manage Model Context Protocol (MCP) server projects. With just a single command, you can create a fully functional MCP server and immediately connect it to Claude Code or your own LLM application.
Features
Project Scaffolding:
Usemcpm initto create a new, production-ready MCP server project.Preconfigured Boilerplate:
Generates a ready-to-run project including a sample MCP server with resource and tool examples.
Installation
Via NPM
npm install -g @mcpkit/mcpmQuick Start
Initialize a new MCP server project:
mcpm init --name my-mcp-serverThis creates a new directory named my-mcp-server with a basic MCP server project scaffold.
Navigate and install dependencies:
cd my-mcp-server
npm installBuild and run your server:
npm run buildYour MCP server is now ready to use with Claude Code.
Connecting Your MCP Server to Claude Code
Once you've generated and started your MCP server, you can connect it to Claude Code to test its capabilities:
Connect Your MCP Server to Claude Code
- Add your MCP server to Claude Code:
# Basic syntax
$ claude mcp add <server-name> <command> [args...]
# Example: Adding your generated MCP server
$ claude mcp add my-mcp-server -- node dist/server.js- Verify your server was added successfully:
$ claude mcp list- Select your MCP server and start using it with Claude:
$ claude
> add the number 5 and the number 7Project Structure
After running mcpm init, your project will include:
src/server.ts: Starter MCP server file with example commands (e.g., an addition tool and a greeting resource).package.json: Preconfigured for the MCP SDK and TypeScript.tsconfig.json: Standard TypeScript configuration.
Usage
The generated MCP server includes examples of:
- Tools: Example tool for basic operations (e.g., addition).
- Resources: Serving dynamic content such as greeting messages.
- Prompts: Predefined templates to facilitate LLM interactions.
Customize src/server.ts to add or modify tools, resources, and prompts as needed. For advanced usage, refer to the MCP TypeScript SDK documentation.
Advanced Configuration
You can also add your MCP server using JSON configuration:
$ claude mcp add-json my-mcp-server '{"type":"stdio","command":"node","args":["dist/server.js"],"env":{"DEBUG":"true"}}'Note: When developing your MCP server, you may need to restart it after making changes. You can update the server configuration in Claude Code without removing and re-adding it.
Contributing
Contributions are welcome! To contribute:
- Fork the repository.
- Create a new branch for your feature or bugfix.
- Write tests and ensure code quality (ESLint/Prettier recommended).
- Submit a pull request with a clear description of your changes.
License
This project is licensed under the MIT License.
Support
If you encounter any issues or have questions, please open an issue in the GitHub repository.