public async Task <DomainValidationResult <Credential> > LinkCredentialAsync(UserId userId, Game game)
        {
            var result = new DomainValidationResult <Credential>();

            if (await _gameCredentialRepository.CredentialExistsAsync(userId, game))
            {
                return(result.AddFailedPreconditionError($"{game} credential are already linked."));
            }

            if (!await _gameAuthenticationService.AuthenticationExistsAsync(userId, game))
            {
                return(result.AddFailedPreconditionError($"{game} authentication process not started."));
            }

            var authFactor = await _gameAuthenticationService.FindAuthenticationAsync(userId, game);

            var authResult = await _gameAuthenticationService.ValidateAuthenticationAsync(userId, game, authFactor);

            if (!authResult.IsValid)
            {
                foreach (var error in authResult.Errors)
                {
                    result.AddFailedPreconditionError(error.ErrorMessage);
                }
            }

            if (result.IsValid)
            {
                var credential = new Credential(
                    userId,
                    game,
                    authFactor.PlayerId,
                    new UtcNowDateTimeProvider());

                _gameCredentialRepository.CreateCredential(credential);

                await _gameCredentialRepository.UnitOfWork.CommitAsync();

                return(credential);
            }

            return(result);
        }