facturaBoNota
Description
Section titled “Description”Issues a credit or debit note. “From invoice” is the simplest: give the CUF and which lines and quantities are returned and factura.bo computes the note (sector 24 or 47). “Manual” sends all the data yourself (sectors 24, 47 or 48 with ICE): lines in pairs (1 = copy of the original, 2 = adjustment) and the node computes the amounts. It also queries the quantities still returnable.
Part of the Bolivia Fiscal Hub as an alternative to connecting directly to the SIAT: factura.bo (SimplifyIT S.R.L.) is a provider that builds and signs the XML and sends it to the SIN. Node: «Nota de crédito/débito».
Configuration
Section titled “Configuration”| Field | Type | Required | Description |
|---|---|---|---|
| credentials_id | credentials | Yes | facturabo credential |
| operation | select | Yes | Operation — from_invoice, available, manual |
| cuf | text | No | CUF — Unique Invoice Code (returned on issue) |
| note_sector | select | No | Note sector — "", 24, 47, 48 |
| returned_items | json | No | Returned lines (JSON, from invoice) — nro_item_original = line number in the original invoice; quantity normalised to 2 decimals |
| branch_code | number | No | Branch (SIAT code) — 0 = head office. Empty = the credential default branch |
| point_of_sale_code | number | No | Point of sale (SIAT code) — 0 = main point. Empty = the credential one |
| user | text | No | User / cashier |
| external_reference | text | No | External reference — Up to 200 characters |
| reason | text | No | Reason — Up to 500 characters |
| client_document_type | select | No | Client document type — 5, 1, 2, 3, 4 |
| client_document_number | text | No | Client document (manual) |
| client_business_name | text | No | Business name (manual) |
| client_email | text | No | Client email (manual) |
| original_invoice_number | number | No | Original invoice number (manual) |
| original_issue_date | text | No | Original invoice date (manual) |
| original_total | number | No | Original invoice total (manual) |
| items | json | No | Note lines (JSON, manual) — For each adjusted item, one line with codigo_detalle_transaccion 1 (identical to the original) and one with 2 (the adjustment). At least 2 lines |
| returned_total | number | No | Returned amount (manual, optional) — Empty = sum of type 2 lines |
| credit_debit_amount | number | No | Note fiscal amount (manual, optional) — Empty = 13% of the returned amount |
| credit_debit_discount | number | No | Discount proration (manual, optional) |
| payment_method_code | number | No | Payment method (manual) |
| idempotency_mode | select | No | Duplicate protection — With a key, a retry after a failure does not duplicate the invoice: the API returns the one already issued (keys are remembered for 30 days). For two identical invoices in a loop use a manual key (e.g. the order id) · auto, manual, off |
| idempotency_key | text | No | Idempotency key — 1–128 visible characters, no spaces. Recommended: the sale id |
| output_key | text | No | Output key — The result is added to data[key] keeping the rest of the data |
Credentials
Section titled “Credentials”This module requires a credential of type facturabo with the fields:
- API key: get it at app.factura.bo → More → API Key
- Environment: testing (sandbox, pilot SIAT) or production; the key does not reveal it, you choose
- NIT and SIAT system code: to sync CUIS/CUFD and catalogs
- Default branch and point of sale: 0 = head office / main point
- Webhook secret (
whsec_…): to verify event signatures
Output
Section titled “Output”{ "success": true, "operation": "from_invoice", "original_cuf": "2872F7294502332E637FABFBC3654EA82202AD48E0969F14EBEB8AF74", "note": { "cuf": "NOTACUF…", "invoice_number": 3, "state": "EMITIDA", "issued_at": "2026-10-26T10:00:00", "url_public": "https://api.factura.bo/f/2872F7294502332E637FABFBC3654EA82202AD48E0969F14EBEB8AF74", "url_pdf": "https://…/pdf", "url_xml": "https://…/xml", "url_ticket": "https://…/ticket", "siat_response": { "codigoEstado": 908 } }, "urls": { "verify": "https://api.factura.bo/f/2872F7294502332E637FABFBC3654EA82202AD48E0969F14EBEB8AF74", "pdf": "https://api.factura.bo/f/2872F7294502332E637FABFBC3654EA82202AD48E0969F14EBEB8AF74/pdf", "ticket": "https://api.factura.bo/f/2872F7294502332E637FABFBC3654EA82202AD48E0969F14EBEB8AF74/ticket", "xml": "https://api.factura.bo/f/2872F7294502332E637FABFBC3654EA82202AD48E0969F14EBEB8AF74/xml" }, "idempotency": { "key": "floogos-exec-1-node-1-8c21…", "mode": "auto" }, "warnings": [], "environment": "production"}The output is stored under the configured key (output_key, default facturabo) and the rest of data is kept. On error: error.message, error.type and, where applicable, status and siat_code.
Usage Example
Section titled “Usage Example”{ "credentials_id": "cred-facturabo", "operation": "from_invoice", "cuf": "2872F7294502332E637FABFBC3654EA82202AD48E0969F14EBEB8AF74", "returned_items": [ { "nro_item_original": 1, "cantidad": 1 } ], "reason": "Devolución parcial"}- “From invoice” is the simplest: give the CUF and which lines (
nro_item_original) and quantities are returned; factura.bo computes the note (sector 24, the most common, or 47). Its idempotency header is mandatory: even if you turn it off, the node generates it. - “Manual” sends all the data: for each adjusted item, one line with
codigo_detalle_transaccion1 (exact copy of the original) and one with 2 (the adjustment); at least 2 lines. The node computesmonto_total_devuelto(over type 2 lines) andmonto_efectivo_credito_debito(13% of it) and warns if what you give does not match. - “See returnable quantities” queries what can still be returned from each line.
- Rejection 1049 means a type 1 line does not replicate the original.
Related Nodes
Section titled “Related Nodes”- facturaBoEmitirFactura - Emitir factura
- facturaBoAnular - Anular o revertir factura
- facturaBoConsultar - Consultar facturas