> For the complete documentation index, see [llms.txt](https://docs.docbits.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.docbits.com/administration-and-setup/settings/global-settings/document-types/edi/supported-electronic-documents/chile-dte.md).

# CHILE DTE

CHILE DTE electronic document support in DocBits

{% hint style="info" %}
Check the country guide for version limits, effective configuration and the country explainer. [Chile](/administration-and-setup/settings/global-settings/document-types/edi/supported-electronic-documents/chile.md). Select the business document type before checking fields. Invoice, credit note and delivery information use different mappings.
{% endhint %}

| Property             | Value                                                      |
| -------------------- | ---------------------------------------------------------- |
| **Country / Region** | Chile                                                      |
| **Document Types**   | Invoice (Factura), Credit Note, Debit Note, Dispatch Guide |
| **Format**           | XML                                                        |
| **Standard**         | DTE (Documento Tributario Electrónico), SII                |
| **Locale**           | `es_CL`                                                    |

DTE (Documento Tributario Electrónico) is the Chilean electronic tax document standard regulated by the Servicio de Impuestos Internos (SII). All DTE documents share the `http://www.sii.cl/SiiDte` namespace. DocBits auto-detects the DTE type code (`TipoDTE`) and routes to the appropriate extraction rules:

| Type Code | Document Type                                   |
| --------- | ----------------------------------------------- |
| 33        | Factura Electrónica (Invoice)                   |
| 34        | Factura No Afecta o Exenta (Tax-exempt invoice) |
| 52        | Guía de Despacho (Dispatch Guide)               |
| 56        | Nota de Débito (Debit Note)                     |
| 61        | Nota de Crédito (Credit Note)                   |

## Support Status

| Component        | Status      |
| ---------------- | ----------- |
| Preview          | ✅ Supported |
| Field Extraction | ✅ Supported |
| Transformation   | ✅ Supported |

## Default Preview

<figure><img src="https://578966019-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FT2n2w4uDCJvv7CJ5zrdk%2Fuploads%2Fgit-blob-14dc1f633a0d81a27cd82ba4774783fdf6d05312%2Fchile-dte-preview.png?alt=media" alt="Chile DTE Factura preview in DocBits"><figcaption><p>Default DocBits preview for a CHILE DTE FACTURA (type 33)</p></figcaption></figure>

## Field Mapping

### Header Fields

| DocBits Field      | Source XML Element | Notes                          |
| ------------------ | ------------------ | ------------------------------ |
| `invoice_id`       | `Folio`            | Document folio number          |
| `invoice_date`     | `FchEmis`          | ISO 8601 emission date         |
| `due_date`         | `FchVenc`          | Payment due date               |
| `currency`         | Fixed: `CLP`       | Always Chilean Peso            |
| `total_amount`     | `MntTotal`         | Total amount incl. VAT         |
| `net_amount`       | `MntNeto`          | Net taxable amount             |
| `tax_amount`       | `IVA`              | VAT amount (19% standard rate) |
| `supplier_name`    | `RznSoc` (Emisor)  | Issuer company name            |
| `supplier_id`      | `RUTEmisor`        | Issuer RUT (e.g. `76123456-7`) |
| `supplier_address` | `DirOrigen`        | Issuer street address          |
| `supplier_city`    | `CiudadOrigen`     | Issuer city                    |
| `supplier_country` | Fixed: `CL`        | Always Chile                   |
| `buyer_name`       | `RznSocRecep`      | Recipient company name         |
| `buyer_id`         | `RUTRecep`         | Recipient RUT                  |
| `buyer_address`    | `DirRecep`         | Recipient street address       |
| `buyer_city`       | `CiudadRecep`      | Recipient city                 |
| `buyer_country`    | Fixed: `CL`        | Always Chile                   |

### Line Item Table (`INVOICE_TABLE`)

Row path: `Detalle`

| Column        | Source XML Element      | Notes                         |
| ------------- | ----------------------- | ----------------------------- |
| `POSITION`    | `NroLinDet`             | Line sequence number          |
| `DESCRIPTION` | `NmbItem`               | Item name                     |
| `QUANTITY`    | `QtyItem`               | Quantity                      |
| `UNIT`        | `UnmdItem`              | Unit of measure               |
| `UNIT_PRICE`  | `PrcItem`               | Unit price excl. VAT          |
| `VAT_RATE`    | `TasaIVA` (from header) | IVA rate in % (typically 19%) |
| `VAT`         | Calculated              | VAT per line                  |
| `NET_AMOUNT`  | `MontoItem`             | Line total                    |

## Classification Rules

DocBits detects Chile DTE documents by matching the XML namespace and `TipoDTE`:

| Electronic Document Type      | Pattern                                              |
| ----------------------------- | ---------------------------------------------------- |
| CHILE DTE FACTURA             | `http://www.sii.cl/SiiDte` + `<TipoDTE>33</TipoDTE>` |
| CHILE DTE FACTURA ELECTRONICA | `http://www.sii.cl/SiiDte` + `<TipoDTE>34</TipoDTE>` |
| CHILE DTE GUIA DESPACHO       | `http://www.sii.cl/SiiDte` + `<TipoDTE>52</TipoDTE>` |
| CHILE DTE NOTA CREDITO        | `http://www.sii.cl/SiiDte` + `<TipoDTE>61</TipoDTE>` |

The envelope element is `<EnvioDTE>` and each DTE is wrapped in `<DTE><Documento>`.

## Related

* [Currently Supported E-Invoice Standards](https://github.com/Fellow-Consulting-AG/docbits/tree/main/readme/administration-and-setup/settings/global-settings/document-types/currently-supported-e-invoice-standards/README.md)
* [Supported Electronic Documents](/administration-and-setup/settings/global-settings/document-types/edi/supported-electronic-documents.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.docbits.com/administration-and-setup/settings/global-settings/document-types/edi/supported-electronic-documents/chile-dte.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
