BR-KSA-06ErrorZATCA Phase 2 UBL 2.1implemented
ZATCA Transaction Code Format NNPNESB (KSA-2)
cbc:InvoiceTypeCode/@name must be a 7-digit code starting with '01' (Standard) or '02' (Simplified) followed by 5 binary flags (Third-party, Nominal, Export, Summary, Self-billed).
- Scope
- Document Header
- Applicable Invoice Types
- Standard (B2B), Simplified (B2C), Credit Note, Debit Note
- Catalog Version
- v1.0.0 (2026-11-23)
- Target XPath
/Invoice/cbc:InvoiceTypeCode/@name
Typical Reason for Failure
Developers omit the @name attribute or pass '01' instead of the full 7-character pattern '0100000'.
Invalid Synthetic Example
Before (Fails)xml
<cbc:InvoiceTypeCode name="01">388</cbc:InvoiceTypeCode>Corrected Synthetic Example
After (Fixed)xml
<cbc:InvoiceTypeCode name="0100000">388</cbc:InvoiceTypeCode>Explanation of the Fix
Provide all 7 characters matching ^(01|02)[01]{5}$.
Official Source Reference
ZATCA Electronic Invoice XML Implementation Standard (Phase 2)
Open official specificationTest your invoice against BR-KSA-06 now
Browser quick check; raw XML is never stored.