E-Invoice Lines

Table name: e_invoice_lines

One row per line item of the e-invoice documents in E-Invoices. Amounts are in major units of the document currency, rounded to 2 decimals per line. Lines of credit notes carry negative quantities and amounts, as sent to the buyer.

SQL: e_invoice_lines

Schema

Column NameData TypeDescription
Primary ID
idINTEGERPrimary key, unique identifier of the document line
Other IDs
e_invoice_document_idINTEGERID of the e-invoice document. References e_invoices.id
Timestamps
created_atTIMESTAMP_NTZTimestamp when the line was created
updated_atTIMESTAMP_NTZTimestamp when the line was last updated
deleted_atTIMESTAMP_NTZTimestamp when the line itself was soft deleted, null if not deleted
document_deleted_atTIMESTAMP_NTZTimestamp when the parent document was soft deleted, null if not deleted. Lines of deleted documents are not returned by the Partner API
Item
item_nameVARCHARName of the item charged for
item_descriptionVARCHARLonger description of the item charged for
unit_codeVARCHARUN/ECE Recommendation 20 code of the unit the quantity is measured in
quantityFLOATQuantity charged for, in unit_code units. Negative on credit notes
unit_priceFLOATPrice per unit excluding VAT, in major units
Tax
tax_categoryVARCHARVAT category applied to the line (for example standard, exempt, reverse charge)
tax_percentFLOATVAT rate applied, as a percentage
tax_country_codeVARCHARISO 3166-1 alpha-2 country whose VAT rules apply
Amounts
net_amountNUMBERLine total excluding VAT, in major units (quantity * unit_price, rounded to 2 decimals); negative on credit notes
vat_amountNUMBERVAT on the line, in major units; negative on credit notes
gross_amountNUMBERLine total including VAT, in major units; negative on credit notes
Status
document_statusVARCHARStatus of the parent document, same values as e_invoices.document_status (deleted, delivered, failed, draft, processing, pending, no_submission)

Inclusion Criteria

A line is included if its parent document is in e_invoices, so the scope is the same: documents issued by your teams and operators. Lines of purged documents are kept, with document_deleted_at set. Filter on document_status = 'delivered' to keep the lines of documents the buyer received.

Data flow

Upstream tablesDownstream tables
e_invoices---

Alignment

Monta API

  • Aligns with the line items returned by the Monta API e-invoices endpoint (seller side only)
  • Lines of soft-deleted documents are included here and never returned by the API

Did this page help you?