Introduction
Electronic invoicing is mandatory for all businesses in Italy. The Sistema di Interscambio (SDI) serves as the Italian governmentโs central hub for transmitting, validating, and delivering all electronic invoices throughout the country. The SDI system operates using a standardized XML format called FatturaPA, which ensures all invoices contain the required information and comply with the strict validation rules established by the Italian tax authority (Agenzia delle Entrate). To ensure proper routing of invoices to the correct recipient, the SDI system uses a unique identifier called a Recipient Code, which is assigned to each registered SDI provider. Invopop simplifies SDI integration by allowing you to work with GOBL format instead of XML, providing synchronous validation before submission, and offering a simple API integration with automatic handling of SDI notifications and status updates. For receiving invoices through SDI, see our companion guide: Italy - SDI: Receiving Invoices.Setup
Connect the SDI Italy app
- Navigate to Configuration โ Apps
- Locate SDI Italy in the app discovery list
- Tap Connect to activate

Configure sending workflow
SDI does not have a sandbox environment. When
sandbox mode is selected, Invopopโs third-party submission service, A-Cube, simulates a response from SDI.Sending Invoices
Invopop uses the GOBL FatturaPA library to process conversions. When creating invoices for SDI, you need to:- Set the
regimefield toITin your GOBL invoice - Add the
it-sdi-v1addon to enable Italian-specific validations and extensions
How the Send step works
This step generates the FatturaPA XML and sends it to SDI through our integration partner. Upon successful completion, the XML file is attached to the invoice entry. The SDI service usually responds within seconds but may take up to 24 hours. While waiting, this step remains in aQueued state.
When the Send step completes, it returns one of three results:
OKif successfulKOfor unrecoverable errorsSKIPif the invoice was already sent
Example Invoices
B2C Standard Invoice
B2C Standard Invoice
In this example, weโre issuing a standard B2C invoice from an Italian supplier to a consumer.Notice:
- the minimal version (
sdi-b2c.min.mdx) contains only the essential fields required to create the invoice, - the
it-sdi-v1addon ensures the document will be validated using the SDI (Sistema di Interscambio) rules built into the GOBL library, - customer details may be simplified for B2C transactions as per Italian requirements,
- there are no totals or calculations in the minimal version; all these will be calculated automatically when running
gobl build, - the built version (
sdi-b2c.mdx) shows the normalized document with calculated totals, line item sums, IVA (VAT) breakdowns, and automatically generated fields, and, - make sure to process it with the SDI workflow to transmit the invoice to the Italian tax authority.
B2B Invoice
B2B Invoice
In this example, weโre issuing a standard B2B invoice from an Italian supplier to another Italian business customer.Notice:
- both supplier and customer have their Partita IVA (VAT number) and Codice Fiscale properly specified,
- the minimal version contains only essential fields;
gobl buildhandles all calculations, - when running
gobl build, the system automatically calculates totals, applies IVA rates, and normalizes the document according to SDI requirements, - the built version shows all calculated fields including tax breakdowns, line totals, payment terms, and final amounts,
- the
it-sdi-v1addon validates the document structure for B2B transactions, and, - the invoice will be transmitted through the SDI system and delivered to the customerโs designated channel.
B2B Invoice with Additional Fields
B2B Invoice with Additional Fields
In this example, weโre issuing a comprehensive B2B invoice with additional optional fields such as ordering information, payment details, and document references.Notice:
- this invoice demonstrates advanced SDI features like CIG/CUP codes, payment methods, and bank details,
- the minimal version includes ordering and payment details;
gobl buildcalculates all totals, - when running
gobl build, the system validates all additional fields according to SDI specifications and calculates totals, - the built version shows the complete document with all calculated fields, tax breakdowns, and properly formatted additional information,
- additional fields like
ordering,payment, and document references are important for public administration invoices (B2G), and, - the addon ensures all optional fields are properly validated and formatted for SDI transmission.
VAT Exempt Invoice
VAT Exempt Invoice
In this example, weโre issuing an invoice for goods or services that are exempt from VAT (IVA).Notice:
- the line item includes a tax with
"key": "exempt"indicating this is a VAT-exempt transaction, - the minimal version omits the exemption code extension (
it-sdi-exempt), which will be automatically added duringgobl build, - when running
gobl build, the system calculates totals with zero VAT and validates the exemption structure, - the built version shows the complete document with the exemption code extension (e.g.,
"it-sdi-exempt": "N4") applied to the tax rate, - exemption codes must comply with SDI requirementsโconsult the complete list of exemption reasons in the GOBL documentation,
- common exemption codes include N4 (exempt), N3.1 (exports), N3.2 (intra-community supplies), and N6.x (reverse charge scenarios), and,
- the SDI validates that exempt invoices include proper exemption codes before transmission.
Credit Note
Credit Note
In this example, weโre issuing a credit note (nota di credito) to correct or refund a previously issued invoice.Notice:
- the
typefield is set tocredit-noteto indicate this is a corrective document, - the
precedingfield references the original invoice being corrected, - the minimal version contains only essential correction details;
gobl buildcalculates negative amounts, - when running
gobl build, the system automatically calculates negative totals, IVA refunds, validates the credit note structure, and applies SDI rules, - the built version shows all calculated fields including negative amounts for the refund and proper tax adjustments,
- credit notes must be properly linked to the original invoice and transmitted through SDI, and,
- the SDI system validates the credit note format before accepting and forwarding it to the recipient.
Technical Details
SDI Response Codes and Statuses
SDI Response Codes and Statuses
When the SDI step processes a document, it returns detailed status codes that provide information about the response from SDI:
Some SDI notifications (File metadati - MT, Esito committente - EC, Scarto esito committente - SE) donโt directly change the code of the invoice.These codes map to different step results as follows:
| Code | Description |
|---|---|
rejected | Notifica di scarto (NS) SDI has rejected the invoice because it contains errors. |
delivered | Ricevuta consegna (RC) SDI has successfully delivered a B2B invoice to the recipient. |
delivered-pa | Ricevuta consegna (RC) SDI has successfully delivered an invoice to a Public Administration (PA). |
not-delivered | Mancata consegna (MC) SDI could not deliver the invoice to the recipient. |
not-delivered | Attestazione trasmissione con impossibilitร di recapito (AT) SDI couldnโt deliver an invoice to PA after 10 days. |
accepted-pa | Notifica esito (NE) A PA has decided to accept an invoice (outcome EC01). |
rejected-pa | Notifica esito (NE) A PA has decided to reject an invoice (outcome EC02). |
deadline-terms | Notifica decorrenza termini (DT) A PA didnโt reply with acceptance or rejection within 15 days. |
invoice-error | An error occurred during the acquisition of a notification. |
sent | The invoice has been submitted to SDI and is awaiting a response. |
not-received | The invoice was not received by the recipient. |
- OK Result:
delivered,not-delivered,not-received,accepted-pa - KO Result:
rejected,rejected-pa,invoice-error,deadline-terms - QUEUED Result:
sent,delivered-pa
QUEUED, the workflow will check again later for updates from SDI.๐ฎ๐น Invopop resources for Italy
๐ฎ๐น Invopop resources for Italy
Italy FAQ
Find answers to frequently asked questions about invoicing in Italy โ
Participate in our community
Ask and answer questions about invoicing in Italy โ
