Error connect ENOENT when trying to send request from beagle bone

I am using the http module to send request to an end point.
It gives me Error connect ENOENT syscall connect.
Can anybody help me figure out what it means?