saveBillingStatement

Set up a recurring billing.

A recurring billing indicates that customer should get a monthly (yearly) invoice for the indicated services, at the indicated price.

After the billing has been set up, recurring invoices need to be manually created and sent from back office Sales → Recurring billing, at the beginning or at the end of a month, as appropriate.

Alternatively, invoices can also be created over API with the saveSalesDocument call, and associated with the billing via the "billingStatementID" field.

Input parameters

Parameter name Description Possible value Required
billingStatementID ID of billing statement. If this parameter is present, then the specified statement is updated. Integer
customerID Customer ID.(Not required if updating an existing statement.) Integer yes
customerAddressID Customer address ID. Integer
payerID Payer ID. Integer
payerAddressID Payer address ID. Integer
employeeID ID of the employee, who is set as the creator of the billing statement. Integer
startDate Start date. ISO date (yyyy-mm-dd)
endDate End date. ISO date (yyyy-mm-dd)
serviceID ID of the service. Integer
productID ID of the product. Integer
customerSpecialPrice Customer special price. Decimal
paymentDays Payment period. Integer
vatrateID ID of VAT (tax) rate. To get the list of rates, use getVatRates.(Not required if updating an existing statement.) Integer yes
currencyCode Currency code: EUR, USD. Currency must be present in the system.
If omitted, default currency will be used.
String
billingStatementPeriod Period of billing statement. Possible values: "MONTH", "QUARTER", "HALFYEAR", "YEAR", "3MONTHS", "4MONTHS".(Not required if updating an existing statement.) String yes
billingStatementTime Time of billing statement. Possible values: "WHEN_PERIOD_STARTS", "WHEN_PERIOD_ENDS", ""BASED_ON_METERED_READINGS".(Not required if updating an existing statement.) String yes
active 0 or 1, by default 1. Integer
sendByEmail 0 or 1. Integer
makeSeparateInvoice 0 or 1. Integer
serviceNameOnInvoices Service name as displayed on invoices. String
notes Notes. String
additionalInvoiceNotes Additional text printed on invoices. String
***** Additional attributes associated with this item.
Attributes must be supplied as a flat list, each attribute defined by the following set of three parameters. Replace # with set number (1, 2, 3, ...). When updating an existing entry, API will only update the attributes specified in input data and leave all other existing attributes unchanged. To delete an attribute, set its value to 'null' or 'undefined'.
attributeName# Attribute name. Name can only contain the following symbols: A-Z, a-z, 0-9, dash and underscore. String
attributeType# Attribute type, possible types are 'text', 'int' and 'double'. By default 'text'. String
attributeValue# Value of the attribute. Set value to 'null' or 'undefined' to delete an attribute.
'text' attribute can be any string, maximum 255 characters.
'int' must be a signed 32-bit integer.
'double' must be a decimal number.
String

Response

Field name Type Description
billingStatementID Integer ID of the created/updated item.