NOTE: NetGeo has not been actively maintained since 1999, and this will probably not change in the foreseeable future. As a result, there are several known major issues affecting accuracy and service availability. Please be warned that NetGeo may give wildly incorrect results, especially for recently allocated or re-assigned IP addresses.
Also, domain-name lookups are no longer supported.
Please see a list of NetGeo alternatives.
A beta distribution of Java and Perl APIs to interact with the NetGeo server is now available: NetGeoClient-1.1.tar.gz
The README.cgi file from the distribution provides some rough documentation. You may also find looking at example scripts useful.