n8n templates for Danish systems

n8n has lots of ready-made integrations, but none for e-conomic, Dinero, Billy or MobilePay. Everything goes through the HTTP Request node. Here are the building blocks, with real code you can paste straight in.

Last checked:

On this pageWhat this page covers
  1. First: there is no shortcut
  2. 1. CVR lookup with soge.dk
  3. 2. Address cleansing with danadresse.dk
  4. 3. Draft invoice in e-conomic
  5. 4. Contact and invoice in Dinero
  6. 5. MobilePay webhook with a signature check

First: there is no shortcut

We checked on 19 November 2026: n8n has no integration page for e-conomic, Dinero, Billy or MobilePay, and a search on npm for community nodes for them turns up nothing usable. e-conomic, Dinero and Billy are Danish accounting systems, and MobilePay is the Danish mobile payment app. For n8n that means three things:

  • You have to set up the headers, tokens and fields yourself in an HTTP Request node.
  • Keys belong in a credential, not in the URL. We moved tokens out of 36 HTTP nodes in 12 workflows ourselves.
  • You have to build the JSON body correctly yourself. Build it as an object in a Code node or with JSON.stringify, never by concatenating text. That cost us 12 of 207 SMS in a salon reminder workflow, because a \ in a service name broke the JSON.

We have previously built integrations between e-conomic, Google Sheets and SQL for clients. If your flow reads from and writes to Google Sheets, put a 2.5-second wait and 5 retries 5 seconds apart on the Sheets nodes. Otherwise loops hit Google’s per-minute quota.

1. CVR lookup with soge.dk

soge.dk is our own product: a Danish search engine for companies and vehicles with a public API. The endpoint GET /api/v1/checkout/cvr/{cvr} returns name, address, postcode, city, VAT number and status for an 8-digit CVR number (the company number in CVR, the Danish company register). It can be used without a key at 20 lookups a minute and 500 a day per server IP, and with a key in the x-api-key header you get your own quota.

Paste the node straight into n8n (copy it and press Ctrl+V on the canvas):

{
  "nodes": [
    {
      "parameters": {
        "url": "=https://soge.dk/api/v1/checkout/cvr/{{ $json.cvr }}",
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth",
        "options": { "timeout": 10000 }
      },
      "name": "CVR-opslag (soge.dk)",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4.2,
      "position": [400, 300],
      "credentials": { "httpHeaderAuth": { "name": "soge.dk API-nøgle" } }
    }
  ],
  "connections": {}
}

The credential is of the type Header Auth with the name x-api-key. The response has the shape {"data": {"cvr", "name", "address", "zipcode", "city", "vat", "status", "active"}}. Check data.active before you create a customer.

2. Address cleansing with danadresse.dk

DAWA, the public Danish address service, closed on 1 October 2026, and all its old endpoints now answer 410 Gone. danadresse.dk is our own product, a DAWA-compatible API at api.danadresse.dk with the key in the X-Api-Key header. The free plan gives you 2,000 calls a month. In a flow we use POST /datavask/adresser to correct an address from a form before it is passed on:

// Code node, "Run Once for Each Item": prepare address cleansing
// Input from a form: { gade: "Rådhuspladsen", nr: "1", postnr: "1550" }
const f = $json;
return {
  json: {
    vejnavn: String(f.gade ?? '').trim(),
    husnr: String(f.nr ?? '').trim().toUpperCase(),   // "12b" → "12B"
    postnr: String(f.postnr ?? '').replace(/\D/g, '').slice(0, 4),
  },
};

The next node is an HTTP Request (POST, https://api.danadresse.dk/datavask/adresser, Body: JSON with {{ $json }}, credential Header Auth X-Api-Key). Only a certain match should be written back automatically. Send the rest to a person.

3. Draft invoice in e-conomic

e-conomic’s REST API lives at https://restapi.e-conomic.com and requires two headers: X-AppSecretToken and X-AgreementGrantToken. With the value demo in both, you can try GET calls against a demo agreement, but you cannot create anything. Put both tokens in one credential of the type Custom Auth:

{
  "headers": {
    "X-AppSecretToken": "jeres-app-secret",
    "X-AgreementGrantToken": "kundens-grant-token"
  }
}

The flow: Webhook (paid order or booking) → HTTP Request GET /customers?filter=corporateIdentificationNumber$eq:{{ $json.body.cvr }} → Code (below) → HTTP Request POST /invoices/drafts. A draft needs a date, currency, customer number, a recipient with a VAT zone, a layout and payment terms.

// Code node, "Run Once for All Items": build a draft invoice for e-conomic
// .first() instead of .item: robust, also after AI and If nodes
const order = $('Ordre').first().json.body;   // { orderId, cvr, lines: [{ sku, text, qty, unitPriceExVat }] }
const customer = ($json.collection ?? [])[0];

if (!customer) {
  // stop with a clear error instead of creating an empty invoice
  throw new Error(`Ingen kunde i e-conomic med CVR ${order.cvr}`);
}

return [{
  json: {
    date: new Date().toISOString().slice(0, 10),
    currency: 'DKK',
    customer: { customerNumber: customer.customerNumber },
    recipient: {
      name: customer.name,
      vatZone: { vatZoneNumber: customer.vatZone.vatZoneNumber },
    },
    paymentTerms: { paymentTermsNumber: customer.paymentTerms.paymentTermsNumber },
    layout: { layoutNumber: 19 },                 // your layout: GET /layouts
    references: { other: `ordre-${order.orderId}` },
    lines: order.lines.map((l, i) => ({
      lineNumber: i + 1,
      description: l.text,
      quantity: l.qty,
      unitNetPrice: Math.round(l.unitPriceExVat * 100) / 100,   // excl. VAT, 2 decimals
      product: { productNumber: l.sku },
    })),
  },
}];

.first() is not a random choice. In n8n 1.x, an AI Agent can lose the output of the previous node after a tool call, so $('Node').item stops working. .first() or .all()[$itemIndex] is safer. Store the order id in an n8n data table, and skip the order if the id already exists. That way a webhook that arrives twice does not turn into two invoices.

4. Contact and invoice in Dinero

Dinero uses Visma Connect with OAuth 2.0 for integrations that other companies will use. For your own company there is a “personal integration”: Client ID and Secret as Basic Auth, your API key as both username and password, and a token that is valid for one hour. The limit is 60 calls a minute.

# Token for a personal integration (the same call the HTTP Request node makes)
curl -s https://authz.dinero.dk/dineroapi/oauth/token \
  -u "$DINERO_CLIENT_ID:$DINERO_CLIENT_SECRET" \
  -H "Content-Type: application/x-www-form-urlencoded" \
  --data-urlencode "grant_type=password" \
  --data-urlencode "scope=read write" \
  --data-urlencode "username=$DINERO_API_KEY" \
  --data-urlencode "password=$DINERO_API_KEY"
// Code node: body for POST https://api.dinero.dk/v1/{organizationId}/contacts
// Required according to Dinero's OpenAPI: Name, CountryKey, IsPerson, IsMember, UseCvr
const c = $('CVR-opslag (soge.dk)').first().json.data;
return [{
  json: {
    Name: c.name,
    Street: c.address,
    ZipCode: c.zipcode,
    City: c.city,
    CountryKey: 'DK',
    VatNumber: c.cvr,
    IsPerson: false,
    IsMember: false,
    UseCvr: true,
  },
}];

The invoice is created with POST /v1/{organizationId}/invoices, where ProductLines is required. Each line must have BaseAmountValue, Quantity, AccountNumber and Discount. Use your own sales account from your chart of accounts.

If you only want to read data from e-conomic, Dinero and Billy through one API, we have built jakonto.dk, our own product. It reads from all three today, but does not yet write orders into the systems. If you need a shop and an accounting program connected as a finished solution, see integration.best-choice.dk.

5. MobilePay webhook with a signature check

Vipps MobilePay signs webhooks differently from Meta. The x-ms-content-sha256 header is a base64 SHA-256 of the raw body. The signature is HMAC-SHA256 in base64 of the text POST\n<path>\n<x-ms-date>;<host>;<hash>, and you receive the secret when you register the webhook.

The flow: Webhook (POST, Raw Body) → Code (below) → Crypto Hash SHA256 base64 of {{ $json.raw }} into bodyHash → Crypto Hmac SHA256 base64 of {{ $json.stringToSign }} into sig, with the secret in a Crypto credential → If → 200 or 403.

// Code node, "Run Once for All Items": prepare the MobilePay signature check
const item = $input.first();
const h = item.json.headers;
const raw = (await this.helpers.getBinaryDataBuffer(0, 'data')).toString('utf8');

// the path MobilePay called – register the webhook URL without a query string
const path = new URL(item.json.webhookUrl).pathname;
const stringToSign = `POST\n${path}\n${h['x-ms-date']};${h['host']};${h['x-ms-content-sha256']}`; // LF, not CRLF

// reject old messages (our own extra requirement, not MobilePay's)
const ageMin = (Date.now() - Date.parse(h['x-ms-date'])) / 60000;

return [{
  json: {
    raw,
    stringToSign,
    headerHash: h['x-ms-content-sha256'] ?? '',
    authorization: h['authorization'] ?? '',
    fresh: Number.isFinite(ageMin) && Math.abs(ageMin) < 5,
  },
}];

The If condition: {{ $json.fresh && $json.bodyHash === $json.headerHash && $json.authorization === 'HMAC-SHA256 SignedHeaders=x-ms-date;host;x-ms-content-sha256&Signature=' + $json.sig }}. We use the same pattern on all our Meta webhooks, where tampered messages get a 403. The If node does not compare in constant time. If you need that, move the comparison into a Code node with crypto.timingSafeEqual.

Sources

Last reviewed: 2026-12-03

Questions about n8n and Danish systems

Is there an n8n node for e-conomic?

No. Neither n8n nor the community has a node for e-conomic, Dinero, Billy or MobilePay as of 19.11.2026. You use the HTTP Request node with a credential.

Can n8n do CVR lookups?

Yes, with an HTTP Request against a CVR API. soge.dk, our own product, can be used without a key for a few lookups and with a key for more.

Can we test against e-conomic without touching our accounts?

Yes, partly. Tokens with the value demo give read access to a demo agreement. To create drafts, you need a separate test or developer agreement with e-conomic, not your real accounts.

How do we avoid duplicate invoices?

Store the order or booking id before the invoice is created, and stop the flow if the id already exists. Webhooks can arrive more than once.

Fixed price, no commitment

Get a fixed price for your n8n task

Tell us briefly what you use today and what you want to achieve. A person answers by e-mail with a proposal and a fixed price before any work starts.

  • A fixed price before we start
  • An answer by e-mail, no calls
  • Your details are used only to answer you

Fields marked with * are required.

What is it about?