public async Task <IActionResult> Get() { var userName = User?.Identity?.Name; if (userName == null) { return(Unauthorized()); } var appId = Guid.NewGuid(); var challengeKey = _obfuscatedEndpoints.StoreEndpoint($"/challenge/{appId}"); var challengeData = new ChallengeRequest { Data = "random data" }; var challenge = new FixedDataSenderChallenge(challengeData, $"/{challengeKey}"); BuildApp(challenge); _apps.PrepareAppToBeServed(appId, userName, "/front/dist"); _challengeRepository.SaveChallenge(challenge, userName, appId); var indexHtml = await _apps.GetHtmlAsync(appId); return(Content(ObfuscateEndpoints(indexHtml), "text/html")); }