Skip to main content
Glama
OpenHue MCP Server

OpenHue MCP Server

by lsemenenko

OpenHue MCP サーバー

OpenHue CLI を使用して、Claude やその他の LLM インターフェイスを通じて Philips Hue ライトを制御できる MCP サーバー。

前提条件

Related MCP server: Philips Hue MCP Service

ブリッジのセットアップ

サーバーを使用する前に、Hue ブリッジで OpenHue CLI を設定する必要があります。

  1. セットアップ コマンドを実行します。

# On Linux/macOS:
docker run -v "${HOME}/.openhue:/.openhue" --rm --name=openhue -it openhue/cli setup

# On Windows (PowerShell):
docker run -v "${env:USERPROFILE}\.openhue:/.openhue" --rm --name=openhue -it openhue/cli setup
  1. 画面上の指示に従います。

    • CLIはHueブリッジを検索します

    • プロンプトが表示されたら、Hueブリッジのリンクボタンを押します。

    • セットアップが完了したことを確認するまで待ちます

  2. ライトをリストしてセットアップを確認します。

# On Linux/macOS:
docker run -v "${HOME}/.openhue:/.openhue" --rm --name=openhue -it openhue/cli get lights

# On Windows (PowerShell):
docker run -v "${env:USERPROFILE}\.openhue:/.openhue" --rm --name=openhue -it openhue/cli get lights

ライトがリストに表示されたら、セットアップは完了しており、MCP サーバーを使用する準備が整っています。

インストール

  1. リポジトリをクローンします。

git clone <your-repo-url>
cd claude-mcp-openhue
  1. 依存関係をインストールします:

npm install
  1. プロジェクトをビルドします。

npm run build
  1. サーバーを実行します。

npm start

特徴

このサーバーは、MCP を通じて次の機能を公開します。

照明制御

  • すべてのライトを一覧表示するか、特定のライトの詳細を取得します

  • ライトのオン/オフ

  • 明るさを調整する

  • 色を設定する

  • 色温度を制御する

ルームコントロール

  • すべての部屋を一覧表示するか、部屋の詳細を取得します

  • 部屋のすべての照明をまとめて制御

  • 部屋全体の明るさと色を設定する

シーン管理

  • 利用可能なシーンを一覧表示する

  • さまざまなモードでシーンをアクティブにする

  • 部屋別にシーンをフィルタリング

Claude Desktopでの使用

  1. Claude Desktop 構成ファイルを開きます。

    • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

    • Windows: %APPDATA%\Claude\claude_desktop_config.json

  2. サーバー構成を追加します。

{
  "mcpServers": {
    "hue": {
      "command": "node",
      "args": ["/absolute/path/to/build/index.js"]
    }
  }
}
  1. Claudeデスクトップを再起動します

  2. サーバーが接続されていることを確認するには、ハンマーアイコンを探します

コマンド例

接続すると、次のような自然言語の質問を Claude に尋ねることができます。

  • 「リビングルームにはどんな照明がありますか?」

  • 「キッチンの電気を全部つけて」

  • 「寝室の照明を50%の明るさに設定してください」

  • 「オフィスの照明を青に変えてください」

  • 「『リラックス』シーンを有効にする」

  • 「書斎ではどんなシーンが楽しめますか?」

利用可能なツール

ライトをゲット

すべてのライトを一覧表示したり、特定のライトの詳細を取得したりします

{
  lightId?: string;  // Optional light ID or name
  room?: string;     // Optional room name filter
}

コントロールライト

個々のライトを制御する

{
  target: string;    // Light ID or name
  action: "on" | "off";
  brightness?: number; // 0-100
  color?: string;     // Color name
  temperature?: number; // 153-500 Mirek
}

部屋を取得する

すべての部屋を一覧表示したり、特定の部屋の詳細を取得したりします

{
  roomId?: string;  // Optional room ID or name
}

制御室

部屋のすべての照明を制御します

{
  target: string;    // Room ID or name
  action: "on" | "off";
  brightness?: number;
  color?: string;
  temperature?: number;
}

シーンを取得する

利用可能なシーンを一覧表示します

{
  room?: string;    // Optional room name filter
}

シーンをアクティブ化する

特定のシーンをアクティブにする

{
  name: string;     // Scene name or ID
  room?: string;    // Optional room name
  mode?: "active" | "dynamic" | "static";
}

発達

プロジェクト構造

.
├── src/
│   └── index.ts    # Main server implementation
├── build/          # Compiled JavaScript
├── package.json
├── tsconfig.json
└── README.md

建物

npm run build

ランニング

npm start

トラブルシューティング

サーバーに接続できません

  1. Dockerが実行中であることを確認する

  2. OpenHue 構成が存在することを確認する

  3. Claude Desktopのログを確認する

  4. OpenHue CLIを直接実行してみる

コマンドの失敗

  1. OpenHue CLI の権限を確認する

  2. ライト/部屋/シーン名を確認する

  3. Dockerコンテナのログを確認する

  4. Hue ブリッジの接続を確認する

ライセンス

MITライセンス

貢献

  1. リポジトリをフォークする

  2. 機能ブランチを作成する

  3. 変更をコミットする

  4. ブランチにプッシュする

  5. 新しいプルリクエストを作成する

Available Tools

6 tools
activate-sceneC

Activate a specific scene

Inputs: name (required), mode, room.

control-lightC

Control a specific Hue light

Inputs: action (required), target (required), brightness, color, +1 more.

control-roomC

Control all lights in a room

Inputs: action (required), target (required), brightness, color, +1 more.

get-lightsB

List all Hue lights or get details for a specific light

Inputs: lightId, room.

get-roomsB

List all rooms or get details for a specific room

Inputs: roomId.

get-scenesC

List all scenes or get details for specific scenes

Inputs: room.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.5/5.0

    Scored across 6 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose: activate-scene targets scene activation, control-light and control-room handle light control at different granularities, and the get-* tools retrieve specific resource types. There is no overlap in functionality, making tool selection straightforward for an agent.

    Naming Consistency5/5

    All tool names follow a consistent verb-noun pattern with hyphen separation (e.g., activate-scene, control-light, get-lights). The naming is uniform across all tools, with no deviations in style or convention, ensuring predictability and readability.

    Tool Count5/5

    With 6 tools, the server is well-scoped for managing Philips Hue devices. The count is appropriate, covering core operations like control and retrieval for lights, rooms, and scenes without being overly sparse or bloated, fitting typical home automation workflows.

    Completeness4/5

    The toolset provides solid coverage for the Hue domain, including control and retrieval for lights, rooms, and scenes. A minor gap exists in missing update or delete operations for scenes or rooms, but agents can still accomplish most common tasks with the available tools.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      A
      quality
      D
      maintenance
      Enables control of Philips Hue lights through VS Code Copilot or Claude Desktop using natural language commands. Supports turning lights on/off, adjusting brightness, changing colors, and listing available lights on your Hue Bridge.
      2
      -
    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables control of Philips Hue lights through the Model Context Protocol, providing tools for turning lights on/off, setting brightness and color, and retrieving light status.
      1
      Apache 2.0
    • F
      license
      Not graded
      quality
      D
      maintenance
      Controls Philips Hue lights based on Claude Code session events, using color animations to indicate Claude's status (thinking, working, success, etc.).
      10
      -