MCP.so
登录

MCP Server Template

@3dyuval

基本信息

分类

开发工具

许可证

MIT

传输方式

stdio

作者

3dyuval

关于 MCP Server Template

A template for building MCP (Model Context Protocol) servers for Claude and other AI assistants

MCP Server Template 配置

使用下面的配置,将此服务器添加到你的 MCP 客户端。

{
  "mcpServers": {
    "mcp-template-3dyuval": {
      "command": "node",
      "args": [
        "build/index.js"
      ]
    }
  }
}

MCP Server Template 工具

工具列表暂未提供

当前收录暂时没有可展示的工具列表,不代表服务没有工具。请查阅项目文档了解支持的能力。

工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。

概览

What is MCP Server Template 🚀?

MCP Server Template 🚀 is a clean, ready-to-use starting point for building custom servers that follow the Model Context Protocol (MCP). It provides a basic server structure with the MCP SDK, example tool definitions, and error handling, making it ideal for developers who want to build an MCP server for use with Claude Desktop, Cursor, or any other MCP client.

How to use MCP Server Template 🚀?

Clone the repository, run npm install and npm run build, then customize src/index.ts and package.json with your own tools, schemas, and API logic. Run your server directly with node build/index.js or configure it in Claude Desktop (by editing claude_desktop_config.json) or Cursor (via Settings > Features > MCP Servers) to point to the built index.js file.

Key features of MCP Server Template 🚀

  • Basic server structure using the official MCP SDK
  • Example tool definitions with commented placeholders
  • Error handling setup included out of the box
  • Environment variable configuration via dotenv
  • Designed for easy customization and extension

Use cases of MCP Server Template 🚀

  • Quickly prototyping a new MCP-compatible data source or tool
  • Creating a custom MCP server to expose internal APIs to Claude Desktop
  • Building a foundation for integrating any third‑party service as an MCP tool
  • Teaching or learning how to implement the Model Context Protocol

常见问题

1

What do I need before using this template?

You need Node.js v20 or higher, an MCP client (such as Claude Desktop or Cursor), and any API key(s) for the service you plan to wrap.

2

How do I customize the template for my own server?

Edit `package.json` with your server name and details, then modify `src/index.ts` to define your API response interface, add actual tool schemas, implement tool logic, and update formatting as needed.

3

How do I configure the server for Claude Desktop?

Create or edit the configuration file at `~/Library/Application Support/Claude/claude_desktop_config.json` (macOS) or `%APPDATA%\Claude\claude_desktop_config.json` (Windows) and add an entry under `mcpServers` with the command `node` and the path to your `build/index.js`.

4

How do I configure the server for Cursor?

Open Cursor Settings, go to Features > MCP Servers, click “+ Add New MCP Server”, enter a nickname, select type “command”, and provide the command including any environment variables, e.g., `env YOUR_API_KEY=your-api-key node /path/to/your/build/index.js`.

5

What transport does the template use?

The template uses the stdio transport for MCP communication. Secrets like API keys are passed via environment variables in the client configuration.

评论

开发工具 分类下的更多 MCP 服务器