switchbot-api 2.7.0__tar.gz → 2.8.0__tar.gz
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.
- {switchbot_api-2.7.0 → switchbot_api-2.8.0}/PKG-INFO +4 -2
- {switchbot_api-2.7.0 → switchbot_api-2.8.0}/pyproject.toml +1 -1
- {switchbot_api-2.7.0 → switchbot_api-2.8.0}/switchbot_api/__init__.py +7 -0
- {switchbot_api-2.7.0 → switchbot_api-2.8.0}/switchbot_api/commands.py +12 -0
- {switchbot_api-2.7.0 → switchbot_api-2.8.0}/switchbot_api/models.py +23 -0
- {switchbot_api-2.7.0 → switchbot_api-2.8.0}/LICENSE +0 -0
- {switchbot_api-2.7.0 → switchbot_api-2.8.0}/README.md +0 -0
- {switchbot_api-2.7.0 → switchbot_api-2.8.0}/switchbot_api/exceptions.py +0 -0
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: switchbot_api
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.8.0
|
|
4
4
|
Summary: An asynchronous library to use Switchbot API
|
|
5
5
|
License: MIT
|
|
6
|
+
License-File: LICENSE
|
|
6
7
|
Author: Ravaka Razafimanantsoa
|
|
7
8
|
Author-email: contact@ravaka.dev
|
|
8
9
|
Requires-Python: >=3.10,<4.0
|
|
@@ -12,6 +13,7 @@ Classifier: Programming Language :: Python :: 3.10
|
|
|
12
13
|
Classifier: Programming Language :: Python :: 3.11
|
|
13
14
|
Classifier: Programming Language :: Python :: 3.12
|
|
14
15
|
Classifier: Programming Language :: Python :: 3.13
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
15
17
|
Requires-Dist: aiohttp (>=3.0.0)
|
|
16
18
|
Project-URL: Repository, https://github.com/SeraphicCorp/py-switchbot-api
|
|
17
19
|
Description-Content-Type: text/markdown
|
|
@@ -37,6 +37,7 @@ from switchbot_api.commands import (
|
|
|
37
37
|
RGBWLightCommands,
|
|
38
38
|
RGBWWLightCommands,
|
|
39
39
|
RollerShadeCommands,
|
|
40
|
+
SmartRadiatorThermostatCommands,
|
|
40
41
|
SpeakerCommands,
|
|
41
42
|
Switch2PMCommands,
|
|
42
43
|
SwitchCommands,
|
|
@@ -54,6 +55,7 @@ from switchbot_api.exceptions import (
|
|
|
54
55
|
from switchbot_api.models import (
|
|
55
56
|
BatteryCirculatorFanMode,
|
|
56
57
|
PowerState,
|
|
58
|
+
SmartRadiatorThermostatMode,
|
|
57
59
|
VacuumCleanMode,
|
|
58
60
|
VacuumFanSpeed,
|
|
59
61
|
VacuumFanSpeedV2,
|
|
@@ -71,6 +73,7 @@ __all__ = [
|
|
|
71
73
|
"CommonCommands",
|
|
72
74
|
"CurtainCommands",
|
|
73
75
|
"DVDCommands",
|
|
76
|
+
"Device",
|
|
74
77
|
"DoorBellCommands",
|
|
75
78
|
"FanCommands",
|
|
76
79
|
"HumidifierCommands",
|
|
@@ -82,9 +85,13 @@ __all__ = [
|
|
|
82
85
|
"PowerState",
|
|
83
86
|
"RGBWLightCommands",
|
|
84
87
|
"RGBWWLightCommands",
|
|
88
|
+
"Remote",
|
|
85
89
|
"RollerShadeCommands",
|
|
90
|
+
"SmartRadiatorThermostatCommands",
|
|
91
|
+
"SmartRadiatorThermostatMode",
|
|
86
92
|
"SpeakerCommands",
|
|
87
93
|
"Switch2PMCommands",
|
|
94
|
+
"SwitchBotAPI",
|
|
88
95
|
"SwitchCommands",
|
|
89
96
|
"T",
|
|
90
97
|
"TVCommands",
|
|
@@ -384,4 +384,16 @@ class LightCommands(Commands):
|
|
|
384
384
|
BRIGHTNESS_DOWN = "brightnessDown"
|
|
385
385
|
|
|
386
386
|
|
|
387
|
+
class SmartRadiatorThermostatCommands(Commands):
|
|
388
|
+
"""Smart Radiator Thermostat commands."""
|
|
389
|
+
|
|
390
|
+
SET_MODE = "setMode"
|
|
391
|
+
SET_MANUAL_MODE_TEMPERATURE = "setManualModeTemperature"
|
|
392
|
+
|
|
393
|
+
@classmethod
|
|
394
|
+
def get_supported_devices(cls) -> list[str]:
|
|
395
|
+
"""Get supported devices."""
|
|
396
|
+
return ["Smart Radiator Thermostat"]
|
|
397
|
+
|
|
398
|
+
|
|
387
399
|
T = TypeVar("T", bound=CommonCommands)
|
|
@@ -45,3 +45,26 @@ class VacuumCleanMode(StrEnum):
|
|
|
45
45
|
SWEEP = "sweep"
|
|
46
46
|
MOP = "mop"
|
|
47
47
|
SWEEP_MOP = "sweep_mop"
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
class SmartRadiatorThermostatMode(Enum):
|
|
51
|
+
"""mode for Smart Radiator Thermostat ."""
|
|
52
|
+
|
|
53
|
+
SCHEDULE = 0
|
|
54
|
+
MANUAL = 1
|
|
55
|
+
OFF = 2
|
|
56
|
+
ENERGY_SAVING = 3
|
|
57
|
+
COMFORT = 4
|
|
58
|
+
FAST_HEATING = 5
|
|
59
|
+
|
|
60
|
+
@classmethod
|
|
61
|
+
def get_all_modes(cls) -> list[SmartRadiatorThermostatMode]:
|
|
62
|
+
"""Get all modes as a list."""
|
|
63
|
+
return [
|
|
64
|
+
cls.SCHEDULE,
|
|
65
|
+
cls.MANUAL,
|
|
66
|
+
cls.OFF,
|
|
67
|
+
cls.ENERGY_SAVING,
|
|
68
|
+
cls.COMFORT,
|
|
69
|
+
cls.FAST_HEATING,
|
|
70
|
+
]
|
|
File without changes
|
|
File without changes
|
|
File without changes
|