Domanda

I'm working on a project that uses Google Maps APIs to reverse geocoding locations.

The customer is supposed to buy a licensed API key when rolling out to production.

Now I'm developing the application and I also need to test its functionality when using a valid, whether free or business, API key.

Let's pick a sample reverse geolocation request

https://maps.googleapis.com/maps/api/geocode/json?latlng=40.714224,-73.961452&sensor=true

I have registered a developer account into https://code.google.com/apis/console/ and generated a server API key. Then I enabled Google Geolocation APIs and Google Maps API v3 (I think I need only the second).

When adding &key=XXX parameter to my previous request I get an error that the key is not valid.

Reading documentation with more attention, I discovered that the geolocation service I'm using is actually part of Maps Web Service APIs (Maps V3 APIs run on browser as Javascript). I tried to find those APIs into the Services list of my console but couldn't find anything more.

How do I use Google's reverse geocoding API with a business key for a project that will handle thousands of daily requests?

È stato utile?

Soluzione

with no api key, the Google Geocoding API has the following limits in place: 2,500 requests per day. Google Maps API for Business customers have higher limits: 100,000 requests per day.

to use to API for Business you have to use URL signing, see https://developers.google.com/maps/documentation/business/webservices/auth

NB: If you're switching from the free API services to a Maps API for Business implementation, you must remove the key parameter from your requests. Google Maps API web services will deny requests made with both a client ID and a key.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top