在新的网络浏览器中使用 Google 的逆向工程建议 API 是否违法?

Is it illegal to use Google's reverse engineered suggestions API in a new web browser?

我不会使用官方 API(如果有),因为所有 Google 的 API 这种性质都需要付款,我将使用URL 我相信在许多小型应用程序和网站中都能找到它。

我将引用 Google 当然有一个 "Google Suggestions" 标题,所有这些在点击时都会重定向到浏览器中的 Google 页面。

这是从 Chrome 网络浏览器 URL 反向工程得到的请求:

http://google.com/complete/search?output=toolbar&client=chrome&q=SEARCHTERM

returns JSON 格式的建议。

我会违反他们的 use/service 条款或准则吗?

我自己没有发现 URL,这是对这里另一个问题的回答,我想在小规模项目中它可能不会被注意到,但是法律方面的事情呢?

不好意思,我不知道该用哪个标签。

虽然我不是律师,但您可以采用以下方法...

  1. URLs 是开放的发现游戏。最好的发明来自做一些新的和不同的事情,我相信 google 同意。如果您遇到一个 URL 可以作为您可以利用的 API 查询执行您想要的操作,请这样做,假设您知道如何处理该 JSON 输出。 APIs 基本上是开放的,除非提供商通过适当的身份验证控制对其进行限制。今天,您可以通过简单的 Javascript 查询或模板 HTML 表单提交,将基本 google 搜索嵌入到许多事情中而不会出现问题。这在我看来没有什么不同。

  2. 如果您在商业上这样做,那是您需要谨慎的地方。 Google 的搜索通常在您访问 https://www.google.com 时可能会在页面上看到条款和条件的上下文中开放,但是该协议基本上是一种方式,并且对一般目的的执行有限消费者。这更像是承认,当您使用开放服务时,他们让您必须遵守法律上必须披露的内容。

https://policies.google.com/terms?fg=1

也就是说,如果您在商业上使用开放/发现 API 然后增加尴尬的需求,他们可能会追究您的商业损失 - 因为要阻止它,他们可能不仅需要处理他们的API 用于查询字符串,但 HTTP post 元数据中的其他模式。他们确实表示,任何直接干扰他们的服务(这可能是商业和重要的)都是他们认真对待的事情。

我发现你的问题很有趣,因此我做了一些研究并偶然发现了一个 Google Webmaster Central Blog post,它指出 Google 很清楚用户使用自动完成 API(又名建议 API):

"For years, a number of developers have integrated the results of autocomplete within their own services using a non-official, non-published API that also had no restrictions on it"

然后他们继续说:

"However, there are some times when using an unsupported, unpublished API also carries the risk that the API will stop being be available. This is one of those situations. We built autocomplete as a complement to Search, and never intended that it would exist disconnected from the purpose of anticipating user search queries."

他们得出结论:

"In the interest of maintaining the integrity of autocomplete as part of Search, we will be restricting unauthorized access to the unpublished autocomplete API as of August 10th, 2015."

所以,关于你的问题,"Will I be violating their terms of use/service or guidelines?"

不这么认为。他们知道开发人员可能会尝试访问自动完成功能 API,您的应用程序很可能在某个时候会受到限制或禁止。

Read more about this here

可以看出,实际上并没有任何官方声明使用此API会违反条款。

但是例如Google Suggest/Autocomplete API在"Data Source Handbook: A Guide to Public Data by Pete Warden"中的解释如下:

此外,还有一篇博客文章介绍了对其非官方自动完成的限制 API。 CORS 政策就是这种限制的一个例子。但是,当然,当打开一个单独的新 tab/window 而 AJAX 调用受到限制时,它仍然可以在浏览器上运行。 [1]
看到这个:https://webmasters.googleblog.com/2015/07/update-on-autocomplete-api.html

很明显,Google 希望开发人员在他们的网站上使用 Google 自定义搜索引擎来实现自动完成,但没有任何官方的全局搜索建议 API Google允许。

[1]

$.ajax({
  'url' : 'https://suggestqueries.google.com/complete/search?output=toolbar&q=test',
  'type' : 'GET',
  'dataType' : 'XML',
  'success' : function(data) {              
            document.body.innerHTML = 'Data: '+data;
        },
  'error' : function(xhr, status, error){
            document.body.innerHTML = "Request: "+ JSON.stringify(xhr);
  }
});
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>

但由于您将在浏览器 window 上使用此 link,因此您不会遇到上述问题。

此外,可能会禁止 IP 或限制应用程序(无论是否用于商业用途),或者 Google 可能认为请求来源可疑,因为检测到异常 activity(例如如果发送到非官方自动完成的请求过多 API.

,则在向 Google) 的进一步请求中询问验证码