Smart Home API
| Method | Path | Purpose |
|---|---|---|
GET | /api/v1/smart-home/devices | Snapshot all bridges |
GET | /api/v1/smart-home/devices/:id | Single device |
POST | /api/v1/smart-home/devices/:id/command | { "on": true, "brightness": 80 } |
POST | /api/v1/smart-home/scenes/:id/activate | Trigger scene |
POST | /api/v1/mqtt/publish | { "topic": "home/test", "payload": "ON" } |
⚠️ Warning: MQTT publish endpoint must be admin-scoped — never expose to unauthenticated LAN guests.
Example
curl -sS -X POST http://127.0.0.1:3000/api/v1/smart-home/devices/hue:light:12/command \
-H "Authorization: Bearer $M2C2_TOKEN" \
-H "Content-Type: application/json" \
-d '{"on":true,"brightness":120}'Troubleshooting
409 Conflict
Bridge rate-limited — back off and coalesce rapid slider moves client-side.
Last updated on
Was this helpful?