https://github.com/nekiplay/ip-api
API for IP
https://github.com/nekiplay/ip-api
csharp csharp-library ip ipv4
Last synced: 4 months ago
JSON representation
API for IP
- Host: GitHub
- URL: https://github.com/nekiplay/ip-api
- Owner: Nekiplay
- Archived: true
- Created: 2021-01-04T00:18:40.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2021-06-27T17:02:32.000Z (about 5 years ago)
- Last Synced: 2025-01-27T07:12:43.546Z (over 1 year ago)
- Topics: csharp, csharp-library, ip, ipv4
- Language: C#
- Homepage:
- Size: 28.3 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# IP-API
**API for IP**
[](https://www.codacy.com/gh/Nekiplay/IP-API/dashboard?utm_source=github.com&utm_medium=referral&utm_content=Nekiplay/IP-API&utm_campaign=Badge_Grade)
**If open Port:**
```C#
IP.API.Port port = new IP.API.Port("IP");
bool valid = port.CheckPort(80);
```
**Get IP Information:**
```C#
IP.API.Information IpInformation = new IP.API.Information("IP");
bool IsTor = information.IsTorAsync().Result;
bool ipvalid = IpInformation.IP.IpValid;
string country = IpInformation.IP.Country;
string city = IpInformation.IP.City;
string region = IpInformation.IP.Region;
string asn = IpInformation.IP.ASN;
string provider = IpInformation.IP.Provider;
double Latitude = IpInformation.IP.Latitude;
double Longitude = IpInformation.IP.Longitude;
double CountryPopulation = IpInformation.IP.CountryPopulation;
```
**Get ICMP Traffic:**
```C#
IP.API.ICMP icmp = new IP.API.ICMP("IP");
int icmppower = icmp.Power; /* Maximum power 4 */
```