Roo MCP サーバー
未知
简介
Roo MCP 服务器为 Roo Code 提供基本工具服务。
前提条件
- 已安装 Deno
基本使用
启动服务器
# 标准启动
deno task start
# 开发模式(监视变更自动重启)
deno task dev
# 运行测试
deno task test
可用工具
工具名称 | 功能描述 | 必需参数 |
---|---|---|
getStringLength | 计算字符串长度 | input : 字符串 |
getGitHubRepoInfo | 获取仓库信息 | owner : 用户名/组织名repo : 仓库名 |
getGitHubRepoContents | 获取仓库内容 | owner , repo 可选: path , ref |
getGitHubIssues | 获取仓库问题 | owner , repo 可选: state , per_page |
getGitHubCommits | 获取提交历史 | owner , repo 可选: path , per_page |
使用示例
# 字符串长度
use_mcp_tool(
server_name="local",
tool_name="getStringLength",
arguments={
"input": "你好世界"
}
)
# 获取GitHub仓库信息
use_mcp_tool(
server_name="local",
tool_name="getGitHubRepoInfo",
arguments={
"owner": "denoland",
"repo": "deno"
}
)
注册到 Roo Code
- 启动服务器:
deno task start
- 编辑配置文件:
~/Library/Application Support/Code/User/globalStorage/rooveterinaryinc.roo-cline/settings/cline_mcp_settings.json
- 添加以下配置:
{
"mcpServers": {
"local": {
"command": "deno",
"args": [
"run",
"--allow-net",
"--allow-env",
"--allow-read",
"/path/to/src/server.ts"
],
"env": {},
"disabled": false,
"alwaysAllow": []
}
}
}
- 替换
/path/to/src/server.ts
为实际路径 - 重启 Roo Cline 应用设置