HttpClient keeps conversting HTTP calls to HTTPS

I have the following code in a Blazor Page (.razor.cs) to load some data from a sample API.The API URL that is pointed to a non https endpoint since there is no https version of the same.

 protected async Task LoadData()
            string APIURL = "";

            // create request object and pass windows authentication credentials
            var request = new HttpRequestMessage(HttpMethod.Get, APIURL);

            // send the request and convert the results to a list
            var httpResponse = await client.SendAsync(request);

But the browser is calling the https version always and this leads to an error

enter image description here enter image description here

I have inspected program.cs file and have removed app.UseHttpsRedirection(),still the same issue.I'm not sure if this affects external api call as it only configures the request processing pipeline as per my understanding.

How many English words
do you know?
Test your English vocabulary size, and measure
how many words do you know
Online Test
Powered by Examplum