# VF-1232

Source: https://xmlvalid.com/rules/VF-1232

> Si se identifica a través de la agrupación IDOtro y CodigoPais tiene valor ES (España), el campo IDType debe valer Pasaporte (03).

- Level: error
- Rule sets: VERI*FACTU checks of the AEAT Validaciones 1.2.2 (8 April 2026)
- Context: `/*:RegFactuSistemaFacturacion/*:RegistroFactura/*:RegistroAnulacion`
- Test: `not(normalize-space(*:GeneradoPor) = 'T' and normalize-space(*:Generador/*:IDOtro/*:CodigoPais) = 'ES') or normalize-space(*:Generador/*:IDOtro/*:IDType) = '03'`

> Si se identifica a través de la agrupación IDOtro y CodigoPais tiene valor ES (España), el campo IDType debe valer Pasaporte (03).

- Level: error
- Rule sets: VERI*FACTU checks of the AEAT Validaciones 1.2.2 (8 April 2026)
- Context: `/*:RegFactuSistemaFacturacion/*:RegistroFactura/*:RegistroAlta/*:Tercero/*:IDOtro`
- Test: `normalize-space(*:CodigoPais) != 'ES' or normalize-space(*:IDType) = '03'`

In English: A third party identified by IDOtro with CodigoPais ES must have IDType 03 (passport).

Validate a document against these rules: https://xmlvalid.com/validate
