Issued invoices
issuing and editing invoices, obtaining PDFs and sending by e-mail via Public API.
Automate the issuing of invoices from your ERP or e-shop and subsequent obtaining of PDF or sending by e-mail.
All operations on this page use method POST, JSON body and header api_key. Access settings can be found in the Authentication. Click on an endpoint to open its inputs and responses in the REST API reference.
issuing via v1 and v2
For issuing via Peppol, use POST /v2/documents/invoice-issue and the instructions eInvoices via Peppol. Mode PDF will create a classic invoice, EINVOICE_DRAFT a draft eInvoice, and EINVOICE_FINALIZE_AND_SEND will also try to finalize and send. Evaluate the actual data.issueMode and the potential peppolSendSkipped.
The entrance fee is data.organizationId when issuing via v1 company identification number (IČO), when issuing via v2 internal organization ID. Output v1 uses data.document. V2 returns data.documentId, invoiceNumber, issueMode, or deliveryId. Therefore, when migrating, also modify the processing of the response.
issuing invoices and obtaining PDFs
| Endpoint | Usage |
|---|---|
POST /v1/documents/invoice-issue | issuing a new invoice without creating a PDF. |
POST /v1/documents/get-invoice-pdf | Obtaining a PDF issued invoice. |
Issuing an invoice and obtaining its PDF are two separate operations. Select the input data and supported document types according to the schema of the specific endpoint. issuing via API has separate accounting rules described on Pricing.
For get-invoice-pdf you can enter documentId or alternatively deliveryId returned when sent via Peppol. organizationId also supports company identification number (IČO) internal organization IDs here. The output remains PDF encoded as Base64.
VAT on invoice items
The PublicIssueInvoiceItem model used when issuing an invoice also contains the following optional fields:
| Field | Type | Meaning |
|---|---|---|
data.items[].isTaxExempt | boolean, it can be null | Non-VAT item designation as described by Swagger |
data.items[].isReverseCharge | boolean, it can be null | Item-level tax pass-through flag |
Both fields belong to a specific item in data.items. The existing data.reverseCharge is a separate field at the whole invoice level.
Item paid advance
When issuing an invoice via POST /v1/documents/invoice-issue, mark the item paid advance with the field itemType with the value advance_payment. The field belongs to a specific entry in the field data.items.
| Field | Type | Meaning |
|---|---|---|
data.items[].itemType | string, optional, can be null | Value advance_payment indicates an item Paid advance. |
The following example issues an invoice with the item paid advance. Replace the API key and company identification number (IČO) of both the organization and the customer with your own data. Fill in the name, price without VAT, VAT rate and quantity according to the specific deposit.
curl --request POST --fail-with-body --silent --show-error \
'https://api-gateway-prod-europe-west-1-7epuecvu.ew.gateway.dev/v1/documents/invoice-issue' \
--header 'api_key: YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data-raw '{
"data": {
"organizationId": "12345678",
"type": "issued_invoice",
"customer": {
"ico": "87654321"
},
"paymentType": "card",
"currency": "EUR",
"items": [
{
"name": "Advance payment received",
"unitPriceWithoutVat": 100,
"vatRate": 23,
"quantity": 1,
"itemType": "advance_payment"
}
]
}
}'
The data.type field specifies the type of issuing document. issued_advance indicates advance invoice. The data.paid field determines the payment status of the entire document. Use data.items[].itemType to mark the paid advance item itself.
Editing of the issued invoice
| Endpoint | Usage |
|---|---|
POST /v1/documents/issued-invoice-update | Editing of the issued invoice according to the input schema of the endpoint. |
Use the invoice identifier and fields listed in the reference. Before repeating the request after an error or timeout, first verify the resulting status of the invoice.
Prices, VAT and other fields when editing
Items use the model PublicUpdateIssuedInvoiceItem when editing. Enter quantity and at least one price entry: unitPriceWithoutVat, unitPriceWithVat or totalPriceWithVat. For multiple prices, totalPriceWithVat takes precedence, then unitPriceWithVat, and finally the price without VAT. Also enter vatRate for the price including VAT.
The adjustment supports taxCategoryCode at both invoice and item level, taxRuleReason, vatexCode, itemized additionalProperties and customVatReverseChargeText for transfer of tax liability. The meaning of the categories and the limits are in the guide to eInvoices.
Common invoice items also support accountingItemId, expenditureCenterId, orderId and activityId. note has a limit of 200 characters and skuCode has a limit of 64 characters.
Both issuing and editing support languages english, slovak, czech, german, hungarian, polish, vietnamese and extended values paymentType by reference. IBAN is not required when paying by card. If you omit the payment method and enter the IBAN, the transfer will be used.
Sending the invoice by e-mail
| Endpoint | Usage |
|---|---|
POST /v1/documents/send-invoice-by-email | Generate a PDF and send an invoice by e-mail. |
Send invoice data, recipients and other parameters according to the endpoint schema. After the timeout, do not repeat the request without verifying the result, so that you do not send the same invoice to the addressee more than once.
More information
Consider paging and errors and API consumption when integrating. For a full list of operations, see endpoint overview.