MCP通知服务器
当Cursor/Windsurf完成代码生成或需要用户批准时,播放通知的MCP服务器会发出声音。
特性
- 使用macOS系统通知声音
- 代码生成完成时发出通知
- 需要用户批准时发出通知
- 简单轻便
需求
- macOS
- Node.js 18或更高版本
安装
npx -y @mkusaka/mcp-notify-server或全局安装:
npm install -g @mkusaka/mcp-notify-server配置
将以下内容添加到Cursor配置文件中(~/.cursor/config.json):
{
"mcpServers": {
"notify": {
"command": "npx",
"args": ["-y", "@mkusaka/mcp-notify-server"]
}
}
}规则配置
将以下内容添加到游标规则文件中:
Always Notify by sound using "notify" every time you need user attention
- when you need user's approval for running the tool
- when you finish the task
- DO NOT MAKE MORE THAN ONE SOUND NOTIFICATION.发展
设置
git clone https://github.com/mkusaka/mcp-notify-server.git
cd mcp-notify-server
npm install
npm run build检查
您可以使用以下命令交互式测试MCP服务器 mcp-inspector:
npm run inspect这允许您在交互式环境中测试服务器的工具和功能。
可用脚本
npm run build-构建项目npm run start-启动服务器npm run dev-使用watch启动开发模式npm run inspect-启动交互式检查模式
注意事项
- 目前仅支持macOS
- 声音通知取决于LLM的判断,这可能会导致:
- 意外的通知时间 - 偶尔错过通知 - 行为的潜在变化
贡献
欢迎投稿!请随时提交拉取请求。
许可证
国际协调委员会
作者
@mkusaka
