Inicio  |  Timbrado  |  2.2. WebServices  |  2.2.1. WS Timbrado  |  2.2.1.4. Timbrado.cancelarBase64 Doc
La LCO fue actualizada por última vez el 23/nov/2024

2.2.1.4. Timbrado.cancelarBase64 Doc

Note: we recommend the webservice method: cancelarAsincrono be use instead.

Cancel one or several invoices.

Cancelation examples in testing environment.

Paremeters:

Name Description Required
usuario Username Yes
password User's password. Yes
uuids String array of fiscal ids (UUIDs) of each invoice. Yes
derCertCSDBase64 Base64-codified string of the CSD to be use for the cancelation request, it must be the same used to generate the digital seal (sello digital) of the invoice. Yes
derKeyCSDBase64 Base64-codified string of the CSD's private key, it must be the same used to generate the digital seal (sello digital) of the invoice. Yes
contrasenaCSD Private key's password, it must be the same used to generate the digital seal (sello digital) of the invoice. Yes

Request example:

Download this example

Returns:

This method returns a complex type: CFDICancelacion, with the following attributes:
Name Description Required
status Operation status' code. See cancelation response codes. Yes
mensaje The response message, a string detailing the status. Yes
resultados Array of complex type: CFDIResultadoCancelacion , with the following attributes: No
CFDIResultadoCancelacion's attributes:
Name Description Required
status Invoice cancelation status' code. Yes
mensaje The response message, a string detailing the status. Yes
uuid Fiscal id of the canceled invoice. Yes
statusUUID SAT's response status for the invoice to be canceled. Conditional

Error response example

Download this example

Successful response example:

Download this example

Response codes

Cancellation response codes:

Response code for the validation of the cancellation request prior to sending the request to the SAT service

Code message
200 The cancellation process completed successfully.
211 The CFDI cancellation request with fiscal folio XXXXXXXXXX is in process.
500 An error occurred. The validation and certification process was not completed.
501 An internal database communication error has occurred, try again.
601 Authentication error, username and/or password are incorrect.
602 his user's account has been blocked.
603 This user's password has expired.
604 Maximum login attempts exceeded.
605 This user is inactive
611 Received data is incomplete or not where expected.
620 Permission denied.
621 Invalid argument format or structure for the data type.
630 The implementation has no folios available.
631 The user's account has no timbres available.
633 Improper use of production account in tests or test account in production.
640 Inactive application.
1701 The CSD's public & private keys do not match.
1702 The private key's password is incorrect.
1703 The private key does not have the proper structure.
1704 The private key is not a RSA key.
1710 The certificate's structure does not have a proper X509 structure.
1711 The certificate is not yet valid.
1712 The certificate has expired.
1713 The public key in this certificate is not a RSA key.

SAT cancellation request status codes:

They correspond to the CodEstatus in the response of the SAT cancellation service

Code message
CFDI Cancellation CodEstatus
300 Invalid User.
301 Malformed XML.
302 Malformed Seal.
304 Revoked or Expired Certificate.
305 Invalid Certificate.
310 Invalid CSD.
CodeStatus of Retentions CFDI cancellation
1300 Invalid authentication.
1301 Malformed XML.
1302 Invalid folios structure.
1303 Invalid RFC Structure.
1304 Invalid date structure.
1305 Certificate does not correspond to the issuer.
1306 Certificate not valid.
1307 Use of FIEL not permitted.
1308 Certificate revoked or expired.
1309 Malformed or invalid signature.
1313 Request outside the annual declaration.
1314 invalid relation.

Códigos de estatus UUID del SAT:

Correspondiente con el estatus de cada UUID del que se ha solicitado la cancelación, devuelto por el servicio de cancelación del SAT

Código Mensaje
201 Solicitud de cancelación recibida.
202 Folio Fiscal Previamente Cancelado
203 Folio Fiscal No Correspondiente al Emisor.
204 Folio Fiscal No Aplicable a Cancelación.
205 Folio Fiscal No Existente.
206 UUID no corresponde a un CFDI del Sector Primario.
207 Folio sustitución Inválido.
208 La Fecha de Solicitud de Cancelación es mayor a la fecha de declaración.
209 La Fecha de Solicitud de Cancelación límite para factura global.
310 CSD Inválido.
311 Clave de motivo de cancelación no válida.
312 UUID no relacionado de acuerdo a la clave de motivo de cancelación.
Estatus UUID de cancelación de CFDI de Retenciones
1201 Solicitud de cancelación recibida.
1202 UUID Previamente cancelado
1203 UUID no corresponde con el emisor
1205 UUID No existe

Note: one can only be certain an invoice has been canceled when its statusUUID is 202 (The invoice had already been canceled).

Datos de contacto
comments powered by Disqus