public IActionResult MortgageCheck([FromBody] MortgageCheckApiModel model) { var res = _mortgageService.CheckMortgage(model.Income, model.MaturityPeriod, model.LoanValue, model.HomeValue); if (res == null) { return(NotFound("Mortgage rate not found.")); } return(Ok(new MortgageCheckViewModel { IsFeasible = res.IsFeasible, MonthlyCost = res.MonthlyCost })); }