Skip to main content
Glama

list_hue_lights

Retrieve all Philips Hue lights connected to your Hue Bridge with their current status, IDs, and names for easy management and control.

Instructions

List all available Philips Hue lights.

Returns: A formatted list of all lights with their IDs, names, and current states

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • main.py:130-154 (handler)
    The main handler function for the 'list_hue_lights' MCP tool. It connects to the Philips Hue Bridge, retrieves the list of lights, and formats their IDs, names, on/off states, and brightness into a string response.
    @mcp.tool() def list_hue_lights() -> str: """ List all available Philips Hue lights. Returns: A formatted list of all lights with their IDs, names, and current states """ try: bridge = get_bridge() lights = bridge.lights if not lights: return "No lights found on the Hue Bridge" result = ["Available Hue Lights:", ""] for idx, light in enumerate(lights, 1): state = "ON" if light.on else "OFF" brightness = light.brightness if hasattr(light, 'brightness') else "N/A" result.append(f" {idx}. {light.name} - {state} (Brightness: {brightness})") return "\n".join(result) except Exception as e: return f"Error listing lights: {str(e)}"

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/tebinraouf/hue-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server