mcp -typescript-template
MCP Server Typescript Template
claude mcp add --transport stdio minimind-org-mcp-server-typescript-template node dist/index.js
How to use
This MCP server template exposes two simple tools implemented in TypeScript: an Example operation and an Addition tool. The Example operation demonstrates a basic, demonstrative command that can be invoked by an AI model to verify tool invocation and response formatting. The Addition tool performs a straightforward arithmetic addition of two numbers. The server uses the Model Context Protocol SDK to handle communication with clients, enabling structured tool calls, argument passing, and result reporting. To use these tools, start the server (e.g., via node dist/index.js after building) and configure an MCP client to point to the server’s endpoint. Once connected, you can request the Example operation or the Addition tool through the MCP client, pass the required inputs, and receive a structured response with the operation’s result.
The template is designed for experimentation and extension. You can extend the existing operations or add new tools by following the project’s TypeScript structure under common/ and operations/. Each tool should implement a command pattern compatible with the MCP SDK so that models can discover, invoke, and receive results in a consistent format.
How to install
Prerequisites:
- Node.js v16 or higher
- npm (or yarn) to install dependencies
Installation steps:
- Clone the repository: git clone <repository-url>
- Navigate to the project directory: cd mcp-server-typescript-template
- Install dependencies: npm install
- Build the TypeScript project (if a build step is present): npm run build
- Run tests (optional): npm run test
- Start the MCP server for testing: npm run start
Notes:
- Ensure you have your environment set up to compile TypeScript if you’re developing locally (tsconfig.json is provided).
- If you customize the server entry point, update the start script in package.json accordingly.
- For client configuration (Claude Desktop or other MCP clients), point to the built server entry (e.g., dist/index.js).
Additional notes
Tips:
- The template includes a minimal set of tools to demonstrate MCP tool invocation. You can add more operations under the operations/ directory and wire them into the server accordingly.
- If you encounter path issues after building, ensure the server entry path used in mcp_config matches the actual build output location (commonly dist/index.js).
- Environment variables can be added if your tools require API keys or configuration (e.g., env: { "API_KEY": "<your-key>" }).
- When deploying, consider packaging the built dist folder and ensuring the runtime environment has Node.js v16+ installed.
Related MCP Servers
MCPNotes
A simple note-taking MCP server for recording and managing notes with AI models.
MCP -Starter
A Model Context Protocol server starter template
pinmeto-location
PinMeTo MCP server that enables users with authorized credentials to unlock their data
mcp
Official BaseHub MCP server.
vscode-context
MCP Server to Connect with VS Code IDE
mcpulse
MCPulse - MCP Analytics Platform