Generate
From API Documentation
Generate is used to generate an invoice for a given account. Similarly to an ad hoc bill run for a single customer account, you can now create an invoice on demand via the API.
Note: generate() is only available in versions 11.0 and greater of the Z-Commerce API.
Using The Generate Call
Call generate() to create a single invoice for a given customer account. It returns a GenerateResponse object, indicating success of the call.
Examples
To generate an invoice for an account, include all charge types:
<ns2:generate> <ns2:zObjects xsi:type="ns1:Invoice"> <ns1:AccountId>8a8ae4b122561fc00122562fbc3d0002</ns1:AccountId> <ns1:IncludesOneTime>True</ns1:IncludesOneTime> <ns1:IncludesRecurring>True</ns1:IncludesRecurring> <ns1:IncludesUsage>True</ns1:IncludesUsage> <ns1:InvoiceDate>2011-07-07T08:07:55-08:00</ns1:InvoiceDate> <ns1:TargetDate>2011-07-07T08:07:55-08:00</ns1:TargetDate> </ns2:zObjects> </ns2:generate>
The above call will generate an invoice for account with ID=8a8ae4b122561fc00122562fbc3d0002 for the date July 7, 2011, and include all charge types.
