Product Search API
The Product Search API gives the UI Extension access to the native product search and fetching functionality of Shopify POS. The interface provides numerous functions to search for products by query, or to fetch the details of one or more products or product variants.
Searching for productsAnchor link to section titled "Searching for products"
The following example shows how a UI Extension can use the
searchProducts method to easily access search results based on a
queryString passed in the ProductSearchParams object.
Product search and fetch methodsAnchor link to section titled "Product search and fetch methods"
The following functions allow your UI Extension to fetch products and variants using various input types.
Search for products using a queryAnchor link to section titled "Search for products using a query"
||The search parameters for the search query.|
Fetch a product's detailsAnchor link to section titled "Fetch a product's details"
||The ID for the product details to fetch.|
Fetch multiple products' detailsAnchor link to section titled "Fetch multiple products' details"
||The IDs belonging to the products to fetch. This function returns a maximum of 50 products, so any IDs after the 50th in the array will be ignored.|
Fetch a product variant's detailsAnchor link to section titled "Fetch a product variant's details"
||The ID for the product variant details to fetch.|
Fetch multiple product variants' detailsAnchor link to section titled "Fetch multiple product variants' details"
||The IDs belonging to the product variants to fetch. This function returns a maximum of 50 product variants, so any IDs after the 50th in the array will be ignored.|
Fetch all product variants belonging to a productAnchor link to section titled "Fetch all product variants belonging to a product"
||The product ID for whose product variants should be fetched.|
ProductSearchParamsAnchor link to section titled "ProductSearchParams"
||The search term to be used to search for POS products.|
||Specifies the number of results to be returned in this page of products. The maximum number of products that will be returned is 50.|
||Specifies the page cursor. Products after this cursor will be returned.|
||Specifies the order in which products should be sorted. When a
||The unique Shopify ID for the product.|
||The date that the product was created.|
||The date that the product was last updated.|
||The title of the product.|
||The description of the product.|
||The description of the product with HTML formatting.|
||The URL where the product image can be found.|
||Whether the product is a giftcard.|
||Whether the product's inventory is tracked.|
||The name of the product vendor.|
||The price of the least expensive variant belonging to the product.|
||The price of the most expensive variant belonging to the product.|
||The type of product.|
||The product's category.|
||The tags associated with the product.|
||The total number of variants tied to this product.|
||The total inventory available for this product at the current location.|
||The total inventory available for this product across all locations.|
||The variants associated with this product.|
||The different options for this product.|
||Whether the product has only a single default variant.|
||Whether any variants are in stock at the current location.|
ProductVariantAnchor link to section titled "ProductVariant"
||The unique Shopify ID for the variant.|
||The date that the variant was created.|
||The date that the variant was last updated.|
||The title of the variant.|
||The comparison price point.|
||Whether the variant is taxed.|
||The SKU belonging to the variant.|
||The barcode belonging to the variant.|
||A combination of the product and variant's names.|
||The variant image's URL.|
||Whether the variant's inventory is tracked.|
||The number of variants stocked at the current location.|
||The number of variants stocked at all the locations.|
||Whether any other variants belonging to the product are in stock.|
||The options associated with the variant.|
||The product associated with the variant.|
||The product ID associated with the variant.|
||The variant's position in the list of variants associated with the product.|
ProductOptionAnchor link to section titled "ProductOption"
||The unique Shopify ID for the product option.|
||The name of the product option.|
||The possible options.|
||The ID of the product associated with the option.|
ProductVariantOptionAnchor link to section titled "ProductVariantOption"
||The name of the variant option.|
||The value of the option.|