MCP Server Template 🛠️
A starter template for building your own Model Context Protocol (MCP) server. This template provides the basic structure and setup needed to create custom MCPs that can be used with Cursor or Claude Desktop.
Features
- Basic MCP server setup with TypeScript
- Sample tool implementation
- Ready-to-use project structure
- Built with @modelcontextprotocol/sdk
Project Structure
mcp-server-template/
├── index.ts # Main server implementation
├── package.json # Project dependencies
├── tsconfig.json # TypeScript configuration
└── build/ # Compiled JavaScript output
Getting Started
- Clone this template:
git clone [your-repo-url] my-mcp-server
cd my-mcp-server
- Install dependencies:
pnpm install
- Build the project:
pnpm run build
This will generate the /build/index.js file - your compiled MCP server script.
Using with Cursor
- Go to Cursor Settings -> MCP -> Add new MCP server
- Configure your MCP:
- Name: [choose your own name]
- Type: command
- Command:
node ABSOLUTE_PATH_TO_MCP_SERVER/build/index.js
Using with Claude Desktop
Add the following MCP config to your Claude Desktop configuration:
{
"mcpServers": {
"your-mcp-name": {
"command": "node",
"args": ["ABSOLUTE_PATH_TO_MCP_SERVER/build/index.js"]
}
}
}
Development
The template includes a sample tool implementation in index.ts. To create your own MCP:
- Modify the server configuration in
index.ts:
const server = new McpServer({
name: "your-mcp-name",
version: "0.0.1",
});
- Define your custom tools using the
server.tool()method:
server.tool(
"your-tool-name",
"Your tool description",
{
// Define your tool's parameters using Zod schema
parameter: z.string().describe("Parameter description"),
},
async ({ parameter }) => {
// Implement your tool's logic here
return {
content: [
{
type: "text",
text: "Your tool's response",
},
],
};
}
);
- Build and test your implementation:
npm run build
Contributing
Feel free to submit issues and enhancement requests!
License
MIT
MCP Server Template
Project Details
- jatinsandilya/mcp-server-template
- send-email
- Last Updated: 3/19/2025
Categories
Recomended MCP Servers
MCP Server + Plugin for Unity Editor and Unity game. The Plugin allows to connect to MCP clients...
All-in-one security testing toolbox that brings together popular open source tools through a single MCP interface. Connected to...
Cloudflare MCP server for IDE ( Cline, Windsurf, Cursor, etc )
MCP server for analyzing claims, validating sources, and detecting manipulation using multiple epistemological frameworks
Send emails directly from Cursor with this email sending MCP server
A complete walkthrough on how to build an MCP server to serve a trained Random Forest model and...
Seamlessly integrate AI agents with Chargebee using AgentKit for smarter billing and subscription workflows.
Financial Modeling Prep MCP Server
An MCP tool that gets things done for you
Model Context Protocol (MCP) Server for the JFrog Platform API, enabling repository management, build tracking, release lifecycle management,...





