I've been trying out the Http API in FlexSim 2021 with no success. At first I thought the issue was the API I was trying to hit, but I was able to hit it successfully in Powershell. I also tried hitting google with no success.
Http.Request request; request.host = "https://www.google.com"; request.method = Http.Method.Get; Http.Response response = request.sendAndWait(); print(response.value); print(response.statusCode);
The response I get in the output console is
0
Which I assume is empty string followed by a 0 status code, which isn't a valid Http response status.
Has anybody encountered this before?