template-mcp-server

This repository provides a CLI tool for quickly building MCP servers with TypeScript, offering dual transport support (stdio/HTTP), an MCP SDK, and an extensible structure for custom tools and resources.

53
6

@mcpdotdirect/template-mcp-server

License: MIT
TypeScript
MCP

This is a CLI tool designed to streamline the creation of Model Context Protocol (MCP) servers.

🚀 Usage

Utilize npx @mcpdotdirect/create-mcp-server or npm init @mcpdotdirect/create-mcp-server to initiate a new project.

⚙️ What's Included

The template provides a basic server setup with stdio and HTTP transport options, a structure for defining MCP tools, resources, and prompts, TypeScript configuration, and development scripts.

✨ Features

It features dual transport support (stdio/HTTP), full TypeScript support, and is built on the official MCP SDK. It's designed to be extensible, allowing easy addition of custom tools, resources, and prompts.

🏁 Getting Started

After project creation, install dependencies using npm, yarn, pnpm, or bun. Start the server using npm start (stdio) or npm run start:http (HTTP). Development modes with auto-reload are available via npm run dev and npm run dev:http.

🧩 Adding Custom Tools and Resources

When adding custom elements, use underscores instead of hyphens in names to ensure compatibility with Cursor and other AI tools.

📚 Documentation

Refer to the MCP Documentation for more information.

📜 License

Licensed under the MIT License.

Repository

MC
mcpdotdirect

mcpdotdirect/template-mcp-server

Created

March 10, 2025

Updated

March 26, 2025

Language

TypeScript

Category

Developer Tools