IHttpActionResult PostPerson(PersonVIewModel person) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } else { _ifunctionService.AddData(person); } return(CreatedAtRoute("DefaultApi", new { id = person.ID }, person)); }