---
title: "Send E-Invoices"
method: POST
path: "/v1/webhook/e-invoicing"
tags: ["Use case / E-invoicing", "Webhooks / Inbound"]
---

# Send E-Invoices

`POST /v1/webhook/e-invoicing`

Webhook to receive e-invoices in structured format or as file uploads.

## Supported Formats
This endpoint accepts e-invoices in multiple formats:

- **JSON payloads**: Structured data using application/json content type.
- **XML payloads**: Structured data using application/xml content type. Must be a valid UBL document.
- **File uploads**: JSON + binary files (PDF, XML, etc.) using multipart/form-data.

## Multipart Upload Support
When using multipart form data, the endpoint expects:
- First part: JSON document (PurchaseEInvoiceInput or PurchaseECreditNoteInput). XML is not supported at the moment.
- Subsequent parts: Supporting documents (invoice PDF, CMR PDF, etc.).

## Examples

**JSON payload example (application/json).**

```json
{
  "name": "INV-2023-001",
  "date": "2023-01-15",
  "due_date": "2023-02-15",
  "invoice_type": "PURCHASE",
  "currency": "EUR",
  "total_excl_tax": 999.99,
  "total_incl_tax": 1209.99,
  "total_tax": 210.00,
  "custom_fields": {},
  "supplier": {
    "id": "550e8400-e29b-41d4-a716-446655440000",
    "name": "Supplier Company Ltd",
    "vat_number": "BE1234.123.123",
    "billing_location": {
      "address": "Gaston Crommenlaan 4",
      "city": "Gent",
      "postal_code": "9050",
      "country": "BE"
    }
  },
  "customer_reference_numbers": ["12345"],
  "line_items": [
    {
      "description": "International freight transport",
      "amount": 999.99,
      "currency": "EUR",
      "tax_rate": {
        "percentage": 21.0,
        "name": "21% VAT",
        "tax_type": "VAT"
      },
      "account": {
        "code": "6000"
      },
      "references": {
        "order_name": "OR-1234"
      }
    }
  ],
  "attachments": [
    {
      "document": {
        "base64": "JVBERi0xLjQKJcfs... (truncated for brevity) ...",
        "content_type": "application/pdf",
        "document_type": "INVOICE",
        "filename": "invoice_123.pdf"
      }
    }
  ]
}
```

**Credit note example (application/json).** Note: credit notes do not have a `due_date` field.

```json
{
  "name": "CN-2023-001",
  "date": "2023-03-01",
  "invoice_type": "PURCHASE_CREDIT_NOTE",
  "currency": "EUR",
  "total_excl_tax": -200.00,
  "total_incl_tax": -242.00,
  "total_tax": -42.00,
  "supplier": {
    "name": "Supplier Company Ltd",
    "vat_number": "BE1234.123.123"
  },
  "customer_reference_numbers": ["12345"],
  "line_items": [
    {
      "amount": -200.00,
      "currency": "EUR",
      "tax_rate": {
        "percentage": 21.0,
        "tax_type": "VAT"
      },
      "account": {
        "code": "6000"
      }
    }
  ]
}
```

**XML payload example (application/xml).**

```xml
<Invoice xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2" xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2" xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2" xmlns:ccts="urn:un:unece:uncefact:documentation:2" xmlns:ext="urn:oasis:names:specification:ubl:schema:xsd:CommonExtensionComponents-2" xmlns:qdt="urn:oasis:names:specification:ubl:schema:xsd:QualifiedDatatypes-2" xmlns:udt="urn:un:unece:uncefact:data:specification:UnqualifiedDataTypesSchemaModule:2">
    <cbc:CustomizationID>urn:cen.eu:en16931:2017#compliant#urn:fdc:peppol.eu:2017:poacc:billing:3.0</cbc:CustomizationID>
    <cbc:ProfileID>urn:fdc:peppol.eu:2017:poacc:billing:01:1.0</cbc:ProfileID>
    <cbc:ID>25900027</cbc:ID>
    <cbc:IssueDate>2025-10-28</cbc:IssueDate>
    <cbc:DueDate>2025-10-28</cbc:DueDate>
    <cbc:InvoiceTypeCode>380</cbc:InvoiceTypeCode>
    <cbc:DocumentCurrencyCode>EUR</cbc:DocumentCurrencyCode>
    <cbc:BuyerReference>25900027</cbc:BuyerReference>
    <cac:AdditionalDocumentReference>
        <cbc:ID>600947</cbc:ID>
        <cac:Attachment>
            <cbc:EmbeddedDocumentBinaryObject mimeCode="application/pdf" filename="25900027.pdf">JVBERi0xLjQKJcfs... (truncated for brevity) ...</cbc:EmbeddedDocumentBinaryObject>
        </cac:Attachment>
    </cac:AdditionalDocumentReference>
    <cac:AccountingSupplierParty>
        <cac:Party>
        <cbc:EndpointID schemeID="0208">0564730040</cbc:EndpointID>
        <cac:PartyName>
            <cbc:Name>qargo-peppol-dev</cbc:Name>
        </cac:PartyName>
        <cac:PostalAddress>
            <cbc:StreetName>Gaston Crommenlaan 4</cbc:StreetName>
            <cbc:CityName>Gent</cbc:CityName>
            <cbc:PostalZone>9050</cbc:PostalZone>
            <cbc:CountrySubentity>Oost-Vlaanderen</cbc:CountrySubentity>
            <cac:Country>
            <cbc:IdentificationCode>BE</cbc:IdentificationCode>
            </cac:Country>
        </cac:PostalAddress>
        <cac:PartyTaxScheme>
            <cbc:CompanyID>BE0772640434</cbc:CompanyID>
            <cac:TaxScheme>
            <cbc:ID>VAT</cbc:ID>
            </cac:TaxScheme>
        </cac:PartyTaxScheme>
        <cac:PartyLegalEntity>
            <cbc:RegistrationName>qargo-peppol-dev</cbc:RegistrationName>
            <cbc:CompanyID schemeID="0208">0564730040</cbc:CompanyID>
        </cac:PartyLegalEntity>
        <cac:Contact>
            <cbc:Telephone>+324854244512</cbc:Telephone>
            <cbc:ElectronicMail>simon@qargo.com</cbc:ElectronicMail>
        </cac:Contact>
        </cac:Party>
    </cac:AccountingSupplierParty>
    <cac:AccountingCustomerParty>
        <cac:Party>
        <cbc:EndpointID schemeID="0208">0772640434</cbc:EndpointID>
        <cac:PartyName>
            <cbc:Name>Qargo</cbc:Name>
        </cac:PartyName>
        <cac:PostalAddress>
            <cbc:StreetName>Gaston Crommenlaan 4</cbc:StreetName>
            <cbc:CityName>Gent</cbc:CityName>
            <cbc:PostalZone>9050</cbc:PostalZone>
            <cac:Country>
            <cbc:IdentificationCode>BE</cbc:IdentificationCode>
            </cac:Country>
        </cac:PostalAddress>
        <cac:PartyLegalEntity>
            <cbc:RegistrationName languageID="nl">Qargo</cbc:RegistrationName>
            <cbc:CompanyID schemeID="0208">0772640434</cbc:CompanyID>
        </cac:PartyLegalEntity>
        </cac:Party>
    </cac:AccountingCustomerParty>
    <cac:TaxTotal>
        <cbc:TaxAmount currencyID="EUR">162.71</cbc:TaxAmount>
        <cac:TaxSubtotal>
        <cbc:TaxableAmount currencyID="EUR">774.83</cbc:TaxableAmount>
        <cbc:TaxAmount currencyID="EUR">162.71</cbc:TaxAmount>
        <cac:TaxCategory>
            <cbc:ID>S</cbc:ID>
            <cbc:Percent>21.00</cbc:Percent>
            <cac:TaxScheme>
            <cbc:ID>VAT</cbc:ID>
            </cac:TaxScheme>
        </cac:TaxCategory>
        </cac:TaxSubtotal>
    </cac:TaxTotal>
    <cac:LegalMonetaryTotal>
        <cbc:LineExtensionAmount currencyID="EUR">774.83</cbc:LineExtensionAmount>
        <cbc:TaxExclusiveAmount currencyID="EUR">774.83</cbc:TaxExclusiveAmount>
        <cbc:TaxInclusiveAmount currencyID="EUR">937.54</cbc:TaxInclusiveAmount>
        <cbc:PayableAmount currencyID="EUR">937.54</cbc:PayableAmount>
    </cac:LegalMonetaryTotal>
    <cac:InvoiceLine>
        <cbc:ID>1</cbc:ID>
        <cbc:InvoicedQuantity unitCode="EA">1.0</cbc:InvoicedQuantity>
        <cbc:LineExtensionAmount currencyID="EUR">65.00</cbc:LineExtensionAmount>
        <cac:Item>
        <cbc:Name>Administratiekost</cbc:Name>
        <cac:ClassifiedTaxCategory>
            <cbc:ID>S</cbc:ID>
            <cbc:Percent>21.00</cbc:Percent>
            <cac:TaxScheme>
            <cbc:ID>VAT</cbc:ID>
            </cac:TaxScheme>
        </cac:ClassifiedTaxCategory>
        </cac:Item>
        <cac:Price>
        <cbc:PriceAmount currencyID="EUR">65.0</cbc:PriceAmount>
        </cac:Price>
    </cac:InvoiceLine>
    <cac:InvoiceLine>
        <cbc:ID>2</cbc:ID>
        <cbc:InvoicedQuantity unitCode="EA">1.0</cbc:InvoicedQuantity>
        <cbc:LineExtensionAmount currencyID="EUR">709.83</cbc:LineExtensionAmount>
        <cac:Item>
        <cbc:Name>Transport charge</cbc:Name>
        <cac:ClassifiedTaxCategory>
            <cbc:ID>S</cbc:ID>
            <cbc:Percent>21.00</cbc:Percent>
            <cac:TaxScheme>
            <cbc:ID>VAT</cbc:ID>
            </cac:TaxScheme>
        </cac:ClassifiedTaxCategory>
        </cac:Item>
        <cac:Price>
        <cbc:PriceAmount currencyID="EUR">709.83</cbc:PriceAmount>
        </cac:Price>
    </cac:InvoiceLine>
</Invoice>
```

**Multipart Form Data example.**

```
POST /v1/webhook/e-invoicing
Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryABC123XYZ

----WebKitFormBoundaryABC123XYZ
Content-Disposition: form-data; name="document"; filename="invoice_data.json"
Content-Type: application/json

{
  "name": "INV-2023-001",
  "date": "2023-01-15",
  "due_date": "2023-02-15",
  "invoice_type": "PURCHASE",
  "currency": "EUR",
  "total_excl_tax": 999.99,
  "total_incl_tax": 1209.99,
  "total_tax": 210.00,
  "custom_fields": {},
  "supplier": {
    "id": "550e8400-e29b-41d4-a716-446655440000",
    "name": "Supplier Company Ltd",
    "vat_number": "BE1234.123.123",
    "billing_location": {
      "address": "Gaston Crommenlaan 4",
      "city": "Gent",
      "postal_code": "9050",
      "country": "BE"
    }
  },
  "customer_reference_numbers": ["12345"],
  "line_items": [
    {
      "description": "International freight transport",
      "amount": 999.99,
      "currency": "EUR",
      "tax_rate": {
        "percentage": 21.0,
        "name": "21% VAT",
        "tax_type": "VAT"
      },
      "account": {
        "code": "6000"
      },
      "references": {
        "order_name": "OR-1234"
      }
    }
  ]
}
----WebKitFormBoundaryABC123XYZ
Content-Disposition: form-data; name="invoice"; filename="invoice_123.pdf"
Content-Type: application/pdf

[binary PDF content]
----WebKitFormBoundaryABC123XYZ
Content-Disposition: form-data; name="cmr"; filename="cmr_document.pdf"
Content-Type: application/pdf

[binary PDF content]
----WebKitFormBoundaryABC123XYZ--
```

## Processing Notes on Multipart Uploads
- First part must be the JSON document containing invoice/credit note data.
- Supporting documents follow as additional parts.
- Content-Type headers determine document processing.

## Request body

- union
  - PurchaseEInvoiceInput
    - `name` string, required — Reference from invoicing party.
    - `date` string, date, required — Invoice transaction date.
    - `currency` string, required — Currency code of the e-invoice.
    - `exchange_rate` ExchangeRate
      - `rate_date` string, date, nullable
      - `rate` number, required
      - `inverse_rate` number, required
    - `total_excl_tax` union, required — Total amount excluding tax for the e-invoice.
      - number
      - string
    - `total_incl_tax` union, required — Total amount including tax for the e-invoice.
      - number
      - string
    - `total_tax` union, required — Total tax amount for the e-invoice.
      - number
      - string
    - `custom_fields` object — Custom fields associated with this e-invoice.
    - `supplier` EInvoiceCompanyInput, required
      - `id` string, uuid, nullable — The unique identifier of the company.
      - `name` string, required — Name of the company.
      - `vat_number` string, nullable — VAT number of the company.
      - `billing_location` Location
        - `code` string, nullable — Technical code for integrations/mapping logic; should be treated as stable once set.
        - `display_name` string, nullable — Human-readable label for a location in operational views.
        - `external_id` string, nullable — Identifier from an external (master data) system.
        - `address` string, nullable — First address line of the location
        - `address_second_line` string, nullable — Second address line of the location
        - `city` string, nullable — City of the location
        - `state` string, nullable — State of the location
        - `country` string, nullable — Country code (ISO 3166-1 alpha-2) of the location
        - `postal_code` string, nullable — Postal code of the location
        - `name` string, nullable — Name of the location
        - `id` string, uuid, nullable — Identifier of the location
        - `latitude` number, nullable
        - `longitude` number, nullable
        - `description` string, nullable — Location description
        - `location_identifier` string, nullable — External location identifier
    - `customer_reference_numbers` string[] — Reference numbers used to match the invoice.
    - `line_items` EInvoiceLineItem[], required — List of invoice lines associated with this e-invoice.
      - `description` string, nullable — Freeform description field.
      - `amount` union, required — Amount of the charge line.
        - number
        - string
      - `account` ApiOrderModelsChargeAccountInput
        - `code` string, required — Code of the general ledger in the accounting software linked to this charge line.
      - `tax_rate` ApiAccountingModelsInvoiceTaxRate
        - `id` string, uuid, nullable — Unique identifier of the tax rate in Qargo.
        - `name` string, nullable — Name of the Tax rate in Qargo.
        - `percentage` number, nullable
        - `code` string, nullable — Code of the tax rate item in the accounting software.
        - `tax_type` 'VAT' | 'NO_VAT' | 'REVERSE_CHARGE' | 'TRANSIT' | 'CO_CONTRACTING' | 'OTHER'
      - `currency` string, required — Currency of the line item.
      - `references` object, nullable — References associated with this line item.
    - `attachments` EInvoiceAttachment[], nullable — List of document attachments associated with this e-invoice.
      - `document` EInvoiceDocumentAttachment, required
        - `base64` string, required — Base64 encoded content of the document attachment.
        - `content_type` string, required — MIME type of the document attachment, e.g., 'application/pdf', 'application/xml'.
        - `document_type` 'INVOICE' | 'CREDIT_NOTE' | 'OTHER', required
        - `filename` string, required — Filename of the document attachment.
    - `due_date` string, date, required — Payment due date.
    - `invoice_type` 'PURCHASE', required — Indicates that this is a purchase invoice.
  - PurchaseECreditNoteInput
    - `name` string, required — Reference from invoicing party.
    - `date` string, date, required — Invoice transaction date.
    - `currency` string, required — Currency code of the e-invoice.
    - `exchange_rate` ExchangeRate
      - `rate_date` string, date, nullable
      - `rate` number, required
      - `inverse_rate` number, required
    - `total_excl_tax` union, required — Total amount excluding tax for the e-invoice.
      - number
      - string
    - `total_incl_tax` union, required — Total amount including tax for the e-invoice.
      - number
      - string
    - `total_tax` union, required — Total tax amount for the e-invoice.
      - number
      - string
    - `custom_fields` object — Custom fields associated with this e-invoice.
    - `supplier` EInvoiceCompanyInput, required
      - `id` string, uuid, nullable — The unique identifier of the company.
      - `name` string, required — Name of the company.
      - `vat_number` string, nullable — VAT number of the company.
      - `billing_location` Location
        - `code` string, nullable — Technical code for integrations/mapping logic; should be treated as stable once set.
        - `display_name` string, nullable — Human-readable label for a location in operational views.
        - `external_id` string, nullable — Identifier from an external (master data) system.
        - `address` string, nullable — First address line of the location
        - `address_second_line` string, nullable — Second address line of the location
        - `city` string, nullable — City of the location
        - `state` string, nullable — State of the location
        - `country` string, nullable — Country code (ISO 3166-1 alpha-2) of the location
        - `postal_code` string, nullable — Postal code of the location
        - `name` string, nullable — Name of the location
        - `id` string, uuid, nullable — Identifier of the location
        - `latitude` number, nullable
        - `longitude` number, nullable
        - `description` string, nullable — Location description
        - `location_identifier` string, nullable — External location identifier
    - `customer_reference_numbers` string[] — Reference numbers used to match the invoice.
    - `line_items` EInvoiceLineItem[], required — List of invoice lines associated with this e-invoice.
      - `description` string, nullable — Freeform description field.
      - `amount` union, required — Amount of the charge line.
        - number
        - string
      - `account` ApiOrderModelsChargeAccountInput
        - `code` string, required — Code of the general ledger in the accounting software linked to this charge line.
      - `tax_rate` ApiAccountingModelsInvoiceTaxRate
        - `id` string, uuid, nullable — Unique identifier of the tax rate in Qargo.
        - `name` string, nullable — Name of the Tax rate in Qargo.
        - `percentage` number, nullable
        - `code` string, nullable — Code of the tax rate item in the accounting software.
        - `tax_type` 'VAT' | 'NO_VAT' | 'REVERSE_CHARGE' | 'TRANSIT' | 'CO_CONTRACTING' | 'OTHER'
      - `currency` string, required — Currency of the line item.
      - `references` object, nullable — References associated with this line item.
    - `attachments` EInvoiceAttachment[], nullable — List of document attachments associated with this e-invoice.
      - `document` EInvoiceDocumentAttachment, required
        - `base64` string, required — Base64 encoded content of the document attachment.
        - `content_type` string, required — MIME type of the document attachment, e.g., 'application/pdf', 'application/xml'.
        - `document_type` 'INVOICE' | 'CREDIT_NOTE' | 'OTHER', required
        - `filename` string, required — Filename of the document attachment.
    - `invoice_type` 'PURCHASE_CREDIT_NOTE', required — Indicates that this is a purchase credit note.
  - string, binary

## Response `200`

Successful Response

- unknown

## Other responses

- `400` — Bad Request — invalid input or malformed request
- `401` — Unauthorized — missing or invalid authentication credentials
- `403` — Forbidden — insufficient permissions for this operation
- `422` — Validation Error
- `429` — Too Many Requests — rate limit exceeded. See the `Retry-After` header
- `500` — Internal Server Error
- `503` — Service Unavailable — temporarily unable to handle the request

---

[API](https://skmtc.dev/qargo/apis/qargo-tms-api.md) · [All operations](https://skmtc.dev/qargo/apis/qargo-tms-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/qargo/qargo-tms-api/revisions/17297902e7ce/schema)
