Product count using Graphql

Hi @parth-gondaliya and @JoshHighland ,

With the deprecation of the REST Product API, there is also a new GraphQL Admin API query that was released in version 2024-04 that does let you retrieve a count of all your products, though it is limited to returning a maximum of 10,000. The productsCount query doe also have a query filter that you can use to work around the 10,000 count limitation by making multiple queries, for example you can query for all products created before and after a certain date in separate calls to get the full count of your products.

Additionally there is also a variantsCount field on the Product object, to retrieve the amount of variants each product has as well.

I hope this helps, and I hope you have a great day :slightly_smiling_face: