飞利浦Hue智能灯控MCP服务器

这是一个模型上下文协议(MCP)服务器,用于控制飞利浦Hue智能灯,支持桥接器发现、API密钥配置以及灯光、区域、房间和分组灯光的统一管理。

  • by Flopsstuff
  • TypeScript
  • 本地部署
  • 1 星标
  • 更新于

使用说明

Philips Hue MCP Server Bundle

MCP server for controlling Philips Hue smart lights.

Features

  • Automatic Bridge discovery via mDNS
  • Setup and configure API key
  • Control lights (on/off, brightness, color)
  • Manage zones and rooms
  • Support for grouped lights

Quick Start

For Claude Desktop

  1. Download and install the MCPB bundle from releases
  2. Configuration (choose one):
    • Option A (Recommended): Skip configuration and use built-in tools:
      • Use discover_bridge tool to find your Hue Bridge
      • Press the physical button on your Hue Bridge
      • Use complete_bridge_setup tool to create API key
    • Option B: Enter Bridge IP and API key in configuration window during installation

For Other MCP Clients (e.g., Cursor)

Requires Node.js 22.23.4+ or 24.22.1+ (older lines are end-of-life and do not receive security fixes).

  1. Clone repository and install dependencies:
git clone https://github.com/yourusername/HUEMCP.git
cd HUEMCP
yarn install
  1. Setup (choose one):

    Option A: Interactive setup (Recommended)

    yarn setup
    

    Follow the interactive prompts to configure your Bridge.

    Option B: Manual configuration via ENV variables

    export HUE_BRIDGE_IP="your-bridge-ip"
    export HUE_API_KEY="your-api-key"
    
  2. Start the server:

yarn start

Need Bridge IP and API key? See Manual Setup Guide for step-by-step instructions using mDNS and curl.

Technical Details

Currently this MCP server uses direct HTTP calls to Philips Hue API v1.

Future Plans

Migration to node-hue-api library is planned, which will provide:

  • TypeScript implementation of Philips Hue API v2
  • Complete API coverage with type definitions
  • Scene management and scheduling
  • Entertainment API for streaming colors
  • Enhanced performance and features

Documentation

Full documentation is available in docs/

Resources

License

MIT