Skip to main content
Key: es-verifactu-v1

Sources

Correction Definitions

Auto-generation of corrective invoices or credit and debit notes is supported.

Extension Keys

One or all of the following extensions may be required as part of the correction options. See the Extensions section for possible values.
  • es-verifactu-doc-type

Extensions

Invoice Type Code

Code used to identify the type of invoice being sent. This will be determined automatically by GOBL during normalization according to the scenario definitions. The codes R2, R3, and R4 are not covered by GOBL’s scenarios and will need to be set manually if needed. Values correspond to L2 list.
CodeName
F1Invoice (Article 6, 7.2 and 7.3 of RD 1619/2012)
F2Simplified invoice (Article 6.1.d) of RD 1619/2012)
F3Invoice issued as replacement of simplified invoice
R1Rectified invoice: articles 80.1, 80.2, and 80.6
R2Rectified invoice: article 80.3
R3Rectified invoice: article 80.4
R4Rectified invoice: other
R5Rectified invoice: simplified invoices

Verifactu Correction Type Code

Correction type code used to identify the type of correction being made. Values map to L3 list. Code is determined automatically according to the invoice type:
Invoice TypeCode
correctiveS
credit-noteI
debit-noteI
CodeName
SSubstitution
IDifferences

Subject and Not Exempt Operation Class Code

Classification code for operations that are subject to tax and not exempt, or for operations not subject to tax. GOBL will attempt to automatically assign operation class codes based on tax key, but if your workflow requires more control, you may prefer to let users select the appropriate operation class and exemption code for each case. Automatic mapping of tax combo keys to operation classes:
Operation ClassTax Key
S1standard, reduced, super-reduced, zero
S2reverse-charge
N1outside-scope
N2outside-scope (default)
This extension maps to the CalificacionOperacion field and must not be used together with the es-verifactu-exempt extension. Values correspond to the L9 list. For further guidance on applying these codes, refer to the AEAT FAQ:
CodeName
S1Subject and Not Exempt - Without reverse charge
S2Subject and Not Exempt - With reverse charge
N1Not Subject - Articles 7, 14, others
N2Not Subject - Due to location rules

Verifactu Exemption Code

Exemption code used to explain why the operation is exempt from taxes. This extension maps to the field OperacionExenta, and cannot be provided alongside the es-verifactu-op-class extension. Values correspond to the L10 list. The follow mappings will be made automatically by GOBL during normalization.
Tax KeyExemption Codes
exemptE1 (default), E6
exportE2 (default), E3, E4
intra-communityE5
CodeName
E1Exempt: pursuant to Article 20. Exemptions in internal operations.
E2Exempt: pursuant to Article 21. Exemptions in exports of goods.
E3Exempt: pursuant to Article 22. Exemptions in operations asimilated to exports.
E4Exempt: pursuant to Articles 23 and 24. Exemptions related to temporary deposit, customs and fiscal regimes, and other situations.
E5Exempt: pursuant to Article 25. Exemptions in the delivery of goods destined to another Member State.
E6Exempt: pursuant to other reasons

VAT/IGIC Regime Code

Identify the type of VAT or IGIC regime applied to the operation. This list combines lists L8A which include values for VAT, and L8B for IGIC. Maps to the field ClaveRegimen, and is required for all VAT and IGIC operations. Values correspond to L8A (VAT) and L8B (IGIC) lists. The regime code must be assigned for each tax combo. If no regime code is provided, GOBL will try to assign a code from the following tax combo contexts:
Combo ContextRegime Code
Key standard01
Key export02
Has surcharge18
CodeName
01General regime operation
02Export
03Special regime for used goods, art objects, antiques and collectibles
04Special regime for investment gold
05Special regime for travel agencies
06Special regime for VAT/IGIC groups (Advanced Level)
07Special cash accounting regime
08Operations subject to a different regime
09Billing of travel agency services acting as mediators in name and on behalf of others
10Collection of professional fees or rights on behalf of third parties
11Business premises rental operations
14Invoice with pending VAT/IGIC accrual in work certifications for Public Administration
15Invoice with pending VAT/IGIC accrual in successive tract operations
17Operation under OSS and IOSS regimes (VAT) / Special regime for retail traders. (IGIC)
18Equivalence surcharge (VAT) / Special regime for small traders or retailers (IGIC)
19Operations included in the Special Regime for Agriculture, Livestock and Fisheries
20Simplified regime (VAT only)

Identity Type Code

Identity code used to identify the type of identity document used by the customer defined in the L7 list. The regular Party Tax Identity is preferred over using a specific identity type code, and will be mapped automatically as follows:
  • Spanish Tax IDs will be mapped to the NIF field.
  • EU Tax IDs will be mapped to the IDOtro field with code 02.
  • Non-EU Tax IDs will be mapped to the IDOtro field with code 04.
VERI*FACTU will perform validation on both Spanish and EU Tax IDs, so it is important to provide the correct details. The following identity key values will be mapped automatically to an extension by the addon for the following keys:
  • passport: 03
  • foreign: 04
  • resident: 05
  • other: 06
The 07 “not registered in census” code is not mapped automatically, but can be provided directly if needed. Example identity of a UK passport:
{
	"identities": [
		{
			"key": "passport",
			"country": "GB",
			"code": "123456789"
		}
	]
}
Will be normalized to:
{
	"identities": [
		{
			"key": "passport",
			"country": "GB",
			"code": "123456789",
			"ext": {
				"es-verifactu-identity-type": "03"
			}
		}
	]
}
CodeName
02NIF-VAT Identity (VIES)
03Passport
04Foreign Identity Document
05Residential Certificate
06Other Identity Document
07Not registered in census

Simplified Invoice Art. 7.2 and 7.3, RD 1619/2012

This extensions covers a specific use-case when the customer specifically requests that the invoice includes their fiscal details, but they are not registered for tax. Maps to the FacturaSimplificadaArt7273 field in Verifactu documents. Can only be true when the invoice type (TipoFactura) is one of: F1, F3, R1, R2, R3, or R4.
CodeName
SYes
NNo

Issuer Type Code

Indicates whether the invoice is issued by a third party or by the customer themselves. Mapped to the field EmitidaPorTerceroODestinatario in Verifactu documents, with list L6. The self-billed tag will automatically be set this extension in the invoice to D. If the issuer field is set in the invoice’s ordering section, then this extension will be set to T.
CodeName
TIssued by Third Party
DIssued by Customer
I