BiGapiguides
POST /v1/einvoice/create · 1 cent per operation

Create an e-invoice (XRechnung or ZUGFeRD)

Turn simple invoice data (JSON) into an XRechnung (UBL or CII) or a ZUGFeRD PDF/A-3 with embedded XML. We calculate the totals and VAT; every invoice must pass the official KoSIT check before you get it.

Try it

curl -X POST https://api.bigapi.dev/v1/einvoice/create -H 'Authorization: Bearer $KEY' -H 'Content-Type: application/json' -d '{"format":"zugferd","number":"RE-2026-0042","issue_date":"2026-10-17","seller":{"name":"Muster GmbH","street":"Hafenstrasse 5","zip":"20459","city":"Hamburg","vat_id":"DE136695976","email":"rechnung@muster.example","phone":"+49 40 1234567"},"buyer":{"name":"Kunde AG","street":"Ring 1","zip":"10115","city":"Berlin","email":"eingang@kunde.example"},"payment":{"iban":"DE89370400440532013000"},"lines":[{"name":"Beratung","quantity":2,"unit":"hour","price":95}]}' -o rechnung.pdf

New keys come with 100 free operations, no signup: curl -X POST https://api.bigapi.dev/v1/keys. Failed calls cost nothing.

Parameters

NameMeaning
number requiredInvoice number.
issue_date requiredInvoice date as YYYY-MM-DD.
seller requiredSeller: name, street, zip, city, country (default DE), vat_id or tax_number, email, phone, contact. XRechnung needs email and phone.
buyer requiredBuyer: name, street, zip, city, country, email (electronic address for XRechnung), vat_id for reverse charge.
lines requiredItems: name, quantity (default 1, up to 4 decimals), unit (piece, hour, day, kg, lump sum … or a UN/ECE code), price (net, up to 4 decimals), vat_rate (default 19 for German sellers, otherwise required), vat_category (S, Z, E, AE, K, G, O; default S). Discounts as an extra line with negative quantity.
formatubl or cii give an XRechnung 3.0 XML; zugferd gives a PDF/A-3 with factur-x.xml (profile EN 16931).
Allowed: ubl, cii, zugferd
Default: ubl
buyer_referenceLeitweg-ID for public buyers, otherwise e.g. order or customer number. Required for XRechnung (falls back to order_reference).
Default: none
due_datePayment due date, YYYY-MM-DD.
Default: none (then 'payable immediately' for XRechnung)
delivery_dateDelivery or service date, YYYY-MM-DD.
Default: none
paymentiban, bic, account_name, reference. XRechnung needs an IBAN for bank transfer.
Default: none
small_businesstrue for German small businesses (§ 19 UStG): all items without VAT, with the legal note.
Default: false
typecredit_note gives a credit note (UBL CreditNote, type 381); add preceding_invoice {number, date}.
Allowed: invoice, credit_note
Default: invoice
langLanguage of the readable PDF (zugferd only).
Allowed: de, en
Default: "de"
order_referencePurchase order number.
Default: none
prepaidAmount already paid; reduces the amount due.
Default: 0
noteFree text note on the invoice.
Default: none

Result and price

1¢ · 1 cent per operation

Returns application/xml | application/pdf. Response headers carry the cost (X-BigAPI-Cost) and notes about your input (X-BigAPI-Warnings).

Good to know

Errors your agent should handle

400 invalid_invoice_dataA field is missing or wrong; the response names it in "field" and says what is needed (e.g. buyer_reference for XRechnung).
422 invoice_invalidThe invoice was built but does not pass the official KoSIT check; you get the rule codes instead of a file. Nothing is charged.

From an agent (MCP)

Connect BiGapi as an MCP server: https://api.bigapi.dev/mcp (hosted) or npx -y @bigapi/mcp (local). Then ask in plain words; the agent finds einvoice_create on its own.

Create an XRechnung for invoice RE-2026-0042 to the city of Musterhausen, Leitweg-ID 04011000-1234512345-06, two hours of consulting at 95 euros.