diff --git a/custom_components/pesc/pesc_client.py b/custom_components/pesc/pesc_client.py index a411d8f..352767e 100644 --- a/custom_components/pesc/pesc_client.py +++ b/custom_components/pesc/pesc_client.py @@ -226,7 +226,7 @@ async def async_login(self, username: str, password: str) -> str: headers["Captcha"] = "none" payload = {"type": "PHONE", "login": username, "password": password} result = await self._session.post( - f"{self._API_URL}/v6/users/auth", headers=headers, json=payload + f"{self._API_URL}/v7/users/auth", headers=headers, json=payload ) json = await self._async_response_json(result) self.token = json["auth"] @@ -246,7 +246,7 @@ async def async_update_value( payload, ) result = await self._session.post( - f"{self._API_URL}/v6/accounts/{account_id}/meters/{meter_id}/reading", + f"{self._API_URL}/v7/accounts/{account_id}/meters/{meter_id}/reading", headers=self._headers, json=payload, )