public IActionResult CreateUser([FromBody] UserModel user) { if (user == null || !user.Name.NotEmpty()) { return(BadRequest()); } try { _signService.CreateUser(user.Name, user.LastName, user.Email); return(CreatedAtRoute("GetUser", new { name = user.Name }, user)); } catch (Exception ex) { return(StatusCode(StatusCodes.Status500InternalServerError, ex.Message)); } }