Accounting documents

The accounting document is usually part of a document.

Attributes of accounting documents

In the first step a document is classified. A classification can be i.e. receipt, income_statement or dunning. Only a subset of an accounting document warrant extraction of financial data. Based on its classification a document will have varying attributes reflecting the content.

As soon as the document has been processed, information on the document is available along with further data (if the document is among those documents with additional extraction). Accounting documents are in general readonly and will not be specified any further.

General receipt attributes

type String This specifies a specific type of receipt according to this list.
invoice_date Date Issue date of the invoice
delivery_date Date Date of delivery
number String Invoice number
order_number String PO numbers, Order number etc…
currency String 3 letter ISO Code of the currency
including_tax Boolean Indicates if invoice line item prices are including or excluding tax.
items Array List of line items (see below).
payment_conditions Array List of payment conditions (see below).
bank_accounts Array List of bank accounts (see below).
payment_method String If it has been paid, this is the payment method (see below).
amount_total Float Gross total of the invoice
reference String Reference number

Invoice line items

Line items are added to the field items. It is an array of objects with the following fields.

title String The title of the line item.
amount_total Float The total of the line item.
nominal_account String A reference to the internal nominal account.
tax_rate Float This is the tax rate of the line item.

Payment method

The attribute payment_method holds one of the following, if the document relates to an already completed payment:

maestro Maestro / PostFinance
creditcard Credit Card
paypal Paypal
stripe Stripe
vpay V PAY
direct_debit LSV
bank_transfer Wire Transfer
cash Cash
other Other

Bank accounts

If bank accounts have been found, they are added to the field bank_accounts. It is an array of objects containing these fields:

iban String IBAN
bic String BIC
account_number String Account number

Payment conditions

There is a defined set of available payment conditions. This is an array containing individual conditions which are stored as objects in the field payment_conditions.

Potential attributes of payment conditions:

percentage Integer Amount of percentage between 0 and 100.
fixed_price Float Fixed amount as a decimal number.
number_of_days Integer Number of days until the payment is due.
date Date Specific date until when the payment is due.

Payment conditions:

Type of condition Used attributes  
payment_condition number_of_days, date Due date of the invoice.
cash_discount percentage, fixed_price, number_of_days, date Cash discount including amount and date.
wir percentage, fixed_price Amount of swiss currency WIR.
installment percentage, fixed_price, number_of_days, date Installment settings including amount and date.
prepayment none Invoice has to be paid upfront.