get_hardware
Retrieves a list of all hardware and gateways configured in Domoticz, enabling monitoring of connected devices.
Instructions
Get all hardware/gateways configured in Domoticz.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |
Implementation Reference
- src/domoticz_mcp/server.py:927-932 (handler)The `get_hardware` MCP tool function. It queries the Domoticz API endpoint `type=command¶m=gethardware` and returns the raw response text containing all configured hardware/gateways.
@mcp.tool() async def get_hardware() -> str: """Get all hardware/gateways configured in Domoticz.""" async with create_client() as client: response = await _do_request(client, "GET", f"{DOMOTICZ_API_URL}?type=command¶m=gethardware") return response.text - src/domoticz_mcp/server.py:927-928 (registration)The tool is registered as an MCP tool via the `@mcp.tool()` decorator on line 927.
@mcp.tool() async def get_hardware() -> str: