Connect your nSelf backend to Home Assistant and MQTT brokers. Control smart lights, locks, thermostats, and sensors from your own API. Activate scenes, subscribe to state changes, and build automations that run in your infrastructure — not a cloud you don't control.
Requires Home Assistant running on your local network with the REST API or Long-Lived Access Token enabled. Set your license key with nself license set nself_pro_... before installing.
nself license set nself_pro_...
nself plugin install home
nself build
nself start| Env Var | Required | Description |
|---|---|---|
HOME_ASSISTANT_URL | Yes | Home Assistant base URL (e.g. http://192.168.1.10:8123) |
HOME_ASSISTANT_TOKEN | Yes | Long-Lived Access Token from HA profile |
MQTT_BROKER_URL | No | MQTT broker URL for direct device control |
curl -X POST http://127.0.0.1:3600/home/entities/light.living_room/control \
-H "Content-Type: application/json" \
-d '{"action": "turn_on", "params": {"brightness": 180, "color_temp": 3000}}'curl -X POST http://127.0.0.1:3600/home/scenes/movie_time/activate| Endpoint | Method | Description |
|---|---|---|
/home/entities | GET | List all Home Assistant entities and their states |
/home/entities/:entity_id | GET | Get state of a specific entity |
/home/entities/:entity_id/control | POST | Send a control action to an entity |
/home/scenes | GET | List available scenes |
/home/scenes/:id/activate | POST | Activate a scene |
/home/events | GET (SSE) | Subscribe to real-time entity state changes |
/health | GET | Plugin health check |
nself plugin remove homeCategory: IoT | Language: Go | Last Updated: April 2026 | Plugin Version 1.1.1