Search API Discontinued in 2014, but as of 2020 still documented on Google's own site

157 views
Skip to first unread message

JavaJive

unread,
Jul 6, 2020, 7:57:46 AM7/6/20
to Google AJAX APIs
As per subject, two questions stand out about this:

? If it was turned off in 2014, how is it that my site has been using it without problems for all these years since, until this last weekend?

? Why has its documentation existed on Google's site over all the intervening years and stills exist now, with a current date?

https://support.google.com/code/answer/74501

Jeremy Geerdes

unread,
Jul 6, 2020, 8:39:57 AM7/6/20
to google-ajax...@googlegroups.com
I don't know what API you've been using, but the suite of services that was originally known as the AJAX Search APIs was shut down. Other services which were rolled out under the AJAX APIs loader have continued to function.

jg

--
--
You received this message because you are subscribed to the Google
Groups "Google AJAX APIs" group.
To post to this group, send email to
google-ajax...@googlegroups.com
To unsubscribe from this group, send email to
google-ajax-searc...@googlegroups.com
To view this message on the web, visit
https://groups.google.com/d/msgid/google-ajax-search-api/bf3f7661-fc10-4a28-bda5-8dbf58fb8db1o%40googlegroups.com
For more options, visit this group at
http://groups.google.com/group/google-ajax-search-api?hl=en?hl=en

---
You received this message because you are subscribed to the Google Groups "Google AJAX APIs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-ajax-searc...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-ajax-search-api/bf3f7661-fc10-4a28-bda5-8dbf58fb8db1o%40googlegroups.com.


--
Rev. Jeremy R. Geerdes, Pastor
Debra Heights Wesleyan Church
4025 Lower Beaver Rd
Des Moines, IA 50310

JavaJive

unread,
Jul 6, 2020, 11:09:45 AM7/6/20
to Google AJAX APIs

Thanks for replying ...

I was merely following the instructions on the web page I linked ...

https://support.google.com/code/answer/74501

... viz, the dynamic loading equivalent of Google's own static loading example given there, in other words the dynamic loading equivalent of this:

<script type="text/javascript" src="http://www.google.com/jsapi?key=YOUR-KEY"></script>
<script type="text/javascript">
	google.load("search", "1");
	// ...
google.load("maps", "3");
</script>

It worked until first the 302 affair of a week or two back previously posted about, but I was able to fix that, until now the search itself is giving a 404 seemingly as from this last weekend.  It may have been deprecated in 2010, and was supposedly switched off in 2014, but I had no knowledge of that, and it was working last week.

And there's still the question of why Google's own documentation is still claiming that it's current, apparently a decade after its deprecation was announced?

Apparently the equivalent replacement service is the Geocoding service which is part of Google Maps.  I have a Google Maps app and apparently Geocoding is already enabled as part of it, but when, following Google's own example page ...

https://developers.google.com/maps/documentation/geocoding/start

... I put the followiing into a browser's address bar ...

https://maps.googleapis.com/maps/api/geocode/json?address=<MyPostcode>+UK&key=<MyKey>

... I get back (I have to look at the page source to see it) ...

{
   "error_message" : "API keys with referer restrictions cannot be used with this API.",
   "results" : [],
   "status" : "REQUEST_DENIED"
}

... so now I'm wondering if the Geocoding API instructions are fully pukka, or if they are out of date as well!



On Monday, 6 July 2020 13:39:57 UTC+1, jgeerdes [AJAX APIs "Guru"] wrote:
 
I don't know what API you've been using, but the suite of services that was originally known as the AJAX Search APIs was shut down. Other services which were rolled out under the AJAX APIs loader have continued to function.

jg

On Mon, Jul 6, 2020 at 6:57 AM JavaJive <...> wrote:
As per subject, two questions stand out about this:

? If it was turned off in 2014, how is it that my site has been using it without problems for all these years since, until this last weekend?

? Why has its documentation existed on Google's site over all the intervening years and stills exist now, with a current date?

https://support.google.com/code/answer/74501


--

Jeremy Geerdes

unread,
Jul 6, 2020, 2:52:11 PM7/6/20
to google-ajax...@googlegroups.com
The knowledge base questions that you are seeing have been partially updated, but they are still woefully outdated. For instance, many of the links for the Search API documentation point to the Custom Search API, which is what Google recommended to replace the AJAX Search API. What I can tell you is that, while the original crew was in charge, they worked very, very hard to make sure that the documentation was both usable and up-to-date. Since the original services were deprecated, though, Google's API documentation has suffered terribly. The new documentation is much more convoluted, much less usable, and (as you have seen) sometimes outdated.

As for the error message that you're seeing, my best guess would be that your API key is restricted to a given referer domain or page. Thus, when you enter the URL directly into the browser, and that referer header is not included in the request, you get the message that you're seeing. I would suggest going through the Developer Console to sign up for a current API key that is appropriately restricted (or not) depending on your needs. Here's the link:



jg

--
--
You received this message because you are subscribed to the Google
Groups "Google AJAX APIs" group.
To post to this group, send email to
google-ajax...@googlegroups.com
To unsubscribe from this group, send email to
google-ajax-searc...@googlegroups.com
To view this message on the web, visit

For more options, visit this group at
http://groups.google.com/group/google-ajax-search-api?hl=en?hl=en

---
You received this message because you are subscribed to the Google Groups "Google AJAX APIs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-ajax-searc...@googlegroups.com.

JavaJive

unread,
Jul 6, 2020, 3:32:33 PM7/6/20
to Google AJAX APIs
Thanks again ...


On Monday, 6 July 2020 19:52:11 UTC+1, jgeerdes [AJAX APIs "Guru"] wrote:
The knowledge base questions that you are seeing have been partially updated, but they are still woefully outdated. For instance, many of the links for the Search API documentation point to the Custom Search API, which is what Google recommended to replace the AJAX Search API. What I can tell you is that, while the original crew was in charge, they worked very, very hard to make sure that the documentation was both usable and up-to-date. Since the original services were deprecated, though, Google's API documentation has suffered terribly. The new documentation is much more convoluted, much less usable, and (as you have seen) sometimes outdated.

Yes, so it seems.  Doesn't exactly inspire confidence in Google generally.,
 

As for the error message that you're seeing, my best guess would be that your API key is restricted to a given referer domain or page. Thus, when you enter the URL directly into the browser, and that referer header is not included in the request, you get the message that you're seeing. I would suggest going through the Developer Console to sign up for a current API key that is appropriately restricted (or not) depending on your needs. Here's the link:



Thanks, I'll try test page from my live site's test area to see if that fixes it.
 

jg

JavaJive

unread,
Jul 6, 2020, 5:38:08 PM7/6/20
to Google AJAX APIs
No joy :-(

JavaJive

unread,
Jul 8, 2020, 11:53:29 AM7/8/20
to Google AJAX APIs
I've found the solution to this, but I don't like it a bit.  Currently my key has a Referrer restriction limiting its use to only my site.  To get a Geocoding query by URL to work, I have to remove all Referrer restrictions on it, but that means anyone else can (ab)use it, potentially even costing me money!  For a firm that is anally retentive about security to the point of insisting on sending me unwanted texts by insecure SMS to tell me that I've just logged into my Google account, as if I didn't know already, and insisting that I confirm it was me to avoid the account being locked, why is Google now insisting that I make my mapping key available for general use?
Reply all
Reply to author
Forward
0 new messages