public async Task <IActionResult> Create([FromBody] DataApiModel data) { if (data == null) { return(new BadRequestObjectResult("Data is empty")); } var response = await _personGroupService.Create(data.Data); if (response.IsSuccessStatusCode) { return(new OkObjectResult(response.ResponseBody)); } return(new BadRequestObjectResult("Something went wrong")); }