Happy Business Starts Here

Extend SOAP API Generate() and Subscribe() with option to create invoice(s) in draft or posted state

Can you align SOAP API generate() and subscribe() calls so that both calls have the same set of invoice creation options.

In the currently implementation both calls have different invoice creation behavior. For instance the subscribe() will create the invoice in the posted state while the generate() call will create invoices in the draft state. The subscribe call can work on both subscription and account level while the generate() call only works on account level.

It would be nice if both call offer the same set of invoice generation options as it gives us a hard time to create the work-around for issue #48408. That is in order to update the custom fields on a invoice prior to posting. As the subscribe() call will post the invoice directly we have to the use the generate() call to generate the invoice in draft state so the custom fields and invoice PDF are updated prior to posting. Unfortunately the generate() call will only work account level and can thus generate multiple invoices, works async and only returns the invoice id of the first invoice created. This gives the business layer a hard time as it requires the invoice for the subscription created prior with the subscribe() call. This forces the BL to regularly poll the invoiceitem table to check whether items have been created for the given subscription ( as the generate() call is async )

So please 
- Extend the subscribe() call with a parameter to indicate whether the invoice should be set to the draft of posted state 
- Extend the generate() call with a parameter to indicate whether the invoice should be set to the draft of posted state 
- Extend the generate() call with a parameter that indicates on which level it should work: acccount or subscription level

Thanks 

3 Comments
Community Manager
Status changed to: More Feedback Needed
 
Tutor
Community Manager
Status changed to: Under Consideration