This repository contains the Home Assistant integration for Heiman smart home devices. This repository is available in multiple languages to help users worldwide understand and use the integration easily.
Dieses Repository enthält die Home Assistant-Integration für Heiman Smart-Home-Geräte. Dieses Repository ist in mehreren Sprachen verfügbar, damit Nutzer weltweit die Integration einfach verstehen und nutzen können.
- English (en)
- German (deutsch) (de)
- Dutch (nederlands) (nl)
- Spanish (español) (es)
- French (français) (fr)
- Italian (italiano) (it)
- Portuguese (português) (pt)
- Russian (русский) (ru)
- Simplified Chinese (中文) (cn)
- Japanese (日本語) (ja)
- Arabic (العربية) (ar)
- Greek (Ελληνικά) (el)
- Hindi (हिन्दी) (hi)
- Polish (polski) (pl)
- Turkish (türkçe) (tr)
If a language is missing, please let us know, and we will do our best to add it.
Falls eine Sprache fehlt, lassen Sie es uns wissen, und wir bemühen uns, diese hinzuzufügen.
- 🔌 Multi-device Support: Gateways, sensors, switches, alarms, and more
- ☁️ Cloud Integration: Connect via Heiman account with OAuth2 authentication
- 📡 MQTT Real-time Updates: Instant device status updates via MQTT push
- 🔄 Firmware Management: Check and install firmware updates directly from Home Assistant
- 👨👩👧👦 Child Device Management: Add, remove, and manage gateway sub-devices via MQTT
- 🏠 Multi-home Support: Manage multiple Heiman homes independently
- 🎛️ Comprehensive Entities: Sensors, switches, buttons, selects, binary sensors, and update entities
- ⚙️ Web UI Configuration: Easy setup without YAML configuration
- Open HACS → Integrations
- Click + EXPLORE & DOWNLOAD REPOSITORIES
- Search for
Heiman Homeor click the three dots (⋮) → Custom repositories - Add repository:
https://github.com/hass-user/heiman-homewith categoryIntegration - Click DOWNLOAD THIS REPOSITORY
- Open HACS → Integrations
- Find Heiman Home
- Click UPDATE or Redownload
- Download the latest release from GitHub Releases
- Extract the
heiman_homefolder - Copy the
heiman_homefolder to your Home Assistantcustom_componentsdirectory/config/custom_components/heiman_home/
wget -O - https://raw.githubusercontent.com/hass-user/heiman-home/main/install.sh | bash -- Restart Home Assistant
- Go to Settings → Devices & Services
- Click + Add Integration
- Search for
Heiman Home
- Open Home Assistant web UI
- Navigate to Settings → Devices & Services
- Click Add Integration
- Search for
Heiman Homeand select it - Authorize with your Heiman account (OAuth2)
- Select the home you want to integrate
- Complete the setup
The integration uses OAuth2 for secure authentication:
- Click Authorize to log in to your Heiman account
- Grant necessary permissions
- Select the home you want to integrate
You can add multiple Heiman homes:
- Each home creates a separate configuration entry
- Each home has independent device management
- Configure each home separately in Devices & Services
You can filter which devices to integrate:
- Open the integration settings
- Navigate to Options
- Enable/disable specific devices
- Save changes
- Smart Gateway (WS3GW-R, etc.)
- 🌐 Zigbee Gateway
- 🌐 WiFi Gateway
- 🌡️ Temperature & Humidity Sensors
- 🚪 Door/Window Sensors
- 💧 Water Leak Sensors
- 🔥 Smoke Sensors
- 💨 Gas Sensors
- 🏃 Motion Sensors
- 🌞 Illumination Sensors
- 🚨 Alarm Systems
- 🔔 Alarm Sound Control
- 🚪 Access Control
- 🔌 Smart Plugs
- 💡 Light Switches
- 🎛️ Scene Controllers
- ️ Thermostats
- 💨 Air Quality Monitors
- 🔋 Battery-powered Devices
- Temperature
- Humidity
- Battery Level
- Signal Strength (RSSI)
- Illumination
- Device Status
- Door/Window Open/Closed
- Motion Detected
- Water Leak
- Smoke Detected
- Tamper Status
- Low Battery Warning
- Device On/Off
- Indicator Light
- Buzzer Control
- Alarm Enable/Disable
- Refresh Device Status
- Remote Check
- Remote Locate
- Remote Silence
- Alarm Sound Options (Fast Beep, Medium Beep, Slow Beep)
- Temperature Unit (°C / °F)
- Operating Mode
- Signal Level Display
- Temperature High Threshold
- Temperature Low Threshold
- Humidity High Threshold
- Humidity Low Threshold
- Temperature Comfort Range
- Humidity Comfort Range
- Firmware Version
- Available Updates
- Firmware Installation Progress
- Firmware updates are automatically checked during device synchronization
- Update entities show available firmware versions
- Compare installed version with latest available version
- Navigate to the device in Home Assistant
- Open the Firmware entity
- Click Install button
- Monitor update progress in real-time
- Device will restart after update completion
- ✅ Automatic version detection
- ✅ Progress monitoring (0-100%)
- ✅ Update status tracking
- ✅ Version comparison
- ✅ Batch update checking
The integration uses MQTT for instant device status updates:
- No polling delay
- Instant state changes
- Lower API usage
- Better performance
- Automatically configured during setup
- Uses Heiman MQTT broker
- Secure connection with TLS/SSL
- No manual configuration required
- Device property updates
- Online/offline status
- Alarm events
- Sensor readings
- Child device management (registration, unregistration, discovery)
The integration provides comprehensive child device management through the heiman-connect library.
All device management logic is implemented in the SDK, and Home Assistant integration provides a simple API to access these features.
from heimanconnect import ChildDeviceManager
# Get child device manager from API client
device_manager = await api_client.async_get_child_device_manager(
user_id="your_user_id",
devices=devices_dict,
user_display_name="Your Name"
)
# Add a child device (recommended method)
result = await device_manager.add_and_sync_device(
gateway_product_id="1733421468953686016",
gateway_device_id="1760910156165971969",
child_device_id="1768080341172985856",
child_product_id="1734821218500292608",
child_device_name="Door Sensor"
)
# Remove a child device (recommended method)
result = await device_manager.remove_and_sync_device(
gateway_product_id="1733421468953686016",
gateway_device_id="1760910156165971969",
child_device_id="1768080341172985856",
product_id="1734821218500292608",
device_name="01000053"
)For detailed documentation on all available methods and their parameters, see the heiman-connect library documentation.
Enable debug logging for troubleshooting:
# configuration.yaml
logger:
default: warning
logs:
custom_components.heiman_home: debug
heimanconnect: debug# configuration.yaml
homeassistant:
customize: !include customize.yaml
# customize.yaml
sensor.heiman_temperature:
friendly_name: "Living Room Temperature"
device_class: temperature
unit_of_measurement: "°C"
binary_sensor.heiman_door:
friendly_name: "Front Door"
device_class: door# configuration.yaml
heiman_home:
exclude_attributes:
- raw_data
- firmware_info
- configurationManually refresh a device's status.
service: heiman_home.refresh_device
data:
device_id: "1972646416676724736"Refresh all devices in the integration.
service: heiman_home.refresh_all_devices- Open Developer Tools → States
- Search for your entity (e.g.,
sensor.heiman_temperature) - View all attributes and current state
- Enable debug logging (see Logger Configuration)
- Open Settings → System → Logs
- Search for
heiman_homeorheimanconnect
- Check device filtering settings
- Verify device is online in Heiman app
- Restart the integration
- Ensure device is online
- Check device compatibility
- Verify firmware update is available in Heiman app
- Check internet connectivity
- Verify Heiman account credentials
- Check Home Assistant logs for errors
- Verify network allows outbound connections to
spmqtt.heiman.cn:1884 - Check firewall settings
- Restart Home Assistant
- Re-authorize the integration
- Verify Heiman account credentials
- Check if account has access to the selected home
- Check MQTT connection status in logs
- Verify device is online
- Try manual refresh via service
- Exclude unnecessary attributes (see Exclude Attributes)
- Disable unused entities
- Check for entities with too many state changes
- Reduce update interval if possible
- Filter out unused devices
- Disable MQTT if not needed (not recommended)
heiman_home/
├── __init__.py # Integration initialization
├── api.py # API client wrapper
├── config_flow.py # Configuration flow
├── const.py # Constants and configuration
├── coordinator.py # Data update coordinator
├── sensor.py # Sensor platform
├── binary_sensor.py # Binary sensor platform
├── switch.py # Switch platform
├── button.py # Button platform
├── select.py # Select platform
├── number.py # Number platform
├── update.py # Update platform (firmware)
├── manifest.json # Integration metadata
└── strings.json # Translations
Note: All device management logic is in the heiman-connect library, not in this integration.
heiman-connect: Python library for Heiman APIpackaging: Version comparison for firmware updates
Contributions are welcome! Please feel free to submit:
- Bug reports
- Feature requests
- Device support
- Translations
- Documentation improvements
This project is licensed under the MIT License - see the LICENSE file for details.
- Heiman for providing the IoT platform
- Home Assistant community
- HACS for the integration framework
- All contributors and testers
- GitHub Issues: Report bugs or request features
- Home Assistant Community Forum: Discuss and get help
- Documentation: Full documentation
Enjoy your smart home with Heiman and Home Assistant! 🏠✨






