diff --git a/src/api/hive_auth_async.py b/src/api/hive_auth_async.py index a422122..0bef108 100644 --- a/src/api/hive_auth_async.py +++ b/src/api/hive_auth_async.py @@ -417,6 +417,18 @@ async def login(self): ) raise HiveApiError from err + if ( + "AuthenticationResult" in result + and "NewDeviceMetadata" in result["AuthenticationResult"] + ): + self.access_token = result["AuthenticationResult"]["AccessToken"] + self.device_group_key = result["AuthenticationResult"][ + "NewDeviceMetadata" + ]["DeviceGroupKey"] + self.device_key = result["AuthenticationResult"][ + "NewDeviceMetadata" + ]["DeviceKey"] + _LOGGER.debug("SRP auth challenge completed successfully.") return result challenge_name = response["ChallengeName"]