productsBySku
Retrieve specific products by their SKU values
Arguments
| Argument | Type | Description |
|---|---|---|
skus | [String!]! |
Returns
[Product!]!
| Field | Type | Description |
|---|---|---|
id | ID! | Unique identifier for the product |
slug | String! | URL-friendly slug for the product |
localizedSlugs | [LocalizedSlug!]! | Localized slugs for different localesArguments: locales |
name | String! | Name of the product |
meta | ResourceMeta | Metadata for the product |
brand | String | Brand of the product |
image | ProductImage | The primary image associated with the product. |
relatedProducts | [Product!] | Products that are similar. E.g. the same t-shirt in another color. |
variant | ProductVariant! | A specific variant, often used to show data in a product card. If no sku is given then the primary variant is returned.Arguments: sku |
variants | [ProductVariant!]! | A list of all variants, often used to show all available options in a product detail page.Arguments: sku |
variantDimensions | [ProductVariantDimension!]! | Product variant dimensions for the product with selection optionsArguments: selectedSku |
categories | [ProductCategory!] | The categories to which the product belongs. |
primaryCategory | ProductCategory | The primary category to which the product belongs. |
startingPrice | TaxedPrice | The lowest price of all variants, often used to communicate the price on the product list page. |
reviews | Reviews | Customer reviews for the product |
bundle | ProductBundle | The products sold with this one as a bundle, added together with cartBundleAdd. Null when the product has none that can be bought now. |
breadcrumbs | [Breadcrumb!] | |
articles | [Page!] | Published pages about the product's primary category, or else about its nearest ancestor: the most specific category first, then the newest first. Nullable, so a content service that cannot answer leaves the product intact. |
reviewDistribution | [ProductReviewRatingCount!]! | How many approved reviews gave each rating, from 5 down to 1, including ratings nobody gave |
reviewFitDistribution | [ProductReviewFitCount!]! | How many approved reviews found the size each way, in the order of ProductReviewFitType, including ways nobody chose. All zero where buyers are not asked. |
reviewList | ProductReviewResult! | The approved reviews of the productArguments: page, pageSize, rating, sort |
Example
query { productsBySku(skus: ["SKU-001", "SKU-002", "SKU-003"]) { id slug name variant { id sku price { gross { centAmount currency } } images { url alt } } }}{ "data": { "productsBySku": [ { "id": "id-1", "slug": "/example", "name": "Example", "variant": { "id": "id-1", "sku": "SKU-1", "price": { "gross": { "centAmount": 1, "currency": "EUR" } }, "images": [ { "url": "https://example.com/", "alt": "Example" } ] } } ] }}The query is the example the schema documents. The response shows its shape with placeholder values.
Served by
| @evolve-framework/commercetools | Resolved |
| @evolve-framework/medusa | Resolved |
| @evolve-framework/sfcc | Resolved |
Used by
The storefront packages that send it, in these GraphQL documents:
- @evolve-storefront/feature-cart:
GetQuickOrderVariants

