fix: migrate to new Google Places API (New) to resolve HTTP 403 errors#19
Merged
cablate merged 5 commits intocablate:mainfrom Oct 16, 2025
Merged
Conversation
- Add @googlemaps/places dependency for new Places API - Create NewPlacesService class to handle new API integration - Update PlacesSearcher to use new API for getPlaceDetails - Maintain backward compatibility with existing response format - Add test script to verify new implementation - Update README with information about the API migration Fixes the error: 'You're calling a legacy API, which is not enabled for your project'
- Clean up NewPlacesService.ts by removing all comments - Clean up PlacesSearcher.ts by removing inline comments - Clean up test-new-api.js by removing documentation comments - Clean up create-pr.sh by removing comment blocks - Maintain clean, comment-free codebase
Owner
|
Thanks for the contribution! |
cablate
approved these changes
Oct 16, 2025
Owner
cablate
left a comment
There was a problem hiding this comment.
LGTM.
I've improved New Place API work and remove obsolete Places API migration artifacts.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Google Places API Migration Fix
Problem
The
get_place_detailstool was returning HTTP 403 errors with the message:Solution
Migrated from the legacy Google Places API to the new Places API (New) to resolve the HTTP 403 errors and ensure continued functionality.
Changes Made
1. Added New Dependency
@googlemaps/placespackage (v2.1.0) topackage.json2. Created New Service Class
src/services/NewPlacesService.ts3. Updated PlacesSearcher
src/services/PlacesSearcher.tsgetPlaceDetails()method to use the newNewPlacesService4. Key Features of the New Implementation
5. Testing
test-new-api.jsscript to verify the new implementation