How to Migrate from Google Maps API in Under 2 Hours
Why Migration Takes Under 2 Hours
Beta Maps API covers the same use cases as Google Maps — directions, geocoding, places search, nearby search, place detail, and autocomplete. The API uses POST with JSON body and Basic Auth, so migration involves updating your API calls rather than just swapping a URL. Most teams complete the switch in under 2 hours.
Step 1: Get Your Beta Credentials
Sign up at beta.vn/maps-api. You'll receive a username and password for Basic Authentication instantly.
Step 2: Update Your API Calls to POST
Switch from Google's GET requests with query params to Beta's POST requests with JSON body:
// Before (Google Maps)
fetch(`https://maps.googleapis.com/maps/api/geocode/json?address=Saigon&key=${API_KEY}`)
// After (Beta Maps)
fetch("https://api.beta.vn/v1/mapapi/geocode", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "Basic " + btoa(username + ":" + password)
},
body: JSON.stringify({ address: "Saigon" })
})
Step 3: Map Your Endpoints
Each Google endpoint has a Beta equivalent:
GET /maps/api/geocode/json→POST /v1/mapapi/geocodeGET /maps/api/directions/json→POST /v1/mapapi/directionGET /maps/api/place/textsearch/json→POST /v1/mapapi/textsearchGET /maps/api/place/nearbysearch/json→POST /v1/mapapi/nearbysearchGET /maps/api/place/details/json→POST /v1/mapapi/detailGET /maps/api/place/autocomplete/json→POST /v1/mapapi/search
Step 4: Test Your Integration
Run your existing test suite against Beta's endpoints. The response data is equivalent to Google's, so your parsing logic should work with minimal adjustment.
Key Differences to Note
Geocoding: Forward and reverse geocoding both supported. Send address or location as JSON body fields.
Directions: Pass origin and destination as lat/lng objects or text addresses in the JSON body.
Places: Text search, nearby search, and place details all supported via POST with JSON body.
Autocomplete: Use /v1/mapapi/search with search_text parameter. Supports country filtering via componentRestrictions.
What About Client-Side Libraries?
Beta Maps API is a server-side REST API, not a JavaScript SDK. If you currently use @googlemaps/js-api-loader for client-side rendering, you'll call Beta's endpoints from your backend instead. Check our documentation for integration examples.
Rollback Plan
Since migration is a URL change, rollback is equally simple. Keep your Google API key active during the transition period. If anything goes wrong, switch back in seconds.