I've been searching google for a module or way to get the public IP in nodejs and I can't find it. I found a module called ip that the router sends you the private address, in my case 192.168.56.1 but I want the public one to come out, which would be this: 76.108.84.167 actually I want the client's IP.
Use externalip this returns your public ip.
https://github.com/alsotang/externalip
Cheers