Invoices: create e-invoice
invoices_create_e_invoiceCreate a structured electronic invoice for customers requiring formats like German XRechnung. Use this when a recipient needs an e-invoice instead of a standard PDF invoice.
Instructions
🟡 WRITE · creates data: Creates new records (receipts, transactions, postings, invoices, master data). Not idempotent: calling twice may create duplicates.
create e-invoice
Add an e-invoice for the specified customer.
Use when the recipient requires a structured electronic invoice, for example a German public-sector customer expecting XRechnung.
For an ordinary PDF invoice, use invoices_create.
Not idempotent. v1 offers no endpoint to list or cancel an e-invoice once created.
Endpoint: POST /invoices/create/e-invoice
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| zip | Yes | The zip of the recipient company. If specified, the field will be validated. | |
| city | Yes | The city of the recipient company. If specified, the field will be validated. | |
| date | Yes | The date of the invoice. | |
| type | Yes | Can be either 'invoice' ("Rechnung"), 'credit' ("Gutschrift") or 'offer' ("Angebot"). | |
| Yes | The email for sending the invoice. If specified, the field will be validated. | ||
| street | Yes | The street of the recipient company. If specified, the field will be validated. | |
| country | Yes | The country of the recipient company. If specified, the field will be validated. Valid cases are only the German version of the country name [Dänemark] OR the two digit ISO code of the country [DK]. | |
| due_days | No | The number of days between the invoice date and the due date. If not specified due date will be set to invoice date (due_days = 0). | |
| language | No | The language for translatable invoice labels (e.g. headings, table headers, payment terms). Can be either 'de_DE' ("Deutsch", default) or 'en_US' ("English"). If omitted, German is used. | |
| item_name | Yes | An array of invoice items. Usage: "item_name" : ['Item 1', 'Item 2'] | |
| item_unit | Yes | An array of invoice items units. Usage: "item_unit" : ['Std.', 'Stk.'] | |
| item_amount | Yes | An array of invoice item amounts. Usage: "item_amount" : ['10', '20'] | |
| company_name | Yes | The company name of the recipient. | |
| e_invoice_id | Yes | Buyer reference (default: 0). If you do not have a reference, please enter "0". A valid is mandatory for e-invoices to public contracting authorities and is provided by the recipient. | |
| discount_type | No | The type of the discount. Can be either 'percent' or 'EUR'. If specified, the field will be validated. | |
| invoicenumber | No | The invoicenumber for the invoice. If not specified, the default BHB number will be created. If specified, the field will be validated. | |
| item_tax_type | Yes | An array of invoice item tax types. Usage: "item_vat" : ['S', 'E'] Valid tax types are the following: S - VAT (standard rate) Z - 0% VAT AE - Reverse Charge (§13b) K - EU Supply (Intra-community supply) G - Third Country Supply (Export) E - VAT Exempt Supply & Services | |
| show_bankdata | No | Show the the bank data on the invoice. If specified, the field will be validated. | |
| correspondence | No | The optional correspondence to the invoice recipient. If specified, the field will be validated. | |
| date_of_supply | No | Date or period of service/delivery. NOTE: The date_of_supply will be displayed on the PDF, but when the date AND the date_of_supply is specified in the format "YYYY-MM-DD", the date_of_supply will also be taken over as date_delivery of the receipt in the 'Belege' or 'Belege/Buchen' view. IMPORTANT: Due to the DATEV compatibility, we cannot accept a date_of_supply that is after the invoice date. In that case it will be ignored! | |
| discount_value | No | The value of granted discount. If specified, the field will be validated. | |
| customer_number | No | The customer number of the recipient. If specified, the field will be validated. | |
| item_tax_amount | Yes | Only required if corresponding item_tax_type = 'S' (VAT). An array of invoice item vats. Usage: "item_tax_amount" : ['7', '19'] Valid vat rates are floating point numbers between 0 and 100. | |
| final_provisions | No | The final comment of the invoice. If specified, the field will be validated. | |
| item_description | No | An array of invoice item description. Usage: "item_description" : ['Description Item 1', 'Description Item 2']. If specified, the field will be validated. | |
| show_contactdata | No | Show the contact data on the invoice. If specified, the field will be validated. | |
| show_prices_type | Yes | Can be either 'net' ("Netto") or 'gross' ("Brutto"). | |
| item_single_price | Yes | An array of invoice item single_prices. Usage: "item_single_price" : ['20', '19.99'] | |
| payment_reference | No | The payment reference id. If specified correctly, the resulting receipt of the created invoice will match with the corresponding transaction. NOTE: Currently we support Amazon order id, PayPal transaction id and Stripe transaction id! | |
| payment_conditions | No | The payment conditions of the invoice. If specified, the field will be validated. | |
| recurring_interval | No | An interval for recurring invoices. Can be either 'weekly', 'monthly', 'quarterly' or 'yearly'. If specified, the field will be validated. | |
| contact_person_name | No | The name of the contact person of the recipient company. If specified, the field will be validated. | |
| recurring_date_next | No | The next date of a recurring invoice. IMPORTANT: The field is required, if "recurring_interval" is specified. If specified, the field will be validated. | |
| additional_addressline | No | The additional address information of the recipient company. If specified, the field will be validated. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| message | No | blank | |
| success | Yes | Success boolean | |
| file_name | No | Filename of the created invoice | |
| invoicenumber | No | blank | |
| id_by_customer | No | blank |