Skip to content

From my practice · Software

Efremtid AS, EHF e-invoices

Our own gateway for sending and receiving EHF e-invoices

since 2015EHF invoices from e-faktury.no, through our own access point
Illustration: Aleksander next to a server rack, invoices fly like paper planes from a laptop through a gateway to a second laptop
Project
Efremtid AS, the efirma.no and e-faktury.no software
Technology
Java 21, Spring Boot, phase4, Docker, AWS S3
Scope
Sending, receiving and reporting EHF e-invoices

Situation

The invoicing software e-faktury.no has been sending EHF invoices since January 2015, through Efremtid AS's own access point in the Peppol network. In 2026 we rebuilt the gateway from scratch: ahead of the B2B e-invoicing requirement from 2027, with new Peppol certificates and mandatory reporting.

How we solved it

  1. Requirements

    Peppol BIS Billing 3.0, the AS4 protocol, new-generation Peppol certificates, statistical reports for OpenPeppol and storing invoices for 5 years.

  2. AS4 gateway

    Java 21, Spring Boot and the phase4 library, behind an nginx server with TLS, in separate Docker containers for test and production.

  3. Sending

    The software hands over the invoice through an API, and the gateway queues it in a database and retries until the recipient confirms.

  4. Receiving

    Incoming invoices go straight to AWS S3, from where the recipient's accounting software picks them up.

  5. Reports and tests

    The gateway builds and checks the reports for OpenPeppol itself, and passes certification tests through a separate module.

Detailed analysis

Where the project came from

e-faktury.no has been running since 2012, and since January 2015 it has been sending EHF invoices, then required mainly by public bodies. Efremtid AS runs its own access point in the Peppol network, so users of the software send EHF with no extra fees.

From 1 January 2027 businesses in Norway invoice each other electronically, so not only invoices to public bodies but all B2B invoices will go through the network. On top of that, Peppol is moving to new certificates and requires regular reports from access points. Instead of patching the old gateway, we built a new one in 2026.

Architecture

The gateway is a Java 21 application on Spring Boot. The AS4 protocol, which Peppol access points use to exchange documents, is handled by the open-source phase4 library. An nginx server with a TLS certificate sits in front of the application, and everything runs in Docker containers: separate ones for test and production. Configuration and keys live in AWS Systems Manager, not in the code.

  • Sending: efirma.no and e-faktury.no hand over the invoice through a token-protected API. The gateway stores it in a queue in the database (the outbox pattern) and sends it in the background, retrying until the recipient's access point confirms receipt.
  • Receiving: an incoming document goes straight to AWS S3 in the Stockholm region, from where the recipient's accounting software picks it up. Nothing is lost, even when the software is briefly unavailable.
  • Reporting: the gateway builds the mandatory statistical reports for OpenPeppol itself, checks them locally before sending and can rebuild missing reports from history.
  • Testing: a separate module handles Peppol certification tests, and we analysed the migration to new-generation certificates before the switch.

Releases without risk

Every change goes automatically to the test container first. We release to production only manually, as a deliberate decision, because real client invoices go through the gateway.

Why our own gateway and not an intermediary

An intermediary charges a fee for every document. Your own access point costs a fixed annual OpenPeppol fee and a server. The server would be needed anyway, because the software needs its own API for sending invoices even when it sends them through an intermediary. So the difference is the OpenPeppol fee and the work on the gateway.

With an intermediary fee of about €0.17 per document, your own gateway pays off above roughly 11,000 documents a year, or 900 a month. From 2027, when all B2B invoices go through Peppol, that threshold is left far behind. On top of that, we have full control over sending and do not depend on an intermediary's prices or outages.

Costs: intermediary or our own gateway

Annual estimate for a company with up to 50 people. OpenPeppol fees from the 2026 price list for an access point only, intermediary fee from the eConnect price list, server estimated.

  • Fee per document

    Through an intermediary: about €0.17 for each invoice sent

    Our own gateway: €0

  • Annual OpenPeppol fee

    Through an intermediary: €0

    Our own gateway: €1,850

  • One-off at the start

    Through an intermediary: €0

    Our own gateway: €1,050 sign-up and €1,500 for certification

  • Server with an API for sending

    Through an intermediary: needed anyway, about €300 a year

    Our own gateway: the same server, about €300 a year

  • Break-even point

    Through an intermediary: not applicable

    Our own gateway: about 11,000 documents a year

Above about 900 invoices a month our own gateway is cheaper, and from 2027 traffic grows with every company that has to issue EHF.

Result

Efremtid AS has its own certified OpenPeppol access point. Users of efirma.no and e-faktury.no send and receive EHF directly from the software, with no intermediary and no extra fees, and the new gateway is ready for the e-invoicing requirement from 2027.

since 2015

EHF invoices from e-faktury.no, through our own access point

Illustration: an invoice with a check mark lands in an inbox tray

OpenPeppol fees from the 2026 price list, intermediary fee from the eConnect price list, server cost estimated.

This is your situation if

  • Your company or your software must send and receive EHF e-invoices from 2027.
  • You want invoices to reach your accounting software without retyping.
  • You are looking for someone who knows both the rules and the technology.

Have a similar matter?

Aleksander Mariański, Authorised accountant in Norway, PhD in computer science

Book a consultation on a similar matter