public IActionResult FindBy(int id) { try { return(new JsonResult(_service.GetById(id)) { StatusCode = 200 }); } catch (Exception ex) { return(BadRequest(ex.Message)); } }