A Model Context Protocol (MCP) server for intelligent Hubitat Rules Machine automation assistance. This server provides AI-powered tools to help analyze, manage, and create Rules Machine automations.
- Rule Executor: Control existing rules (run/stop/pause/resume) via Rules Machine API
- Rule Template Generator: Create detailed templates and step-by-step instructions for manual rule creation
- Device Finder: Discover and analyze devices with their capabilities
- Rule Analyzer: Analyze existing rules for optimization and improvement opportunities
- Hub Integration: Manage hub modes, HSM status, and variables
- Device Capabilities: Comprehensive reference of Hubitat device capabilities and commands
- Automation Patterns: Library of common automation patterns and templates
- Best Practices: Guidelines for effective Rules Machine automation
- Rule Guidance: Interactive guidance for creating Rules Machine automations
- Troubleshooting: Help debug and resolve automation issues
- Best Practices: Comprehensive automation best practices guidance
- Node.js 18+
- TypeScript 5.0+
- Hubitat Hub with Rules Machine
- Hubitat Maker API access token
- Clone and install:
git clone <repository-url>
cd hubitat-rules-mcp
npm install- Build the project:
npm run build- Start the server:
npm startnpm run devThe MCP server requires your Hubitat hub IP address and Maker API access token for API operations. These are provided as parameters when using the tools.
- In Hubitat admin interface, go to Apps → Add Built-In App
- Select Maker API
- Select the devices you want to control
- Note the access token from the app page
{
"tool": "execute_rule",
"arguments": {
"action": "run",
"rule_ids": ["123"],
"hubitat_ip": "192.168.1.100",
"access_token": "your-token-here"
}
}{
"tool": "generate_template",
"arguments": {
"automation_goal": "Turn on lights when motion detected at night",
"complexity": "intermediate",
"devices": ["Motion Sensor", "Living Room Lights"]
}
}{
"tool": "find_devices",
"arguments": {
"hubitat_ip": "192.168.1.100",
"access_token": "your-token-here",
"filter": {
"capability": "motionSensor"
}
}
}✅ What it CAN do:
- Control existing rules (run/stop/pause/resume)
- Manage hub variables and settings
- Provide expert guidance for manual rule creation
- Analyze existing rules for optimization
- Generate detailed templates and instructions
❌ What it CANNOT do:
- Automatically create rules (not supported by Rules Machine API)
- Modify existing rule logic (security limitation)
- Export rule configurations (limited API access)
The server provides intelligent assistance for Rules Machine automation through:
- API Integration: Direct control of supported Rules Machine functions
- Expert Knowledge: Comprehensive automation guidance and best practices
- Template Generation: Detailed instructions for manual rule implementation
- Analysis Tools: Rule optimization and improvement recommendations
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Submit a pull request
AGPL-3.0
For issues and questions:
- Check the troubleshooting resources in the MCP server
- Review the best practices guidance
- Open an issue on GitHub
Made with ❤️ for intelligent home automation
Bringing AI assistance to Hubitat Rules Machine - working within platform capabilities to enhance your automation experience.