public IActionResult GetAllProjectsByClientId(string id) { if (id == null || id == "") { return(new BadRequestObjectResult(new { message = "Please provide a valid client id" })); } Guid clientGuid = Guid.Parse(id); return(new OkObjectResult(projectRepo.GetAllProjectsByClientId(clientGuid))); }