map

How to create a reverse geocoding API

Engineering

6/2/2021 12:00 PM

Location Open Source Web Development

Turn coordinate data into real-world information

Latitude and longitude data has been used for centuries. From the initial use of navigating through the open seas, to the more current purpose of having an app tell you how to get where you need to be.

This geographical coordinate data can be converted into useful, real-world information using something called reverse geocoding.

Rather than your smartphone telling you to travel 0.3° latitudinally and 0.11° longitudinally, the data is converted into real directions, such as “turn left on First Street and walk 200 yards to your destination”.

It’s this conversion of real address information that is so appetizing about reverse geocoding. One life-saving benefit is that the Healthcare and public safety services can now use coordinate data and translate it to a physical location that emergency dispatches rely on.

This blog will not only go through how to use reverse geocoding, but why you’d want to implement it into your own API.

map

How Which Three Birdies uses reverse geocoding

A quirky example of reverse geocoding in action is Which Three Birdies. It is simply a combination of 51Degrees geolocation solution, Xeno-Canto's freely-available database of bird calls, and Wikidata's huge collection of imagery.

Ordinarily, these three things have little in common, but magic is made when you put them together. When you place a pin on a map (generating coordinates), Which Three Birdies creates a “birdday card”. The card shows you images of three birds that can be found in that specific area, alongside their bird song.

example
An example “birdday card”

Our reverse geocoding API comes into its own when combined with other APIs, and Which Three Birdies is a defining example of how simple it is to do this – you can read how it was made to see for yourself.

How can I get started?

Creating your own reverse geocoding API has never been this simple. We've documented the method to look up a latitude and longitude to a geographical location in more detail, but you can find a summary below.

  1. Obtain a resource key using our configurator.
  2. Install the relevant library for your programming language – we have support for C#, Java, Node.js, PHP, and Python.
  3. Create a Pipeline and authorize it with the resource key.
  4. Create a FlowData on the Pipeline and add evidence to it.
  5. Start a query with: process()
  6. Read the results.
configurator
A selection of location properties available on our configurator.

Why choose our reverse geocoding API?

There are many reverse geocoding APIs out there all vying for your attention, so we’ll keep it plain and simple. Here are 3 reasons why 51Degrees is the smart choice:

#1 | We offer free options

Want to test the waters before you dive right in? When you select your location properties on our configurator, you can decide whether you want our simpler free version, or want more possibilities with the paid properties. Even if you choose our paid properties, you can contact us for a free trial.

Additionally, when you compare us to others in the market, we offer ten times the number of free requests. We respect the consumers right to try before they buy, and that is reflected in our free options.

#2 | We are an open source API

We value the contributions to the community. Which Three Birdies is an open source website, and so is our reverse geocoding service. We offer complete transparency and our main focus is giving to the community.

An open source API is cost-effective and gives you the flexibility to create unique solutions. You can get as creative as you want with our reverse geocoding API.

#3 | We promise unrivalled accuracy

Our geolocation power isn’t limited to turning coordinates into a detailed native-language description of where that point is, but we also provide complete and accurate information such as buildings or a street address. We offer closer targeting for the best and most accurate results.

Alright, that’s enough tooting of our own horn. We’ve shown you how simple it is to get started with our free reverse geocoding API, so now all that’s left for you to do is to go and follow these 6 easy steps to start!