#external-ip
Get your external IP, with fallbacks
##Installation
npm install external-ip
##Test
Change your working directory to the project's root, npm install
to get the development dependencies and then run npm test
##Usage
basic
'use strict';
var getIP = require('../index')();
getIP(function (err, ip) {
if (err) {
throw err;
}
console.log(ip);
});
with configuration
'use strict';
var extIP = require('../index');
var getIP = extIP({
replace: true,
services: ['http://ifconfig.co/x-real-ip', 'http://ifconfig.me/ip'],
timeout: 600
});
getIP(function (err, ip) {
if (err) {
throw err;
}
console.log(ip);
});
##Why?
No idea, really. Just another lib that gives you your external ip address
##Todo:
- clean up some mess
- sequential / parallel (spam) requests ?