Slack Notification MCP Server

Slack Notification MCP Server

Enables Claude AI to send real-time notifications to Slack channels with support for rich formatting, multiple channels, and customizable message styling for workflow automation and task completion alerts.

Category
访问服务器

README

🚀 Slack Notification MCP Server

License: MIT Node.js Version MCP Compatible GitHub stars Buy Me A Coffee

Transform your Claude AI workflows with instant Slack notifications!

A powerful Model Context Protocol (MCP) server that seamlessly connects Claude AI with Slack, enabling real-time notifications for task completions, alerts, and workflow automation. Never miss important updates from your AI assistant again!

✨ Why This MCP Server?

  • 🤖 Claude Integration: Built specifically for Claude AI via the Model Context Protocol
  • ⚡ Instant Notifications: Get real-time updates when Claude completes tasks
  • 🎯 Multi-Channel Support: Send targeted messages to different Slack channels
  • 🎨 Rich Formatting: Support for titles, colors, and message styling
  • 🔧 Zero Config Hassle: Simple JSON configuration gets you running in minutes
  • 🚀 Lightweight: Fast Node.js implementation with minimal dependencies

🛠️ Features

  • 🚀 Dynamic tool creation based on your configured Slack channels
  • 📱 Support for rich message formatting (titles, colors)
  • ⚡ Fast and lightweight Node.js implementation
  • 🔧 Easy configuration via JSON file
  • 🎯 Separate tools for each channel for precise control

🎯 Perfect For

  • AI Workflow Automation: Get notified when Claude finishes long-running tasks
  • Development Teams: Automate deployment notifications and error alerts
  • Data Analysis: Receive updates when data processing completes
  • Content Creation: Get alerts when Claude finishes writing or research tasks
  • System Monitoring: Send formatted alerts for system status updates
  • Project Management: Automate status updates to project channels

🚀 Quick Start

# 1. Clone and install
git clone https://github.com/Zavdielx89/slack-notification-mcp.git
cd slack-notification-mcp
npm install

# 2. Configure your Slack webhooks
cp config.example.json config.json
# Edit config.json with your webhook URLs

# 3. Add to your Claude Desktop config
# See detailed setup instructions below

📋 Setup

1. Install Dependencies

cd ~/code/workflows/Slack-Notification-MCP
npm install

2. Create Slack Webhooks

For each Slack channel you want to send notifications to:

  1. Go to your Slack workspace
  2. Navigate to Apps > Manage > Custom Integrations > Incoming Webhooks
  3. Or visit: https://[your-workspace].slack.com/apps/manage/custom-integrations
  4. Click Add to Slack
  5. Choose the channel you want to send notifications to
  6. Copy the Webhook URL

3. Configure Channels

Create a config.json file in the project directory:

cp config.example.json config.json

Edit config.json with your actual Slack webhook URLs:

{
  "channels": {
    "general": {
      "name": "General",
      "webhook_url": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX"
    },
    "notifications": {
      "name": "Task Notifications",
      "webhook_url": "https://hooks.slack.com/services/T11111111/B11111111/YYYYYYYYYYYYYYYYYYYYYYYY"
    },
    "alerts": {
      "name": "System Alerts",
      "webhook_url": "https://hooks.slack.com/services/T22222222/B22222222/ZZZZZZZZZZZZZZZZZZZZZZZZ"
    }
  }
}

4. Add to MCP Settings

Add this server to your MCP client configuration (e.g., Claude Desktop):

{
  "mcpServers": {
    "slack-notifications": {
      "command": "node",
      "args": ["/Users/zavdielx/code/workflows/Slack-Notification-MCP/index.js"]
    }
  }
}

5. Restart Claude Desktop

Restart your Claude Desktop application to load the new MCP server.

Usage

Once configured, you'll have access to tools for each channel you configured. For example, if you configured channels named "general", "notifications", and "alerts", you'll see these tools:

  • slack_notify_general
  • slack_notify_notifications
  • slack_notify_alerts

Basic Message

Use the slack_notify_notifications tool to send a message "Task completed successfully!"

Message with Title

Send a notification to the general channel with title "Build Complete" and message "The deployment finished without errors"

Colored Message

Send an alert to the alerts channel with title "Error Detected", message "API endpoint is returning 500 errors", and color "danger"

Tool Parameters

Each slack_notify_* tool accepts these parameters:

  • message (required): The main message content
  • title (optional): A bold title that appears before the message
  • color (optional): Color for the message sidebar
    • "good" - Green (success)
    • "warning" - Yellow (warning)
    • "danger" - Red (error)

Example Workflows

Task Completion Notifications

After completing a long analysis, send a message to notifications channel: "Data analysis complete. Found 15 anomalies in the dataset. Report ready for review."

Error Alerts

If an error occurs, send a danger-colored alert to the alerts channel with title "Processing Error" and message "Failed to process user upload: invalid file format"

Status Updates

Send a good-colored message to general channel with title "System Update" and message "All services are running normally after the maintenance window"

Development

Running in Development Mode

npm run dev

This will start the server with file watching for automatic restarts.

Adding New Channels

  1. Create a new Slack webhook for the channel
  2. Add the channel configuration to config.json
  3. Restart the MCP server
  4. The new slack_notify_[channel_id] tool will be automatically available

Testing

You can test the server directly:

npm start

The server will run and wait for MCP protocol messages on stdin/stdout.

Troubleshooting

"Config file not found" Error

Make sure you've created config.json in the project directory with valid Slack webhook URLs.

"Failed to send Slack message" Error

  • Verify your webhook URLs are correct
  • Check that the Slack webhooks are still active
  • Ensure the channels still exist in your Slack workspace

Tools Not Appearing in Claude

  • Verify the MCP server path in your Claude configuration
  • Restart Claude Desktop after making configuration changes
  • Check that Node.js is installed and accessible

Security Notes

  • Keep your config.json file secure and don't commit webhook URLs to version control
  • Webhook URLs provide direct access to post in your Slack channels
  • Consider using environment variables for webhook URLs in production environments

🤝 Contributing

Contributions are welcome! Feel free to:

  • 🐛 Report bugs or request features via GitHub Issues
  • 🔀 Submit pull requests for improvements
  • ⭐ Star the repository if you find it useful
  • 📢 Share it with others who might benefit

☕ Support This Project

If this MCP server saves you time or enhances your Claude AI workflows, consider supporting its development:

Buy Me A Coffee

Your support helps me:

  • 🚀 Add new features and improvements
  • 🐛 Fix bugs and provide support
  • 📚 Create better documentation
  • 🎯 Build more useful MCP servers for the community

🔗 Related Projects

📈 Stats

GitHub repo size GitHub last commit GitHub issues


Made with ❤️ for the Claude AI community

If this project helps you stay connected with your AI workflows, consider giving it a ⭐!

License

MIT License - feel free to use and modify as needed!

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选