private async Task <string> GetApiKeyFromOnboardingServiceEndpoint() { Identification identification; if (!await _secureStorageService.IsDeviceIdentificationCreated().ConfigureAwait(false)) { identification = await _registrationService.Register(new Identification { DeviceIdentification = _deviceInformationService.GenerateNewDeviceIdentification() }).ConfigureAwait(false); await _secureStorageService.SaveDeviceIdentification(identification).ConfigureAwait(false); } else { identification = await _secureStorageService.GetDeviceIdentification().ConfigureAwait(false); } return(await _apiKeyService.GetBricksetApiKey(identification).ConfigureAwait(false)); }