public async Task <IActionResult> AnalyzeAsync(string message) { var result = await _toneService.AnalyzeAsync(new ToneSubmission() { Message = message }); _logger.LogDebug($"Request Status:{result.StatusCode} Object: {JsonConvert.SerializeObject(result)}"); //Todo: Should we really be returning status codes and success messages on failure, they expose server information to the end user? return(StatusCode((int)result.StatusCode, result)); }