uiprotect 7.18.1__py3-none-any.whl → 7.19.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 uiprotect might be problematic. Click here for more details.

uiprotect/api.py CHANGED
@@ -2120,6 +2120,17 @@ class ProtectApiClient(BaseApiClient):
2120
2120
 
2121
2121
  return response["data"]["full_api_key"]
2122
2122
 
2123
+ def set_api_key(self, api_key: str) -> None:
2124
+ """Set the API key for the NVR."""
2125
+ if not api_key:
2126
+ raise BadRequest("API key cannot be empty")
2127
+
2128
+ self._api_key = api_key
2129
+
2130
+ def is_api_key_set(self) -> bool:
2131
+ """Check if the API key is set."""
2132
+ return bool(self._api_key)
2133
+
2123
2134
  async def get_meta_info(self) -> MetaInfo:
2124
2135
  """Get metadata about the NVR."""
2125
2136
  data = await self.api_request(
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: uiprotect
3
- Version: 7.18.1
3
+ Version: 7.19.0
4
4
  Summary: Python API for Unifi Protect (Unofficial)
5
5
  License: MIT
6
6
  Author: UI Protect Maintainers
@@ -1,7 +1,7 @@
1
1
  uiprotect/__init__.py,sha256=Oz6i1tonIz4QWVnEPkbielJDJ3WQdwZVgYtjY4IwGAQ,636
2
2
  uiprotect/__main__.py,sha256=C_bHCOkv5qj6WMy-6ELoY3Y6HDhLxOa1a30CzmbZhsg,462
3
3
  uiprotect/_compat.py,sha256=HThmb1zQZCEssCxYYbQzFhJq8zYYlVaSnIEZabKc-6U,302
4
- uiprotect/api.py,sha256=75F_jRPSmn8liQ8NqDTiKzoCyBX6Jj3E7fy7F3BuKow,73858
4
+ uiprotect/api.py,sha256=JI1jPXYPv3UP1DkxzdJiytAq7S5xQ93MwokoK3h0D5c,74181
5
5
  uiprotect/cli/__init__.py,sha256=J5KE7Wt_rIr55EdGxfTOCoGfBzO5gzO5WvaruXp5AZI,9688
6
6
  uiprotect/cli/aiports.py,sha256=22sC-OVkUFfBGJR2oID8QzWsk4GQfLEmam06-LBP2Z0,1545
7
7
  uiprotect/cli/backup.py,sha256=lC44FujSYgVBUs32CbsY8pBejO4qScy6U94UzO-l2fc,36742
@@ -32,8 +32,8 @@ uiprotect/test_util/__init__.py,sha256=O22HGFX5Mb0j9LPzO48tm4ZqZTqGVBHo0jnye2FdT
32
32
  uiprotect/test_util/anonymize.py,sha256=f-8ijU-_y9r-uAbhIPn0f0I6hzJpAkvJzc8UpWihObI,8478
33
33
  uiprotect/utils.py,sha256=4EIblOcOxlApiXkI2rwram4SkgiMu_JTDRIZOul83Bc,20749
34
34
  uiprotect/websocket.py,sha256=ww-PberFztJppRQMKwdu5A9gyofepV-Y6am4Hj_DV44,8178
35
- uiprotect-7.18.1.dist-info/LICENSE,sha256=INx18jhdbVXMEiiBANeKEbrbz57ckgzxk5uutmmcxGk,1111
36
- uiprotect-7.18.1.dist-info/METADATA,sha256=Z--39OPK7v3OgtgpVxaZ_MP5gwSfLAVBOzfIW3adReY,11167
37
- uiprotect-7.18.1.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
38
- uiprotect-7.18.1.dist-info/entry_points.txt,sha256=J78AUTPrTTxgI3s7SVgrmGqDP7piX2wuuEORzhDdVRA,47
39
- uiprotect-7.18.1.dist-info/RECORD,,
35
+ uiprotect-7.19.0.dist-info/LICENSE,sha256=INx18jhdbVXMEiiBANeKEbrbz57ckgzxk5uutmmcxGk,1111
36
+ uiprotect-7.19.0.dist-info/METADATA,sha256=U0NDF6bdieT_aTNRjacByZrE1NtB1VYT7RA1aFjoZl4,11167
37
+ uiprotect-7.19.0.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
38
+ uiprotect-7.19.0.dist-info/entry_points.txt,sha256=J78AUTPrTTxgI3s7SVgrmGqDP7piX2wuuEORzhDdVRA,47
39
+ uiprotect-7.19.0.dist-info/RECORD,,