Add lights/jets/salt control, app-traffic mimicry, and optional local read path

- New entities: number (salt output level 0-10), switch (lights, jets); the
  read-only salt sensor is replaced by the settable number.
- Look identical to the official app on the wire: send the app's Dalvik UA on
  REST, okhttp/4.12.0 on the mTLS creds fetch, and "mqtt-<uuid>" client ids.
- Consolidate every constant value into constants.py (well commented); protocol.py
  keeps only the command builders; const.py removed.
- Optional local read path: a `local_status_url` config option polls the dongle's
  local /status endpoint for telemetry instead of the cloud MQTT subscription
  (control stays cloud MQTT). State getters handle both schemas.

No private/internal values in the repo (the spa IP is runtime config only).

Fixes bug-41mqxddz7zeh

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F6B8b3iYNv6QUftK2FDfYb
This commit is contained in:
Hank MuellerandClaude Opus 5 committed 2026-09-01 15:12:24 +00:00
1 parent 8cda06f7f3
commit cde2bbc772
16 files changed
+497 -151

No files matched your search

+6 -1
View File
@@ -19,11 +19,12 @@ from homeassistant.helpers.selector import (
)
from .api import HotSpringApiError, HotSpringAuthError, HotSpringCloud
from .const import (
from .constants import (
CA_FILE,
CERT_FILE,
CONF_CERT_DIR,
CONF_EMAIL,
CONF_LOCAL_STATUS_URL,
CONF_PASSWORD,
DEFAULT_CERT_DIR,
DOMAIN,
@@ -42,6 +43,10 @@ def _schema(defaults: dict[str, Any] | None = None) -> vol.Schema:
vol.Optional(
CONF_CERT_DIR, default=defaults.get(CONF_CERT_DIR, DEFAULT_CERT_DIR)
): str,
vol.Optional(
CONF_LOCAL_STATUS_URL,
default=defaults.get(CONF_LOCAL_STATUS_URL, ""),
): str,
}
)