GraphQL Admin API Get product count, excluding products published to a channel

I use GraphQL Admin API to get the number of products

I use the product statistics api posts_status:approved

But the number of products that do not select channels cannot be excluded

I have the same issue

I use the GraphQL Admin API 2024-10 version to filter by the publication_ids parameter, which can filter channels. The channel acquisition interface is https://shopify.dev/docs/api/admin-graphql/2024-04/queries/publications

1 Like