Bragdocs
Log in Sign up

← Fardin

January 14th, 2025

Maps API

We solved the location gathering. Now we needed a solution to represent the data. As of writing I was able to find out 3 main usage of Map:
  1. Get current location
  2. Identify nearest intersection: to create a route
  3. Find distance between multiple point

Thought of using Google Maps API for all the tasks but things got sour quickly.
Get current location was easy. We will just use the device's GPS. Google can help us get accurate location data.
To Identify nearest intersection, Google doesn't have anything directly. I have to use Geocoding. But the problem is, even for trial I need to provide credit card information for verification. I understand the need but I don't have a international card. There is no other way of accessing Geocoding API.
So went back to OpenStreetMap(OSM). OSM has its own query language: Overpass Query Language. On https://overpass-turbo.eu/ I have run this query and boom! It gave me pointers of intersections in my view! It was so amazing.
Lastly to Find distance between multiple point I wanted to use OSM. Found out OpenRouteService. Here I can create a route from points as well.

Now that I have all the tools in hand, I can proceed😊