Create SdI / FatturaPA Invoice (XML)
pop_create_sdi_invoiceGenerate Italian FatturaPA e-invoices as XML, with optional submission to the SdI exchange system for B2B/B2C delivery.
Instructions
Generate an Italian FatturaPA electronic invoice in XML format and optionally submit it to the SdI (Sistema di Interscambio).
This tool creates a compliant FatturaPA XML document that satisfies Italian e-invoicing regulations (D.Lgs. 127/2015). The invoice can be generated locally (XML only) or submitted directly to SdI for B2B/B2C delivery.
Key facts:
Supports invoice types: TD01 (invoice) and TD04 (credit note)
Customer types: private, company, freelance, pa (Public Administration)
For Private customers: sdi_type must be '0000000' and tax_id_code (codice fiscale) is required
For PA customers: use version='FPA12' and the 6-char PA office code as sdi_type
VAT rates: 22%, 10%, 5%, 4%, 0% (with nature code required when 0%)
Submission to SdI requires Growth+ plan with active SdI via POP integration
Returns: XML document string when not submitting, or JSON with UUID when submitting.
Args:
data: Complete invoice data (transmitter, supplier, customer, line items, payment)
submit_to_sdi: Set true to automatically submit to SdI (requires active integration)
integration: Override integration config (sdi-via-pop, pop-to-webhook, fatture-in-cloud)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | Yes | Full invoice data object | |
| site_url | No | Site/shop URL | |
| site_title | No | Site/shop title | |
| environment | No | Target environment (e.g. 'sandbox') | |
| integration | No | Integration configuration — use this to override the default behaviour or deliver via webhook/Fatture in Cloud. Overrides submit_to_sdi if set. | |
| submit_to_sdi | No | If true, automatically submits the invoice to the Italian SdI (Sistema di Interscambio). Requires active SdI via POP integration (Growth+ plan). | |
| plugin_version | No | Caller application version |