Back

Product Architecture

HomeOS unifies fragmented smart-home installations under one control plane — from a single suite to an entire hospitality portfolio.

5-level hierarchy
Portfolio → Property → Building → Floor → Room
Per-property bridge
Each Home Assistant instance is its own secured tunnel
Realtime state
Device states stream via Supabase Realtime channels
RBAC + RLS
5 roles, row-level security on every table

Core data flow

  ┌──────────────┐    ┌───────────────────┐    ┌────────────────┐
  │   Client     │◄──►│   Edge Functions  │◄──►│   Supabase DB  │
  │  (React app) │    │  (Auth · Relay)   │    │  (PG + RLS)    │
  └──────┬───────┘    └─────────┬─────────┘    └────────┬───────┘
         │ Realtime               │ Command Relay         │ Audit
         ▼                        ▼                       ▼
  ┌──────────────┐    ┌───────────────────┐    ┌────────────────┐
  │ Live updates │    │  Home Assistant   │    │  Event log     │
  │  device:on   │    │  REST + Webhook   │    │  per actor     │
  └──────────────┘    └─────────┬─────────┘    └────────────────┘
                                ▼
                       ┌────────────────┐
                       │  Devices (Zig- │
                       │   bee · WiFi)  │
                       └────────────────┘

Rules engine

Trigger → Condition → Action, scoped to any hierarchy level.

  TRIGGER          CONDITION                ACTION
  ─────────        ───────────              ──────────────────
  guest_checkin →  property.kind=hotel  →   scene.run("Welcome")
  sensor.door  →   between(22:00,06:00) →   light.set(corridor, 30%)
  ha.offline   →   duration > 5m        →   ticket.create(urgent)
  temp > 26°C  →   thermostat.on=false  →   thermostat.set(target=23)
Edge
Cloudflare Workers route commands to the nearest HA bridge.
Storage
Postgres with row-level security per portfolio tenant.
Sync
Outbox pattern keeps device state eventually consistent.
Workflows
Visual rule builder compiles to deterministic state machines.
Security
Zero-trust mTLS between control plane and property bridges.
Latency
P95 command relay under 180ms across European regions.