homeassistant-stubs 2025.8.2__py3-none-any.whl → 2025.9.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of homeassistant-stubs might be problematic. Click here for more details.
- homeassistant-stubs/auth/models.pyi +3 -1
- homeassistant-stubs/components/airos/binary_sensor.pyi +27 -0
- homeassistant-stubs/components/airos/sensor.pyi +4 -2
- homeassistant-stubs/components/airq/number.pyi +31 -0
- homeassistant-stubs/components/aladdin_connect/__init__.pyi +10 -5
- homeassistant-stubs/components/aladdin_connect/api.pyi +12 -0
- homeassistant-stubs/components/aladdin_connect/application_credentials.pyi +5 -0
- homeassistant-stubs/components/aladdin_connect/config_flow.pyi +15 -4
- homeassistant-stubs/components/aladdin_connect/const.pyi +10 -0
- homeassistant-stubs/components/aladdin_connect/coordinator.pyi +16 -0
- homeassistant-stubs/components/aladdin_connect/cover.pyi +25 -0
- homeassistant-stubs/components/aladdin_connect/entity.pyi +15 -0
- homeassistant-stubs/components/aladdin_connect/sensor.pyi +25 -0
- homeassistant-stubs/components/alexa_devices/__init__.pyi +3 -2
- homeassistant-stubs/components/alexa_devices/config_flow.pyi +5 -2
- homeassistant-stubs/components/alexa_devices/const.pyi +2 -0
- homeassistant-stubs/components/alexa_devices/coordinator.pyi +1 -1
- homeassistant-stubs/components/alexa_devices/sensor.pyi +1 -1
- homeassistant-stubs/components/alexa_devices/services.pyi +0 -1
- homeassistant-stubs/components/amberelectric/config_flow.pyi +1 -1
- homeassistant-stubs/components/amberelectric/const.pyi +1 -1
- homeassistant-stubs/components/amberelectric/coordinator.pyi +1 -1
- homeassistant-stubs/components/amberelectric/services.pyi +2 -1
- homeassistant-stubs/components/ambient_station/entity.pyi +1 -1
- homeassistant-stubs/components/android_ip_webcam/coordinator.pyi +0 -1
- homeassistant-stubs/components/apcupsd/binary_sensor.pyi +2 -6
- homeassistant-stubs/components/apcupsd/entity.pyi +11 -0
- homeassistant-stubs/components/apcupsd/sensor.pyi +2 -6
- homeassistant-stubs/components/asuswrt/bridge.pyi +12 -8
- homeassistant-stubs/components/asuswrt/helpers.pyi +8 -0
- homeassistant-stubs/components/auth/login_flow.pyi +1 -1
- homeassistant-stubs/components/auth/mfa_setup_flow.pyi +1 -1
- homeassistant-stubs/components/awair/const.pyi +1 -0
- homeassistant-stubs/components/awair/sensor.pyi +2 -2
- homeassistant-stubs/components/backup/config.pyi +0 -14
- homeassistant-stubs/components/bayesian/__init__.pyi +6 -4
- homeassistant-stubs/components/bayesian/binary_sensor.pyi +6 -5
- homeassistant-stubs/components/bayesian/config_flow.pyi +69 -0
- homeassistant-stubs/components/bayesian/const.pyi +5 -0
- homeassistant-stubs/components/bayesian/issues.pyi +1 -1
- homeassistant-stubs/components/bosch_alarm/const.pyi +0 -1
- homeassistant-stubs/components/bosch_alarm/services.pyi +2 -1
- homeassistant-stubs/components/braviatv/button.pyi +1 -1
- homeassistant-stubs/components/braviatv/coordinator.pyi +1 -0
- homeassistant-stubs/components/braviatv/entity.pyi +1 -1
- homeassistant-stubs/components/climate/__init__.pyi +1 -1
- homeassistant-stubs/components/cloud/alexa_config.pyi +2 -1
- homeassistant-stubs/components/cloud/subscription.pyi +2 -4
- homeassistant-stubs/components/co2signal/coordinator.pyi +3 -3
- homeassistant-stubs/components/co2signal/helpers.pyi +2 -3
- homeassistant-stubs/components/co2signal/sensor.pyi +3 -3
- homeassistant-stubs/components/config/config_entries.pyi +6 -3
- homeassistant-stubs/components/deconz/hub/hub.pyi +0 -1
- homeassistant-stubs/components/deconz/services.pyi +0 -1
- homeassistant-stubs/components/demo/media_player.pyi +2 -0
- homeassistant-stubs/components/device_automation/condition.pyi +2 -2
- homeassistant-stubs/components/enphase_envoy/binary_sensor.pyi +29 -1
- homeassistant-stubs/components/enphase_envoy/sensor.pyi +30 -1
- homeassistant-stubs/components/esphome/manager.pyi +1 -2
- homeassistant-stubs/components/esphome/media_player.pyi +5 -0
- homeassistant-stubs/components/fan/intent.pyi +7 -0
- homeassistant-stubs/components/fritz/coordinator.pyi +0 -1
- homeassistant-stubs/components/fyta/const.pyi +4 -0
- homeassistant-stubs/components/fyta/sensor.pyi +11 -0
- homeassistant-stubs/components/glances/coordinator.pyi +0 -1
- homeassistant-stubs/components/group/config_flow.pyi +2 -0
- homeassistant-stubs/components/habitica/__init__.pyi +6 -2
- homeassistant-stubs/components/habitica/binary_sensor.pyi +13 -4
- homeassistant-stubs/components/habitica/coordinator.pyi +18 -4
- homeassistant-stubs/components/habitica/entity.pyi +10 -1
- homeassistant-stubs/components/habitica/image.pyi +19 -4
- homeassistant-stubs/components/habitica/sensor.pyi +27 -3
- homeassistant-stubs/components/habitica/util.pyi +5 -2
- homeassistant-stubs/components/home_connect/const.pyi +0 -7
- homeassistant-stubs/components/home_connect/services.pyi +1 -14
- homeassistant-stubs/components/homeassistant_hardware/coordinator.pyi +0 -1
- homeassistant-stubs/components/homee/config_flow.pyi +8 -2
- homeassistant-stubs/components/homee/const.pyi +3 -0
- homeassistant-stubs/components/homekit/accessories.pyi +1 -1
- homeassistant-stubs/components/homekit/const.pyi +4 -0
- homeassistant-stubs/components/homekit/type_switches.pyi +11 -1
- homeassistant-stubs/components/homekit/util.pyi +3 -2
- homeassistant-stubs/components/huawei_lte/__init__.pyi +2 -2
- homeassistant-stubs/components/huawei_lte/const.pyi +0 -1
- homeassistant-stubs/components/huawei_lte/notify.pyi +2 -2
- homeassistant-stubs/components/husqvarna_automower/button.pyi +4 -0
- homeassistant-stubs/components/husqvarna_automower/const.pyi +1 -0
- homeassistant-stubs/components/husqvarna_automower/coordinator.pyi +10 -0
- homeassistant-stubs/components/husqvarna_automower/event.pyi +35 -0
- homeassistant-stubs/components/husqvarna_automower/sensor.pyi +1 -2
- homeassistant-stubs/components/idasen_desk/__init__.pyi +0 -1
- homeassistant-stubs/components/jewish_calendar/__init__.pyi +2 -1
- homeassistant-stubs/components/jewish_calendar/coordinator.pyi +41 -0
- homeassistant-stubs/components/jewish_calendar/entity.pyi +5 -26
- homeassistant-stubs/components/jewish_calendar/sensor.pyi +1 -1
- homeassistant-stubs/components/knx/scene.pyi +5 -4
- homeassistant-stubs/components/knx/storage/entity_store_schema.pyi +5 -11
- homeassistant-stubs/components/knx/storage/knx_selector.pyi +57 -6
- homeassistant-stubs/components/knx/storage/serialize.pyi +10 -0
- homeassistant-stubs/components/knx/storage/util.pyi +2 -0
- homeassistant-stubs/components/knx/websocket.pyi +7 -3
- homeassistant-stubs/components/letpot/select.pyi +39 -0
- homeassistant-stubs/components/mastodon/__init__.pyi +1 -2
- homeassistant-stubs/components/mastodon/config_flow.pyi +2 -2
- homeassistant-stubs/components/mastodon/const.pyi +0 -1
- homeassistant-stubs/components/mastodon/diagnostics.pyi +2 -2
- homeassistant-stubs/components/mastodon/services.pyi +2 -1
- homeassistant-stubs/components/matter/lock.pyi +6 -0
- homeassistant-stubs/components/matter/sensor.pyi +2 -1
- homeassistant-stubs/components/mealie/const.pyi +0 -1
- homeassistant-stubs/components/mealie/services.pyi +2 -2
- homeassistant-stubs/components/media_player/__init__.pyi +4 -0
- homeassistant-stubs/components/media_player/intent.pyi +13 -3
- homeassistant-stubs/components/met_eireann/const.pyi +1 -1
- homeassistant-stubs/components/met_eireann/weather.pyi +4 -0
- homeassistant-stubs/components/miele/climate.pyi +3 -1
- homeassistant-stubs/components/miele/const.pyi +1 -0
- homeassistant-stubs/components/miele/coordinator.pyi +2 -3
- homeassistant-stubs/components/miele/entity.pyi +2 -3
- homeassistant-stubs/components/miele/sensor.pyi +25 -6
- homeassistant-stubs/components/modbus/binary_sensor.pyi +1 -2
- homeassistant-stubs/components/modbus/climate.pyi +1 -2
- homeassistant-stubs/components/modbus/const.pyi +2 -0
- homeassistant-stubs/components/modbus/entity.pyi +7 -16
- homeassistant-stubs/components/modbus/light.pyi +0 -1
- homeassistant-stubs/components/modbus/modbus.pyi +9 -11
- homeassistant-stubs/components/modbus/sensor.pyi +1 -3
- homeassistant-stubs/components/mqtt/alarm_control_panel.pyi +2 -23
- homeassistant-stubs/components/mqtt/config_flow.pyi +8 -2
- homeassistant-stubs/components/mqtt/const.pyi +40 -1
- homeassistant-stubs/components/mqtt/lock.pyi +1 -21
- homeassistant-stubs/components/mqtt/number.pyi +1 -0
- homeassistant-stubs/components/mqtt/sensor.pyi +1 -1
- homeassistant-stubs/components/music_assistant/actions.pyi +2 -1
- homeassistant-stubs/components/music_assistant/const.pyi +0 -1
- homeassistant-stubs/components/music_assistant/media_browser.pyi +1 -1
- homeassistant-stubs/components/nanoleaf/config_flow.pyi +1 -1
- homeassistant-stubs/components/number/__init__.pyi +3 -0
- homeassistant-stubs/components/number/const.pyi +2 -1
- homeassistant-stubs/components/open_router/entity.pyi +2 -2
- homeassistant-stubs/components/openai_conversation/entity.pyi +3 -3
- homeassistant-stubs/components/opower/__init__.pyi +1 -0
- homeassistant-stubs/components/opower/repairs.pyi +13 -0
- homeassistant-stubs/components/overseerr/const.pyi +0 -1
- homeassistant-stubs/components/overseerr/services.pyi +2 -1
- homeassistant-stubs/components/person/__init__.pyi +2 -1
- homeassistant-stubs/components/qbus/binary_sensor.pyi +43 -0
- homeassistant-stubs/components/qbus/climate.pyi +1 -1
- homeassistant-stubs/components/qbus/coordinator.pyi +4 -3
- homeassistant-stubs/components/qbus/cover.pyi +1 -1
- homeassistant-stubs/components/qbus/entity.pyi +6 -5
- homeassistant-stubs/components/qbus/light.pyi +1 -1
- homeassistant-stubs/components/qbus/scene.pyi +4 -6
- homeassistant-stubs/components/qbus/sensor.pyi +67 -0
- homeassistant-stubs/components/qbus/switch.pyi +1 -1
- homeassistant-stubs/components/recorder/statistics.pyi +1 -1
- homeassistant-stubs/components/recorder/websocket_api.pyi +1 -1
- homeassistant-stubs/components/rest_command/__init__.pyi +1 -1
- homeassistant-stubs/components/romy/coordinator.pyi +0 -1
- homeassistant-stubs/components/russound_rio/media_browser.pyi +8 -0
- homeassistant-stubs/components/russound_rio/media_player.pyi +3 -2
- homeassistant-stubs/components/ruuvitag_ble/sensor.pyi +2 -2
- homeassistant-stubs/components/scene/__init__.pyi +13 -4
- homeassistant-stubs/components/sensibo/select.pyi +0 -5
- homeassistant-stubs/components/sensor/__init__.pyi +3 -0
- homeassistant-stubs/components/sensor/const.pyi +3 -2
- homeassistant-stubs/components/sensor/recorder.pyi +1 -1
- homeassistant-stubs/components/sleep_as_android/__init__.pyi +16 -0
- homeassistant-stubs/components/sleep_as_android/config_flow.pyi +2 -0
- homeassistant-stubs/components/sleep_as_android/const.pyi +9 -0
- homeassistant-stubs/components/sleep_as_android/diagnostics.pyi +5 -0
- homeassistant-stubs/components/sleep_as_android/entity.pyi +20 -0
- homeassistant-stubs/components/sleep_as_android/event.pyi +33 -0
- homeassistant-stubs/components/sleep_as_android/sensor.pyi +25 -0
- homeassistant-stubs/components/solarlog/sensor.pyi +11 -1
- homeassistant-stubs/components/speedtestdotnet/coordinator.pyi +0 -1
- homeassistant-stubs/components/stookwijzer/const.pyi +0 -1
- homeassistant-stubs/components/stookwijzer/services.pyi +2 -1
- homeassistant-stubs/components/sun/condition.pyi +2 -2
- homeassistant-stubs/components/switchbot_cloud/__init__.pyi +1 -0
- homeassistant-stubs/components/switchbot_cloud/const.pyi +10 -0
- homeassistant-stubs/components/switchbot_cloud/cover.pyi +57 -0
- homeassistant-stubs/components/switchbot_cloud/fan.pyi +22 -1
- homeassistant-stubs/components/telegram_bot/__init__.pyi +2 -1
- homeassistant-stubs/components/telegram_bot/bot.pyi +4 -1
- homeassistant-stubs/components/telegram_bot/notify.pyi +21 -0
- homeassistant-stubs/components/unifi/switch.pyi +3 -0
- homeassistant-stubs/components/volvo/__init__.pyi +1 -1
- homeassistant-stubs/components/volvo/binary_sensor.pyi +42 -0
- homeassistant-stubs/components/volvo/const.pyi +1 -1
- homeassistant-stubs/components/volvo/coordinator.pyi +8 -1
- homeassistant-stubs/components/volvo/sensor.pyi +2 -2
- homeassistant-stubs/components/webostv/__init__.pyi +2 -2
- homeassistant-stubs/components/webostv/const.pyi +0 -1
- homeassistant-stubs/components/webostv/notify.pyi +2 -2
- homeassistant-stubs/components/websocket_api/http.pyi +1 -0
- homeassistant-stubs/components/wemo/coordinator.pyi +0 -1
- homeassistant-stubs/components/withings/diagnostics.pyi +4 -0
- homeassistant-stubs/components/workday/__init__.pyi +6 -8
- homeassistant-stubs/components/workday/binary_sensor.pyi +9 -33
- homeassistant-stubs/components/workday/entity.pyi +34 -0
- homeassistant-stubs/components/workday/util.pyi +14 -0
- homeassistant-stubs/components/yalexs_ble/__init__.pyi +3 -1
- homeassistant-stubs/components/yalexs_ble/config_cache.pyi +10 -0
- homeassistant-stubs/components/yalexs_ble/config_flow.pyi +4 -0
- homeassistant-stubs/components/zone/condition.pyi +2 -2
- homeassistant-stubs/components/zwave_js/__init__.pyi +5 -5
- homeassistant-stubs/components/zwave_js/binary_sensor.pyi +18 -10
- homeassistant-stubs/components/zwave_js/config_flow.pyi +6 -0
- homeassistant-stubs/components/zwave_js/const.pyi +0 -1
- homeassistant-stubs/components/zwave_js/discovery.pyi +7 -51
- homeassistant-stubs/components/zwave_js/discovery_data_template.pyi +1 -11
- homeassistant-stubs/components/zwave_js/entity.pyi +15 -5
- homeassistant-stubs/components/zwave_js/helpers.pyi +0 -7
- homeassistant-stubs/components/zwave_js/migrate.pyi +2 -2
- homeassistant-stubs/components/zwave_js/models.pyi +95 -1
- homeassistant-stubs/components/zwave_js/sensor.pyi +7 -4
- homeassistant-stubs/components/zwave_js/triggers/event.pyi +5 -4
- homeassistant-stubs/components/zwave_js/triggers/trigger_helpers.pyi +2 -2
- homeassistant-stubs/components/zwave_js/triggers/value_updated.pyi +3 -2
- homeassistant-stubs/components/zwave_js/update.pyi +0 -3
- homeassistant-stubs/config_entries.pyi +5 -0
- homeassistant-stubs/const.pyi +9 -5
- homeassistant-stubs/data_entry_flow.pyi +0 -1
- homeassistant-stubs/helpers/automation.pyi +2 -0
- homeassistant-stubs/helpers/condition.pyi +6 -6
- homeassistant-stubs/helpers/config_validation.pyi +3 -0
- homeassistant-stubs/helpers/data_entry_flow.pyi +1 -1
- homeassistant-stubs/helpers/device_registry.pyi +2 -2
- homeassistant-stubs/helpers/entity_registry.pyi +4 -3
- homeassistant-stubs/helpers/json.pyi +0 -7
- homeassistant-stubs/helpers/llm.pyi +1 -0
- homeassistant-stubs/helpers/schema_config_entry_flow.pyi +2 -1
- homeassistant-stubs/helpers/selector.pyi +2 -1
- homeassistant-stubs/helpers/target.pyi +3 -2
- homeassistant-stubs/helpers/trigger.pyi +6 -6
- homeassistant-stubs/util/unit_conversion.pyi +11 -1
- {homeassistant_stubs-2025.8.2.dist-info → homeassistant_stubs-2025.9.0.dist-info}/METADATA +2 -2
- {homeassistant_stubs-2025.8.2.dist-info → homeassistant_stubs-2025.9.0.dist-info}/RECORD +241 -215
- homeassistant-stubs/components/linear_garage_door/__init__.pyi +0 -10
- homeassistant-stubs/components/linear_garage_door/config_flow.pyi +0 -25
- homeassistant-stubs/components/linear_garage_door/const.pyi +0 -1
- homeassistant-stubs/components/linear_garage_door/coordinator.pyi +0 -26
- homeassistant-stubs/components/linear_garage_door/cover.pyi +0 -28
- homeassistant-stubs/components/linear_garage_door/diagnostics.pyi +0 -10
- homeassistant-stubs/components/linear_garage_door/entity.pyi +0 -17
- homeassistant-stubs/components/linear_garage_door/light.pyi +0 -23
- homeassistant-stubs/components/mastodon/notify.pyi +0 -24
- {homeassistant_stubs-2025.8.2.dist-info → homeassistant_stubs-2025.9.0.dist-info}/WHEEL +0 -0
- {homeassistant_stubs-2025.8.2.dist-info → homeassistant_stubs-2025.9.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
from . import SleepAsAndroidConfigEntry as SleepAsAndroidConfigEntry
|
|
2
|
+
from homeassistant.core import HomeAssistant as HomeAssistant
|
|
3
|
+
from typing import Any
|
|
4
|
+
|
|
5
|
+
async def async_get_config_entry_diagnostics(hass: HomeAssistant, config_entry: SleepAsAndroidConfigEntry) -> dict[str, Any]: ...
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import abc
|
|
2
|
+
from . import SleepAsAndroidConfigEntry as SleepAsAndroidConfigEntry
|
|
3
|
+
from .const import DOMAIN as DOMAIN
|
|
4
|
+
from _typeshed import Incomplete
|
|
5
|
+
from abc import abstractmethod
|
|
6
|
+
from homeassistant.const import CONF_WEBHOOK_ID as CONF_WEBHOOK_ID
|
|
7
|
+
from homeassistant.helpers.device_registry import DeviceInfo as DeviceInfo
|
|
8
|
+
from homeassistant.helpers.dispatcher import async_dispatcher_connect as async_dispatcher_connect
|
|
9
|
+
from homeassistant.helpers.entity import Entity as Entity, EntityDescription as EntityDescription
|
|
10
|
+
|
|
11
|
+
class SleepAsAndroidEntity(Entity, metaclass=abc.ABCMeta):
|
|
12
|
+
_attr_has_entity_name: bool
|
|
13
|
+
_attr_unique_id: Incomplete
|
|
14
|
+
entity_description: Incomplete
|
|
15
|
+
webhook_id: Incomplete
|
|
16
|
+
_attr_device_info: Incomplete
|
|
17
|
+
def __init__(self, config_entry: SleepAsAndroidConfigEntry, entity_description: EntityDescription) -> None: ...
|
|
18
|
+
@abstractmethod
|
|
19
|
+
def _async_handle_event(self, webhook_id: str, data: dict[str, str]) -> None: ...
|
|
20
|
+
async def async_added_to_hass(self) -> None: ...
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
from . import SleepAsAndroidConfigEntry as SleepAsAndroidConfigEntry
|
|
2
|
+
from .const import ATTR_EVENT as ATTR_EVENT, MAP_EVENTS as MAP_EVENTS
|
|
3
|
+
from .entity import SleepAsAndroidEntity as SleepAsAndroidEntity
|
|
4
|
+
from dataclasses import dataclass
|
|
5
|
+
from enum import StrEnum
|
|
6
|
+
from homeassistant.components.event import EventDeviceClass as EventDeviceClass, EventEntity as EventEntity, EventEntityDescription as EventEntityDescription
|
|
7
|
+
from homeassistant.core import HomeAssistant as HomeAssistant, callback as callback
|
|
8
|
+
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback as AddConfigEntryEntitiesCallback
|
|
9
|
+
|
|
10
|
+
PARALLEL_UPDATES: int
|
|
11
|
+
|
|
12
|
+
@dataclass(kw_only=True, frozen=True)
|
|
13
|
+
class SleepAsAndroidEventEntityDescription(EventEntityDescription):
|
|
14
|
+
event_types: list[str]
|
|
15
|
+
|
|
16
|
+
class SleepAsAndroidEvent(StrEnum):
|
|
17
|
+
ALARM_CLOCK = 'alarm_clock'
|
|
18
|
+
USER_NOTIFICATION = 'user_notification'
|
|
19
|
+
SMART_WAKEUP = 'smart_wakeup'
|
|
20
|
+
SLEEP_HEALTH = 'sleep_health'
|
|
21
|
+
LULLABY = 'lullaby'
|
|
22
|
+
SLEEP_PHASE = 'sleep_phase'
|
|
23
|
+
SLEEP_TRACKING = 'sleep_tracking'
|
|
24
|
+
SOUND_EVENT = 'sound_event'
|
|
25
|
+
|
|
26
|
+
EVENT_DESCRIPTIONS: tuple[SleepAsAndroidEventEntityDescription, ...]
|
|
27
|
+
|
|
28
|
+
async def async_setup_entry(hass: HomeAssistant, config_entry: SleepAsAndroidConfigEntry, async_add_entities: AddConfigEntryEntitiesCallback) -> None: ...
|
|
29
|
+
|
|
30
|
+
class SleepAsAndroidEventEntity(SleepAsAndroidEntity, EventEntity):
|
|
31
|
+
entity_description: SleepAsAndroidEventEntityDescription
|
|
32
|
+
@callback
|
|
33
|
+
def _async_handle_event(self, webhook_id: str, data: dict[str, str]) -> None: ...
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
from . import SleepAsAndroidConfigEntry as SleepAsAndroidConfigEntry
|
|
2
|
+
from .const import ALARM_LABEL_DEFAULT as ALARM_LABEL_DEFAULT, ATTR_EVENT as ATTR_EVENT, ATTR_VALUE1 as ATTR_VALUE1, ATTR_VALUE2 as ATTR_VALUE2
|
|
3
|
+
from .entity import SleepAsAndroidEntity as SleepAsAndroidEntity
|
|
4
|
+
from _typeshed import Incomplete
|
|
5
|
+
from enum import StrEnum
|
|
6
|
+
from homeassistant.components.sensor import RestoreSensor as RestoreSensor, SensorDeviceClass as SensorDeviceClass, SensorEntityDescription as SensorEntityDescription
|
|
7
|
+
from homeassistant.core import HomeAssistant as HomeAssistant, callback as callback
|
|
8
|
+
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback as AddConfigEntryEntitiesCallback
|
|
9
|
+
|
|
10
|
+
PARALLEL_UPDATES: int
|
|
11
|
+
|
|
12
|
+
class SleepAsAndroidSensor(StrEnum):
|
|
13
|
+
NEXT_ALARM = 'next_alarm'
|
|
14
|
+
ALARM_LABEL = 'alarm_label'
|
|
15
|
+
|
|
16
|
+
SENSOR_DESCRIPTIONS: tuple[SensorEntityDescription, ...]
|
|
17
|
+
|
|
18
|
+
async def async_setup_entry(hass: HomeAssistant, config_entry: SleepAsAndroidConfigEntry, async_add_entities: AddConfigEntryEntitiesCallback) -> None: ...
|
|
19
|
+
|
|
20
|
+
class SleepAsAndroidSensorEntity(SleepAsAndroidEntity, RestoreSensor):
|
|
21
|
+
entity_description: SensorEntityDescription
|
|
22
|
+
_attr_native_value: Incomplete
|
|
23
|
+
@callback
|
|
24
|
+
def _async_handle_event(self, webhook_id: str, data: dict[str, str]) -> None: ...
|
|
25
|
+
async def async_added_to_hass(self) -> None: ...
|
|
@@ -8,17 +8,22 @@ from homeassistant.const import PERCENTAGE as PERCENTAGE, UnitOfElectricPotentia
|
|
|
8
8
|
from homeassistant.core import HomeAssistant as HomeAssistant
|
|
9
9
|
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback as AddConfigEntryEntitiesCallback
|
|
10
10
|
from homeassistant.helpers.typing import StateType as StateType
|
|
11
|
-
from solarlog_cli.solarlog_models import InverterData as InverterData, SolarlogData as SolarlogData
|
|
11
|
+
from solarlog_cli.solarlog_models import BatteryData as BatteryData, InverterData as InverterData, SolarlogData as SolarlogData
|
|
12
12
|
|
|
13
13
|
@dataclass(frozen=True, kw_only=True)
|
|
14
14
|
class SolarLogCoordinatorSensorEntityDescription(SensorEntityDescription):
|
|
15
15
|
value_fn: Callable[[SolarlogData], StateType | datetime | None]
|
|
16
16
|
|
|
17
|
+
@dataclass(frozen=True, kw_only=True)
|
|
18
|
+
class SolarLogBatterySensorEntityDescription(SensorEntityDescription):
|
|
19
|
+
value_fn: Callable[[BatteryData], float | int | None]
|
|
20
|
+
|
|
17
21
|
@dataclass(frozen=True, kw_only=True)
|
|
18
22
|
class SolarLogInverterSensorEntityDescription(SensorEntityDescription):
|
|
19
23
|
value_fn: Callable[[InverterData], float | None]
|
|
20
24
|
|
|
21
25
|
SOLARLOG_SENSOR_TYPES: tuple[SolarLogCoordinatorSensorEntityDescription, ...]
|
|
26
|
+
BATTERY_SENSOR_TYPES: tuple[SolarLogBatterySensorEntityDescription, ...]
|
|
22
27
|
INVERTER_SENSOR_TYPES: tuple[SolarLogInverterSensorEntityDescription, ...]
|
|
23
28
|
|
|
24
29
|
async def async_setup_entry(hass: HomeAssistant, entry: SolarlogConfigEntry, async_add_entities: AddConfigEntryEntitiesCallback) -> None: ...
|
|
@@ -28,6 +33,11 @@ class SolarLogCoordinatorSensor(SolarLogCoordinatorEntity, SensorEntity):
|
|
|
28
33
|
@property
|
|
29
34
|
def native_value(self) -> StateType | datetime: ...
|
|
30
35
|
|
|
36
|
+
class SolarLogBatterySensor(SolarLogCoordinatorEntity, SensorEntity):
|
|
37
|
+
entity_description: SolarLogBatterySensorEntityDescription
|
|
38
|
+
@property
|
|
39
|
+
def native_value(self) -> StateType: ...
|
|
40
|
+
|
|
31
41
|
class SolarLogInverterSensor(SolarLogInverterEntity, SensorEntity):
|
|
32
42
|
entity_description: SolarLogInverterSensorEntityDescription
|
|
33
43
|
@property
|
|
@@ -11,7 +11,6 @@ type SpeedTestConfigEntry = ConfigEntry[SpeedTestDataCoordinator]
|
|
|
11
11
|
|
|
12
12
|
class SpeedTestDataCoordinator(DataUpdateCoordinator[dict[str, Any]]):
|
|
13
13
|
config_entry: SpeedTestConfigEntry
|
|
14
|
-
hass: Incomplete
|
|
15
14
|
api: Incomplete
|
|
16
15
|
servers: dict[str, dict]
|
|
17
16
|
def __init__(self, hass: HomeAssistant, config_entry: SpeedTestConfigEntry, api: speedtest.Speedtest) -> None: ...
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
from .const import
|
|
1
|
+
from .const import DOMAIN as DOMAIN, SERVICE_GET_FORECAST as SERVICE_GET_FORECAST
|
|
2
2
|
from .coordinator import StookwijzerConfigEntry as StookwijzerConfigEntry
|
|
3
3
|
from _typeshed import Incomplete
|
|
4
4
|
from homeassistant.config_entries import ConfigEntryState as ConfigEntryState
|
|
5
|
+
from homeassistant.const import ATTR_CONFIG_ENTRY_ID as ATTR_CONFIG_ENTRY_ID
|
|
5
6
|
from homeassistant.core import HomeAssistant as HomeAssistant, ServiceCall as ServiceCall, ServiceResponse as ServiceResponse, SupportsResponse as SupportsResponse
|
|
6
7
|
from homeassistant.exceptions import ServiceValidationError as ServiceValidationError
|
|
7
8
|
from typing import Required, TypedDict
|
|
@@ -15,8 +15,8 @@ class SunCondition(Condition):
|
|
|
15
15
|
_hass: Incomplete
|
|
16
16
|
def __init__(self, hass: HomeAssistant, config: ConfigType) -> None: ...
|
|
17
17
|
@classmethod
|
|
18
|
-
async def
|
|
19
|
-
async def
|
|
18
|
+
async def async_validate_config(cls, hass: HomeAssistant, config: ConfigType) -> ConfigType: ...
|
|
19
|
+
async def async_get_checker(self) -> ConditionCheckerType: ...
|
|
20
20
|
|
|
21
21
|
CONDITIONS: dict[str, type[Condition]]
|
|
22
22
|
|
|
@@ -19,6 +19,7 @@ class SwitchbotDevices:
|
|
|
19
19
|
binary_sensors: list[tuple[Device, SwitchBotCoordinator]] = field(default_factory=list)
|
|
20
20
|
buttons: list[tuple[Device, SwitchBotCoordinator]] = field(default_factory=list)
|
|
21
21
|
climates: list[tuple[Remote, SwitchBotCoordinator]] = field(default_factory=list)
|
|
22
|
+
covers: list[tuple[Device, SwitchBotCoordinator]] = field(default_factory=list)
|
|
22
23
|
switches: list[tuple[Device | Remote, SwitchBotCoordinator]] = field(default_factory=list)
|
|
23
24
|
sensors: list[tuple[Device, SwitchBotCoordinator]] = field(default_factory=list)
|
|
24
25
|
vacuums: list[tuple[Device, SwitchBotCoordinator]] = field(default_factory=list)
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
from _typeshed import Incomplete
|
|
2
|
+
from enum import Enum
|
|
2
3
|
from typing import Final
|
|
3
4
|
|
|
4
5
|
DOMAIN: Final[str]
|
|
@@ -12,3 +13,12 @@ VACUUM_FAN_SPEED_STANDARD: str
|
|
|
12
13
|
VACUUM_FAN_SPEED_STRONG: str
|
|
13
14
|
VACUUM_FAN_SPEED_MAX: str
|
|
14
15
|
AFTER_COMMAND_REFRESH: int
|
|
16
|
+
COVER_ENTITY_AFTER_COMMAND_REFRESH: int
|
|
17
|
+
|
|
18
|
+
class AirPurifierMode(Enum):
|
|
19
|
+
NORMAL = 1
|
|
20
|
+
AUTO = 2
|
|
21
|
+
SLEEP = 3
|
|
22
|
+
PET = 4
|
|
23
|
+
@classmethod
|
|
24
|
+
def get_modes(cls) -> list[str]: ...
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
from . import SwitchBotCoordinator as SwitchBotCoordinator, SwitchbotCloudData as SwitchbotCloudData
|
|
2
|
+
from .const import COVER_ENTITY_AFTER_COMMAND_REFRESH as COVER_ENTITY_AFTER_COMMAND_REFRESH, DOMAIN as DOMAIN
|
|
3
|
+
from .entity import SwitchBotCloudEntity as SwitchBotCloudEntity
|
|
4
|
+
from _typeshed import Incomplete
|
|
5
|
+
from homeassistant.components.cover import CoverDeviceClass as CoverDeviceClass, CoverEntity as CoverEntity, CoverEntityFeature as CoverEntityFeature
|
|
6
|
+
from homeassistant.config_entries import ConfigEntry as ConfigEntry
|
|
7
|
+
from homeassistant.core import HomeAssistant as HomeAssistant, callback as callback
|
|
8
|
+
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback as AddConfigEntryEntitiesCallback
|
|
9
|
+
from switchbot_api import Device as Device, Remote as Remote, SwitchBotAPI as SwitchBotAPI
|
|
10
|
+
from typing import Any
|
|
11
|
+
|
|
12
|
+
async def async_setup_entry(hass: HomeAssistant, config: ConfigEntry, async_add_entities: AddConfigEntryEntitiesCallback) -> None: ...
|
|
13
|
+
|
|
14
|
+
class SwitchBotCloudCover(SwitchBotCloudEntity, CoverEntity):
|
|
15
|
+
_attr_name: Incomplete
|
|
16
|
+
_attr_is_closed: bool | None
|
|
17
|
+
_attr_current_cover_position: Incomplete
|
|
18
|
+
_attr_current_cover_tilt_position: Incomplete
|
|
19
|
+
def _set_attributes(self) -> None: ...
|
|
20
|
+
|
|
21
|
+
class SwitchBotCloudCoverCurtain(SwitchBotCloudCover):
|
|
22
|
+
_attr_device_class: Incomplete
|
|
23
|
+
_attr_supported_features: CoverEntityFeature
|
|
24
|
+
async def async_open_cover(self, **kwargs: Any) -> None: ...
|
|
25
|
+
async def async_close_cover(self, **kwargs: Any) -> None: ...
|
|
26
|
+
async def async_set_cover_position(self, **kwargs: Any) -> None: ...
|
|
27
|
+
async def async_stop_cover(self, **kwargs: Any) -> None: ...
|
|
28
|
+
|
|
29
|
+
class SwitchBotCloudCoverRollerShade(SwitchBotCloudCover):
|
|
30
|
+
_attr_device_class: Incomplete
|
|
31
|
+
_attr_supported_features: CoverEntityFeature
|
|
32
|
+
async def async_open_cover(self, **kwargs: Any) -> None: ...
|
|
33
|
+
async def async_close_cover(self, **kwargs: Any) -> None: ...
|
|
34
|
+
async def async_set_cover_position(self, **kwargs: Any) -> None: ...
|
|
35
|
+
|
|
36
|
+
class SwitchBotCloudCoverBlindTilt(SwitchBotCloudCover):
|
|
37
|
+
_attr_direction: str | None
|
|
38
|
+
_attr_device_class: Incomplete
|
|
39
|
+
_attr_supported_features: CoverEntityFeature
|
|
40
|
+
_attr_is_closed: Incomplete
|
|
41
|
+
_attr_current_cover_position: Incomplete
|
|
42
|
+
_attr_current_cover_tilt_position: Incomplete
|
|
43
|
+
def _set_attributes(self) -> None: ...
|
|
44
|
+
async def async_set_cover_tilt_position(self, **kwargs: Any) -> None: ...
|
|
45
|
+
async def async_open_cover_tilt(self, **kwargs: Any) -> None: ...
|
|
46
|
+
async def async_close_cover_tilt(self, **kwargs: Any) -> None: ...
|
|
47
|
+
|
|
48
|
+
class SwitchBotCloudCoverGarageDoorOpener(SwitchBotCloudCover):
|
|
49
|
+
_attr_device_class: Incomplete
|
|
50
|
+
_attr_supported_features: CoverEntityFeature
|
|
51
|
+
_attr_is_closed: Incomplete
|
|
52
|
+
def _set_attributes(self) -> None: ...
|
|
53
|
+
async def async_open_cover(self, **kwargs: Any) -> None: ...
|
|
54
|
+
async def async_close_cover(self, **kwargs: Any) -> None: ...
|
|
55
|
+
|
|
56
|
+
@callback
|
|
57
|
+
def _async_make_entity(api: SwitchBotAPI, device: Device | Remote, coordinator: SwitchBotCoordinator) -> SwitchBotCloudCoverBlindTilt | SwitchBotCloudCoverRollerShade | SwitchBotCloudCoverCurtain | SwitchBotCloudCoverGarageDoorOpener: ...
|
|
@@ -1,17 +1,23 @@
|
|
|
1
1
|
from . import SwitchbotCloudData as SwitchbotCloudData
|
|
2
|
-
from .const import DOMAIN as DOMAIN
|
|
2
|
+
from .const import AFTER_COMMAND_REFRESH as AFTER_COMMAND_REFRESH, AirPurifierMode as AirPurifierMode, DOMAIN as DOMAIN
|
|
3
3
|
from .entity import SwitchBotCloudEntity as SwitchBotCloudEntity
|
|
4
4
|
from _typeshed import Incomplete
|
|
5
5
|
from homeassistant.components.fan import FanEntity as FanEntity, FanEntityFeature as FanEntityFeature
|
|
6
6
|
from homeassistant.config_entries import ConfigEntry as ConfigEntry
|
|
7
|
+
from homeassistant.const import STATE_ON as STATE_ON
|
|
7
8
|
from homeassistant.core import HomeAssistant as HomeAssistant
|
|
8
9
|
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback as AddConfigEntryEntitiesCallback
|
|
10
|
+
from switchbot_api import SwitchBotAPI as SwitchBotAPI
|
|
9
11
|
from typing import Any
|
|
10
12
|
|
|
13
|
+
_LOGGER: Incomplete
|
|
14
|
+
PARALLEL_UPDATES: int
|
|
15
|
+
|
|
11
16
|
async def async_setup_entry(hass: HomeAssistant, config: ConfigEntry, async_add_entities: AddConfigEntryEntitiesCallback) -> None: ...
|
|
12
17
|
|
|
13
18
|
class SwitchBotCloudFan(SwitchBotCloudEntity, FanEntity):
|
|
14
19
|
_attr_name: Incomplete
|
|
20
|
+
_api: SwitchBotAPI
|
|
15
21
|
_attr_supported_features: Incomplete
|
|
16
22
|
_attr_preset_modes: Incomplete
|
|
17
23
|
_attr_is_on: bool | None
|
|
@@ -24,3 +30,18 @@ class SwitchBotCloudFan(SwitchBotCloudEntity, FanEntity):
|
|
|
24
30
|
async def async_turn_off(self, **kwargs: Any) -> None: ...
|
|
25
31
|
async def async_set_percentage(self, percentage: int) -> None: ...
|
|
26
32
|
async def async_set_preset_mode(self, preset_mode: str) -> None: ...
|
|
33
|
+
|
|
34
|
+
class SwitchBotAirPurifierEntity(SwitchBotCloudEntity, FanEntity):
|
|
35
|
+
_api: SwitchBotAPI
|
|
36
|
+
_attr_supported_features: Incomplete
|
|
37
|
+
_attr_preset_modes: Incomplete
|
|
38
|
+
_attr_translation_key: str
|
|
39
|
+
_attr_name: Incomplete
|
|
40
|
+
_attr_is_on: bool | None
|
|
41
|
+
@property
|
|
42
|
+
def is_on(self) -> bool | None: ...
|
|
43
|
+
_attr_preset_mode: Incomplete
|
|
44
|
+
def _set_attributes(self) -> None: ...
|
|
45
|
+
async def async_set_preset_mode(self, preset_mode: str) -> None: ...
|
|
46
|
+
async def async_turn_on(self, percentage: int | None = None, preset_mode: str | None = None, **kwargs: Any) -> None: ...
|
|
47
|
+
async def async_turn_off(self, **kwargs: Any) -> None: ...
|
|
@@ -3,7 +3,7 @@ from .bot import TelegramBotConfigEntry as TelegramBotConfigEntry, TelegramNotif
|
|
|
3
3
|
from .const import ATTR_ALLOWS_MULTIPLE_ANSWERS as ATTR_ALLOWS_MULTIPLE_ANSWERS, ATTR_AUTHENTICATION as ATTR_AUTHENTICATION, ATTR_CALLBACK_QUERY_ID as ATTR_CALLBACK_QUERY_ID, ATTR_CAPTION as ATTR_CAPTION, ATTR_CHAT_ID as ATTR_CHAT_ID, ATTR_DISABLE_NOTIF as ATTR_DISABLE_NOTIF, ATTR_DISABLE_WEB_PREV as ATTR_DISABLE_WEB_PREV, ATTR_FILE as ATTR_FILE, ATTR_IS_ANONYMOUS as ATTR_IS_ANONYMOUS, ATTR_IS_BIG as ATTR_IS_BIG, ATTR_KEYBOARD as ATTR_KEYBOARD, ATTR_KEYBOARD_INLINE as ATTR_KEYBOARD_INLINE, ATTR_MESSAGE as ATTR_MESSAGE, ATTR_MESSAGEID as ATTR_MESSAGEID, ATTR_MESSAGE_TAG as ATTR_MESSAGE_TAG, ATTR_MESSAGE_THREAD_ID as ATTR_MESSAGE_THREAD_ID, ATTR_ONE_TIME_KEYBOARD as ATTR_ONE_TIME_KEYBOARD, ATTR_OPEN_PERIOD as ATTR_OPEN_PERIOD, ATTR_OPTIONS as ATTR_OPTIONS, ATTR_PARSER as ATTR_PARSER, ATTR_PASSWORD as ATTR_PASSWORD, ATTR_QUESTION as ATTR_QUESTION, ATTR_REACTION as ATTR_REACTION, ATTR_RESIZE_KEYBOARD as ATTR_RESIZE_KEYBOARD, ATTR_SHOW_ALERT as ATTR_SHOW_ALERT, ATTR_STICKER_ID as ATTR_STICKER_ID, ATTR_TARGET as ATTR_TARGET, ATTR_TIMEOUT as ATTR_TIMEOUT, ATTR_TITLE as ATTR_TITLE, ATTR_URL as ATTR_URL, ATTR_USERNAME as ATTR_USERNAME, ATTR_VERIFY_SSL as ATTR_VERIFY_SSL, CONF_ALLOWED_CHAT_IDS as CONF_ALLOWED_CHAT_IDS, CONF_BOT_COUNT as CONF_BOT_COUNT, CONF_CONFIG_ENTRY_ID as CONF_CONFIG_ENTRY_ID, CONF_PROXY_URL as CONF_PROXY_URL, CONF_TRUSTED_NETWORKS as CONF_TRUSTED_NETWORKS, DEFAULT_TRUSTED_NETWORKS as DEFAULT_TRUSTED_NETWORKS, DOMAIN as DOMAIN, PARSER_MD as PARSER_MD, PLATFORM_BROADCAST as PLATFORM_BROADCAST, PLATFORM_POLLING as PLATFORM_POLLING, PLATFORM_WEBHOOKS as PLATFORM_WEBHOOKS, SERVICE_ANSWER_CALLBACK_QUERY as SERVICE_ANSWER_CALLBACK_QUERY, SERVICE_DELETE_MESSAGE as SERVICE_DELETE_MESSAGE, SERVICE_EDIT_CAPTION as SERVICE_EDIT_CAPTION, SERVICE_EDIT_MESSAGE as SERVICE_EDIT_MESSAGE, SERVICE_EDIT_REPLYMARKUP as SERVICE_EDIT_REPLYMARKUP, SERVICE_LEAVE_CHAT as SERVICE_LEAVE_CHAT, SERVICE_SEND_ANIMATION as SERVICE_SEND_ANIMATION, SERVICE_SEND_DOCUMENT as SERVICE_SEND_DOCUMENT, SERVICE_SEND_LOCATION as SERVICE_SEND_LOCATION, SERVICE_SEND_MESSAGE as SERVICE_SEND_MESSAGE, SERVICE_SEND_PHOTO as SERVICE_SEND_PHOTO, SERVICE_SEND_POLL as SERVICE_SEND_POLL, SERVICE_SEND_STICKER as SERVICE_SEND_STICKER, SERVICE_SEND_VIDEO as SERVICE_SEND_VIDEO, SERVICE_SEND_VOICE as SERVICE_SEND_VOICE, SERVICE_SET_MESSAGE_REACTION as SERVICE_SET_MESSAGE_REACTION
|
|
4
4
|
from _typeshed import Incomplete
|
|
5
5
|
from homeassistant.config_entries import SOURCE_IMPORT as SOURCE_IMPORT
|
|
6
|
-
from homeassistant.const import ATTR_LATITUDE as ATTR_LATITUDE, ATTR_LONGITUDE as ATTR_LONGITUDE, CONF_API_KEY as CONF_API_KEY, CONF_PLATFORM as CONF_PLATFORM, CONF_SOURCE as CONF_SOURCE, CONF_URL as CONF_URL
|
|
6
|
+
from homeassistant.const import ATTR_LATITUDE as ATTR_LATITUDE, ATTR_LONGITUDE as ATTR_LONGITUDE, CONF_API_KEY as CONF_API_KEY, CONF_PLATFORM as CONF_PLATFORM, CONF_SOURCE as CONF_SOURCE, CONF_URL as CONF_URL, Platform as Platform
|
|
7
7
|
from homeassistant.core import HomeAssistant as HomeAssistant, ServiceCall as ServiceCall, ServiceResponse as ServiceResponse, SupportsResponse as SupportsResponse
|
|
8
8
|
from homeassistant.exceptions import ConfigEntryAuthFailed as ConfigEntryAuthFailed, ConfigEntryNotReady as ConfigEntryNotReady, HomeAssistantError as HomeAssistantError, ServiceValidationError as ServiceValidationError
|
|
9
9
|
from homeassistant.helpers.typing import ConfigType as ConfigType
|
|
@@ -27,6 +27,7 @@ SERVICE_SCHEMA_LEAVE_CHAT: Incomplete
|
|
|
27
27
|
SERVICE_SCHEMA_SET_MESSAGE_REACTION: Incomplete
|
|
28
28
|
SERVICE_MAP: Incomplete
|
|
29
29
|
MODULES: dict[str, ModuleType]
|
|
30
|
+
PLATFORMS: list[Platform]
|
|
30
31
|
|
|
31
32
|
async def async_setup(hass: HomeAssistant, config: ConfigType) -> bool: ...
|
|
32
33
|
async def async_setup_entry(hass: HomeAssistant, entry: TelegramBotConfigEntry) -> bool: ...
|
|
@@ -18,10 +18,13 @@ from typing import Any
|
|
|
18
18
|
_LOGGER: Incomplete
|
|
19
19
|
type TelegramBotConfigEntry = ConfigEntry[TelegramNotificationService]
|
|
20
20
|
|
|
21
|
+
def _get_bot_info(bot: Bot, config_entry: ConfigEntry) -> dict[str, Any]: ...
|
|
22
|
+
|
|
21
23
|
class BaseTelegramBot(metaclass=abc.ABCMeta):
|
|
22
24
|
hass: Incomplete
|
|
23
25
|
config: Incomplete
|
|
24
|
-
|
|
26
|
+
_bot: Incomplete
|
|
27
|
+
def __init__(self, hass: HomeAssistant, config: TelegramBotConfigEntry, bot: Bot) -> None: ...
|
|
25
28
|
@abstractmethod
|
|
26
29
|
async def shutdown(self) -> None: ...
|
|
27
30
|
async def handle_update(self, update: Update, context: CallbackContext) -> bool: ...
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
from . import TelegramBotConfigEntry as TelegramBotConfigEntry
|
|
2
|
+
from .const import ATTR_TITLE as ATTR_TITLE, CONF_CHAT_ID as CONF_CHAT_ID, DOMAIN as DOMAIN
|
|
3
|
+
from _typeshed import Incomplete
|
|
4
|
+
from homeassistant.components.notify import NotifyEntity as NotifyEntity, NotifyEntityFeature as NotifyEntityFeature
|
|
5
|
+
from homeassistant.config_entries import ConfigSubentry as ConfigSubentry
|
|
6
|
+
from homeassistant.const import CONF_PLATFORM as CONF_PLATFORM
|
|
7
|
+
from homeassistant.core import HomeAssistant as HomeAssistant
|
|
8
|
+
from homeassistant.helpers.device_registry import DeviceEntryType as DeviceEntryType, DeviceInfo as DeviceInfo
|
|
9
|
+
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback as AddConfigEntryEntitiesCallback
|
|
10
|
+
|
|
11
|
+
async def async_setup_entry(hass: HomeAssistant, config_entry: TelegramBotConfigEntry, async_add_entities: AddConfigEntryEntitiesCallback) -> None: ...
|
|
12
|
+
|
|
13
|
+
class TelegramBotNotifyEntity(NotifyEntity):
|
|
14
|
+
_attr_supported_features: Incomplete
|
|
15
|
+
_attr_unique_id: Incomplete
|
|
16
|
+
name: Incomplete
|
|
17
|
+
_attr_device_info: Incomplete
|
|
18
|
+
_target: Incomplete
|
|
19
|
+
_service: Incomplete
|
|
20
|
+
def __init__(self, config_entry: TelegramBotConfigEntry, subentry: ConfigSubentry) -> None: ...
|
|
21
|
+
async def async_send_message(self, message: str, title: str | None = None) -> None: ...
|
|
@@ -35,8 +35,11 @@ async def async_firewall_policy_control_fn(hub: UnifiHub, obj_id: str, target: b
|
|
|
35
35
|
def async_firewall_policy_supported_fn(hub: UnifiHub, obj_id: str) -> bool: ...
|
|
36
36
|
@callback
|
|
37
37
|
def async_outlet_switching_supported_fn(hub: UnifiHub, obj_id: str) -> bool: ...
|
|
38
|
+
@callback
|
|
39
|
+
def async_port_control_supported_fn(hub: UnifiHub, obj_id: str) -> bool: ...
|
|
38
40
|
async def async_outlet_control_fn(hub: UnifiHub, obj_id: str, target: bool) -> None: ...
|
|
39
41
|
async def async_poe_port_control_fn(hub: UnifiHub, obj_id: str, target: bool) -> None: ...
|
|
42
|
+
async def async_port_control_fn(hub: UnifiHub, obj_id: str, target: bool) -> None: ...
|
|
40
43
|
async def async_port_forward_control_fn(hub: UnifiHub, obj_id: str, target: bool) -> None: ...
|
|
41
44
|
async def async_traffic_rule_control_fn(hub: UnifiHub, obj_id: str, target: bool) -> None: ...
|
|
42
45
|
async def async_traffic_route_control_fn(hub: UnifiHub, obj_id: str, target: bool) -> None: ...
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
from .api import VolvoAuth as VolvoAuth
|
|
2
2
|
from .const import CONF_VIN as CONF_VIN, DOMAIN as DOMAIN, PLATFORMS as PLATFORMS
|
|
3
|
-
from .coordinator import VolvoConfigEntry as VolvoConfigEntry, VolvoMediumIntervalCoordinator as VolvoMediumIntervalCoordinator, VolvoSlowIntervalCoordinator as VolvoSlowIntervalCoordinator, VolvoVerySlowIntervalCoordinator as VolvoVerySlowIntervalCoordinator
|
|
3
|
+
from .coordinator import VolvoConfigEntry as VolvoConfigEntry, VolvoFastIntervalCoordinator as VolvoFastIntervalCoordinator, VolvoMediumIntervalCoordinator as VolvoMediumIntervalCoordinator, VolvoSlowIntervalCoordinator as VolvoSlowIntervalCoordinator, VolvoVerySlowIntervalCoordinator as VolvoVerySlowIntervalCoordinator
|
|
4
4
|
from homeassistant.const import CONF_API_KEY as CONF_API_KEY
|
|
5
5
|
from homeassistant.core import HomeAssistant as HomeAssistant
|
|
6
6
|
from homeassistant.exceptions import ConfigEntryAuthFailed as ConfigEntryAuthFailed, ConfigEntryError as ConfigEntryError, ConfigEntryNotReady as ConfigEntryNotReady
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
from .const import API_NONE_VALUE as API_NONE_VALUE
|
|
2
|
+
from .coordinator import VolvoBaseCoordinator as VolvoBaseCoordinator, VolvoConfigEntry as VolvoConfigEntry
|
|
3
|
+
from .entity import VolvoEntity as VolvoEntity, VolvoEntityDescription as VolvoEntityDescription
|
|
4
|
+
from _typeshed import Incomplete
|
|
5
|
+
from dataclasses import dataclass, field
|
|
6
|
+
from homeassistant.components.binary_sensor import BinarySensorDeviceClass as BinarySensorDeviceClass, BinarySensorEntity as BinarySensorEntity, BinarySensorEntityDescription as BinarySensorEntityDescription
|
|
7
|
+
from homeassistant.const import EntityCategory as EntityCategory
|
|
8
|
+
from homeassistant.core import HomeAssistant as HomeAssistant
|
|
9
|
+
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback as AddConfigEntryEntitiesCallback
|
|
10
|
+
from volvocarsapi.models import VolvoCarsApiBaseModel as VolvoCarsApiBaseModel
|
|
11
|
+
|
|
12
|
+
PARALLEL_UPDATES: int
|
|
13
|
+
|
|
14
|
+
@dataclass(frozen=True, kw_only=True)
|
|
15
|
+
class VolvoBinarySensorDescription(BinarySensorEntityDescription, VolvoEntityDescription):
|
|
16
|
+
on_values: tuple[str, ...]
|
|
17
|
+
|
|
18
|
+
@dataclass(frozen=True, kw_only=True)
|
|
19
|
+
class VolvoCarsDoorDescription(VolvoBinarySensorDescription):
|
|
20
|
+
device_class: BinarySensorDeviceClass = ...
|
|
21
|
+
on_values: tuple[str, ...] = field(default=('OPEN', 'AJAR'), init=False)
|
|
22
|
+
|
|
23
|
+
@dataclass(frozen=True, kw_only=True)
|
|
24
|
+
class VolvoCarsTireDescription(VolvoBinarySensorDescription):
|
|
25
|
+
device_class: BinarySensorDeviceClass = ...
|
|
26
|
+
on_values: tuple[str, ...] = field(default=('VERY_LOW_PRESSURE', 'LOW_PRESSURE', 'HIGH_PRESSURE'), init=False)
|
|
27
|
+
|
|
28
|
+
@dataclass(frozen=True, kw_only=True)
|
|
29
|
+
class VolvoCarsWindowDescription(VolvoBinarySensorDescription):
|
|
30
|
+
device_class: BinarySensorDeviceClass = ...
|
|
31
|
+
on_values: tuple[str, ...] = field(default=('OPEN', 'AJAR'), init=False)
|
|
32
|
+
|
|
33
|
+
_DESCRIPTIONS: tuple[VolvoBinarySensorDescription, ...]
|
|
34
|
+
|
|
35
|
+
async def async_setup_entry(hass: HomeAssistant, entry: VolvoConfigEntry, async_add_entities: AddConfigEntryEntitiesCallback) -> None: ...
|
|
36
|
+
|
|
37
|
+
class VolvoBinarySensor(VolvoEntity, BinarySensorEntity):
|
|
38
|
+
entity_description: VolvoBinarySensorDescription
|
|
39
|
+
_attr_extra_state_attributes: Incomplete
|
|
40
|
+
def __init__(self, coordinator: VolvoBaseCoordinator, description: VolvoBinarySensorDescription) -> None: ...
|
|
41
|
+
_attr_is_on: Incomplete
|
|
42
|
+
def _update_state(self, api_field: VolvoCarsApiBaseModel | None) -> None: ...
|
|
@@ -10,11 +10,12 @@ from homeassistant.exceptions import ConfigEntryAuthFailed as ConfigEntryAuthFai
|
|
|
10
10
|
from homeassistant.helpers.update_coordinator import DataUpdateCoordinator as DataUpdateCoordinator, UpdateFailed as UpdateFailed
|
|
11
11
|
from typing import Any
|
|
12
12
|
from volvocarsapi.api import VolvoCarsApi as VolvoCarsApi
|
|
13
|
-
from volvocarsapi.models import VolvoCarsApiBaseModel, VolvoCarsVehicle as VolvoCarsVehicle
|
|
13
|
+
from volvocarsapi.models import VolvoCarsApiBaseModel, VolvoCarsValueStatusField, VolvoCarsVehicle as VolvoCarsVehicle
|
|
14
14
|
|
|
15
15
|
VERY_SLOW_INTERVAL: int
|
|
16
16
|
SLOW_INTERVAL: int
|
|
17
17
|
MEDIUM_INTERVAL: int
|
|
18
|
+
FAST_INTERVAL: int
|
|
18
19
|
_LOGGER: Incomplete
|
|
19
20
|
type VolvoConfigEntry = ConfigEntry[tuple[VolvoBaseCoordinator, ...]]
|
|
20
21
|
type CoordinatorData = dict[str, VolvoCarsApiBaseModel | None]
|
|
@@ -44,5 +45,11 @@ class VolvoSlowIntervalCoordinator(VolvoBaseCoordinator):
|
|
|
44
45
|
async def _async_determine_api_calls(self) -> list[Callable[[], Coroutine[Any, Any, Any]]]: ...
|
|
45
46
|
|
|
46
47
|
class VolvoMediumIntervalCoordinator(VolvoBaseCoordinator):
|
|
48
|
+
_supported_capabilities: list[str]
|
|
49
|
+
def __init__(self, hass: HomeAssistant, entry: VolvoConfigEntry, api: VolvoCarsApi, vehicle: VolvoCarsVehicle) -> None: ...
|
|
50
|
+
async def _async_determine_api_calls(self) -> list[Callable[[], Coroutine[Any, Any, Any]]]: ...
|
|
51
|
+
async def _async_get_energy_state(self) -> dict[str, VolvoCarsValueStatusField | None]: ...
|
|
52
|
+
|
|
53
|
+
class VolvoFastIntervalCoordinator(VolvoBaseCoordinator):
|
|
47
54
|
def __init__(self, hass: HomeAssistant, entry: VolvoConfigEntry, api: VolvoCarsApi, vehicle: VolvoCarsVehicle) -> None: ...
|
|
48
55
|
async def _async_determine_api_calls(self) -> list[Callable[[], Coroutine[Any, Any, Any]]]: ...
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
from .const import DATA_BATTERY_CAPACITY as DATA_BATTERY_CAPACITY
|
|
2
|
-
from .coordinator import
|
|
1
|
+
from .const import API_NONE_VALUE as API_NONE_VALUE, DATA_BATTERY_CAPACITY as DATA_BATTERY_CAPACITY
|
|
2
|
+
from .coordinator import VolvoConfigEntry as VolvoConfigEntry
|
|
3
3
|
from .entity import VolvoEntity as VolvoEntity, VolvoEntityDescription as VolvoEntityDescription, value_to_translation_key as value_to_translation_key
|
|
4
4
|
from _typeshed import Incomplete
|
|
5
5
|
from collections.abc import Callable as Callable
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
from .const import
|
|
1
|
+
from .const import DATA_HASS_CONFIG as DATA_HASS_CONFIG, DOMAIN as DOMAIN, PLATFORMS as PLATFORMS, WEBOSTV_EXCEPTIONS as WEBOSTV_EXCEPTIONS
|
|
2
2
|
from .helpers import WebOsTvConfigEntry as WebOsTvConfigEntry, update_client_key as update_client_key
|
|
3
3
|
from _typeshed import Incomplete
|
|
4
|
-
from homeassistant.const import CONF_CLIENT_SECRET as CONF_CLIENT_SECRET, CONF_HOST as CONF_HOST, CONF_NAME as CONF_NAME, EVENT_HOMEASSISTANT_STOP as EVENT_HOMEASSISTANT_STOP, Platform as Platform
|
|
4
|
+
from homeassistant.const import ATTR_CONFIG_ENTRY_ID as ATTR_CONFIG_ENTRY_ID, CONF_CLIENT_SECRET as CONF_CLIENT_SECRET, CONF_HOST as CONF_HOST, CONF_NAME as CONF_NAME, EVENT_HOMEASSISTANT_STOP as EVENT_HOMEASSISTANT_STOP, Platform as Platform
|
|
5
5
|
from homeassistant.core import Event as Event, HomeAssistant as HomeAssistant
|
|
6
6
|
from homeassistant.exceptions import ConfigEntryAuthFailed as ConfigEntryAuthFailed
|
|
7
7
|
from homeassistant.helpers import discovery as discovery
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
from . import WebOsTvConfigEntry as WebOsTvConfigEntry
|
|
2
|
-
from .const import
|
|
2
|
+
from .const import DOMAIN as DOMAIN, WEBOSTV_EXCEPTIONS as WEBOSTV_EXCEPTIONS
|
|
3
3
|
from _typeshed import Incomplete
|
|
4
4
|
from aiowebostv import WebOsClient as WebOsClient
|
|
5
5
|
from homeassistant.components.notify import ATTR_DATA as ATTR_DATA, BaseNotificationService as BaseNotificationService
|
|
6
|
-
from homeassistant.const import ATTR_ICON as ATTR_ICON
|
|
6
|
+
from homeassistant.const import ATTR_CONFIG_ENTRY_ID as ATTR_CONFIG_ENTRY_ID, ATTR_ICON as ATTR_ICON
|
|
7
7
|
from homeassistant.core import HomeAssistant as HomeAssistant
|
|
8
8
|
from homeassistant.exceptions import HomeAssistantError as HomeAssistantError
|
|
9
9
|
from homeassistant.helpers.typing import ConfigType as ConfigType, DiscoveryInfoType as DiscoveryInfoType
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
from . import CONF_CLOUDHOOK_URL as CONF_CLOUDHOOK_URL, WithingsConfigEntry as WithingsConfigEntry
|
|
2
|
+
from _typeshed import Incomplete
|
|
3
|
+
from homeassistant.components.diagnostics import async_redact_data as async_redact_data
|
|
2
4
|
from homeassistant.const import CONF_WEBHOOK_ID as CONF_WEBHOOK_ID
|
|
3
5
|
from homeassistant.core import HomeAssistant as HomeAssistant
|
|
4
6
|
from typing import Any
|
|
5
7
|
|
|
8
|
+
TO_REDACT: Incomplete
|
|
9
|
+
|
|
6
10
|
async def async_get_config_entry_diagnostics(hass: HomeAssistant, entry: WithingsConfigEntry) -> dict[str, Any]: ...
|
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
from .const import CONF_PROVINCE as CONF_PROVINCE,
|
|
2
|
-
from
|
|
1
|
+
from .const import CONF_ADD_HOLIDAYS as CONF_ADD_HOLIDAYS, CONF_CATEGORY as CONF_CATEGORY, CONF_OFFSET as CONF_OFFSET, CONF_PROVINCE as CONF_PROVINCE, CONF_REMOVE_HOLIDAYS as CONF_REMOVE_HOLIDAYS, LOGGER as LOGGER, PLATFORMS as PLATFORMS
|
|
2
|
+
from .util import add_remove_custom_holidays as add_remove_custom_holidays, async_validate_country_and_province as async_validate_country_and_province, get_holidays_object as get_holidays_object, validate_dates as validate_dates
|
|
3
|
+
from holidays import HolidayBase
|
|
3
4
|
from homeassistant.config_entries import ConfigEntry as ConfigEntry
|
|
4
5
|
from homeassistant.const import CONF_COUNTRY as CONF_COUNTRY, CONF_LANGUAGE as CONF_LANGUAGE
|
|
5
6
|
from homeassistant.core import HomeAssistant as HomeAssistant
|
|
6
|
-
from homeassistant.exceptions import ConfigEntryError as ConfigEntryError
|
|
7
|
-
from homeassistant.helpers.issue_registry import IssueSeverity as IssueSeverity, async_create_issue as async_create_issue
|
|
8
|
-
from homeassistant.setup import SetupPhases as SetupPhases, async_pause_setup as async_pause_setup
|
|
9
7
|
|
|
10
|
-
|
|
11
|
-
async def async_setup_entry(hass: HomeAssistant, entry:
|
|
12
|
-
async def async_unload_entry(hass: HomeAssistant, entry:
|
|
8
|
+
type WorkdayConfigEntry = ConfigEntry[HolidayBase]
|
|
9
|
+
async def async_setup_entry(hass: HomeAssistant, entry: WorkdayConfigEntry) -> bool: ...
|
|
10
|
+
async def async_unload_entry(hass: HomeAssistant, entry: WorkdayConfigEntry) -> bool: ...
|
|
@@ -1,47 +1,23 @@
|
|
|
1
|
-
from .
|
|
1
|
+
from . import WorkdayConfigEntry as WorkdayConfigEntry
|
|
2
|
+
from .const import CONF_EXCLUDES as CONF_EXCLUDES, CONF_OFFSET as CONF_OFFSET, CONF_WORKDAYS as CONF_WORKDAYS
|
|
3
|
+
from .entity import BaseWorkdayEntity as BaseWorkdayEntity
|
|
2
4
|
from _typeshed import Incomplete
|
|
3
|
-
from datetime import
|
|
4
|
-
from holidays import HolidayBase
|
|
5
|
+
from datetime import datetime
|
|
6
|
+
from holidays import HolidayBase as HolidayBase
|
|
5
7
|
from homeassistant.components.binary_sensor import BinarySensorEntity as BinarySensorEntity
|
|
6
|
-
from homeassistant.
|
|
7
|
-
from homeassistant.
|
|
8
|
-
from homeassistant.core import CALLBACK_TYPE as CALLBACK_TYPE, HomeAssistant as HomeAssistant, ServiceResponse as ServiceResponse, SupportsResponse as SupportsResponse, callback as callback
|
|
9
|
-
from homeassistant.helpers.device_registry import DeviceEntryType as DeviceEntryType, DeviceInfo as DeviceInfo
|
|
8
|
+
from homeassistant.const import CONF_NAME as CONF_NAME
|
|
9
|
+
from homeassistant.core import HomeAssistant as HomeAssistant, SupportsResponse as SupportsResponse
|
|
10
10
|
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback as AddConfigEntryEntitiesCallback, async_get_current_platform as async_get_current_platform
|
|
11
|
-
from homeassistant.helpers.event import async_track_point_in_utc_time as async_track_point_in_utc_time
|
|
12
|
-
from homeassistant.helpers.issue_registry import IssueSeverity as IssueSeverity, async_create_issue as async_create_issue
|
|
13
|
-
from homeassistant.util import slugify as slugify
|
|
14
11
|
from typing import Final
|
|
15
12
|
|
|
16
13
|
SERVICE_CHECK_DATE: Final[str]
|
|
17
14
|
CHECK_DATE: Final[str]
|
|
18
15
|
|
|
19
|
-
def
|
|
20
|
-
def _get_obj_holidays(country: str | None, province: str | None, year: int, language: str | None, categories: list[str] | None) -> HolidayBase: ...
|
|
21
|
-
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry, async_add_entities: AddConfigEntryEntitiesCallback) -> None: ...
|
|
16
|
+
async def async_setup_entry(hass: HomeAssistant, entry: WorkdayConfigEntry, async_add_entities: AddConfigEntryEntitiesCallback) -> None: ...
|
|
22
17
|
|
|
23
|
-
class IsWorkdaySensor(BinarySensorEntity):
|
|
24
|
-
_attr_has_entity_name: bool
|
|
18
|
+
class IsWorkdaySensor(BaseWorkdayEntity, BinarySensorEntity):
|
|
25
19
|
_attr_name: Incomplete
|
|
26
|
-
_attr_translation_key = DOMAIN
|
|
27
|
-
_attr_should_poll: bool
|
|
28
|
-
unsub: CALLBACK_TYPE | None
|
|
29
|
-
_obj_holidays: Incomplete
|
|
30
|
-
_workdays: Incomplete
|
|
31
|
-
_excludes: Incomplete
|
|
32
|
-
_days_offset: Incomplete
|
|
33
20
|
_attr_extra_state_attributes: Incomplete
|
|
34
|
-
_attr_unique_id: Incomplete
|
|
35
|
-
_attr_device_info: Incomplete
|
|
36
21
|
def __init__(self, obj_holidays: HolidayBase, workdays: list[str], excludes: list[str], days_offset: int, name: str, entry_id: str) -> None: ...
|
|
37
|
-
def is_include(self, day: str, now: date) -> bool: ...
|
|
38
|
-
def is_exclude(self, day: str, now: date) -> bool: ...
|
|
39
|
-
def get_next_interval(self, now: datetime) -> datetime: ...
|
|
40
|
-
def _update_state_and_setup_listener(self) -> None: ...
|
|
41
|
-
@callback
|
|
42
|
-
def point_in_time_listener(self, time_date: datetime) -> None: ...
|
|
43
|
-
async def async_added_to_hass(self) -> None: ...
|
|
44
22
|
_attr_is_on: Incomplete
|
|
45
23
|
def update_data(self, now: datetime) -> None: ...
|
|
46
|
-
def check_date(self, check_date: date) -> ServiceResponse: ...
|
|
47
|
-
def date_is_workday(self, check_date: date) -> bool: ...
|