Getting list of items from custom action

Hi,
I’m making a restaurant app where I need to retrieve how many items are still in stock from the restaurant’s Square.
There’s an API, but I cannot get a custom action to retrieve all the items available and their quantity, it only GETs the first item when I create list out of the custom action.

Has anyone managed to make that? (I’ve only seen one post about this here and it did not have an answer for it)

This is what I’m trying to use: GET /v2/inventory/physical-counts/{physical_count_id} - Square API Reference

Happy to buy a solution to this if you post it on nocodeshare.co :slight_smile:

Hi Axel,

I’m not sure a way for getting the all records through a custom action ( maybe @Victor knows :upside_down_face: ) but you can use a External collection.

In the Base URL for the physical count ID you could create a property on the Users collection and use it with magic text.

Did you tried that?

Thank you

Hey @axme,

Well, as I see this API call is designed to return one record. Physical_count_id is a required parameter, according to the docs.
I guess batch retrieve could be done via smth like “Batch retrieve inventory count”. But as I’m seeing this API for the first time in my life, I might be wrong here :))

As a side note: you can retrieve many records using custom action, but you will be able to get values only from the first one.

Best,
Victor.

thank you very much @Victor !
What’s the best way to retrieve all the values from one call? using integromat’s iterator or is there another way to do it inside adalo?
i want to use this API call: POST /v2/inventory/counts/batch-retrieve - Square API Reference

Hey @axme,

I believe you will have to use some external service like Integromat here…

Best,
Victor