Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jtblin/ip2location
Simple client for the IP2Location API
https://github.com/jtblin/ip2location
Last synced: 19 days ago
JSON representation
Simple client for the IP2Location API
- Host: GitHub
- URL: https://github.com/jtblin/ip2location
- Owner: jtblin
- License: mit
- Created: 2012-07-09T17:17:33.000Z (over 12 years ago)
- Default Branch: master
- Last Pushed: 2012-07-09T17:21:00.000Z (over 12 years ago)
- Last Synced: 2024-10-28T09:07:05.106Z (2 months ago)
- Language: Ruby
- Homepage: http://github.com/ezkl/ip2location
- Size: 105 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
ip2location
===========Description
-----------
This is a stupid simple client for [IP2LocationAPI](http://www.ip2locationapi.com/) written with [David Balatero](https://github.com/dbalatero)'s awesome [monster_mash](https://github.com/dbalatero/monster_mash) library. I wrote it more or less
as practice and to continue to familiarize myself with Ruby 1.9, RSpec, and Typhoeus.Usage
--------
require 'ip2location'
# Ip2Location.api_key = YOUR_API_KEY
# Ip2Location.user = YOUR_API_USERNAME
#
# OR
Ip2Location.setup do |s|
s.api_key = YOUR_API_KEY
s.user = YOUR_API_USERNAME
endputs Ip2Location.ip2l('8.8.8.8')
#=>
Requirements
------------
* monster_mash (~> 0.2.3)
* A username and API key from [IP2LocationAPI](http://www.ip2locationapi.com/geoip-location-api/signup.php) (free)Install
-------
gem install ip2locationCopyright
---------
Copyright (c) 2011 Ezekiel TemplinSee LICENSE.txt for details.