Skip to content
This repository was archived by the owner on Jun 5, 2026. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions pymyq/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
API_BASE = "https://api.myqdevice.com/api/v{0}"

DEFAULT_APP_ID = "JVM/G9Nwih5BwKgNCjLxiFUQxQijAebyyg8QUHr7JOrP+tuPb8iHfRHKwTmDzHOu"
DEFAULT_USER_AGENT = "okhttp/3.10.0"
DEFAULT_USER_AGENT = 'pymyq'
DEFAULT_BRAND_ID = 2
DEFAULT_REQUEST_RETRIES = 5
DEFAULT_CULTURE = "en"
Expand Down Expand Up @@ -92,6 +92,7 @@ async def _send_request(
return data
except ClientError as err:
_LOGGER.debug(f"Attempt {attempt} request failed with exception: {str(err)}")
message = f"Error requesting data from {url}: {data.get('description', str(err))}"
if hasattr(err, "status") and err.status == 401:
if login_request:
self._credentials = {}
Expand All @@ -111,7 +112,6 @@ async def _send_request(
attempt = 0
continue

message = f"Error requesting data from {url}: {data.get('description', str(err))}"
_LOGGER.error(message)
raise RequestError(message)

Expand Down