MCP Add Server

MCP Add Server

mcp-add-server•byzhangzhefang-github

A minimal Model Context Protocol server offering a single add(a, b) tool that returns the sum of two numbers.

License: MIT License•Runtime: Awaiting documentation review•Category: developer tools

WHAT IT DOES

  • •Implements a Model Context Protocol compliant server.
  • •Provides a single tool named add that returns the sum of two numbers.
  • •Is available on npm for installation and use.
  • •Communicates with MCP clients via stdio transport once running.

BEST FOR

  • •Demonstrating how an MCP client invokes an MCP server tool to perform an addition.
  • •Learning a basic example implementation of an MCP server.

ABOUT MCP-ADD-SERVER

MCP Add Server is cataloged as an MCP server attributed to zhangzhefang-github. A minimal Model Context Protocol server offering a single add(a, b) tool that returns the sum of two numbers. It is categorized under developer tools. See the capability inspector for recorded interfaces and their independent review status; consult upstream documentation for the current interface.

HOW TO INSTALL

Installation configuration is not reviewed. No executable setup is offered for this entry; inspect the source repository before proceeding.

LICENSE

Catalog license label: MIT License. Check the source repository's current license and terms before using, modifying or distributing this software.

能力检查器

能力定义尚未审核。未核验的采集内容不会作为可信接口展示。

Tools (0)

暂无可展示的已审核记录。这不表示上游不支持此能力。

Resources (0)

暂无可展示的已审核记录。这不表示上游不支持此能力。

Prompts (0)

暂无可展示的已审核记录。这不表示上游不支持此能力。

NEWSLETTER - COMING LATER

Newsletter subscriptions are not open yet

Email delivery is not connected. This page does not collect email addresses or create subscriptions.

Browse the registry for current listings instead.

Community Reviews

Coming later

Reviews for MCP Add Server are not available yet

Review publishing and storage are not connected. This page does not collect or publish ratings or comments, including after sign-in.

FREQUENTLY ASKED QUESTIONS

What tool does this MCP server expose?

It exposes a single tool called add(a, b), which returns the sum of two numbers.

What transport does the server use to connect with MCP clients?

Once running, the server is available to MCP clients via stdio transport.

上游原版 README

在 GitHub 查看同一版本原文

README.md · 2216184c37af · 采集于 2026-11-13 12:52:11 UTC

保留上游原文,不做 AI 改写。为安全起见过滤脚本、表单和不安全链接。

当前显示最后一次成功采集的文档快照,请以来源页面为准。

MCP Add Server

A minimal Model Context Protocol (MCP) server that provides a simple add(a, b) tool. This project serves as a basic example of an MCP server implementation.

Add Server MCP server

npm version

Features

  • Implements a Model Context Protocol compliant server.
  • Provides a single tool: add(a, b) which returns the sum of two numbers.
  • Available on npm for easy installation and use.

实际运行效果 (Showcase)

下图展示了 mcp-add-server 在 mcp.so 服务发现平台上的配置信息,以及一个兼容 MCP 的聊天机器人 (例如 Cherry Studio) 成功调用本服务器的 add 工具来执行加法运算的场景:

MCP Add Server in Action

  • 左侧: mcp-add-server 在 mcp.so 上的信息,展示了其概述和启动配置。
  • 右侧: 一个 MCP 客户端 (例如 Cherry Studio 这样的聊天机器人) 接收到用户关于加法的请求后,调用了 @zhefang/mcp-add-server 提供的 add 工具,并正确返回了计算结果。

这清晰地演示了遵循 Model Context Protocol 的服务器和客户端之间如何无缝集成和协作。

Prerequisites

  • Node.js (version 18.x.x or higher recommended)
  • npm (comes with Node.js)

Installation

The easiest way to use this MCP server is with npx:

npx @zhefang/mcp-add-server

Global Installation

For frequent use, install globally:

npm install -g @zhefang/mcp-add-server

Then run:

mcp-add-server

Development Setup

  1. Clone the repository:
    git clone https://github.com/zhangzhefang-github/mcp-add-server.git
    cd mcp-add-server
    
  2. Install dependencies:
    npm install
    
  3. Run locally:
    npm start
    

Usage

There are several ways to run the mcp-add-server:

1. Using npx (Recommended for most users):

npx @zhefang/mcp-add-server

This command will download the latest version of @zhefang/mcp-add-server and execute it.

2. Global installation (for frequent use):

npm install -g @zhefang/mcp-add-server
mcp-add-server

3. Running from a cloned repository:

After cloning the repository and installing dependencies:

npm start

4. Local linking for development: In the project's root directory:

npm link
mcp-add-server

Once the server is running, it will be available to MCP clients via stdio transport.

Client Example

The src/client.js file demonstrates how to connect to the server:

import { Client } from "@modelcontextprotocol/sdk/client/index.js";
import { StdioClientTransport } from "@modelcontextprotocol/sdk/client/stdio.js";

const transport = new StdioClientTransport({
  command: "npx",
  args: ["@zhefang/mcp-add-server"]
});

// Connect and use the add tool
await client.connect(transport);
const result = await client.callTool({
  name: "add",
  arguments: { a: 10, b: 5 }
});
console.log("计算结果:", result);

Example Tool Call (JSON)

{
  "tool_name": "add",
  "arguments": {
    "a": 5,
    "b": 3
  }
}

The server responds with:

{
  "content": [
    {
      "type": "text", 
      "text": "结果是:8"
    }
  ]
}

Running Tests

(When tests are added, describe how to run them here)

npm test

(Currently, npm test will output "Error: no test specified". Update the test script in package.json when tests are added.)

Project Structure

mcp-add-server/
├── .git/               # Git directory
├── .gitignore          # Specifies intentionally untracked files that Git should ignore
├── .cursor/            # Cursor specific files (if any)
├── node_modules/       # Project dependencies
├── src/                # Source code
│   └── server.js       # Main server logic
├── bin.js              # Executable for the server
├── LICENSE             # Project license
├── package-lock.json   # Records exact versions of dependencies
├── package.json        # Project metadata and dependencies
└── README.md           # This file

Contributing

Contributions are welcome! Please feel free to submit a pull request or open an issue.

License

This project is licensed under the MIT License.

Install configuration

Are you the maintainer?

Claim this server with your GitHub account to request manual ownership verification.

README Embed Badge
Markdown

Link to the catalog listing for MCP Add Server from your README. This badge does not certify ownership, compatibility or security.

[![MCP catalog listing](https://img.shields.io/badge/MCP-awesome--mcp-orange?style=flat-square)](https://awesome-mcp.com/servers/mcp-add-server)

REPOSITORY STATS

GitHub StarsUnavailable
ForksUnavailable

Public repository statistics could not be verified. Check the configured source address; unavailable counts are not zero.

下载与拉取统计

来源、范围和时段分别列出;不相加,不代表安装人数、活跃用户或安全审核。

尚无已审核的包 / 镜像标识,暂不展示下载统计。

Related developer tools MCP Servers

Alternative and complementary servers in the same category

View all in developer tools →
Postbye
postbye-mcp•postbye-team

A directory listing describing a cancellation-letter and mailing-address service. The configured public GitHub repository returned 404 during source verification.

Repository stats unavailable
Developer Tools
Singapore Proxy MCP
singapore-proxy-mcp•Xavierfok

A hosted MCP service for browsing and searching through Singapore mobile-network proxies.

0
Developer Tools

A directory listing describing a Markdown-to-PDF service. The configured public GitHub repository returned 404 during source verification.

Repository stats unavailable
Developer Tools