Hi
Is there a way to get around this error?
I see from Node.js discussions about node needing to use rejectUnauthorized: false
but this may be insecure..... any thoughts on solving this. I have tried removing the https but I then get a Error: socket hang up :
I am trying to retrieve values for a British Gas hive system and this flow is supposed to login me in and return a session ID
[{"id":"17ced1d2.e8312e","type":"inject","z":"8099d500.7f6628","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"x":180,"y":1360,"wires":[["e851772a.17ae88"]]},{"id":"e851772a.17ae88","type":"function","z":"8099d500.7f6628","name":"","func":"msg.headers = {\n \"Content-type\" : \"application/vnd.alertme.zoo-6.1+json\",\n \"Accept\" : \"application/vnd.alertme.zoo-6.2+json\",\n \"Content-Type\" : \"application/*+json\",\n \"X-AlertMe-Client\" : \"Hive Web Dashboard\"\n};\n\nmsg.payload = {\n \"sessions\":[{\n \"username\":\"user\",\n \"password\":\"password\"\n }]\n};\n\nreturn msg;\n","outputs":1,"noerr":0,"x":330,"y":1360,"wires":[["cc81d52d.337e28"]]},{"id":"cc81d52d.337e28","type":"http request","z":"8099d500.7f6628","name":"","method":"POST","ret":"obj","url":"
https://api.prod.bgchprod.info:443/auth/sessions","x":490,"y":1360,"wires":[["e157231e.1ea8e"]]},{"id":"e157231e.1ea8e","type":"debug","z":"8099d500.7f6628","name":"","active":true,"console":"false","complete":"true","x":650,"y":1360,"wires":[]}]
Tony