截至 2024-10 版本的 GraphQL Admin API,新增了一个名为 collection _id 的筛选器, collection_id用于 products 查询。此筛选器允许您检索属于特定集合的产品。
使用collection_id筛选器时,它可以与以下筛选器结合使用:
- created_at
- updated_at
- published_at
- gift_card
- handle
- combined_listing_role
- product_type
- status
- title
- vendor
如需了解 products 查询所有可用属性的详细信息,请访问 shopify.dev 上的 Shopify 开发者文档 products 查询,请访问 Shopify 开发者文档 位于 shopify.dev。
collection_id筛选器在查询中的示例用法如下:
{ products(query: "collection_id:1234567890") { edges { node { id title } } } }此查询从ID为1234567890的集合中检索产品。

