E-Invoice API
API referenceTemplates

Render an invoice with a template → Factur-X PDF

The body is the invoice JSON — exactly what `/e-invoice/invoice2XML` accepts, with the line items under `zfitems`. Amounts are passed to the engine digit for digit as you sent them. The engine computes every total from the line items (totals in the body are not used), renders the template to PDF/A-3 and embeds the EN 16931 CII XML as `factur-x.xml`. A line whose VAT amount needs more than two decimals (for example 2.5 × 30.50 at 19 %) is refused by the engine with `422 RENDER_REJECTED` and the message `Rounding necessary`. Counted against your quota like any engine call.

POST
/e-invoice/templates/{id}/render

Authorization

AuthorizationBearer <token>

Your API key as a bearer token: Authorization: Bearer of_live_…. An of_test_ key uses the sandbox — same URL, same templates.

In: header

Path Parameters

id*string

Template id (UUID), from the list. An unknown id — or one that is not a UUID — is a 404.

Formatuuid

Query Parameters

language?string

DE, EN or FR, passed to the engine. It only selects the words the {{#UNIT}} helper prints; the engine's number and date helpers print the same way in every language, and the template's own labels decide the language of the document.

Default"DE"

Value in

  • "DE"
  • "EN"
  • "FR"

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

The invoice, in the shape /e-invoice/invoice2XML accepts (CalculatedInvoice in the Documents API): number, currency, issueDate, dueDate, sender, recipient, zfitems[] with price, quantity and product, plus any references, notes, payment terms and bank details. Totals may be present but are recomputed by the engine. At most 1 MiB.

Response Body

application/octet-stream

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/e-invoice/templates/497f6eca-6276-4993-bfeb-53cbbbba6f08/render" \  -H "Content-Type: application/json" \  -d '{    "number": "RE-2026-0042",    "currency": "EUR",    "issueDate": "2026-09-25",    "dueDate": "2026-10-09",    "sender": {      "name": "Muster GmbH",      "street": "Hauptstraße 12",      "zip": "10115",      "location": "Berlin",      "country": "DE",      "vatID": "DE123456789",      "bankDetails": [        {          "iban": "DE02120300000000202051",          "bic": "BYLADEM1001",          "accountName": "Muster GmbH"        }      ]    },    "recipient": {      "name": "Beispiel AG",      "street": "Musterweg 7",      "zip": "80331",      "location": "München",      "country": "DE"    },    "paymentTermDescription": "Zahlbar bis 09.10.2026.",    "paymentReference": "RE-2026-0042",    "zfitems": [      {        "id": "1",        "price": 100,        "quantity": 10,        "product": {          "name": "Beratung",          "unit": "HUR",          "vatpercent": 19        }      },      {        "id": "2",        "price": 20,        "quantity": 10,        "product": {          "name": "Fachbuch",          "unit": "C62",          "vatpercent": 7        }      }    ]  }'
"string"