Export accounting/row information

In Next there are two different ways of handling the accounting information on the invoice that is needed for updating the accounts receivable and the ledger in the accounting system:

  • Without revenue recognition
  • With revenue recognition

📘

Revenue recognition has also been called "invoice accounting" and the Swedish term for both are "intäktskontering"

Setup without revenue recognition in Next

  1. The customer will create one or more articles (also called products or items) in the accounting system to be used by the integration. The article will hold information such as which revenue account should be used when the invoice is booked.
  2. All reported time, material and other costs booked against a project will be connected to a cost account in the chart of accounts in Next. For each cost account it is possible to register an external article number (created above) and an external vat code in the account master data registry in Next.
  3. When the invoice is generated all invoice rows will hold information about the cost account and can for example be fetched using the customerinvoice/rows/ endpoint. That account can then be used to fetch the invoicearticleno and vatcode e.g. from the /account/ endpoint. These values can then be used when posting to the accounting system via the integration.

Setup with revenue recognition in Next

Endpoints

When revenue recognition is activated it is possible to set up rules inside Next to decide which revenue- and balance accounts should be used when generating invoices. This can be done under Admin/Accounting/Revenue recognition/Revenue recognition rule in Next UI

With this setup, the customerinvoice/row endpoint is of less interest from an integration perspective. Instead it is the endpoints customerinvoice/accounting and customerinvoice/specification that should be used.

When a customer invoice is generated, the accounting endpoint will hold information about the information needed for updating the ledger while the specification endpoint will hold information that can be used to generate invoice rows in the accounting system. However, the invoice specification data is primarily developed for the Swedish market in order to handle tax reduction invoices (see separate page) hence it might not be of interest in other markets.

Accounting row types

In the customerinvoice/accounting endpoint there will be three types of rows corresponding to the rows presented in Next UI under Invoice/Revenue recognition/Show accounting result:

  • Revenue rows with account no and the dimensions that have been ticked in Next UI under Admin/Accounting/Revenue recognition/Revenue recognition dimension .
  • Vat rows with turnover and turnover account no. Account no is fetched from the Vat table under Admin/Accounting/Vat. vat field will always be true for these but they will never have a project.
  • Account receivable rows with account no and the dimensions that have been ticked under Revenue recognition dimension. The debit field will always be true for these rows.

To only fetch revenue rows, create a filter string for rows where debit==false and vat==false.