Finds pages that show the same or a similar image, and names what the image shows when that is known. Send a public http(s) URL of a JPEG, PNG, WebP or GIF of at most 10 MB, or a data:image/...;base64, URL of at most 5 MB.
What is charged
Charged when at least one result comes back. An image that cannot be loaded or decoded returns 400 invalid_image and is free.
Units: lens. usage.items in the response lists them.
Request
POST https://api.websearch.fast/v1/web/lens
Planned. Until it ships, calls return 501 api_not_implemented.
Body
Name
Type
Description
image_urlrequired
string
Public http(s) URL (JPEG, PNG, WebP, GIF, at most 10 MB) or data:image URL (at most 5 MB).
q
string
At most 256 characters.
country
string
ISO 3166-1 alpha-2 country code, case-insensitive.
Billable unit, for example search_web, content_page, fetch_page, geocode, autocomplete, knowledge.
countrequired
integer
cache
object
Show fields
Name
Type
Description
hitrequired
boolean
The response, or every page in it, came from a stored copy.
data_age_secondsrequired
integer
Age of the oldest part of the response.
fetched_atrequired
integer
Unix seconds when the oldest part was read.
warnings
array of object
Show fields
Name
Type
Description
coderequired
string
For example no_results, content_partial, answer_unavailable, partial, all_failed, reach_reduced.
message
string
param
string
resultsrequired
array of object
Show fields
Name
Type
Description
positionrequired
integer
1-based rank across pages. At least 1.
titlerequired
string
urlrequired
string
Real destination URL, never a redirect link.
domainrequired
string
Host of url, lowercase, without www.
snippet
string
At most 400 characters.
published_at
string
ISO 8601 UTC, when known.
site_name
string
The publisher's own name, when known.
originrequired
string
Our neutral label of how the result reached you. New values can appear. One of index, live, open_data.
image_url
string
thumbnail_url
string
price
object
Show fields
Name
Type
Description
amount
number
currency
string
ISO 4217.
textrequired
string
entities
array of object
Show fields
Name
Type
Description
namerequired
string
kind
string
Errors
Status
Codes
400
invalid_request, invalid_url, invalid_schema or invalid_image. Not charged.
401
invalid_token. Not charged.
403
pre_consume_token_quota_failed (the key's own spending limit), access_denied, web_not_allowed or model_not_in_plan (customer keys while plans cannot include the web tools). Not charged.
404
not_found or invalid_endpoint. Not charged.
413
read_request_body_failed: the request body is over the limit. Not charged.
429
rate_limited, concurrency_limited, api_key_temporarily_frozen, or the failure guard. Not charged.
500
internal_error. Not charged.
501
api_not_implemented: the endpoint, type or option has not shipped. Not charged.
503
source_unavailable, web_api_disabled, token_cache_busy or billing_busy (the charge could not be prepared in time; retry after Retry-After). Not charged.