问题描述
现在,我正在使用自定义搜索引擎(CSE)来按搜索词在整个网络中进行搜索.该请求看起来像:
Right now I'm using Custom Search Engine (CSE) to search through entire web by search term. The request looks like:
GET "https:/www.googleapis.com/customsearch/v1?key=API_KEY&cx=SEARCH_ENGINE_ID&q=SEARCH_TERM"
此请求将向我返回搜索结果列表.
And this request returns me list of search results.
但是,我需要通过图像或图像URL进行搜索. Google API是否提供此类url参数?也许像"image_url"?因此,该请求可以如下所示:
But, I need to implement search by image or image url. Do Google API provide such a url param? Maybe something like "image_url"? So, the request can look the following:
https://www.googleapis.com/customsearch/v1?key=API_KEY&cx=SEARCH_ENGINE_ID&image_url=http://www.example.com/image.png
基本上,我需要使用自定义搜索引擎来实现与images.google.com/相同的功能.谢谢.
Basically, I need to implement the same functionality as images.google.com/ but using my Custom Search Engine. Thanks.
我需要实现的示例:
推荐答案
据我所知,您要查找的内容仅受视觉AI 服务(至少部分是,以前从未使用过).您可能会注意到,Google CSE API仅允许您搜索图像,而不能按图像搜索.
As far as I know, what you're looking for is only supported by Vision AI service (partially at least, never used it before). Google CSE API only allows you to search images and not by images as you may noticed.
这篇关于Google自定义搜索引擎-按图片搜索的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!