Getting All Open Deliveries

Hello everyone, time for another question :slight_smile:

I am trying to generate a List with all open Orders which have not been fully delivered yet. Usually this would not be a problem, however there does not seem to be any keys connecting Commandes and Expeditions (Orders and Deliveries). On the commande page there is the linked object section which actually shows any deliveries but I can not for the love of God find in the source code how this is done. I also think there has to be a much easier way to be able to just querry this information from the Database which I have missed. Any help would be aprpeciated.

The links are in the llx_element_element, see https://wiki.dolibarr.org/index.php/Table_llx_element_element
There is currently no REST API for this, it would be nice to have.