public IActionResult Post([FromBody] Donor value) { try { return(new OkObjectResult(new Result { Success = _donorService.Create(Mapper.Map <Donor, DomainModels.Donor>(value)) != 0, Message = "Donor created" })); } catch (Exception ex) { return(StatusCode(500, new Result { Success = false, Message = "Donor Creation Failed", Content = ex.InnerException.Message })); } }