Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Omit the BIC (Business Identifier Code) in the <DbtrAgt><FinInstnId> #17

Closed
rjdkolb opened this issue Oct 30, 2024 · 1 comment
Closed

Comments

@rjdkolb
Copy link

rjdkolb commented Oct 30, 2024

From the documentation is seems, the debtorAccount BIC is optional.

If I comment out the debtorAccount bic, the validation tool fails.

XML document is well-formed.

XML document does not validate against XSD schema. Following XML errors found:
-----------------------------------------------------------------
            </DbtrAcct>
            <ChrgBr>DEBT</ChrgBr>

Error, see line 33: 
Element '{urn:iso:std:iso:20022:tech:xsd:pain.001.001.03}ChrgBr': This element is not expected. Expected is ( {urn:iso:std:iso:20022:tech:xsd:pain.001.001.03}DbtrAgt ).

-----------------------------------------------------------------

This is the modified code from the README.md example.

   public static void main(String... args) {

    // Optional debtor identification
    Party debtor =
        Bank.simpleParty()
            .name("Debtor Name") // Optional name
            .build();

    // Debtor account
    BankAccount debtorAccount =
        Bank.simpleBankAccount()
            .iban("FR7610011000201234567890188") // IBAN
            // .bic("PSSTFRPP")                     // Optional BIC
            .build();

What I would expect is:

<DbtrAgt>
    <FinInstnId/>
</DbtrAgt>

Thanks

@pblanchardie
Copy link
Member

pblanchardie commented Jan 3, 2025

Hi, thanks for pointing this out and sorry for the late answer.
Fixed in v3.0.1 and backported to v2.5.1

pblanchardie added a commit that referenced this issue Jan 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants