Create a Sales Invoice and use the Slim API to GET that invoice - you will get the json value. Form your new Invoice in json accordingly and use the PUT endpoint to inject your invoice. Putting in such an invoice will not have the Sales Order, Sales Delivery and Customer Payment that would need to have their own PUT requests in place (or does it?).
I'm sure you can now parse the code and determine what you need. The community has put in sufficient effort in double quick time to assist you among others. Hopefully you too will contribute tested code to it once you get familiar.
This is what makes Open Source tick.
