I am trying to make an API Call on my C# Web API from my Angular Frontend. I have tried it by HTTP and HTTPS.
HTTP: I am getting a CORS exception HTTPS: I am getting a CONNECTION CLOSED EXCEPTION
I also have tried it via Postman and it worked so the Backend should not be the Problem.
I am using the Angular HTTP Client.
Cors is security of browser, without cors configuration in api work it on postman, postman is not a web browser.
Try adding Cors configuration, on your api
Install package
Install-Package Microsoft.AspNet.WebApi.CorsEdit WebApiConfig file, in App_Start/WebApiConfig.cs
Edit Startup.cs and add CORS middleware and service
References
AspNet WebApi .Net Core