Creates a new Invoice for an Invoice Type.
Syntax
long
createInvoiceForInvoiceType
(
long
customerId
,
long
invoiceTypeId
,
Long
amount
,
String
currency
,
String
reference
,
String
alias
,
Long
authorisationThreshold
,
Duration
autoPayDelay
,
Duration
billingCycle
,
Long
defaultPi
,
Map< Integer, String >
attributes
,
Duration
maxDelay
,
Date
startDate
,
Date
endDate
,
long
callerId
)
Parameters
-
customerId –
refers to the customer for whom to create the Invoice
-
invoiceTypeId –
-
amount –
is optional, if not provided the default amount from the Invoice Type is used
-
currency –
is optional, if not provided the default currency from the Invoice Type is used
-
callerId –
The ID of the customer invoking the method
Returns
the Invoice id that was created.
Usage
In case the required InvoiceConfiguration in between is missing, it is created automatically.
the Invoice id that was created.