Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/niklasberglund/ipinfo
A Bash shell-script wrapping the IP address information API of http://ipinfo.io
https://github.com/niklasberglund/ipinfo
host internet-protocol ip ip-address ipinfo isp shell
Last synced: about 8 hours ago
JSON representation
A Bash shell-script wrapping the IP address information API of http://ipinfo.io
- Host: GitHub
- URL: https://github.com/niklasberglund/ipinfo
- Owner: niklasberglund
- License: mit
- Created: 2014-02-16T12:08:33.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2018-01-16T10:39:45.000Z (almost 7 years ago)
- Last Synced: 2023-03-11T04:47:28.380Z (over 1 year ago)
- Topics: host, internet-protocol, ip, ip-address, ipinfo, isp, shell
- Language: Shell
- Homepage:
- Size: 3.91 KB
- Stars: 21
- Watchers: 5
- Forks: 11
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
ipinfo.sh
======
A Bash shell-script wrapping the IP address information API of http://ipinfo.io. For request limits and more info about their service see http://ipinfo.io/developers. At the time of writing this the limitation is 1000 requests per day.Usage
------
```
$ ./ipinfo.sh -h
Usage: ./ipinfo.sh [-f field] [IP address]
-f field Only output specified field's info. Run script without -f to see available fields.
-h Show this help text.
```Examples
------
### Current IP address info
```
$ ./ipinfo.sh
ip: 125.71.208.203
hostname: No Hostname
city: Chengdu
region: Sichuan
country: CN
loc: 30.6667,104.0667
org: AS4134 Chinanet
```### Specified IP address info
```
$ ./ipinfo.sh 173.194.127.233
ip: 173.194.127.233
hostname: hkg03s16-in-f9.1e100.net
city: Mountain View
region: California
country: US
loc: 37.4192,-122.0574
org: AS15169 Google Inc.
postal: 94043
```### Specify field (specified IP address)
```
$ ./ipinfo.sh -f city 173.194.127.233
Mountain View
```### Specify field (current IP address)
```
$ ./ipinfo.sh -f ip
117.175.141.105
```