Reputation: 146
I have a UBL file which has cbc:ProfileIDurn:fdc:peppol.eu:2017:poacc:billing:01:1.0</cbc:ProfileID> but it's supposed to be not an invoice but a self billed invoice, hence I would almost insist on cbc:InvoiceTypeCode389</cbc:InvoiceTypeCode> (or 381) instead of 380.
I set the new type code but the validation (as OpenPeppol UBL Invoice 3.15.0) via https://ecosio.com/de/peppol-und-xml-dokumente-online-validieren-button/
fails with $profile != '01' or (some $code in tokenize('71 80 82 84 102 218 219 331 380 382 383 386 388 393 395 553 575 623 780 817 870 875 876 877', '\s') satisfies normalize-space(text()) = $code): Invoice type code MUST be set according to the profile.
Tried urn:fdc:peppol.eu:2017:poacc:selfbilling:01:1.0 but that raises a Business process MUST be in the format 'urn:fdc:peppol.eu:2017:poacc:billing:NN:1.0' where NN indicates the process number.
Using sth like urn:fdc:peppol.eu:2017:poacc:billing:02:1.0 (i.e. "process" 2 instead of 1) as ProfileID does work but unfortunately that just seems to skip parts of the validation because e.g. 3 works as well :-(
Also the validation as OpenPeppol UBL Credit Note 3.15.0 does not work, neither when I change the root element to CreditNote (which returns a lot more errors).
Upvotes: 0
Views: 601
Reputation: 1
You must use the Maindoc-Type SelfBilledInvoice.
See: https://docs.oasis-open.org/ubl/os-UBL-2.1/xsd/maindoc/UBL-SelfBilledInvoice-2.1.xsd
Upvotes: 0