Skip to content

European Union

Space Invoices provides EU transaction-classification and VIES helpers. Your integration remains responsible for selecting and supplying the correct taxes unless a documented country module explicitly applies additional behavior.

VIES Validation

Check a customer’s VAT number and classify the seller/buyer relationship before creating the document:

Vies validationtypescript
// title: VIES validation
const _result = await sdk.vies.checkVies({
  issuer: { country_code: "DE", is_tax_subject: true },
  customer: { country: "FR", tax_number: "FR87654321" },
});

Store or re-check the result according to your own workflow. Invoice creation does not guarantee that every supplied VAT number has been checked automatically.

Reverse Charge

For an eligible B2B transaction across EU borders:

  • Your entity is in EU country A
  • Customer has valid VAT number in EU country B
  • Your integration supplies the appropriate tax treatment and reverse-charge wording
Slovenia (Seller) → Germany (Buyer with VAT)
Check VIES and transaction type
Apply the appropriate tax treatment

E-Invoicing Unit Codes

Line item unit remains your display value. For e-invoicing XML exports, including XRechnung, ZUGFeRD, e-SLOG, UJP packages, and Peppol-compatible UBL, the XML output needs a valid UN/ECE unit code.

Space Invoices maps common display units automatically. When you use a product-specific label that is not a real unit, set items[].e_invoicing.unit_code on the document line or saved item. The override changes only XML output; the display unit stays unchanged.

{
"items": [
{
"name": "Medical vial",
"quantity": 1,
"unit": "VIALA",
"e_invoicing": {
"unit_code": "C62"
},
"price": 100
}
]
}

Common codes include:

CodeMeaning
C62unit or piece
HURhour
DAYday
KGMkilogram
GRMgram
MGMmilligram
LTRlitre
MLTmillilitre
MTRmetre
MTKsquare metre
SETset

For the full valid list, use the Peppol BIS Billing 3.0 UNECERec20 code list. The upstream source is UNECE Recommendation 20, but Peppol-compatible integrations should validate against the Peppol list.

Transaction Types

The transaction-type helper can classify:

TypeDescription
domesticSeller and customer are in the same country
intra_eu_b2bEU cross-border B2B; may be reverse-charge eligible
intra_eu_b2cEU cross-border B2C
exportCustomer is outside the EU

Use the classification as an input to your tax logic; it does not itself prove the final VAT treatment.

Country-Specific

Some EU countries have additional requirements: