Skip to content

This package will get an ip address when you access by browser or to server

Notifications You must be signed in to change notification settings

isekaimaou1109/get-client-ip-address

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

THIS PACKAGE IS NOT USED FOR COMMERCIAL PURPOSE


Usage:

  • Case 1: When using in CommonJS (Node environment)
(async function () {
	return await (await import('get-real-client-ip')).getClientInformation();
})();
  • Case 2: When using in ESM
import { getClientInformation } from 'get-real-client-ip'

getClientInformation()
  .then(ip => console.log(ip))
  .catch(e => console.error(e))

Result:

{
  "ip": "x.x.x.x",
  "registry": "<registry-name>",
  "countrycode": "DE",
  "countryname": "Germany",
  "asn": {
    "code": "X",
    "name": "<isp-name>",
    "route": "X.X.X.X/24",
    "start": "X.X.X.X",
    "end": "X.X.X.X",
    "count": "X"
  },
  "spam": false,
  "tor": false
}

Hope all of you guys like this small package, please give a star. Thank you. ❤️❤️

About

This package will get an ip address when you access by browser or to server

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published