How Do I Query Available Filters - GraphQL Admin API

How Do I Query Available Filters - GraphQL Admin API

drmartin1998
Visitor
1 0 0

I'm attempting to query the available filters for products in a collection by following step 3 here: https://shopify.dev/docs/custom-storefronts/building-with-the-storefront-api/products-collections/fi...

 

I'm receiving an error that "Cannont query field filters on type ProductConnection" when I attempt to run the query listed on that page.

 

 

 

query Facets {
  collection(handle: "filterable-collection") {
    handle
    products(first: 10) {
      filters {
        id
        label
        type
        values {
          id
          label
          count
          input
        }
      }
    }
  }
}

 

 

 

 

Replies 0 (0)