How to update quantityAvailable of a product in an inventory via API?

this inventory item will decrease from 10 (for example) to 9, I mean we are decreasing its quantity by 1, not setting it to 1, right? And after that openboxes will automatically create a transaction?

Correct. But we can also create an API that will allow you to adjust the transaction by telling us what the current Quantity on Hand for an inventory item and we’ll create the adjustment transaction.

But until this API is implemented I need to use Transaction API or Stock Transfer API to create transactions myself, correct?

Correct.

Using the generic Transaction API would basically be the same as above but would require two API requests (one to create the transaction header and another to create the transaction entry for each item).
In other words, the only difference between the two is that the streamlined API above would basically merge those two requests into a single request.

Using the Stock Transfer API would be a hack that allows you to move quantity from available to unavailable like you can do using either of the transfer features available from the UI.

The end result would look something like this.