Token导航 LogoToken导航TokenDH.com
ModelContextProtocolServer logo
搜索检索SSE官方级别未说明来源级核验

ModelContextProtocolServer

MCP Server

MCP server to provide tools

工具数

2

提示词数

0

GitHub Stars

1

资源数

0
API集成开发工具JavaMath AssistantMath Solver

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

InnoBridge

提供方

InnoBridge

最后核验

2026/5/18 04:07

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

详细介绍

模型上下文协议服务器

API示例

连接到SSE流

curl -N -H "Accept: text/event-stream" http://localhost:8081/sse

连接到stdio

生成Java工件

./mvnw clean install

正在启动stdio服务器

java -Dtransport.mode=stdio \
     -Dspring.main.web-application-type=none \
     -Dspring.main.banner-mode=off \
     -Dlogging.file.name=mcpserver.log \
     -jar target/mcpserver-0.0.1-SNAPSHOT.jar

发送工具/列表请求

示例

请求

curl -X POST -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","id":2,"method":"tools/list","params":{}}' http://localhost:8081/mcp/message

信任状

event:message
data:{"jsonrpc":"2.0","id":2,"result":{"tools":[{"name":"calculator","description":"Basic calculator","inputSchema":{"type":"object","properties":{"operation":{"type":"string"},"a":{"type":"number"},"b":{"type":"number"}},"required":["operation","a","b"]}},{"name":"get_current_weather","description":"Get the current weather in a given location","inputSchema":{"type":"object","properties":{"location":{"type":"string","description":"The name of the city e.g. San Francisco, CA"},"format":{"type":"string","enum":["celsius","fahrenheit"],"description":"The format to return the weather in"}},"required":["location"]}}]}}

调用计算器工具

示例

请求

curl -X POST -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"calculator","arguments":{"operation":"+","a":2,"b":3}}}' http://localhost:8081/mcp/message

响应

event:message
data:{"jsonrpc":"2.0","id":1,"result":{"content":[{"type":"text","type":"text","text":"2.00 + 3.00 = 5.00"}],"isError":false}}

调用天气工具

示例

请求

curl -X POST -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"get_current_weather","arguments":{"location":"San Francisco","format":"celsius"}}}' http://localhost:8081/mcp/

响应

event:message
data:{"jsonrpc":"2.0","id":1,"result":{"content":[{"type":"text","type":"text","text":"Current weather in San Francisco, United States of America: Partly cloudy, 11.1°C, Precipitation: 0.0 mm"}],"isError":false}}```

目录标签

目录标签

API集成开发工具JavaMath AssistantMath Solverresearch-and-datamathgptmath-solvermath-assistantAPI服务混合部署工具集成

接入字段

传输方式(transport,传输协议)

SSE

鉴权方式(authType,认证方式)

none

工具数量(toolCount,工具数)

2

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

SSEnone部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

仍需确认:installCommand

来源信息

继续浏览同类 MCP