Error while trying to POST JSON data to the service Now API

#1

Hello ,
Am new to Node-red.
Tried to create an incident in service now by posting JSON data to the rest api.

Error: getaddrinfo ENOTFOUND xxxxx.service-now.com xxxxx.service-now.com:443 : https://xxxxx.service-now.com/api/now/v1/table/incident.

But I was able to hit get the response from POSTMAN.

Can anyone please advice.
PFB the Json flow file.

[{"id":"271a81c6.780f8e","type":"tab","label":"Flow 14","disabled":false,"info":""},{"id":"2d3df2c.a30d00e","type":"inject","z":"271a81c6.780f8e","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":100,"y":60,"wires":[["829dca1c.1e10d8"]]},{"id":"829dca1c.1e10d8","type":"conf ping","z":"271a81c6.780f8e","name":"","host":"localhost","timeout":"5","requests":"1","x":300,"y":100,"wires":[["41d21b2d.fdfb64"]]},{"id":"41d21b2d.fdfb64","type":"change","z":"271a81c6.780f8e","name":"","rules":[{"t":"set","p":"headers","pt":"msg","to":"{\"Content-Type\":\"application/json\"}","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"{\"short_description\":\"Test incident1 creation through REST\",\"comments\":\"Test_Comments\",\"problem_id\":\"Inc002\"}","tot":"str"},{"t":"set","p":"method","pt":"msg","to":"POST","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":340,"y":180,"wires":[["ac4d677e.2175a8"]]},{"id":"ac4d677e.2175a8","type":"http request","z":"271a81c6.780f8e","name":"Service_Now_Ticket_creation","method":"use","ret":"obj","url":"https://xxxxx.service-now.com/api/now/v1/table/incident","tls":"","x":610,"y":120,"wires":[["c8040a93.2a5278"]]},{"id":"c8040a93.2a5278","type":"debug","z":"271a81c6.780f8e","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":690,"y":260,"wires":[]}]
#2

I notice you have specified https, but have not clicked the secure connection box. I don't know whether that is an issue, it doesn't seem to be documented in the info panel.