public IHttpActionResult PostGuestUserDetail(GuestUserDetail guestUserDetail) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } db.proc_InsertGuestUserDetail(guestUserDetail.FirstName, guestUserDetail.Lastname, guestUserDetail.EmailId, guestUserDetail.PhoneNumber); //db.tblUsers.Add(tblUser); db.SaveChanges(); return(CreatedAtRoute("DefaultApi", new { id = guestUserDetail.GID }, guestUserDetail)); }