// POST /api/customer public void Post(CustomerModel customer) { context.AddToCustomers(new Customer { Id = customer.Id, Name = customer.Name, Salary = customer.Salary }); context.SaveChanges(System.Data.Objects.SaveOptions.AcceptAllChangesAfterSave); }