Skip to content

SiatAnular

Cancels a previously issued invoice in the SIN’s SIAT in Bolivia, identifying it by its CUF (Unique Invoicing Code) and providing a reason code from the SIN’s official catalog (for example, an invoice issued by mistake or a correction via a credit-debit note).

Just like issuance, cancellation requires a valid CUFD (either passed in or taken from the credential); without it, the node never reaches out to the SIN. Once the SIN confirms the cancellation, the document’s internal status becomes cancelled.

FieldTypeRequiredDescription
credentials_idcredentialsYessiat credential
cuftextYesCUF of the invoice to cancel
codigo_motivotextYesCancellation reason code (SIN catalog). Defaults to “1”
cufdtextNoValid CUFD (if not in the credential)

This module requires a siat credential type with the following fields:

  • Digital certificate (.p12): signing certificate, or alternatively private key + certificate in PEM
  • Certificate password: password for the .p12 file
  • Issuer NIT: tax ID of the company issuing invoices
  • SIN token/apikey: access token for the SIAT services (or delegated token)
  • Environment: testing/pilot or production
{
"cuf": "8A1B2C3D4E5F60718293A4B5C6D7E8F9",
"estado": "cancelled",
"codigoMotivo": "1"
}
{
"credentials_id": "cred-siat-prod",
"cuf": "8A1B2C3D4E5F60718293A4B5C6D7E8F9",
"codigo_motivo": "1",
"cufd": "ABCDEFGHIJK0123456789LMNOPQRSTUVWXYZ"
}
  • Requires a valid CUFD (either passed in or taken from the credential); without it, the node stops before calling the SIN.
  • The reason code follows the SIN’s official catalog (for example 1 for an invoice issued by mistake); it’s worth checking the current catalog before cancelling.
  • If the SIN rejects the cancellation, the node returns an error with the received messages and the document keeps its previous status.
  • Once confirmed, the document’s internal status (issued invoices table) becomes cancelled.