I have no idea what\'s going on here. I have a POST route using ASP.NET web API that should change some data in my SQL Server. When I use Postman to test out my REST API it work
Postman does not send a XmlHttp Request. With postman you're manually interacting with a site so that you have full control. However in your web application you are making a Cross Origin Request.You need to enable CORS in your Api.
You can read more about CORS in Asp.Net Web API here.
In Global.asax.cs file add following code
protected void Application_BeginRequest()
{
if (Request.Headers.AllKeys.Contains("Origin") && Request.HttpMethod == "OPTIONS")
{
Response.Flush();
}
}