Initial commit

This commit is contained in:
gerviba committed 2026-11-01 18:33:58 +01:00
commit e1e03ba73f
38 files changed
+2968

No files matched your search

+30
View File
@@ -0,0 +1,30 @@
"""Constants for the HA Probe integration."""
from __future__ import annotations
from dataclasses import dataclass, field
from typing import TYPE_CHECKING
from homeassistant.const import Platform
if TYPE_CHECKING:
from .sensor import HaProbeSensor
DOMAIN = "ha_probe"
PLATFORMS: list[Platform] = [Platform.SENSOR]
CONF_WEBHOOK_ID = "webhook_id"
def signal_entities(entry_id: str) -> str:
"""Return the dispatcher signal used to deliver a webhook payload's entities."""
return f"{DOMAIN}_{entry_id}_entities"
@dataclass
class HaProbeRuntimeData:
"""Runtime state for a configured probe webhook, kept on ConfigEntry.runtime_data."""
webhook_url: str = ""
devices: dict[str, str] = field(default_factory=dict)
entities: dict[str, "HaProbeSensor"] = field(default_factory=dict)