Can't make HTTP GET requests when on Arduino IoT Cloud

I have a sketch for a Nano 33 IoT that's running perfectly fine when it is uploaded from the IDE. However, when trying to shift to the Arduino Cloud, it is not working.

My normal code (works from IDE-loaded sketch:

WiFiSSLClient client;
String servername = "testserver.com");
String dataset = "GET /insert.php?gX=9";
 if (client.connectSSL(servername, 443)) 
   {
      client.println(dataset);
      client.println("Host: testserver.com");
      client.println("User-Agent: Arduino");
      client.println("Accept: */*");
      client.println("Content-Type: application/x-www-form-urlencoded");
      client.println("Connection: close");
      client.println();
   }

I also tried to use <ArduinoHttpClient.h>, but with similar results - no connection on the Cloud.

I have tried what I could find in the forum, but to no avail. Any ideas?

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.