Google Geocoding v2 API stopped working suddenly - google-maps

The Geocoding v2 API stopped unexpectedly.
e.g.
http://maps.google.com/maps/geo?q=27703&output=json&key=AIzaSyBVr3n3IVZzakGvtIWeRaJEXsC63JHZ0w8
I'm not able to get lat,long from the API. The output from server is:
{
"Status": {
"code": 610,
"request": "geocode"
}
}
I searched for status: 610 but could not find any relevant info.
Thanks.

The service has been stopped.
It is the 8th of March.
See the top of this page for information on the death of v2
See The Google Geocoding API for v3
...
Edit.
Actually, there is a page about upgrading to v3 that may be of use.
...
Edit.
As just pointed out, the Geocoding API V2 deprecation timeline was just extended by another 6 months, but be careful of your usage.
From #FrVaBe's link:
"Today we’re also reducing the limit on Geocoding API V2 from 15,000 requests per day to 2,500 requests per day, which is equivalent to the daily limit on the Geocoding API V3."

It seems that you are using Geocoding API V2. You can find the list of status codes here. The status you get is
610 G_GEO_BAD_KEY
The given key is either invalid or does not match the domain for which it was given.
So check to use the right API version (obvious V3 - V2 has been stopped as #Rafe mentions)
I never used this API but request should have this form
http://maps.googleapis.com/maps/api/geocode/output?parameters

Related

Google Maps Javascript API reporting I'm over limit

Google Maps Javascript API is reporting that I'm over the limit, but I'm pretty sure I'm not. I get this error:
You have exceeded your daily request quota for this API. For more information on usage limits and the Google Maps Javascript API services please see: https://developers.google.com/maps/documentation/javascript/usage
My Google API dashboard gives these numbers for the past day:
Google Places API Web Service: 407
Google Maps Geocoding API: 70
Google Maps JavaScript API: 30
What could be causing this? How can I get this up and running again, it is killing my application?
I came across your question because I am in the same position, seemingly well below the quota limits according to the console.
In the developer's console, go to the Dashboard, then click on the Google Places API Web Service. Then in the Quotas tab, scroll to the bottom and you'll see the Requests per Day. Here I was clearly reaching the 1000 requests per day limit, hence explaining the blocking of the requests.
We now count Google Maps JavaScript API client-side requests towards
the daily limit of the associated web service API.*
So it's the libraries=places and associated api usage (e.g. autosuggest in the search box) that is triggering this.

Why does the Google Geocoding API work without key?

I'm reading the documentation for the Google Geocoding API, and I noticed that it says that a key is required in a geocoding request, but when I do "https://maps.googleapis.com/maps/api/geocode/json?address=LosAngeles,usa" it gives me the expected result.
Why is this? Is the documentation wrong? Will it start asking for the key after a certain amount of requests? Or is there something I'm not understanding?
Providing a key is not required for most geocoding API requests. When you do not provide a key, Google will use an IP-based quota to determine when you reach the 2,500-queries daily limit.
Some parameters require a key and will not allow IP-based quota. These are explicitly marked in the documentation with:
Note: This parameter is available only for requests that include an API key or a client ID.
Currently, this is only for two parameters in reverse geocoding: result_type and location_type.
source
Beginning on June 11, 2018, you’ll need to enable billing with a
credit card and have a valid API key for all projects. This will give
you the ability to scale easily with less downtime and fewer
performance issues. In addition, we’re simplifying our 18 individual
APIs into three products: Maps, Routes, and Places.
Also, in June 2016 we announced that we would stop supporting keyless
usage, meaning any request that doesn’t include an API key or Client
ID. This will go into effect on June 11th, and keyless access will no
longer be supported. At that time, keyless calls to the Maps
JavaScript API and Street View API will return low-resolution maps
watermarked with “for development purposes only.” Keyless calls to any
of the following APIs will return an error: Maps Static API (including
Static Street View), Directions API, Distance Matrix API, Geocoding
API, Geolocation API, Places API, Roads API, and Time Zone API.
To avoid a service interruption to your projects, please visit our Get
Started page to enable a billing account and generate an API key. Once
you generate and secure an API key, make sure to update your
application with the new API key.

Using a business API key for reverse geocoding with Google

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?
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.

Google maps Restful Webservice - Wrong Location

I was testing the Netbeans tutorial about Restful WEbservices Getting Started With Restful Webservices
Everything seems to be working , but the problem is that whatever address i give, the maps always shows the same location.(Near Africa on Equator. Think its the default location). I got an api key from Google as described in the tutorial.
Tried to read the response from firebug. There are no errors, but the response is not easy to understand.
Any suggestions?
I don't know if you've found a solution or not yet, but I ran into the same problem and after looking around a bit, came to the conclusion that the problem lies in the returned value from the geocoding query (look for 'codeStr' in GoogleMapService.java).
The tutorial uses v2 of the Google Geocoding API and this problem is related to Google Maps' depreciation of v2 on the 8th of March 2013. I'll bet you are receiving a 610 code from the Geocoding API instead of the expected response, so the marker is plotted at 0 lat, 0 long.
You can find more information about the change in the GoogleMaps API here, and at the site for the Geocoding API. Hopefully, the creator of the tutorial will update it to get it into a working state again as it is otherwise a good source of information.
Then again, it could be the Netbeans implementation of the RESTful api that has been affected by the depreciation of v2.

Google maps API Geocode Return code 610 [duplicate]

The Geocoding v2 API stopped unexpectedly.
e.g.
http://maps.google.com/maps/geo?q=27703&output=json&key=AIzaSyBVr3n3IVZzakGvtIWeRaJEXsC63JHZ0w8
I'm not able to get lat,long from the API. The output from server is:
{
"Status": {
"code": 610,
"request": "geocode"
}
}
I searched for status: 610 but could not find any relevant info.
Thanks.
The service has been stopped.
It is the 8th of March.
See the top of this page for information on the death of v2
See The Google Geocoding API for v3
...
Edit.
Actually, there is a page about upgrading to v3 that may be of use.
...
Edit.
As just pointed out, the Geocoding API V2 deprecation timeline was just extended by another 6 months, but be careful of your usage.
From #FrVaBe's link:
"Today we’re also reducing the limit on Geocoding API V2 from 15,000 requests per day to 2,500 requests per day, which is equivalent to the daily limit on the Geocoding API V3."
It seems that you are using Geocoding API V2. You can find the list of status codes here. The status you get is
610 G_GEO_BAD_KEY
The given key is either invalid or does not match the domain for which it was given.
So check to use the right API version (obvious V3 - V2 has been stopped as #Rafe mentions)
I never used this API but request should have this form
http://maps.googleapis.com/maps/api/geocode/output?parameters