{"id":"e742b9c8-4f28-4e21-80e9-5fac4bca4b96","slug":"robot-team-discord-mcp","kind":"mcp","name":"Robot-Team-discord-MCP","summary":"ORAGEN TEAM","owner":"MushroomFleet","repoUrl":"https://github.com/MushroomFleet/Robot-Team-discord-MCP","license":"MIT","licenseTier":"permissive","trust":"community","stars":2,"match":null,"fewStars":true,"format":"mcp","createdAt":"2025-06-10T13:26:12.000Z","addedAt":"2026-10-21T04:00:57.879Z","logoUrl":"https://avatars.githubusercontent.com/u/7318371?u=bbb61310a06c7b76e1253b1f3ad8780ec9338912&v=4","linkOnly":false,"collection":null,"skillPath":null,"categories":["communication","cloud-infra","memory-knowledge"],"tags":["ai-tools"],"runtime":"binary","local":true,"cloudCapable":false,"cloudCapability":"unknown","cloudReadyOnPlatform":false,"needsApiKey":false,"reviewed":false,"syncedAt":"2026-10-23T10:58:09.458Z","sample":false,"url":"https://conduits.dev/tools/robot-team-discord-mcp","language":"JavaScript","transports":["stdio"],"install":{},"requirements":{"env":[],"upstreamMayCharge":false},"tools":null,"readme":"# Robot Team Discord Bot + REST API\r\n\r\nA comprehensive Discord bot system with integrated REST API that manages 7 unique robot personas (:one::robot: through :seven::robot:) for automated scheduling, posting, and cross-platform integration.\r\n\r\n## 🚀 System Overview\r\n\r\n**Robot Team** is a dual-interface system providing both Discord bot functionality and a complete REST API for external integrations. Perfect for automated content management, scheduled announcements, and multi-platform bot coordination.\r\n\r\n## ✨ Core Features\r\n\r\n### 🤖 Discord Bot Features\r\n- **7 Individual Robot Personas** - Each with unique colors, webhooks, and personalities\r\n- **Advanced Scheduling** - One-time and recurring posts with cron expressions\r\n- **Rich Embeds** - Beautiful, color-coded messages with images and formatting\r\n- **Webhook System** - Individual webhooks for authentic robot posting with unique avatars\r\n- **Slash Commands** - Modern Discord command interface with full admin controls\r\n\r\n### 🌐 REST API Features\r\n- **Complete CRUD Operations** - Full message and schedule management via API\r\n- **API Key Authentication** - Secure access with granular permissions and expiration\r\n- **Rate Limiting** - Global and per-robot limits to prevent abuse\r\n- **Cross-Platform Integration** - Use robots from any application or service\r\n- **Real-time Monitoring** - Health checks, usage analytics, and error tracking\r\n- **Security First** - CORS, request validation, and secure key storage\r\n\r\n### 🗄️ Database & Infrastructure\r\n- **SQLite Database** - Persistent storage with automatic migrations\r\n- **Sequelize ORM** - Type-safe database operations and relationships\r\n- **Job Scheduling** - Robust cron-based scheduling with failure recovery\r\n- **Graceful Shutdown** - Zero-downtime deployments and restarts\r\n- **Comprehensive Logging** - Detailed system monitoring and debugging\r\n\r\n## 📋 Quick Start\r\n\r\n### Prerequisites\r\n- Node.js v16.7 or higher\r\n- Discord Developer Account\r\n- Discord server with admin permissions\r\n\r\n### 1. Installation & Setup\r\n\r\n```bash\r\n# Clone and install\r\ngit clone <repository>\r\ncd robot-team\r\nnpm install\r\n\r\n# Configure environment\r\ncp .env.example .env\r\n# Edit .env with your Discord credentials and API settings\r\n```\r\n\r\n### 2. Discord Setup\r\nSee [Discord-Handoff.md](./docs/Discord-Handoff.md) for detailed Discord configuration.\r\n\r\nRequired `.env` variables:\r\n```env\r\nDISCORD_TOKEN=your_bot_token_here\r\nCLIENT_ID=your_bot_client_id_here\r\nGUILD_ID=your_server_id_here\r\nDATABASE_URL=./data/database.sqlite\r\n\r\n# API Configuration\r\nAPI_PORT=9000\r\nCORS_ORIGIN=*\r\nAPI_RATE_LIMIT_MAX=100\r\nADMIN_KEY=change-in-production\r\nDEFAULT_CHANNEL_ID=your_default_channel_id\r\n```\r\n\r\n### 3. Deploy & Start\r\n\r\n```bash\r\n# Deploy Discord commands\r\nnpm run deploy\r\n\r\n# Start the system (Discord bot + API server)\r\nnpm start\r\n\r\n# For development with auto-restart\r\nnpm run dev\r\n```\r\n\r\n### 4. Initialize Robots\r\n\r\n```bash\r\n# In Discord, initialize each robot:\r\n/init-robot robot:1\r\n/init-robot robot:2\r\n# ... continue for robots 3-7\r\n\r\n# Check status\r\n/robot-status\r\n```\r\n\r\n## 💬 Discord Usage\r\n\r\n### Setup Commands\r\n- `/init-robot robot:1` - Initialize robot with webhook\r\n- `/robot-status` - Check all robots or specific robot status\r\n- `/reset-robot robot:1` - Reset robot configuration\r\n\r\n### Immediate Posting\r\n```bash\r\n# Simple message\r\n/robot-post robot:1 content:\"Hello World!\"\r\n\r\n# Rich embed with title\r\n/robot-post robot:2 content:\"Important update\" title:\"📢 Announcement\"\r\n```\r\n\r\n### Scheduling Posts\r\n```bash\r\n# One-time scheduled post\r\n/schedule robot:1 content:\"Meeting in 10 minutes\" when:\"2024-12-25 15:30\" title:\"⏰ Reminder\"\r\n\r\n# Recurring daily post\r\n/schedule robot:2 content:\"Good morning team!\" when:\"0 9 * * *\" recurring:true title:\"🌅 Daily Greeting\"\r\n\r\n# Weekly report (Mondays at noon)\r\n/schedule robot:3 content:\"Weekly status update\" when:\"0 12 * * MON\" recurring:true\r\n```\r\n\r\n### Schedule Management\r\n```bash\r\n# List all scheduled posts\r\n/schedule-list\r\n\r\n# List for specific robot\r\n/schedule-list robot:1\r\n\r\n# Cancel a scheduled post\r\n/schedule-cancel post-id:abc-123-def\r\n```\r\n\r\n## 🤖 AI Assistant Integration (MCP)\r\n\r\n**NEW!** Control Robot Team Discord bots directly from your AI assistant using the Model Context Protocol (MCP). Send messages, schedule posts, and manage robots with natural language commands!\r\n\r\n### 👥 For AI Assistant Users\r\nWant to control Discord bots from Cline, Claude Desktop, or other AI assistants?\r\n**👉 [Get Started with MCP Client Handbook](./MCP/MCP-Client-Handbook.md)**\r\n\r\n**What you can do:**\r\n- *\"Send a message through Robot 1 saying 'Hello World!'\"*\r\n- *\"Schedule Robot 3 to post daily reminders at 9 AM\"*\r\n- *\"What's the status of all the robots?\"*\r\n- *\"List all scheduled messages for Robot 2\"*\r\n\r\n### 🛠️ For Server Administrators\r\nSetting up MCP server for your team or organization?\r\n**👉 [Deploy with MCP Server Handbook](./MCP/MCP-Server-Handbook.md)**\r\n\r\n**Features:**\r\n- ✅ Secure API key management and user permissions\r\n- ✅ Production-ready deployment with monitoring\r\n- ✅ Multi-client support (Cline, Claude Desktop, etc.)\r\n- ✅ Complete administrative tools and troubleshooting\r\n\r\n### 🌉 MCP Integration Benefits\r\n- **Seamless Control** - Use natural language instead of slash commands\r\n- **Stay in Flow** - No need to switch between applications\r\n- **Powerful Automation** - Schedule complex recurring messages\r\n- **Team Productivity** - Everyone can control bots through their AI assistant\r\n\r\n---\r\n\r\n## 🌐 REST API Usage\r\n\r\n### API Authentication\r\n\r\n```bash\r\n# Generate API key (requires admin access)\r\ncurl -X POST http://localhost:9000/api/auth/keys \\\r\n  -H \"Content-Type: application/json\" \\\r\n  -d '{\"name\": \"My App Key\", \"expiresIn\": 30}'\r\n\r\n# Use API key in requests\r\ncurl -H \"X-API-Key: rtk_your_api_key_here\" \\\r\n  http://localhost:9000/api/robots/status\r\n```\r\n\r\n### Send Immediate Messages\r\n\r\n```bash\r\n# Simple message\r\ncurl -X POST http://localhost:9000/api/robots/1/message \\\r\n  -H \"X-API-Key: your_key\" \\\r\n  -H \"Content-Type: application/json\" \\\r\n  -d '{\"content\": \"Hello from API!\"}'\r\n\r\n# Rich embed message\r\ncurl -X POST http://localhost:9000/api/robots/2/message \\\r\n  -H \"X-API-Key: your_key\" \\\r\n  -H \"Content-Type: application/json\" \\\r\n  -d '{\r\n    \"title\": \"API Announcement\",\r\n    \"content\": \"This message was sent via the REST API\",\r\n    \"image\": \"https://example.com/image.png\"\r\n  }'\r\n```\r\n\r\n### Schedule Messages\r\n\r\n```bash\r\n# One-time scheduled message\r\ncurl -X POST http://localhost:9000/api/robots/1/schedule \\\r\n  -H \"X-API-Key: your_key\" \\\r\n  -H \"Content-Type: application/json\" \\\r\n  -d '{\r\n    \"title\": \"Scheduled Reminder\",\r\n    \"content\": \"Don't forget about the meeting!\",\r\n    \"when\": \"2024-12-25T15:30:00Z\"\r\n  }'\r\n\r\n# Recurring message (daily at 9 AM)\r\ncurl -X POST http://localhost:9000/api/robots/2/schedule \\\r\n  -H \"X-API-Key: your_key\" \\\r\n  -H \"Content-Type: application/json\" \\\r\n  -d '{\r\n    \"content\": \"Daily standup in 30 minutes\",\r\n    \"recurring\": true,\r\n    \"cron\": \"0 9 * * *\"\r\n  }'\r\n```\r\n\r\n### Manage Schedules\r\n\r\n```bash\r\n# List scheduled posts\r\ncurl -H \"X-API-Key: your_key\" \\\r\n  \"http://localhost:9000/api/schedules?robotId=1&limit=10\"\r\n\r\n# Cancel scheduled post\r\ncurl -X DELETE http://localhost:9000/api/schedules/post-id-here \\\r\n  -H \"X-API-Key: your_key\"\r\n\r\n# Update scheduled post\r\ncurl -X PUT http://localhost:9000/api/schedules/post-id-here \\\r\n  -H \"X-API-Key: your_key\" \\\r\n  -H \"Content-Type: application/json\" \\\r\n  -d '{\"content\": \"Updated message content\"}'\r\n```\r\n\r\n### System Monitoring\r\n\r\n```bash\r\n# Health check\r\ncurl http://localhost:9000/health\r\n\r\n# Robot status\r\ncurl -H \"X-API-Key: your_key\" \\\r\n  http://localhost:9000/api/robots/status\r\n\r\n# API documentation\r\ncurl http://localhost:9000/api\r\n```\r\n\r\n## 🛠️ JavaScript SDK Example\r\n\r\nUse the included JavaScript client for easy integration:\r\n\r\n```javascript\r\nconst RobotTeamClient = require('./examples/api-client.js');\r\n\r\nconst client = new RobotTeamClient('your-api-key');\r\n\r\n// Send immediate message\r\nawait client.sendMessage(1, 'Hello from SDK!', {\r\n  title: '🤖 SDK Test',\r\n  image: 'https://example.com/image.png'\r\n});\r\n\r\n// Schedule recurring message\r\nawait client.scheduleMessage(2, 'Weekly reminder', null, {\r\n  recurring: true,\r\n  cron: '0 9 * * MON',\r\n  title: '📅 Weekly Update'\r\n});\r\n\r\n// Get robot status\r\nconst status = await client.getRobotStatus();\r\nconsole.log('Active robots:', status.summary.active);\r\n```\r\n\r\n## 🤖 Robot Personalities\r\n\r\nEach robot has a unique color scheme and can be customized:\r\n\r\n| Robot | Color | Hex Code | Use Case |\r\n|-------|-------|----------|----------|\r\n| 🤖 Robot 1 | Red | #FF0000 | Alerts & Urgent Messages |\r\n| 🤖 Robot 2 | Green | #00FF00 | Success & Positive Updates |\r\n| 🤖 Robot 3 | Blue | #0099FF | Information & Announcements |\r\n| 🤖 Robot 4 | Yellow | #FFFF00 | Warnings & Cautions |\r\n| 🤖 Robot 5 | Magenta | #FF00FF | Special Events |\r\n| 🤖 Robot 6 | Cyan | #00FFFF | Tech & Development |\r\n| 🤖 Robot 7 | Orange | #FFA500 | Social & Community |\r\n\r\n## 📁 Project Structure\r\n\r\n```\r\nrobot-team/\r\n├── src/\r\n│   ├── api/                    # REST API Server\r\n│   │   ├── server.js           # Express server setup\r\n│   │   ├── middleware/         # Auth, logging, validation\r\n│   │   └── routes/             # API endpoints\r\n│   │       ├── robots.js       # Robot operations\r\n│   │       ├── schedules.js    # Schedule management\r\n│   │       └── auth.js         # API key management\r\n│   ├── commands/               # Discord slash commands\r\n│   │   ├── admin/              # Admin-only commands\r\n│   │   ├── robot/              # Robot management\r\n│   │   └── schedule/           # Scheduling commands\r\n│   ├── models/                 # Database models (Sequelize)\r\n│   ├── services/               # Core business logic\r\n│   │   ├── webhooks.js         # Discord webhook management\r\n│   │   └── scheduler.js        # Cron job scheduling\r\n│   └── utils/                  # Shared utilities\r\n│       ├── embedBuilder.js     # Rich embed creation\r\n│       └── robotNames.js       # Robot name utilities\r\n├── examples/\r\n│   └── api-client.js           # JavaScript SDK & CLI tool\r\n├── docs/                       # Documentation\r\n│   ├── api-documentation.md    # Complete API reference\r\n│   ├── robot-team-guide.md     # Detailed setup guide\r\n│   ├── Discord-Handoff.md      # Discord configuration\r\n│   └── Art-Team-Handoff.md     # Visual specifications\r\n├── data/                       # SQLite database\r\n├── SETUP.md                    # Quick start guide\r\n├── Robot-Team-Handbook.md      # Complete handbook\r\n└── index.js                    # Main application entry\r\n```\r\n\r\n## ⏰ Scheduling Examples\r\n\r\n### Cron Expression Reference\r\n\r\n| Pattern | Description | Example |\r\n|---------|-------------|---------|\r\n| `0 9 * * *` | Daily at 9:00 AM | Morning announcements |\r\n| `0 */6 * * *` | Every 6 hours | Periodic status updates |\r\n| `0 12 * * 1-5` | Weekdays at noon | Lunch reminders |\r\n| `0 0 1 * *` | First day of month | Monthly reports |\r\n| `0 17 * * FRI` | Fridays at 5 PM | Weekly wrap-ups |\r\n\r\n### Advanced Scheduling\r\n\r\n```bash\r\n# Complex recurring schedules\r\n/schedule robot:1 content:\"Backup completed\" when:\"0 2 * * *\" recurring:true title:\"🔄 System Backup\"\r\n/schedule robot:2 content:\"Weekly team meeting\" when:\"0 10 * * MON\" recurring:true title:\"📅 Team Meeting\"\r\n/schedule robot:3 content:\"Server maintenance window\" when:\"0 1 * * SUN\" recurring:true title:\"🔧 Maintenance\"\r\n```\r\n\r\n## 🔧 Development\r\n\r\n### Adding New Commands\r\n\r\n1. Create command file:\r\n```javascript\r\n// src/commands/example/hello.js\r\nconst { SlashCommandBuilder } = require('discord.js');\r\n\r\nmodule.exports = {\r\n  data: new SlashCommandBuilder()\r\n    .setName('hello')\r\n    .setDescription('Say hello'),\r\n    \r\n  async execute(interaction) {\r\n    await interaction.reply('Hello from Robot Team!');\r\n  }\r\n};\r\n```\r\n\r\n2. Redeploy commands:\r\n```bash\r\nnpm run deploy\r\n```\r\n\r\n### Adding API Endpoints\r\n\r\n1. Add route in `src/api/routes/`:\r\n```javascript\r\nrouter.get('/custom-endpoint', requirePermission('canViewStatus'), async (req, res) => {\r\n  res.json({ message: 'Custom endpoint working!' });\r\n});\r\n```\r\n\r\n2. Test endpoint:\r\n```bash\r\ncurl -H \"X-API-Key: your_key\" http://localhost:9000/api/custom-endpoint\r\n```\r\n\r\n### Database Operations\r\n\r\n```bash\r\n# Reset database (WARNING: Deletes all data)\r\nnpm run db:reset\r\n\r\n# View database in development\r\nnpm run dev\r\n# Check logs for SQL queries\r\n```\r\n\r\n## 📊 Monitoring & Analytics\r\n\r\n### Health Monitoring\r\n- **System Health**: `/health` endpoint provides uptime and status\r\n- **Robot Status**: Track active robots and webhook health\r\n- **Scheduler Health**: Monitor job execution and failures\r\n- **API Usage**: Track requests, rate limits, and authentication\r\n\r\n### Logging\r\nAll operations are logged with context:\r\n- 🤖 Bot operations and command execution\r\n- 📡 Webhook activities and message sending\r\n- ⏰ Scheduler events and job execution\r\n- 🌐 API requests and responses\r\n- ❌ Errors with full stack traces\r\n\r\n## 🚀 Production Deployment\r\n\r\n### Environment Configuration\r\n```env\r\nNODE_ENV=production\r\nADMIN_KEY=secure-random-key-here\r\nCORS_ORIGIN=https://yourdomain.com\r\nAPI_RATE_LIMIT_MAX=1000\r\n```\r\n\r\n### Hosting Options\r\n\r\n#### Railway (Recommended)\r\n1. Connect GitHub repository\r\n2. Set environment variables\r\n3. Deploy automatically\r\n4. Scale as needed\r\n\r\n#### Alternative Platforms\r\n- **Heroku**: Classic PaaS with easy deployment\r\n- **DigitalOcean**: VPS with full control\r\n- **AWS/GCP**: Enterprise-grade with advanced features\r\n\r\n### Security Checklist\r\n- [ ] Change default `ADMIN_KEY`\r\n- [ ] Use HTTPS in production\r\n- [ ] Restrict CORS origins\r\n- [ ] Set appropriate rate limits\r\n- [ ] Monitor API usage\r\n- [ ] Regularly rotate API keys\r\n- [ ] Use production Discord tokens\r\n\r\n## 🔍 Troubleshooting\r\n\r\n### Common Issues\r\n\r\n#### Discord Bot Issues\r\n- **Bot not responding**: Check `DISCORD_TOKEN` and bot permissions\r\n- **Commands not appearing**: Run `npm run deploy` and verify `CLIENT_ID`/`GUILD_ID`\r\n- **Webhooks failing**: Ensure \"Manage Webhooks\" permission and re-run `/init-robot`\r\n\r\n#### API Issues\r\n- **Authentication errors**: Generate new API key and check `X-API-Key` header\r\n- **Rate limiting**: Check limits and implement backoff in your client\r\n- **CORS errors**: Update `CORS_ORIGIN` environment variable\r\n\r\n#### Scheduling Issues\r\n- **Jobs not executing**: Validate cron expressions at [crontab.guru](https://crontab.guru)\r\n- **Wrong timezone**: System uses UTC, adjust your cron expressions accordingly\r\n- **Robot offline**: Check robot status with `/robot-status` or API\r\n\r\n### Debug Commands\r\n\r\n```bash\r\n# Test bot connection\r\nnpm test\r\n\r\n# Check system health\r\ncurl http://localhost:9000/health\r\n\r\n# Generate test API key\r\nnode examples/api-client.js generate-key \"Debug Key\"\r\n\r\n# Test API client\r\nnode examples/api-client.js examples your-api-key\r\n```\r\n\r\n## 📚 Documentation\r\n\r\n- **[SETUP.md](./SETUP.md)** - Quick setup guide\r\n- **[Robot-Team-Handbook.md](./Robot-Team-Handbook.md)** - Complete system handbook\r\n- **[API Documentation](./docs/api-documentation.md)** - Full REST API reference\r\n- **[Discord Setup](./docs/Discord-Handoff.md)** - Discord configuration guide\r\n- **[Art Specifications](./docs/Art-Team-Handoff.md)** - Visual design guidelines\r\n\r\n## 🤝 Contributing\r\n\r\n1. Fork the repository\r\n2. Create a feature branch (`git checkout -b feature/amazing-feature`)\r\n3. Make your changes and test thoroughly\r\n4. Update documentation as needed\r\n5. Submit a pull request with detailed description\r\n\r\n### Development Guidelines\r\n- Follow existing code style and patterns\r\n- Add JSDoc comments for new functions\r\n- Update tests for new features\r\n- Ensure backwards compatibility\r\n- Document breaking changes\r\n\r\n## 📄 License\r\n\r\nMIT License - see [LICENSE](./LICENSE) file for details.\r\n\r\n## 🆘 Support & Community\r\n\r\n- **Issues**: [GitHub Issues](https://github.com/your-repo/issues)\r\n- **Discussions**: [GitHub Discussions](https://github.com/your-repo/discussions)\r\n- **Discord**: Join our community server for support\r\n- **Documentation**: Check the `/docs` folder for detailed guides\r\n\r\n---\r\n\r\n**🤖 Robot Team Bot** - Bringing automation, personality, and powerful API integration to your Discord server and beyond! \r\n\r\n*Built with ❤️ for the modern Discord community and developer ecosystem.*\r\n"}