public ActionResult PostMateria(Materia materia) { var result = new Result <Materia>(); try { Utilidades <Materia> auxiliar = new Utilidades <Materia>(); auxiliar.AddMateria(materia); result.Error = false; result.Message = Message.Success; return(Ok(result)); } catch (Exception ex) { result.Error = true; result.Message = Message.Failure + ex.Message; result.Status = System.Net.HttpStatusCode.InternalServerError; return(NotFound(result)); } }