XML generation for prepaid Invoice

Dear zatca team,

Can you please specify the reason of warning on this xml

total invoice 1200 SAR “VAT Inclusive“

Prepaid Invoice 1000 SAR “VAT Inclusive“


--sent XML for validition

<?xml version="1.0" encoding="UTF-8"?><Invoice
xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2"
xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
xmlns:ext="urn:oasis:names:specification:ubl:schema:xsd:CommonExtensionComponents-2">
<cbc:ProfileID>reporting:1.0</cbc:ProfileID>
<cbc:ID>INV1441</cbc:ID>
<cbc:UUID>29ee27c0-f53f-4c04-bc22-db3091b0a5a1</cbc:UUID>
<cbc:IssueDate>2025-08-06</cbc:IssueDate>
<cbc:IssueTime>15:44:41</cbc:IssueTime>
<cbc:InvoiceTypeCode name="0200000">388</cbc:InvoiceTypeCode>
<cbc:DocumentCurrencyCode>SAR</cbc:DocumentCurrencyCode>
<cbc:TaxCurrencyCode>SAR</cbc:TaxCurrencyCode>
<cac:AdditionalDocumentReference>
	<cbc:ID>ICV</cbc:ID>
	<cbc:UUID>1441</cbc:UUID>
</cac:AdditionalDocumentReference>
<cac:AdditionalDocumentReference>
	<cbc:ID>PIH</cbc:ID>
	<cac:Attachment>
		<cbc:EmbeddedDocumentBinaryObject mimeCode="text/plain">aE6Umy+/FGGo3E65g5WaVoe48njinOvQyGLquHuZvKc=</cbc:EmbeddedDocumentBinaryObject>
	</cac:Attachment>
</cac:AdditionalDocumentReference>
<cac:AdditionalDocumentReference>
	<cbc:ID>QR</cbc:ID>
	<cac:Attachment>
		<cbc:EmbeddedDocumentBinaryObject mimeCode="text/plain"></cbc:EmbeddedDocumentBinaryObject>
	</cac:Attachment>
</cac:AdditionalDocumentReference>
<cac:Signature>
	<cbc:ID>urn:oasis:names:specification:ubl:signature:Invoice</cbc:ID>
	<cbc:SignatureMethod>urn:oasis:names:specification:ubl:dsig:enveloped:xades</cbc:SignatureMethod>
</cac:Signature>
<cac:AccountingSupplierParty>
	<cac:Party>
		<cac:PartyIdentification>
			<cbc:ID schemeID="CRN">4123124124</cbc:ID>
		</cac:PartyIdentification>
		<cac:PostalAddress>
			<cbc:StreetName>Test</cbc:StreetName>
			<cbc:BuildingNumber>4124</cbc:BuildingNumber>
			<cbc:CitySubdivisionName>Mecca</cbc:CitySubdivisionName>
			<cbc:CityName>Mecca</cbc:CityName>
			<cbc:PostalZone>41241</cbc:PostalZone>
			<cac:Country>
				<cbc:IdentificationCode>SA</cbc:IdentificationCode>
			</cac:Country>
		</cac:PostalAddress>
		<cac:PartyTaxScheme>
			<cbc:CompanyID>399999999900003</cbc:CompanyID>
			<cac:TaxScheme>
				<cbc:ID>VAT</cbc:ID>
			</cac:TaxScheme>
		</cac:PartyTaxScheme>
		<cac:PartyLegalEntity>
			<cbc:RegistrationName>Ultra Cloud Beauty Salon</cbc:RegistrationName>
		</cac:PartyLegalEntity>
	</cac:Party>
</cac:AccountingSupplierParty>
<cac:AccountingCustomerParty>
    <cac:Party>
        <cac:PartyLegalEntity>
            <cbc:RegistrationName>Tareq Abed Etisalat</cbc:RegistrationName>
        </cac:PartyLegalEntity>
    </cac:Party>
</cac:AccountingCustomerParty>
<cac:AllowanceCharge>
	<cbc:ChargeIndicator>false</cbc:ChargeIndicator>
	<cbc:AllowanceChargeReason>discount</cbc:AllowanceChargeReason>
	<cbc:Amount currencyID="SAR">0.00</cbc:Amount>
	<cac:TaxCategory>
		<cbc:ID schemeID="UN/ECE 5305" schemeAgencyID="6">S</cbc:ID>
		<cbc:Percent>15.00</cbc:Percent>
		<cac:TaxScheme>
			<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
		</cac:TaxScheme>
	</cac:TaxCategory>
	<cac:TaxCategory>
		<cbc:ID schemeID="UN/ECE 5305" schemeAgencyID="6">S</cbc:ID>
		<cbc:Percent>15.00</cbc:Percent>
		<cac:TaxScheme>
			<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
		</cac:TaxScheme>
	</cac:TaxCategory>
</cac:AllowanceCharge>
<cac:TaxTotal>
	<cbc:TaxAmount currencyID="SAR">156.52</cbc:TaxAmount>
</cac:TaxTotal>
<cac:TaxTotal>
	<cbc:TaxAmount currencyID="SAR">156.52</cbc:TaxAmount>
	<cac:TaxSubtotal>
		<cbc:TaxableAmount currencyID="SAR">1043.48</cbc:TaxableAmount>
		<cbc:TaxAmount currencyID="SAR">156.52</cbc:TaxAmount>
		<cac:TaxCategory>
			<cbc:ID schemeID="UN/ECE 5305" schemeAgencyID="6">S</cbc:ID>
			<cbc:Percent>15.00</cbc:Percent>
			<cac:TaxScheme>
				<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
			</cac:TaxScheme>
		</cac:TaxCategory>
	</cac:TaxSubtotal>
</cac:TaxTotal>
<cac:LegalMonetaryTotal>
	<cbc:LineExtensionAmount currencyID="SAR">1043.48</cbc:LineExtensionAmount>
	<cbc:TaxExclusiveAmount currencyID="SAR">1043.48</cbc:TaxExclusiveAmount>
	<cbc:TaxInclusiveAmount currencyID="SAR">1200.00</cbc:TaxInclusiveAmount>
	<cbc:AllowanceTotalAmount currencyID="SAR">0.00</cbc:AllowanceTotalAmount>
	<cbc:PrepaidAmount currencyID="SAR">1000.00</cbc:PrepaidAmount>
	<cbc:PayableAmount currencyID="SAR">200.00</cbc:PayableAmount>
</cac:LegalMonetaryTotal>
	<cac:InvoiceLine>
	<cbc:ID>1</cbc:ID>
	<cbc:InvoicedQuantity unitCode="PCE">1.000000</cbc:InvoicedQuantity>
	<cbc:LineExtensionAmount currencyID="SAR">1043.48</cbc:LineExtensionAmount>
	<cac:TaxTotal>
		<cbc:TaxAmount currencyID="SAR">156.52</cbc:TaxAmount>
		<cbc:RoundingAmount currencyID="SAR">1200.00</cbc:RoundingAmount>
	</cac:TaxTotal>
	<cac:Item>
		<cbc:Name>Waxing Full Hands | واكس كامل اليد</cbc:Name>
		<cac:ClassifiedTaxCategory>
			<cbc:ID>S</cbc:ID>
			<cbc:Percent>15.00</cbc:Percent>
			<cac:TaxScheme>
				<cbc:ID>VAT</cbc:ID>
			</cac:TaxScheme>
		</cac:ClassifiedTaxCategory>
	</cac:Item>
	<cac:Price>
		<cbc:PriceAmount currencyID="SAR">1043.480000</cbc:PriceAmount>
		<cac:AllowanceCharge>
			<cbc:ChargeIndicator>false</cbc:ChargeIndicator>
			<cbc:AllowanceChargeReason>discount</cbc:AllowanceChargeReason>
			<cbc:Amount currencyID="SAR">0.00</cbc:Amount>
		</cac:AllowanceCharge>
	</cac:Price>
</cac:InvoiceLine>
</Invoice>

response:

{“validationResults”:{“infoMessages”:[{“type”:“INFO”,“code”:“XSD_ZATCA_VALID”,“category”:“XSD validation”,“message”:“Complied with UBL 2.1 standards in line with ZATCA specifications”,“status”:“PASS”}],“warningMessages”:[{“type”:“WARNING”,“code”:“BR-KSA-80”,“category”:“KSA”,“message”:" The Pre-Paid amount (BT-113) must be equal to the sum total of the Prepayment VAT category Taxable Amount (KSA-31) and the Prepayment VAT Category Tax Amount (KSA-32).",“status”:“WARNING”},{“type”:“WARNING”,“code”:“BR-KSA-73”,“category”:“KSA”,“message”:“If Pre-Paid amount (BT-113) is provided, then the following data is mandatory to provide as additional invoice line(s) Prepayment ID (KSA-26) ; Sequential invoice number (BT-1) of the prepayment invoice(s) Prepayment Issue Date (KSA-28) ; Issue date (BT-2) of the prepayment invoice(s) Prepayment Issue Time (KSA-29) ; Issue time (KSA-25) of the prepayment invoice(s) Prepayment Document Type Code (KSA-30); Invoice type code (BT-3) must be 386”,“status”:“WARNING”}],“errorMessages”:,“status”:“WARNING”},“reportingStatus”:“REPORTED”}

thanks

@ucitco you need to provide the document reference to Original Prepaid Invoice (IRN, UUID, Issue Date and time of prepaid invoice) and Taxable Amount and tax amount of prepaid invoice. Please go through Section 8 of the Detailed Guideline https://zatca.gov.sa/en/E-Invoicing/Introduction/Guidelines/Documents/E-Invoicing_Detailed__Guideline.pdf.

Also, refer the sample XMLs related to Advance Payment Adjustment in SDK