SEPA is an initiative of the European Union that aims to standardise and facilitate payment transactions within Europe. The PAIN format is used specifically for data exchange in the area of payment transactions. This library creates "pain.001.001.03" XML files for SEPA Credit Transfer Initiation. It is used to transmit information about a credit transfer from a payer to a payee.
finalStringWriterwriter = newStringWriter();
finalvardebtor = newSepaBankAccount("Max Mustermann", "COBADEFFXXX", "DE40850400611005507328");
finalvarcreditor = newSepaBankAccount("John Doe", "INGBNL2AXXX", "NL50INGB4362244417");
finalvarpaymentInstruction = newSepaPaymentInstruction("1234567890", debtor, LocalDate.of(2023, 11, 16),
List.of(newSepaTransactionInfo(creditor, newBigDecimal("27.53"), "Project 1 - Jan 2023")));
finalvarsepaCreditTransfer = newSepaCreditTransfer("COBADEFFXXX0020230716110719", "Roamsys S.A.", List.of(paymentInstruction));
newSepaCreditTransferXmllWriter().build(sepaCreditTransfer, writer);
System.out.println(writer.toString());