handle:
String! -
A unique string that identifies the product. Handles are automatically
generated based on the product's title, and are always lowercase. Whitespace
and special characters are replaced with a hyphen: `-`. If there are
multiple consecutive whitespace or special characters, then they're replaced
with a single hyphen. Whitespace or special characters at the beginning are
removed. If a duplicate product title is used, then the handle is
auto-incremented by one. For example, if you had two products called
`Potion`, then their handles would be `potion` and `potion-1`. After a
product has been created, changing the product title doesn't update the handle.
Returns
adjacentVariants:
ProductVariant!
A list of variants whose selected options differ with the provided selected options by one, ordered by variant id.
If selected options are not provided, adjacent variants to the first available variant is returned.
Note that this field returns an array of variants. In most cases, the number of variants in this array will be low.
However, with a low number of options and a high number of values per option, the number of variants returned
here can be high. In such cases, it recommended to avoid using this field.
This list of variants can be used in combination with the `options` field to build a rich variant picker that
includes variant availability or other variant information.
availableForSale:
Boolean!
Indicates if at least one product variant is available for sale.
category:
TaxonomyCategory
The taxonomy category for the product.
compareAtPriceRange:
ProductPriceRange!
The compare at price of the product across all variants.
createdAt:
DateTime!
The date and time when the product was created.
description:
String!
Stripped description of the product, single line with HTML tags removed.
descriptionHtml:
HTML!
The description of the product, complete with HTML formatting.
encodedVariantAvailability:
String
An encoded string containing all option value combinations
with a corresponding variant that is currently available for sale.
Integers represent option and values:
[0,1] represents option_value at array index 0 for the option at array index 0
`:`, `,`, ` ` and `-` are control characters.
`:` indicates a new option. ex: 0:1 indicates value 0 for the option in position 1, value 1 for the option in position 2.
`,` indicates the end of a repeated prefix, mulitple consecutive commas indicate the end of multiple repeated prefixes.
` ` indicates a gap in the sequence of option values. ex: 0 4 indicates option values in position 0 and 4 are present.
`-` indicates a continuous range of option values. ex: 0 1-3 4
Decoding process:
Example options: [Size, Color, Material]
Example values: [[Small, Medium, Large], [Red, Blue], [Cotton, Wool]]
Example encoded string: "0:0:0,1:0-1,,1:0:0-1,1:1,,2:0:1,1:0,,"
Step 1: Expand ranges into the numbers they represent: "0:0:0,1:0 1,,1:0:0 1,1:1,,2:0:1,1:0,,"
Step 2: Expand repeated prefixes: "0:0:0,0:1:0 1,1:0:0 1,1:1:1,2:0:1,2:1:0,"
Step 3: Expand shared prefixes so data is encoded as a string: "0:0:0,0:1:0,0:1:1,1:0:0,1:0:1,1:1:1,2:0:1,2:1:0,"
Step 4: Map to options + option values to determine existing variants:
[Small, Red, Cotton] (0:0:0), [Small, Blue, Cotton] (0:1:0), [Small, Blue, Wool] (0:1:1),
[Medium, Red, Cotton] (1:0:0), [Medium, Red, Wool] (1:0:1), [Medium, Blue, Wool] (1:1:1),
[Large, Red, Wool] (2:0:1), [Large, Blue, Cotton] (2:1:0).
encodedVariantExistence:
String
An encoded string containing all option value combinations with a corresponding variant.
Integers represent option and values:
[0,1] represents option_value at array index 0 for the option at array index 0
`:`, `,`, ` ` and `-` are control characters.
`:` indicates a new option. ex: 0:1 indicates value 0 for the option in position 1, value 1 for the option in position 2.
`,` indicates the end of a repeated prefix, mulitple consecutive commas indicate the end of multiple repeated prefixes.
` ` indicates a gap in the sequence of option values. ex: 0 4 indicates option values in position 0 and 4 are present.
`-` indicates a continuous range of option values. ex: 0 1-3 4
Decoding process:
Example options: [Size, Color, Material]
Example values: [[Small, Medium, Large], [Red, Blue], [Cotton, Wool]]
Example encoded string: "0:0:0,1:0-1,,1:0:0-1,1:1,,2:0:1,1:0,,"
Step 1: Expand ranges into the numbers they represent: "0:0:0,1:0 1,,1:0:0 1,1:1,,2:0:1,1:0,,"
Step 2: Expand repeated prefixes: "0:0:0,0:1:0 1,1:0:0 1,1:1:1,2:0:1,2:1:0,"
Step 3: Expand shared prefixes so data is encoded as a string: "0:0:0,0:1:0,0:1:1,1:0:0,1:0:1,1:1:1,2:0:1,2:1:0,"
Step 4: Map to options + option values to determine existing variants:
[Small, Red, Cotton] (0:0:0), [Small, Blue, Cotton] (0:1:0), [Small, Blue, Wool] (0:1:1),
[Medium, Red, Cotton] (1:0:0), [Medium, Red, Wool] (1:0:1), [Medium, Blue, Wool] (1:1:1),
[Large, Red, Wool] (2:0:1), [Large, Blue, Cotton] (2:1:0).
featuredImage:
Image
The featured image for the product.
This field is functionally equivalent to `images(first: 1)`.
handle:
String!
A human-friendly unique string for the Product automatically generated from its title.
They are used by the Liquid templating language to refer to objects.
isGiftCard:
Boolean!
Whether the product is a gift card.
metafield:
Metafield
Returns a metafield found by namespace and key.
metafields:
Metafield!
The metafields associated with the resource matching the supplied list of namespaces and keys.
onlineStoreUrl:
URL
The URL used for viewing the resource on the shop's Online Store. Returns
`null` if the resource is currently not published to the Online Store sales channel.
productType:
String!
A categorization that a product can be tagged with, commonly used for filtering and searching.
publishedAt:
DateTime!
The date and time when the product was published to the channel.
requiresSellingPlan:
Boolean!
Whether the product can only be purchased with a selling plan.
selectedOrFirstAvailableVariant:
ProductVariant
Find an active product variant based on selected options, availability or the first variant.
All arguments are optional. If no selected options are provided, the first available variant is returned.
If no variants are available, the first variant is returned.
tags:
String!
A comma separated list of tags that have been added to the product.
Additional access scope required for private apps: unauthenticated_read_product_tags.
totalInventory:
Int
The total quantity of inventory in stock for this Product.
trackingParameters:
String
URL parameters to be added to a page URL to track the origin of on-site search traffic for [analytics reporting](https://help.shopify.com/manual/reports-and-analytics/shopify-reports/report-types/default-reports/behaviour-reports). Returns a result when accessed through the [search](https://shopify.dev/docs/api/storefront/current/queries/search) or [predictiveSearch](https://shopify.dev/docs/api/storefront/current/queries/predictiveSearch) queries, otherwise returns null.
updatedAt:
DateTime!
The date and time when the product was last modified.
A product's `updatedAt` value can change for different reasons. For example, if an order
is placed for a product that has inventory tracking set up, then the inventory adjustment
is counted as an update.
variantBySelectedOptions:
ProductVariant
Find a product’s variant based on its selected options.
This is useful for converting a user’s selection of product options into a single matching variant.
If there is not a variant for the selected options, `null` will be returned.
variantsCount:
Count
The total count of variants for this product.