NodeMCU HTTP How to use HTTPS post request

0 votes

So, I am using the NodeMCU firmware with its  HTTP module. The code is from the link. As per this documentation, both HTTP and HTTPS URLs should be working just fine. I keep getting an error when I use HTTPS.

https://nodemcu.readthedocs.io/en/master/en/modules/http/#httppost

"The plain HTTP request was sent for HTTPS port".

http.post('https://maker.ifttt.com/trigger/......',
        'Content-Type: application/json\r\n',
        '{"value1":"mainlobby"}', function(code, data)
        if (code < 0) then
            print("HTTP request failed")
        else
        print(code, data)
        end        
  end

kindly, help out. Thanks.

Feb 11, 2019 in IoT (Internet of Things) by Upasana
• 8,620 points
3,659 views

1 answer to this question.

0 votes

Your firmware might not have SSL/TLS enabled. That's my suspicion. So, it would internally use HTTP instead of HTTPS. Still, send it to port 443.

answered Feb 11, 2019 by Shubham
• 13,490 points

Related Questions In IoT (Internet of Things)

0 votes
1 answer

How to use the data I receive from Azure IoT Hub?

The payload you receive will be a ...READ MORE

answered Aug 1, 2018 in IoT (Internet of Things) by DataKing99
• 8,250 points
1,814 views
0 votes
1 answer

How to use jquery with asp.net ajax?

If you weren't aware, Microsoft is planning ...READ MORE

answered Oct 15, 2018 in IoT (Internet of Things) by Annie97
• 2,160 points
752 views
0 votes
1 answer

How to get Unicast, Dns and Gateway Address in UWP?

Try this code Snippet I found here: https://social.msdn.microsoft.com/Forums/en-US/27a8b7a8-8071-4bc1-bbd4-e7c1fc2bd8d7/windows-10-iot-core-how-do-you-create-a-tcp-server-and-client?forum=WindowsIoT ...READ MORE

answered Jul 17, 2018 in IoT (Internet of Things) by anonymous2
• 4,240 points
1,221 views
0 votes
1 answer

How to connect Raspberry Pi and lighting the LED?

You might want to try instead to ...READ MORE

answered Jul 23, 2018 in IoT (Internet of Things) by anonymous2
• 4,240 points
669 views
0 votes
1 answer

MQTT on ESP8266 with NodeMCU - problems with publishing

Perhaps this was solved by more recent ...READ MORE

answered Aug 13, 2018 in IoT (Internet of Things) by anonymous2
• 4,240 points
2,030 views
0 votes
1 answer

Faster communication between two ESP8266 in client-server setup

Try following. Server loop void loop() { // ...READ MORE

answered Jul 13, 2018 in IoT (Internet of Things) by anonymous2
• 4,240 points
6,836 views
0 votes
1 answer

MQTT pubish is slow to send with ESP8266 & NodeMCU

I think you're almost correct and on ...READ MORE

answered Aug 1, 2018 in IoT (Internet of Things) by nirvana
• 3,130 points
3,275 views
0 votes
1 answer
0 votes
1 answer

How to detect presence of a device in a WiFi network?

Finding the mac-address would probably work. Basically, ...READ MORE

answered Nov 16, 2018 in IoT (Internet of Things) by Shubham
• 13,490 points
3,359 views
0 votes
1 answer

LoNet Mini GSM Module : sim800L gprs post request

Did you set up your PDP context ...READ MORE

answered Nov 16, 2018 in IoT (Internet of Things) by Shubham
• 13,490 points
2,875 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP