There might be a way to do this, but need to look this up.
as a fast and simple solution you could create several versions of your shop. 1 with the items and the other without, and simply replace it. But this might not work well if you have many items and can remove more than 1 or 2 items. This would need like 20 shops you need to replace with every possible solution that can be achieved.
So if you only want to remove the same item all the time, it's easy to do 2 shops, and replace it with the shop that doesn't have the item in storage.