Geocoding with Graticule and SimpleGeo

I’ve been keeping an eye on SimpleGeo over the last few months. If you haven’t heard of the company, they’re providing some interesting ways on making applications location-aware through their two beta products: Context and Places.

You’ll need to sign up for a JSONP API key if you want to use SimpleGeo as your geocoding service for Graticule. The JSONP client gives you read-only access to every endpoint available through their API.

After that, it’s just a matter of initializing a Graticule service, and you’re on your way to simple geocoding…

geocoder = Graticule.service(:SimpleGeo).new(LONG_SIMPLEGEO_TOKEN)

location = geocoder.locate '41 Decatur Street, San Francisco, CA 94103'
#=> [37.772555, -122.405978]