offline-geo-from-ip

1.0.1 • Public • Published

offline-geo-from-ip

Get geo location information from an IP address without an internet connection.

This is a modified version of geo-from-ip that includes a local database.

Installation

npm install --save offline-geo-from-ip

Usage

var geoIP = require('offline-geo-from-ip');
 
console.log(geoIP.allData('199.188.195.120'));
 
/*
{
  code: { state: 'CA', country: 'US', continent: 'NA' },
  city: 'San Francisco',
  state: 'California',
  country: 'United States',
  continent: 'North America',
  postal: '94103',
  location:
  {
    accuracy_radius: 10,
    latitude: 37.7758,
    longitude: -122.4128,
    metro_code: 807,
    time_zone: 'America/Los_Angeles'
  }
}
 */

Credits

Original version created by Vikram Tiwari

License

Licensed under MIT License

Dependencies (2)

Dev Dependencies (2)

Package Sidebar

Install

npm i offline-geo-from-ip

Weekly Downloads

126

Version

1.0.1

License

MIT

Unpacked Size

61.1 MB

Total Files

6

Last publish

Collaborators

  • john-doherty