Sparebank1 Factoring (export)

Modified on Thu, 5 Nov at 12:02 PM

How the export works

With the Sparebank1 Factoring export, Project Flow creates files with your finalized invoices and credit notes, and the customers on them, which you send to SpareBank 1 Factoring. You can add the invoice PDFs and EHF files. It is a file export, not a live connection.

  • Two files every time: an invoice file ending in .sb1, and customers.csv with the customers (debtors) on the invoices.
  • Optional: the invoice PDFs and the EHF (XML) files, as separate files.
  • One direction. Nothing comes back from SpareBank 1 Factoring, neither payments nor status.
  • Not the same as Sparebank1 Regnskap. That is a live accounting integration, described in its own article.



Set up the export

Step 1: Add the integration

  1. Go to Setup → Settings → Integrations (Oppsett → Innstillinger → Integrasjoner) and switch to the tab Export to file (Eksport til fil). You need administrator access.
  2. Click + Create integration and choose Sparebank1 Factoring.
  3. Fill in the fields below, tick Enabled and save.

Project Flow plan. The export isn't available on the Start plan. If it has a monthly cost, the form shows it.


Step 2: Sparebank1 Factoring settings

Field (EN / NB)Description
Client ID / Klient-ID for eksport til regnskapssystemYour client number at SpareBank 1 Factoring, which you get from them. It is written first on every invoice line, and in customers.csv. Required.
Invoices (PDF) / Fakturaer (PDF)Under Optional files (Valgfrie filer). Adds the PDF of each exported invoice. Off by default.
Invoices (XML) / Fakturaer (XML)Under Optional files. Adds the EHF file of each exported invoice, if the invoice has one. Off by default.

Use the client ID exactly as SpareBank 1 Factoring gives it. Project Flow doesn't add zeros or check its length.


Step 3: How and when the files are sent

Field (EN / NB)Description
Default invoice issue date limit / Standard sluttdato for fakturaeksportWhich invoices are included, by invoice date: Up to and including last day of previous month, Current date, or No limitations on date (everything that hasn't been exported yet) (default).
Send data to / Send data tilDownload folder (default), Email, FTP / FTPS (also SFTP) or HTTP / HTTPS.
Transfer filesOnly for FTP and HTTP. Manually (default), or Continuously (after each invoice finalization).
Define access / Definer tilgangOnly for manual transfer. Limit who may run the export, by access role or coworker.


Step 4: Prepare Project Flow

The invoice file has fixed positions. A value that is too long moves all the fields after it, and Project Flow doesn't warn you. Check:

  • Customer numbers: numbers only, at most 6 digits.
  • Invoice numbers: at most 6 digits.
  • KID: every invoice needs a KID. Project Flow doesn't check this when you export.
  • Country: every customer needs a country.
  • Departments: if you use departments, the Department number in external system can have at most 2 digits. Invoices without a department get 00.



Run the export

  1. When there are invoices to export, Export to accounting (N) (Eksport til regnskap) appears in the notifications menu (the bell). You need permission to edit invoices, and must be on the access list if one is defined.
  2. Click it, check the invoices to be exported, and choose a To date if your date limit allows it.
  3. Click Export. You get links to the files. With Download folder, they are downloaded right away.
  • What is included: finalized invoices and credit notes that haven't been exported yet, up to the date you choose, in invoice-number order.
  • Customers: the customers of the exported invoices are written to customers.csv in every export, also if they were sent before.
  • After the export: the invoices get the export status Has been transferred.
  • Export again: in the invoice overview, open the cog menu, choose Edit export status (Rediger eksportstatus), set the invoices back to To transfer, and run the export again.
  • Earlier files: in the invoice overview, open the cog menu and choose Exported files (Eksporterte filer).
  • Continuous transfer: with FTP or HTTP and Continuously, each invoice is sent when it is finalized, and the menu item doesn't appear.



The files

Invoice file (.sb1)

  • Named {company}-{id}-to-{date}-at-{time}-spareba.sb1.
  • Fixed width, without separators or a header row. One line per invoice or credit note, with Windows line breaks.
  • Encoding ISO-8859-1.
  • Dates as YYMMDD.
  • Amounts in øre, without decimal separator or sign, for example 00000012345 = 123.45.
FieldLengthContent
Client IDAs enteredThe Client ID from the integration
Customer number6The customer number on the invoice, with leading zeros
Invoice number6With leading zeros
Invoice date6YYMMDD
Due date6YYMMDD
Department2The department's Department number in external system, or 00
Filler100000000000
Transaction type221 invoice, 22 credit note
Amount11Total including VAT, after rounding, in øre
KIDAs on the invoiceThe invoice's KID
Filler16Zeros
Country2The customer's country code, for example NO
Currency3The invoice currency, for example NOK

Example (client ID 383, customer 2241, invoice 1179, amount 123.45, KID 999999):

38300224100117915111915121999000000000021000012345009999990000000000000000ACNOK

  • Credit notes have type 22. The amount has no minus sign.
  • Foreign currency: the amount is in the invoice currency, not converted, and the currency code is at the end of the line.
  • Not in the file: VAT, invoice lines, accounts, project and invoice text.


customers.csv

  • Separated by semicolons, without a header row. Encoding ISO-8859-1.
  • One line per customer on the exported invoices, with the customer's current details.
  • Semicolons in the values are replaced with spaces, and long values are cut.
#ContentMax. length
1A followed by the Client ID, for example A383
2Customer number
3Name35
4–6Address lines 1, 2 and 335 each
7Postal code9
8Postal place35
9Phone13
10Fax13
11VAT number, or the organization number if there is none23
12F
13The customer's bank account number30
14Country code, only if not Norway
15Empty (language)
16Currency, only if not NOK
17E-mail40
18Empty
19Name

The address is the customer's invoice address, or the main address if there is no invoice address.


PDF and XML files

  • With Invoices (PDF), each invoice's PDF is sent as its own file, with the name it has in Project Flow. If Project Flow has a combined PDF for the invoice, with its attachments, that one is used.
  • With Invoices (XML), each invoice's EHF file is sent as its own file. Invoices without an EHF are skipped.
  • The files are sent the same way as the invoice file. They aren't zipped.



Q&A

Q: SpareBank 1 Factoring can't read a line, or the fields are shifted.

A: Check the invoice on that line: customer number and invoice number at most 6 digits, a department number of at most 2 digits, a KID, and a country on the customer. If the line contains the word null, the KID or the country is missing.

Q: The export fails with "Export to sparebank1Factoring failed".

A: Check that all the invoices have a due date. Contact Project Flow support with the invoice numbers if it still fails.

Q: "There are no invoices to export in the specified period."

A: All finalized invoices up to the date are already exported. Choose a later date, or set invoices back to To transfer with Edit export status.

Q: A PDF is missing.

A: Only invoices that have a PDF in Project Flow get one. Generate the PDF on the invoice, set the invoice back to To transfer and export again.

Q: Why are the same customers in every file?

A: Project Flow always includes the customers of the exported invoices, also if they were sent before.

Q: I need to send an invoice again.

A: Set its export status back to To transfer with Edit export status, and run the export again. Or download the earlier files from Exported files.

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article