SriEmitirNota
Description
Section titled “Description”Issues a Credit Note (type 04) or a Debit Note (type 05) to Ecuador’s SRI. Both reference the modified document (docModificado: type, number and date of the original invoice). The node builds the XML, computes the access key, signs it and runs the same two-step flow as an invoice: reception and authorization.
The Credit Note carries items (just like an invoice, to void or correct amounts); the Debit Note carries motivos[] (reason and amount) for additional charges on the original document.
Configuration
Section titled “Configuration”| Field | Type | Required | Description |
|---|---|---|---|
| credentials_id | credentials | Yes | SRI credential |
| nota | json | No | Note JSON: tipo (04 credit, 05 debit), comprador, docModificado (tipo, numero, fecha). The credit note carries items; the debit note carries motivos[] (razon, valor). If omitted, the previous node’s input is used |
Credentials
Section titled “Credentials”This module requires an sri credential type with the following fields:
- Certificate (.p12): the issuer’s digital certificate, PKCS#12 format
- Certificate password: password to open the .p12 file
- RUC: issuer’s tax ID (13 digits)
- Environment:
pruebas(testing) orproducción(production)
Output
Section titled “Output”{ "claveAcceso": "0512202504179001234500110010010000000021234567822", "tipo": "04", "estado": "authorized", "numeroAutorizacion": "0512202504179001234500110010010000000021234567822", "docModificado": { "tipo": "01", "numero": "001-001-000000001" }, "total": 100.00, "xml": "<?xml version=\"1.0\"?><autorizacion>...</autorizacion>"}Usage Example
Section titled “Usage Example”Credit note for a full invoice refund
Section titled “Credit note for a full invoice refund”{ "credentials_id": "cred-sri-prod", "nota": { "tipo": "04", "comprador": { "tipoIdentificacion": "05", "identificacion": "1712345678", "razonSocial": "Juan Pérez" }, "docModificado": { "tipo": "01", "numero": "001-001-000000001", "fecha": "2025-12-01" }, "motivo": "Product return", "items": [ { "codigo": "0001", "descripcion": "Cotton shirt, size M", "cantidad": 1, "precioUnitario": 100.00, "codigoPorcentajeIva": 4 } ] }}Debit note for an additional charge
Section titled “Debit note for an additional charge”{ "credentials_id": "cred-sri-prod", "nota": { "tipo": "05", "comprador": { "tipoIdentificacion": "04", "identificacion": "1790012345001", "razonSocial": "Comercial Andina S.A." }, "docModificado": { "tipo": "01", "numero": "001-001-000000002", "fecha": "2025-12-01" }, "motivos": [ { "razon": "Late payment interest", "valor": 12.50 } ] }}motivo(Credit Note) anddocModificadoare mandatory; without the referenced document the SRI rejects the note.- Just like the invoice, the note is only valid once the SRI AUTHORIZES it.
- If the note is left IN PROCESSING, reconcile its status with SriConsultarAutorizacion.
Related Nodes
Section titled “Related Nodes”- SriEmitirFactura - Issue the original invoice to reference
- SriConsultarAutorizacion - Reconcile documents left IN PROCESSING
- SriRIDE - Generate the RIDE with QR for the issued note