Managing Products and Reference Images

Product Search has three resource types: product sets, products, and reference images.

  • Product Set - A container for a group of products with reference images for those products. When you query for product images, you must supply the id of the product set to search.

  • Product - Describes a product. Contains one or more reference images, a product category, and optional list of product labels that describe the product. You can add any key/value pair as a label. Label examples include color=blue, style=kids.

    Currently supported product categories are: homegoods and apparel

  • Reference Image - An image file for a product. The metadata includes a product ID, a category, and bounding box details. Reference images must belong to a product.

The API contains methods for creating, listing/getting, updating, and deleting product sets, products, and reference images.


Cloud Vision API product search supports both API key and OAuth 2.0 authentication.

If you use an API key when creating your reference images, the image files in Google Cloud Storage must be publicly readable. Private files are supported when using OAuth 2.0, provided the service account has read access.

For instructions on authenticating with either method, refer to Authenticating to a Cloud Service in the Cloud Vision API docs.

Client Libraries

The samples in this topic use the Beta Client Libraries. Be sure to install the client library before running the samples in this topic.

Was this page helpful? Let us know how we did:

Send feedback about...

Cloud Vision API
Need help? Visit our support page.