Corrective invoices in Verifactu (R1–R5)

A corrective invoice is sent with tipo_factura R1 to R5 depending on its reason under the VAT Law, either by substitution or by difference.

FieldValue
APIVerifactu API
Invoice type or keyR1 a R5
When to use itCorrect an invoice already issued: types R1 to R5.

What changes in this case

Corrective invoices are essential documents for correcting errors or modifying data on previous invoices. In the Verifactu API, the creation of a corrective invoice requires indicating the type of corrective invoice through the field tipo_factura. There are five options, each based on specific articles of the VAT Act (Law 37/1992) and its regulations.

The correction can be done by substitution or by difference: each page has its JSON examples.

Corrective invoice types (R1–R5)
TypeAEAT descriptionWhat the rules say
R1Corrective Invoice (Error based on law and Art. 80 One, Two and Six LIVA)When there has been an error based on law or any of the causes of Art. 80.One, Two and Six LIVA (return of goods, discounts or price alterations after the transaction, resolution of transactions, provisional consideration amount), a corrective invoice must be issued with a specific series whose information will be recorded with the invoice type R1. In the case of returns of goods or packaging carried out in connection with a subsequent supply to the same recipient and tax rate, it will not be necessary to issue a corrective invoice; instead, the amount of the returned goods or packaging will be subtracted from the amount of that subsequent transaction, and the result may be positive or negative. The transaction date should be the date on which the delivery was made or the service was provided, as indicated on the original invoice. In the case of correcting multiple invoices with a single corrective invoice, the most recent date should be indicated.
R2Corrective Invoice (Art. 80.Three, insolvency proceedings)When there has been a modification of the VAT taxable base because the client is in insolvency proceedings (Art. 80.Three LIVA), a corrective invoice must be issued with a specific series whose information will be recorded with the invoice type R2. Additionally, the type of corrective invoice must be identified with the keys “S – by substitution” or “I – by difference” depending on how the business owner wishes to carry out the correction. The transaction date should be the date on which the delivery was made or the service was provided, as indicated on the original invoice. In the case of correcting multiple invoices with a single corrective invoice, the most recent date should be indicated. The identification of the corrected invoices is optional. If they are identified, the number and date of issuance must be reported.
R3Corrective Invoice (Art. 80.Four, bad debt)When there has been a modification of the VAT taxable base due to non-collection from the client (Art. 80.Four LIVA), a corrective invoice must be issued with a specific series whose information will be recorded with the invoice type R3. Additionally, the type of corrective invoice must be identified with the keys “S – by substitution” or “I – by difference” depending on how the business owner wishes to carry out the correction. The transaction date should be the date on which the delivery was made or the service was provided, as indicated on the original invoice. In the case of correcting multiple invoices with a single corrective invoice, the most recent date should be indicated. The identification of the corrected invoices is optional. If they are identified, the number and date of issuance must be reported.
R4Corrective Invoice (Other)Invoice type R4 should be used in these situations: When there has been a modification of the VAT taxable base for reasons other than those provided for in Article 80 LIVA and it is not due to an error based on law, a corrective invoice must be issued with a specific series whose information will be recorded with the invoice type R4. Also when a non-monetary datum has been incorrectly recorded on the invoice.
R5Corrective Invoice for simplified invoicesThe correction of a simplified invoice will be recorded with the key R5 regardless of the reason for the correction.

Try this case in the test environment

Create your free account and try these cases with the test API key of your test NIF.

Test environment and test NIF includedRead the documentation