Replacing Google Maps API in Vietnam: When to Evaluate TrackAsia

A customer enters an address from an older document, selects a suggestion and then sees a differently worded address on the map. Your support team needs to know whether the location changed, the administrative label changed or the wrong result was selected. That is a concrete reason to evaluate another maps provider: a requirement in the product needs a clearer implementation.

TrackAsia can be evaluated as an alternative to Google Maps API for Vietnam-focused workflows. The decision should be about suitability for your addresses, interfaces, operating regions and commercial agreement, not a universal claim that one platform is better. Google Maps remains an established international platform; replacing it is justified only when the relevant TrackAsia services satisfy your actual requirements and the total cost makes sense.

Start with the services your application actually uses

Open the code and list the map display library, suggestion service, place-details calls, full-address searches, route calculations and distance comparisons. Include the fields the UI reads, not only the endpoints. A checkout may depend on a provider’s place ID; a dispatch page may depend on a particular route structure; a contact page may simply need your own branch markers.

These dependencies have different migration costs. Replacing a basemap does not automatically replace address search. Replacing a REST response does not replace a JavaScript map class. TrackAsia’s Search v2 and Autocomplete v2 describe response structures following Google’s corresponding Legacy Places services.[1][9] That is a useful starting point for conversion, not proof that every Google parameter, newer API or UI widget will work unchanged.

Record the API generation explicitly. Google Text Search (Legacy) uses the endpoint and query parameter shown below.[6] If your application uses a newer Places service with a different request body and field selection, treat that as a separate conversion. Do not apply a Legacy example by changing a hostname and hope that incompatible inputs will be ignored safely.

Map each service to a real replacement

Task Existing Google integration to inventory TrackAsia target to evaluate Main conversion
Interactive map Google Maps JavaScript map and overlays trackasiagl.Map with a TrackAsia style Rebuild map objects, markers and events
Suggestions Places Autocomplete, noting its generation /api/v2/place/autocomplete/json input, predictions, scoped place IDs
Full address or place query Places Text Search (Legacy) /api/v2/place/textsearch/json query, results, geometry.location
Selected place Your current Place Details fields TrackAsia Place Detail, following the current documentation Recheck requested and returned fields
Journey between points Your current Directions or Routes service /route/v2/directions/json Coordinates, modes, route and leg fields
Many journey comparisons Your current matrix service /distance-matrix/v1/{profile}/{coordinates} Index lists and numeric tables

The TrackAsia targets above are documented in its quickstart and REST service pages.[1][2][3][9][10] The Google column is an inventory prompt: use the actual generation in your code rather than assuming all projects still use Legacy APIs. Place Detail should be checked against the fields your screen needs; a search response is not a complete substitute for every detail field.

Convert a full-address search before touching the whole UI

For a Google Legacy integration, the original request may look like this. It requires your existing authorised Google key; this guide does not provide one or claim a Google live test.[6]

const before = new URL('https://maps.googleapis.com/maps/api/place/textsearch/json');
before.search = new URLSearchParams({
  query: 'Landmark 81, Ho Chi Minh City', key: process.env.GOOGLE_MAPS_KEY
});

The TrackAsia version uses a different endpoint and can request the documented new and old administrative forms.[1] Save the complete example below as search-trackasia.mjs, then run it with Node.js 20 or later. The public key is limited and for testing only; configure an account key for production.

const url = new URL('https://maps.track-asia.com/api/v2/place/textsearch/json');
url.search = new URLSearchParams({
  query: process.argv.slice(2).join(' ') || 'Landmark 81, Ho Chi Minh City',
  key: process.env.TRACKASIA_KEY || 'public_key',
  new_admin: 'true', include_old_admin: 'true'
});
const response = await fetch(url, { signal: AbortSignal.timeout(15000) });
if (!response.ok) throw new Error(`HTTP ${response.status}`);
const body = await response.json();
if (body.status !== 'OK' && body.status !== 'ZERO_RESULTS') {
  throw new Error(`API ${body.status || 'unknown'}`);
}
console.log((body.results || []).map(place => ({
  provider: 'trackasia',
  providerPlaceId: place.place_id,
  label: place.formatted_address,
  oldLabel: place.old_formatted_address ?? null,
  point: place.geometry?.location
})));

The normalised object is deliberately small. It gives your UI a provider name, provider-scoped identifier, labels and point. It does not claim the providers’ results are identical. Keep your own customer or branch ID separate. A Google place ID should never be sent to TrackAsia Place Detail as if it identified the same record there.

A successful response still needs semantic review. Compare the selected place and usable entrance, not just whether both services return a number. Save rejected examples too: they show which addresses need clarification or a different interaction.

Try the source: Normalize search-provider results

Normalize Search results into a provider-neutral structure while retaining provider IDs and both address forms.

API examples use the limited public_key; the image captures a run of the source below.

Unzip, run python3 -m http.server 8080 in the extracted folder, then open http://localhost:8080/index-en.html. Vietnamese and English READMEs are included; no npm or build step is needed.

Download complete source ZIP

Normalize search-provider results
Tap the image to open full size.

Suggestions need a selection flow, not just matching JSON

TrackAsia Autocomplete v2 takes input and returns predictions; its documentation also describes place_id, formatted_address, description and optional old-address fields.[9] A suggestion list should show enough context for the customer to distinguish similarly named places. When a person selects an item, retain its provider identity through the details request.

If the person continues typing, clear the previous selection. Otherwise a form can display a new address string while silently retaining the old coordinate. Debounce input, cancel obsolete requests and ensure a late response cannot replace newer suggestions. Those are application behaviours, not features delivered automatically by an endpoint conversion.

Do not copy every Google parameter into the TrackAsia request. Retain only documented inputs and test the resulting search behaviour. A familiar response structure does not imply equivalent session accounting, ranking, supported types or billing. Confirm each dependency that the existing application actually uses.

Rebuild map objects at the coordinate boundary

The TrackAsia browser quickstart uses trackasiagl.Map and the streets v2 style.[3] A Google map object is not a TrackAsia map object, and a Google marker cannot simply be attached to it. Keep your own location data independent from the renderer so only the display layer changes.

// Existing data should use named fields, independent of either map SDK.
const branch = { id: 'demo-branch', lat: 10.769034, lng: 106.694945 };
// After loading TrackAsia GL JS and its CSS:
const map = new trackasiagl.Map({
  container: 'map',
  style: 'https://maps.track-asia.com/styles/v2/streets.json?key=public_key',
  center: [branch.lng, branch.lat], zoom: 13
});
new trackasiagl.Marker().setLngLat([branch.lng, branch.lat]).addTo(map);

This is the renderer portion of a page, not a standalone HTML file. Your page must load the library and CSS and give #map a non-zero height. Keep attribution visible. Insert branch names from your CMS as text rather than concatenating untrusted HTML into popups. Test keyboard access and retain a readable address list when WebGL or a network resource fails.

Administrative display deserves its own check. Search flags describe returned address labels; they do not prove that every map style displays the same administrative layer. Open the actual style used by your product and compare its visible labels with suggestion wording, popup labels and saved records. Confirm any required old/new boundary display mode with TrackAsia rather than inventing a style flag.

Routing conversion has its own units and modes

TrackAsia Directions v2 documents origin and destination as latitude,longitude, with modes including driving, motorcycling, walking and truck. Route legs expose numeric distance values in metres and duration values in seconds.[10] Matrix v1 instead puts longitude,latitude pairs in its path and uses profiles such as car and moto.[2]

const point = { lng: 106.698, lat: 10.773 };
const directionsValue = `${point.lat},${point.lng}`;
const matrixValue = `${point.lng},${point.lat}`;

Keep these conversions next to the provider calls. Preserve metres and seconds internally and format only at the UI boundary. Do not parse a human-readable distance string when a numeric value exists. Recheck route geometry encoding, error handling and the fields used for instructions before replacing an existing navigation display.

A mode name does not establish support for your exact truck dimensions, local restrictions or live traffic requirements. Test representative origin–destination pairs using the same vehicle assumptions. If a required capability has no documented equivalent, keep that component on the existing service or reconsider the scope instead of disguising the gap in an adapter.

Data rights can rule out an otherwise convenient shortcut

Google’s Geocoding policies explain storage restrictions, the place-ID exception and display requirements, including the requirement that mapped Geocoding results be shown on a Google Map.[7] Read the rules for each service you use; do not generalise one policy to every product or contractual region.

Do not copy an old provider-derived coordinate cache into a new basemap integration without reviewing the applicable agreement. Your own independently maintained branch coordinates are a different category from provider content. Ask TrackAsia for its corresponding storage, reuse and display terms, and document which data source produced each field.

Address files may contain personal information. Use an authorised test corpus, minimise fields and keep keys out of screenshots and logs. A technically working migration can still be unsuitable if it requires a data-handling arrangement your organisation cannot accept.

Compare one workload, then make the smallest justified change

Google publishes pricing by product SKU, so collect the actual services and API generations used by your project.[8] Give TrackAsia the same map, tile, suggestion, details, search, route and matrix forecast. For Matrix, include origins, destinations and recalculation frequency. Confirm billing units rather than comparing a generic request count across unrelated services.

Include conversion work, regression testing and any temporary overlap in the budget. Do not publish a savings percentage without the real invoice and a comparable quote. A lower unit price does not automatically offset a costly missing feature, and a higher price does not automatically justify replacing an integration that already fits.

Finish with a compact decision test: can users find the intended places, can the app preserve required old and new labels, do map and popup wording make sense together, do relevant routes fit operations, and are commercial terms acceptable for the same workload? If only the branch map benefits, replace only that part. If the address and routing flows also pass, expand deliberately. The right alternative is the one that satisfies the product’s requirements with understandable trade-offs.

Decide what evidence would change the decision

Before comparing outputs, write a few concrete acceptance cases with the people who use the product. A support agent may need to find an address from an old document; a customer may need to distinguish two branches with the same name; a dispatcher may need a route to a confirmed receiving entrance. These cases are more informative than an unlabelled collection of successful screenshots.

For each case, record the input, selected place, relevant fields and the user’s next action. A result that looks different can still support the task, while a similar-looking JSON object may hide the wrong location. Evaluate the action the screen enables, not the amount of field overlap.

Keep an explicit list of features that are outside the proposed switch. If the project still relies on an existing provider for a specialised map layer or a separately licensed dataset, state that boundary in the implementation notes. A partial migration is a legitimate outcome when data policies permit the arrangement and the interfaces make the sources clear.

The final recommendation should explain both the fit and the remaining cost. For example, a branch-map conversion may be straightforward while a custom route-instruction interface needs additional work. That is a useful engineering conclusion, not a failure to choose a winner. It gives procurement and development a decision they can act on without relying on unsupported claims about universal accuracy, availability or savings.

Sources

[1] https://docs.track-asia.com/api-integration/search/v2
[2] https://docs.track-asia.com/api-integration/distance-matrix/v1
[3] https://docs.track-asia.com/guides
[6] https://developers.google.com/maps/documentation/places/web-service/legacy/search-text
[7] https://developers.google.com/maps/documentation/geocoding/policies
[8] https://developers.google.com/maps/billing-and-pricing/overview
[9] https://docs.track-asia.com/api-integration/autocomplete/v2
[10] https://docs.track-asia.com/api-integration/directions/v2