// POST: api/CustomerCategory public IHttpActionResult Post([FromBody] CustomerCategory category) { var returnCategory = service.CreateCustomerCategory(category); if (returnCategory == null) { return(BadRequest("Category Already Exists.")); } return(Ok(returnCategory)); }