Examples
In this page, you can find some code examples on how you can use the API.
Find the country/city of an address
EpicGuardAPI api = EpicGuardAPI.INSTANCE; // obtain the EpicGuardAPI instance.
GeoManager geoManager = api.getGeoManager(); // GeoManager instance.
String countryCode = geoManager.countryCode("127.0.0.1"); // ISO code of the country.
String city = geoManager.city("127.0.0.1"); // city's nameBlacklisting and checking whitelist
EpicGuardAPI api = EpicGuardAPI.INSTANCE; // obtain the EpicGuardAPI instance.
String address = "127.0.0.1";
if (api.getWhitelistedAddresses().contains(address)) {
api.blacklistAddress(address);
}Checking attack status
Last updated