Generate EN 16931 UBL Invoice XML (Slovakia / Peppol)
Skill: Convert invoice data into a valid EN 16931 UBL 2.1 invoice
Region: Slovakia (Slovensko)
Category: E-Invoicing — IS EFA / Peppol
Does: Takes ordinary invoice data and produces an EN 16931-compliant UBL 2.1 Invoice document — the structured format for Slovak B2G submission to IS EFA and B2B exchange over the Peppol network (Peppol BIS Billing 3.0).
Standard: EN 16931, UBL 2.1, Peppol BIS Billing 3.0
Slovakia accepts UBL 2.1 or CII D16B at EN 16931. This skill emits UBL 2.1. The B2B mandate routes invoices over Peppol with data reported to the government platform via an accredited provider. Validate against the Peppol BIS / EN 16931 schematron before sending.
Input data required
| Input | EN 16931 term | UBL element |
|---|---|---|
| Invoice number, issue date, due date, type code | BT-1, BT-2, BT-9, BT-3 | cbc:ID, cbc:IssueDate, cbc:DueDate, cbc:InvoiceTypeCode |
| Currency | BT-5 | cbc:DocumentCurrencyCode |
| Seller name, address, IČ DPH (VAT), IČO | BT-27.., BT-31, BT-30 | cac:AccountingSupplierParty |
| Buyer name, address, VAT, IČO | BT-44.., BT-48 | cac:AccountingCustomerParty |
| Payment means, IBAN, due date | BG-16 | cac:PaymentMeans |
| Line items: name, quantity, net price, VAT category & rate | BG-25 | cac:InvoiceLine |
Namespaces
| Prefix | URI |
|---|---|
| default | urn:oasis:names:specification:ubl:schema:xsd:Invoice-2 |
cac |
urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2 |
cbc |
urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2 |
Identification:
cbc:CustomizationID=urn:cen.eu:en16931:2017#compliant#urn:fdc:peppol.eu:2017:poacc:billing:3.0cbc:ProfileID=urn:fdc:peppol.eu:2017:poacc:billing:01:1.0
Document structure to emit
Invoice
├── cbc:CustomizationID / cbc:ProfileID
├── cbc:ID / cbc:IssueDate / cbc:DueDate / cbc:InvoiceTypeCode (380) / cbc:DocumentCurrencyCode
├── cac:AccountingSupplierParty (PartyName, PostalAddress, PartyTaxScheme, PartyLegalEntity)
├── cac:AccountingCustomerParty
├── cac:PaymentMeans (PaymentMeansCode, PayeeFinancialAccount/IBAN)
├── cac:TaxTotal (TaxAmount + TaxSubtotal per category)
├── cac:LegalMonetaryTotal (LineExtensionAmount, TaxExclusiveAmount, TaxInclusiveAmount, PayableAmount)
└── cac:InvoiceLine ... (one per item)
Party (seller / buyer)
| Element | Notes |
|---|---|
cac:PartyName/cbc:Name |
trading name |
cac:PostalAddress |
cbc:StreetName, cbc:CityName, cbc:PostalZone, cac:Country/cbc:IdentificationCode (SK) |
cac:PartyTaxScheme/cbc:CompanyID |
IČ DPH / VAT number (e.g. SK2020123456), with cac:TaxScheme/cbc:ID = VAT |
cac:PartyLegalEntity/cbc:CompanyID |
IČO (legal registration number) |
InvoiceLine
| Element | Meaning |
|---|---|
cbc:ID |
line number |
cbc:InvoicedQuantity |
quantity (with unitCode, e.g. HUR) |
cbc:LineExtensionAmount |
line net (with currencyID) |
cac:Item/cbc:Name |
item name |
cac:Item/cac:ClassifiedTaxCategory/cbc:ID |
VAT category (S, Z, E, AE, K, G, O) |
cac:Item/cac:ClassifiedTaxCategory/cbc:Percent |
rate |
cac:Price/cbc:PriceAmount |
net unit price |
TaxTotal / TaxSubtotal
| Element | Meaning |
|---|---|
cac:TaxTotal/cbc:TaxAmount |
total VAT |
cac:TaxSubtotal/cbc:TaxableAmount |
net per category+rate |
cac:TaxSubtotal/cbc:TaxAmount |
VAT per category+rate |
cac:TaxSubtotal/cac:TaxCategory/cbc:ID + cbc:Percent |
category + rate |
LegalMonetaryTotal
cbc:LineExtensionAmount (Σ line nets), cbc:TaxExclusiveAmount, cbc:TaxInclusiveAmount, cbc:PayableAmount — all with currencyID.
Calculation rules
- Line net = quantity × net unit price (2 decimals).
- Group lines by VAT category + rate →
TaxSubtotal:TaxableAmount= Σ nets;TaxAmount= taxable × rate. LineExtensionAmount(header) =TaxExclusiveAmount= Σ line nets.cac:TaxTotal/cbc:TaxAmount= Σ subtotal VAT.TaxInclusiveAmount= exclusive + VAT;PayableAmount= inclusive − prepaid.- Slovak standard VAT rate is 23% (as of 2025); reduced rates 19% and 5%. Confirm the current rates.
Worked example (single standard-rate line)
<?xml version="1.0" encoding="UTF-8"?>
<Invoice xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2"
xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2">
<cbc:CustomizationID>urn:cen.eu:en16931:2017#compliant#urn:fdc:peppol.eu:2017:poacc:billing:3.0</cbc:CustomizationID>
<cbc:ProfileID>urn:fdc:peppol.eu:2017:poacc:billing:01:1.0</cbc:ProfileID>
<cbc:ID>2024-001</cbc:ID>
<cbc:IssueDate>2024-01-15</cbc:IssueDate>
<cbc:DueDate>2024-01-29</cbc:DueDate>
<cbc:InvoiceTypeCode>380</cbc:InvoiceTypeCode>
<cbc:DocumentCurrencyCode>EUR</cbc:DocumentCurrencyCode>
<cac:AccountingSupplierParty><cac:Party>
<cac:PartyName><cbc:Name>Acme s.r.o.</cbc:Name></cac:PartyName>
<cac:PostalAddress><cbc:StreetName>Programátorská 42</cbc:StreetName><cbc:CityName>Bratislava</cbc:CityName><cbc:PostalZone>81101</cbc:PostalZone><cac:Country><cbc:IdentificationCode>SK</cbc:IdentificationCode></cac:Country></cac:PostalAddress>
<cac:PartyTaxScheme><cbc:CompanyID>SK2020123456</cbc:CompanyID><cac:TaxScheme><cbc:ID>VAT</cbc:ID></cac:TaxScheme></cac:PartyTaxScheme>
<cac:PartyLegalEntity><cbc:RegistrationName>Acme s.r.o.</cbc:RegistrationName><cbc:CompanyID>12345678</cbc:CompanyID></cac:PartyLegalEntity>
</cac:Party></cac:AccountingSupplierParty>
<cac:AccountingCustomerParty><cac:Party>
<cac:PartyName><cbc:Name>Klient a.s.</cbc:Name></cac:PartyName>
<cac:PostalAddress><cbc:StreetName>Obchodná 7</cbc:StreetName><cbc:CityName>Košice</cbc:CityName><cbc:PostalZone>04001</cbc:PostalZone><cac:Country><cbc:IdentificationCode>SK</cbc:IdentificationCode></cac:Country></cac:PostalAddress>
<cac:PartyTaxScheme><cbc:CompanyID>SK2020654321</cbc:CompanyID><cac:TaxScheme><cbc:ID>VAT</cbc:ID></cac:TaxScheme></cac:PartyTaxScheme>
<cac:PartyLegalEntity><cbc:RegistrationName>Klient a.s.</cbc:RegistrationName><cbc:CompanyID>87654321</cbc:CompanyID></cac:PartyLegalEntity>
</cac:Party></cac:AccountingCustomerParty>
<cac:PaymentMeans><cbc:PaymentMeansCode>30</cbc:PaymentMeansCode><cac:PayeeFinancialAccount><cbc:ID>SK3112000000198742637541</cbc:ID></cac:PayeeFinancialAccount></cac:PaymentMeans>
<cac:TaxTotal>
<cbc:TaxAmount currencyID="EUR">2300.00</cbc:TaxAmount>
<cac:TaxSubtotal>
<cbc:TaxableAmount currencyID="EUR">10000.00</cbc:TaxableAmount>
<cbc:TaxAmount currencyID="EUR">2300.00</cbc:TaxAmount>
<cac:TaxCategory><cbc:ID>S</cbc:ID><cbc:Percent>23</cbc:Percent><cac:TaxScheme><cbc:ID>VAT</cbc:ID></cac:TaxScheme></cac:TaxCategory>
</cac:TaxSubtotal>
</cac:TaxTotal>
<cac:LegalMonetaryTotal>
<cbc:LineExtensionAmount currencyID="EUR">10000.00</cbc:LineExtensionAmount>
<cbc:TaxExclusiveAmount currencyID="EUR">10000.00</cbc:TaxExclusiveAmount>
<cbc:TaxInclusiveAmount currencyID="EUR">12300.00</cbc:TaxInclusiveAmount>
<cbc:PayableAmount currencyID="EUR">12300.00</cbc:PayableAmount>
</cac:LegalMonetaryTotal>
<cac:InvoiceLine>
<cbc:ID>1</cbc:ID>
<cbc:InvoicedQuantity unitCode="HUR">40</cbc:InvoicedQuantity>
<cbc:LineExtensionAmount currencyID="EUR">10000.00</cbc:LineExtensionAmount>
<cac:Item><cbc:Name>Programátorské služby</cbc:Name>
<cac:ClassifiedTaxCategory><cbc:ID>S</cbc:ID><cbc:Percent>23</cbc:Percent><cac:TaxScheme><cbc:ID>VAT</cbc:ID></cac:TaxScheme></cac:ClassifiedTaxCategory>
</cac:Item>
<cac:Price><cbc:PriceAmount currencyID="EUR">250.00</cbc:PriceAmount></cac:Price>
</cac:InvoiceLine>
</Invoice>
Validation checklist
-
cbc:CustomizationID/cbc:ProfileIDset to the Peppol BIS Billing 3.0 values - Seller and buyer have VAT (
PartyTaxScheme) and legal IČO (PartyLegalEntity) - Each
InvoiceLinehas quantity (unitCode), net price, line extension amount, VAT category + rate - Every monetary amount carries the matching
currencyID -
TaxSubtotalper category reconciles with line nets;TaxTotal/TaxAmount= Σ subtotals -
TaxInclusiveAmount= exclusive + VAT;PayableAmountcorrect - Passes EN 16931 + Peppol BIS schematron before routing over Peppol / to IS EFA
Last updated: 2026-05-26 — confirm the Slovak mandate's go-live date, accepted formats, VAT rates, and the accredited-provider reporting flow against the current Finančná správa / IS EFA specifications before use.