UNPKG

homebridge-dreame-vacuum

Version:

Homebridge plugin for Dreame vacuum cleaners with support for room cleaning, zones, and more

246 lines (245 loc) 7.96 kB
{ "pluginAlias": "DreameVacuum", "pluginType": "platform", "singular": true, "headerDisplay": "For more information, see [the plugin readme](https://github.com/yourusername/homebridge-dreame-vacuum)", "footerDisplay": "Dreame Vacuum Platform - Copyright © 2025", "schema": { "type": "object", "properties": { "name": { "title": "Platform Name", "type": "string", "default": "Dreame Vacuum", "required": true, "description": "Name of the platform that will appear in the Homebridge log." }, "email": { "title": "Dreame Account Email", "type": "string", "required": true, "description": "Email address used for your Dreame/Xiaomi account." }, "password": { "title": "Dreame Account Password", "type": "string", "required": true, "description": "Password for your Dreame/Xiaomi account.", "minLength": 8 }, "countryCode": { "title": "Country/Region Code", "type": "string", "default": "us", "description": "Your country/region code (e.g., 'us', 'de', 'cn', 'ru', 'sg')." }, "connectionType": { "title": "Connection Type", "type": "string", "default": "auto", "oneOf": [ { "enum": ["auto"], "title": "Auto (Try cloud first, fallback to local)" }, { "enum": ["cloud"], "title": "Cloud Only" }, { "enum": ["local"], "title": "Local Network Only" } ], "description": "Choose how to connect to your vacuum." }, "enableMop": { "title": "Enable Mop Control", "type": "boolean", "default": true, "description": "Enable mop-related controls (for models with mopping functionality)." }, "rooms": { "title": "Room Configuration", "type": "array", "items": { "type": "object", "properties": { "id": { "title": "Room ID", "type": "string", "required": true, "description": "The ID of the room as defined in the Dreame app." }, "name": { "title": "Room Name", "type": "string", "required": true, "description": "The name of the room as it will appear in HomeKit." }, "cleanOrder": { "title": "Cleaning Order", "type": "integer", "description": "The order in which this room should be cleaned (1 = first)." } } }, "default": [] }, "zones": { "title": "Zone Cleaning Presets", "type": "array", "items": { "type": "object", "properties": { "name": { "title": "Zone Name", "type": "string", "required": true, "description": "Name of this zone preset." }, "zones": { "title": "Zone Coordinates", "type": "array", "items": { "type": "object", "properties": { "x1": { "type": "number", "title": "X1", "minimum": 0, "maximum": 10000 }, "y1": { "type": "number", "title": "Y1", "minimum": 0, "maximum": 10000 }, "x2": { "type": "number", "title": "X2", "minimum": 0, "maximum": 10000 }, "y2": { "type": "number", "title": "Y2", "minimum": 0, "maximum": 10000 }, "cleanings": { "type": "integer", "title": "Cleanings", "minimum": 1, "maximum": 3, "default": 1 } }, "required": ["x1", "y1", "x2", "y2"] } } }, "required": ["name", "zones"] }, "default": [] }, "spots": { "title": "Spot Cleaning Presets", "type": "array", "items": { "type": "object", "properties": { "name": { "title": "Spot Name", "type": "string", "required": true, "description": "Name of this spot preset." }, "x": { "title": "X Coordinate", "type": "number", "minimum": 0, "maximum": 10000, "description": "X coordinate of the spot" }, "y": { "title": "Y Coordinate", "type": "number", "minimum": 0, "maximum": 10000, "description": "Y coordinate of the spot" } }, "required": ["name", "x", "y"] }, "default": [] }, "refreshInterval": { "title": "Status Refresh Interval (seconds)", "type": "integer", "default": 30, "minimum": 10, "maximum": 300, "description": "How often to refresh the device status in seconds." }, "debug": { "title": "Enable Debug Logging", "type": "boolean", "default": false, "description": "Enable additional debug logging (useful for troubleshooting)." }, "maintenance": { "title": "Maintenance Reminders", "type": "object", "properties": { "filterHours": { "title": "Filter Replacement (hours)", "type": "integer", "default": 300, "description": "Hours of use before filter replacement is recommended." }, "mainBrushHours": { "title": "Main Brush Replacement (hours)", "type": "integer", "default": 300, "description": "Hours of use before main brush replacement is recommended." }, "sideBrushHours": { "title": "Side Brush Replacement (hours)", "type": "integer", "default": 200, "description": "Hours of use before side brush replacement is recommended." }, "sensorHours": { "title": "Sensor Cleaning (hours)", "type": "integer", "default": 100, "description": "Hours of use before sensor cleaning is recommended." } } } }, "required": ["name", "email", "password"] }, "layout": [ { "type": "field", "fieldName": "name" }, { "type": "field", "fieldName": "email" }, { "type": "field", "fieldName": "password" }, { "type": "field", "fieldName": "countryCode" }, { "type": "field", "fieldName": "connectionType" }, { "type": "field", "fieldName": "enableMop" }, { "type": "flex", "flex-direction": "row", "items": [ { "type": "field", "fieldName": "refreshInterval", "flex": 1 }, { "type": "field", "fieldName": "debug", "flex": 1 } ] }, { "type": "panel", "title": "Rooms", "expandable": true, "expanded": false, "items": [ { "type": "array", "fieldName": "rooms" } ] }, { "type": "panel", "title": "Zone Cleaning Presets", "expandable": true, "expanded": false, "items": [ { "type": "array", "fieldName": "zones" } ] }, { "type": "panel", "title": "Spot Cleaning Presets", "expandable": true, "expanded": false, "items": [ { "type": "array", "fieldName": "spots" } ] }, { "type": "panel", "title": "Maintenance Settings", "expandable": true, "expanded": false, "items": [ { "type": "field", "fieldName": "maintenance.filterHours" }, { "type": "field", "fieldName": "maintenance.mainBrushHours" }, { "type": "field", "fieldName": "maintenance.sideBrushHours" }, { "type": "field", "fieldName": "maintenance.sensorHours" } ] } ] }