Grouped product data types
The GroupedProduct
data type implements ProductInterface and PhysicalProductInterface. As a result, attributes that are specific to grouped products can be used when performing a products query. It also implements RoutableInterface.
Sample query
The following query returns information about downloadable product 24-WG085_Group
, which is defined in the sample data.
Copied to your clipboard{products(filter:{sku: {eq: "24-WG085_Group"}}){items {uidnamesku__typename... on GroupedProduct {items{qtypositionproduct{skuname__typenameurl_key}}}}}}
Copied to your clipboard{"data": {"products": {"items": [{"uid": "NDU=","name": "Set of Sprite Yoga Straps","sku": "24-WG085_Group","__typename": "GroupedProduct","items": [{"qty": 0,"position": 0,"product": {"sku": "24-WG085","name": "Sprite Yoga Strap 6 foot","__typename": "SimpleProduct","url_key": "sprite-yoga-strap-6-foot"}},{"qty": 0,"position": 1,"product": {"sku": "24-WG086","name": "Sprite Yoga Strap 8 foot","__typename": "SimpleProduct","url_key": "sprite-yoga-strap-8-foot"}},{"qty": 0,"position": 2,"product": {"sku": "24-WG087","name": "Sprite Yoga Strap 10 foot","__typename": "SimpleProduct","url_key": "sprite-yoga-strap-10-foot"}}]}]}}}