Guide

Migrating from another maps provider to GeoDesh

This guide moves an app from Google Maps Platform or another maps provider to GeoDesh, the Dhaka-based maps platform that bills in Taka. It maps each common call to its GeoDesh endpoint, explains the differences in requests and responses, and gives a safe order of work so nothing breaks for your users.

30 November 2026 · 8 min read

Before you start

  • List every maps call your app makes: search the code for the provider’s domain and SDK.
  • Note your monthly volume per call from the old provider’s console.
  • Request a GeoDesh account and create two keys: a server key and a browser key restricted to your origin.

Endpoint map

What you call todayGeoDesh endpointNotes
GeocodingGET /v1/geocode?address=Returns formattedAddress, location, viewport, addressComponents.
Reverse geocodingGET /v1/reverse-geocode?lat=&lng=
Places text searchGET /v1/places/search?q=Bias with lat, lng, radius; up to 120 results with limit.
Nearby searchGET /v1/places/nearbyradius is required; type or keyword.
Place detailsGET /v1/places/{id}Accepts the place id from search or autocomplete.
AutocompleteGET /v1/places/autocomplete?input=Each result includes location.
Directions / routesPOST /v1/routesJSON body: origin, destination, waypoints, mode.
Distance matrixPOST /v1/routes/matrixUp to 100 elements per request.
Static mapsGET /v1/maps/staticlat, lng, zoom, markers, path.
Street View imageGET /v1/streetview/imageMetadata is free at /v1/streetview/metadata.
Elevation, time zoneGET /v1/elevation, GET /v1/timezone

Differences to handle

  • Authentication: send x-api-key: YOUR_KEY as a header. Map tile, Street View and static image URLs may carry ?key= because images cannot send headers.
  • Envelope: results are in data, with meta holding the request id and cache state. Errors come as { "error": { "code", "message", "requestId" } }.
  • Routes are POST with JSON, not query strings. Origins and destinations can be coordinates ({ "lat", "lng" }) or plain text.
  • Durations and distances are { value, text } in seconds and metres; traffic time is durationInTraffic.
  • Field names follow camelCase: formattedAddress, userRatingsTotal, openingHours.

A thin adapter

Put every maps call behind one module in your app. Then the switch is one file, and you can run both providers side by side.

const BASE = 'https://geodesh.com';
const KEY = process.env.GEODESH_KEY;

async function call(path, init = {}) {
  const res = await fetch(BASE + path, { ...init, headers: { 'x-api-key': KEY, 'content-type': 'application/json', ...init.headers } });
  const body = await res.json();
  if (!res.ok) throw Object.assign(new Error(body.error?.message ?? 'Maps error'), { code: body.error?.code, status: res.status });
  return body.data;
}

export const geocode = (address) => call('/v1/geocode?address=' + encodeURIComponent(address)).then((d) => d[0] ?? null);
export const autocomplete = (input, near) => call('/v1/places/autocomplete?input=' + encodeURIComponent(input) + (near ? '&lat=' + near.lat + '&lng=' + near.lng : ''));
export const directions = (origin, destination, mode = 'driving') => call('/v1/routes', { method: 'POST', body: JSON.stringify({ origin, destination, mode }) });
export const matrix = (origins, destinations) => call('/v1/routes/matrix', { method: 'POST', body: JSON.stringify({ origins, destinations, mode: 'driving' }) });
maps.js: one adapter for the whole app

Swapping the map

You have three options:

  • GeoDesh Map SDK: one script tag with markers, clustering, polylines, polygons, popups and a place panel. addPolyline accepts an encoded polyline from Directions directly.
  • Leaflet or MapLibre: keep your map library and point it at GeoDesh tiles, /v1/maps/atlas/{theme}/{z}/{x}/{y}, or the MapLibre style at /v1/maps/atlas/{theme}/style.json.
  • Mobile WebView: load /embed/map.html and send commands with atlasCommand.

A safe order of work

  1. Move server-side calls first (geocoding, directions, matrix), behind the adapter.
  2. Run both providers on a sample of real requests for a few days and compare results.
  3. Switch the adapter to GeoDesh for all traffic; keep the old provider’s key active for a week.
  4. Swap the map in the web app, then in mobile apps with the next release.
  5. Watch usage and errors in the GeoDesh console, then close the old account.

Estimating the new bill

Multiply each call’s monthly volume by its GeoDesh price per 1,000 on the pricing page, apply your plan discount and subtract the included credit. The worked examples in what a maps API costs show the method.

Things that do not change

GeoDesh data comes from Google Maps, so place results, addresses and roads match what your users already know. Show the attribution GeoDesh returns on your maps.

After the switch

Once all traffic runs on GeoDesh, review the console after the first week: the busiest endpoints, error codes and cost per day. Tighten key restrictions now that you know every origin that calls the API, and set your plan quota as a ceiling.

Comparing results during the overlap

While both providers run, log a sample of requests with both answers: the coordinates from each geocode, the duration from each route. Look for large differences rather than small ones; a few metres apart is normal, a different district is a bug in the input or a gap to report. Share the worst cases with the GeoDesh team so they can be checked.

Mobile apps need a release

Web apps switch the moment you deploy. Mobile apps switch only when users update, so keep the old provider working for older app versions until most users have moved, or move mobile maps calls behind your own server so the switch does not depend on an app release at all.

Rolling back if you need to

Because every call goes through one adapter, rolling back is a configuration change. Keep the old provider’s key active until you have run a full month on GeoDesh, and keep logging which provider served each request so you can compare error rates.

A migration checklist

  • All maps calls go through one adapter module.
  • Server key in environment variables; browser key restricted by origin.
  • Responses read from data and errors from error.code.
  • Directions and matrix send JSON bodies with POST.
  • Map attribution visible on every map.
  • Usage alerts set up in the GeoDesh console.

Frequently asked questions

Do place ids carry over?

GeoDesh place ids come from the same index, so ids from search and autocomplete work with GeoDesh place details. Re-fetch any you stored long ago, as ids can change.

Can I migrate one feature at a time?

Yes. The adapter lets you move geocoding first, then routes, then the map.

How long does migration take?

For a typical app with a handful of maps calls, a developer can move the server-side calls in a day and the map in another day or two, plus testing.

Start with ৳5,000 free every month.

Request an account and the GeoDesh team sets it up for your organization. Then make a key and your first call in minutes. Billed in Taka.