question

Sean avatar image
Sean asked rachel Deactivated commented

Getting total items count of merchant inventory

I wonder how to get the total amount of items I currently have in my merchant's inventory, through the API. Is there a specific endpoint to use to get this data?

Inventory
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

rachel avatar image
rachel Deactivated answered rachel Deactivated commented

Hi @seanmichaelpiettojogmailcom,

There isn't an endpoint that returns the total number of items currently in inventory per se; you'd need to use the v3/merchants/{mId}/items endpoint to get all items and then count them.

2 comments
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Sean avatar image Sean commented ·

Thank you for the response Rachel. I marked this as the right answer, as I also didn't find any way to do this.

Wonder though, what would you do, if the merchant's inventory is way over the hundreds? Getting all of the item first then count them later, seem to be the worst possible way to do that, isn't it?

1 Like 1 ·
rachel avatar image rachel commented ·

Hi @seanmichaelpiettojogmailcom,

What about using the offset and limitquery parameters to split the results into chunks? https://docs.clover.com/build/web-api...

0 Likes 0 ·

Welcome to the
Clover Developer Community