Utility APIFree

Formats API

Retrieve all supported countries and e-invoice formats. Ideal for dynamic UI components like dropdown menus or for validating user inputs.

GET/api/v1/invoice/formats
GET/api/v1/invoice/{countryCode}/formats
Formats API is free!

This API does not consume billing quota. You can query formats as often as you like.

Endpoints

GET/api/v1/invoice/formats

Returns all supported countries with their available e-invoice formats. Ideal for discovery and dynamic UI components.

Use Cases: Use Cases: Dropdown menus for country selection, format picker, generate documentation

GET/api/v1/invoice/{countryCode}/formats

Returns the available e-invoice formats for a specific country. Use this endpoint when you already know the country.

Path Parameters

countryCode
required

ISO 3166-1 Alpha-2 Ländercode (z.B. DE, AT, FR)

Germany

/api/v1/invoice/DE/formats

Austria

/api/v1/invoice/AT/formats

France

/api/v1/invoice/FR/formats

Code Examples

bash
1curl -X GET 'https://service.invoice-api.xhub.io/api/v1/invoice/formats' \
2 -H 'Authorization: Bearer sk_test_xxx'

Response

/api/v1/invoice/formats

200 OK
json
1{
2 "countries": [
3 {
4 "code": "DE",
5 "name": "Deutschland",
6 "formats": [
7 {
8 "id": "PDF",
9 "name": "PDF",
10 "mimeType": "application/pdf",
11 "description": "Standard PDF Rechnung"
12 },
13 {
14 "id": "ZUGFERD",
15 "name": "ZUGFeRD 2.3",
16 "mimeType": "application/pdf",
17 "description": "PDF mit eingebettetem XML (EN16931)"
18 },
19 {
20 "id": "XRECHNUNG",
21 "name": "XRechnung 3.0",
22 "mimeType": "application/xml",
23 "description": "XML nach EN16931 (UBL/CII)"
24 }
25 ]
26 },
27 {
28 "code": "AT",
29 "name": "Österreich",
30 "formats": [
31 {
32 "id": "PDF",
33 "name": "PDF",
34 "mimeType": "application/pdf"
35 },
36 {
37 "id": "EBINTERFACE",
38 "name": "ebInterface",
39 "mimeType": "application/xml",
40 "description": "Österreichisches E-Rechnungsformat"
41 }
42 ]
43 }
44 ]
45}

/api/v1/invoice/{countryCode}/formats

200 OK
json
1{
2 "code": "DE",
3 "name": "Deutschland",
4 "formats": [
5 {
6 "id": "PDF",
7 "name": "PDF",
8 "mimeType": "application/pdf",
9 "description": "Standard PDF Rechnung"
10 },
11 {
12 "id": "ZUGFERD",
13 "name": "ZUGFeRD 2.3",
14 "mimeType": "application/pdf",
15 "description": "PDF mit eingebettetem XML (EN16931)"
16 },
17 {
18 "id": "XRECHNUNG",
19 "name": "XRechnung 3.0",
20 "mimeType": "application/xml",
21 "description": "XML nach EN16931 (UBL/CII)"
22 }
23 ]
24}

Error Response

404 Not Found

Returned when an invalid country code is specified.

json
1{
2 "error": "NOT_FOUND",
3 "message": "Country 'XX' is not supported"
4}

Response Schema

Country Object

FieldTypeDescription
countriesarrayList of all supported countries (only for /formats)
codestringISO 3166-1 alpha-2 country code
namestringLocalized country name
formatsarrayList of supported formats for the country

Format Object

FieldTypeDescription
idstringFormat identifier for API calls (e.g. XRECHNUNG, ZUGFERD)
namestringDisplay name of the format (e.g. 'XRechnung 3.0')
mimeTypestringMIME type of the output format (application/xml or application/pdf)
descriptionstringOptional description of the format

Supported Countries & Formats

DEGermany
PDFZUGFeRD 2.3XRechnung 3.0
ATAustria
PDFebInterface
CHSwitzerland
PDFQR-Bill
FRFrance
PDFFactur-X
ITItaly
PDFFatturaPA
ESSpain
PDFFacturae
NLNetherlands
PDFUBL
BEBelgium
PDFUBL
PTPortugalQ2.2026
PDF
PLPolandQ2.2026
PDF
CZCzech RepublicQ2.2026
PDFISDOC
HUHungaryQ2.2026
PDFNAV
RORomaniaQ2.2026
PDF
BGBulgariaQ2.2026
PDF

= Available | Q2.2026 = Planned

Use Cases

Dynamic UI

Use the API to dynamically populate dropdown menus for country and format selection. This keeps your UI components always up to date.

Validation

Validate user inputs before calling the Creator or Converter API. Prevent invalid country-format combinations.

Documentation

Automatically generate documentation for your application with currently supported formats and countries.

Using Format IDs

The id from the response (e.g. XRECHNUNG, ZUGFERD) is used as the formatparameter in the other APIs, e.g. /api/v1/invoice/DE/XRECHNUNG/generate.