Make HTTPS call without using certificate - ARDUINO
Posted: Fri Dec 13, 2019 7:42 am
Hello,
I am trying to make https get call from ESP-32 (Arduino) without using any certificate.
Below is the code I am trying:
HTTPClient http;
http.begin("https://148.72.210.150:443/line/generat ... for-device", "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00");
http.addHeader("Content-Type", "application/json");
int httpCode = http.GET();
if(httpCode == HTTP_CODE_OK)
{
String payload = http.getString();
Serial.println(httpCode);
Serial.println(payload);
}
else
{
printf("HTTPCODE is not OK\n");
Serial.println(httpCode);
}
http.end();
int httpCode = http.GET() in above code returns -1.
Please help, how to make https call without using any certicate in ESP32 on Arduino Platform.
Waiting for your response.
Thanks
Ritu
I am trying to make https get call from ESP-32 (Arduino) without using any certificate.
Below is the code I am trying:
HTTPClient http;
http.begin("https://148.72.210.150:443/line/generat ... for-device", "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00");
http.addHeader("Content-Type", "application/json");
int httpCode = http.GET();
if(httpCode == HTTP_CODE_OK)
{
String payload = http.getString();
Serial.println(httpCode);
Serial.println(payload);
}
else
{
printf("HTTPCODE is not OK\n");
Serial.println(httpCode);
}
http.end();
int httpCode = http.GET() in above code returns -1.
Please help, how to make https call without using any certicate in ESP32 on Arduino Platform.
Waiting for your response.
Thanks
Ritu