public async Task <IActionResult> DownloadFile(Guid applicationId, int sequenceNo, int sectionNo, string pageId, string questionId, string filename) { var response = await _applyApiClient.DownloadFile(applicationId, sequenceNo, sectionNo, pageId, questionId, filename); if (response.IsSuccessStatusCode) { var fileStream = await response.Content.ReadAsStreamAsync(); return(File(fileStream, response.Content.Headers.ContentType.MediaType, filename)); } return(NotFound()); }