action.skip

Configuring SEPA Direct Debit Export

Your organization's business may want to export bank transfer orders for invoices or account balances – a common means for collecting payments. These payment orders can then directly be used by banks for triggering the corresponding payment operations.

JustOn supports two common implementations of (interchangeable) bank transfer orders:

For open invoices whose payment method is SEPA, you use the invoice export mechanism to produce SEPA XML files for debits or credits (depending on whether the invoice states a positive or a negative amount).

Invoice export history

In addition to the actual export file (CSV or SEPA XML, according to the applied export setting), the export operation produces an Invoice Export History record for each exported invoice. The history holds the following information:

  • Export time
  • Effective payment due date (for installment invoices)
  • File name and link to the exported file
  • Flag stating whether a payment balance has been created
  • Flag that controls whether to prevent repeated exports
  • Flag stating whether an invoice has been exported more than once (forced export)

    The Times Exported field on the invoice shows the export count.

You can also export SEPA Credit orders from account balances of the types Payment or Prepayment that are not assigned to an invoice. When exporting account balances, the exported balances as well as generated reverse balances (if set up to do so) are locked. Locked balances are exempt from certain business processes like (further) exports or automatic balance assignment.

Info

Generally, JustOn recommends to export SEPA bank transfer orders on a regular base.

SEPA Direct Debit export concepts

JustOn exports SEPA Direct Debit orders for invoices if

  • the invoice's open amount is greater than 0,
  • the invoice has not yet been exported (multiple exports can be forced, however), and
  • the payment method is SEPA (as an active picklist value).

    For compatibility reasons, JustOn still supports SEPA exports for invoices with the payment methods Direct Debit or Bank Transfer. For this purpose, the invoice field Payment Method must not include the picklist value SEPA. Otherwise, the SEPA export will involve invoices with the payment method set to SEPA only, and the values Direct Debit and Bank Transfer will be ignored. For details, see Payment Method SEPA.

Before executing the export, JustOn validates the SEPA payment information. It checks the format and structure (length, allowed characters, etc.) of the SEPA Creditor ID, IBAN, BIC and Direct Debit Mandate Reference according to the definitions in the SEPA Direct Debit Core Schemes.

As part of the validation, JustOn removes any whitespaces from IBAN numbers.

The result of the validation is written to the invoice field SEPA Validation Error. The bank transfer order for an invoice is exported if the SEPA Validation Error field is empty.

If you use payment instruments, the data to be validated is taken from the active payment instrument set for an account (in the field Current SEPA Mandate).

Otherwise, the following conditions must be true in order for the validation to succeed:

  • The invoice refers to a business entity.
  • The following fields of the business entity are set:

    SEPA Creditor ID

    IBAN

    Company

  • The following fields of the invoice are set:

    Bank Account

    Bank Account Owner

    Direct Debit Mandate Granted

    Direct Debit Mandate Reference

    Direct Debit Sequence Type

  • When using a CBI export format, the Member ID field of the business entity contains the ABI code of the bank.

When exporting bank transfer orders from invoices, JustOn determines the relevant date range automatically, ignoring any specified date range. For SEPA-compliant bank transfer orders, the Next Payment Due Date is relevant. It must be in the past or within the next 14 days from today.

For invoices whose Next Payment Due Date is in the past, JustOn corrects the payment date to TODAY + 2. Any manually specified payment date beyond the next 14 days from today will be corrected to be within the allowed date range.

Generated payment balance

If the user has selected the option Create Payments upon exporting the bank transfer orders for invoices, JustOn creates payment balances on the invoices to set them Paid. The balance field values are set as follows:

Field Value
Account value of Account of the invoice
Amount inverted value of Next Payment Due of the invoice
Date value of Next Payment Due Date of the invoice
Payment Method value of PaymentMethod of the invoice
Reference string as defined in PaymentReference of the invoice template, with the placeholders resolved using invoice data
Type Payment

The involved tasks for configuring the SEPA Direct Debit export differ depending on whether you use the SEPA data from payment instruments or accounts/invoices:

Info

For information about executing payment exports, see Exporting Bank Transfer Orders.

Defining Export Settings

Depending on your organization's requirements, you must define an export configuration for SEPA Direct Debit exports.

Info

The invoice export and balance export use the same export configurations, which allows to apply the same configuration for exporting both invoices and balances.

  1. Click to enter Setup, then open Custom Settings.

    In Salesforce Lightning, navigate to Custom Code > Custom Settings.

    In Salesforce Classic, navigate to Develop > Custom Settings.

  2. Click Manage in the row of Export Settings.

  3. Click New.
  4. Specify the details as necessary.

    Field Possible Values Description
    Name SEPA Direct Debit A unique name for the custom setting record, will be selectable when exporting invoice or account balance data.
    Active true
    false
    Determines whether the configuration is available in the UI.
    SEPA: Booking per Transaction true
    false
    Determines whether to override SEPA batch booking (consolidated payment, default). If true, forces an individual SEPA transaction per payment. Produces a corresponding <BtchBookg> element in the SEPA XML.
    If you use SEPA batch bookings (SEPA: Booking per Transaction = false), JustOn recommends to enable the payment balance/reverse balance creation (Create Payments = true) to avoid the time-consuming manual assignment from the consolidated payment.
    CUC 3121975D The unique CBI code that identifies all parties in the CBI community (clients, banks and network access points). Required when using a CBI format string, is applied for and registered by the access bank.
    Create Payments true
    false
    Determines whether to create payment balances on the invoices, which sets the invoices Paid, or reverse balances for the exported balances to offset their amount. Enabling this setting prevents multiple exports using the Force Export option.
    If you use SEPA batch bookings (SEPA: Booking per Transaction = false), JustOn recommends to enable the payment balance/reverse balance creation (Create Payments = true) to avoid the time-consuming manual assignment from the consolidated payment.
    Users can overwrite this option manually when starting the export.
    Payment Reference [AccountAccountName] balance offset Specifies the reference text to be used for SEPA payments. Accepts placeholders that refer to the balance, the account or the business entity.
    Used for balance exports only.
    Format XML CDD or
    XML CDD pain.008.001.02
    Either value creates an XML file in the format CDD (Core Direct Debit, pain.008.001.02).
    XML CDD REQUIRED_BIC pain.008.001.02 Creates an XML file in the format pain.008.001.02 with the BIC as a required value (valid for Austria and Netherlands)
    XML CDD CBISDDReqLogMsg.00.01.00 Creates an XML file in the format CBISDDReqLogMsg.00.01.00 (CBI format for Italy)
    Select Condition Date__c = THIS_YEAR Specifies a condition expression as used in an SOQL WHERE clause to restrict the set of included records. If empty, matches all invoices or account balances in the list.
    For details, see SOQL WHERE clause in the Salesforce Help.
    Use ASCII Encoding Scheme true
    false
    Determines whether to perform a phonetic replacement of the contents of the resulting CSV or XML file.
    For XML exports, all required replacements for the SEPA format are performed. For details, see SEPA Requirements for an Extended Character Set (UNICODE Subset) - Best Practices.
    Target Export Specifies the name of a file distribution target for the exported files.
    For exports to cloud storage services, the file distribution target must be the one set up as the storage location with the use case Export and the backend AmazonS3 or GoogleDrive.
    If left empty, the file will only be available on Salesforce's Files tab as of JustOn 2.49.
    Allowed Currencies EUR,SEK Specifies a comma-separated list of currencies that are allowed for ISO 20022 XML formats. Defaults to EUR, which is the only allowed currency for SEPA.
    ISO20022: Service Level Code SEPA Specifies the pre-agreed level of service between the parties. For SEPA, defaults to SEPA. For non-SEPA payments, contact your bank.

    file_dist_amazon
    Creating an export settings record for producing SEPA Direct Debit XML files

  5. Click Save.

Export Settings or File Distribution?

JustOn Billing & Invoice Management uses the custom settings Export Settings and File Distribution to control the output of produced documents. It may be hard to tell which to apply. Remember that the two settings impact different aspects:

  • Export Settings records control what to export – invoice and bookkeeping data CSV files or SEPA XML files.
  • File Distribution settings control the output location of any produced files, be it PDF files for finalized invoices, dunning reminders and account statements, or exported CSV and XML files.

That is, your use cases determine which settings to use:

File export

If you export data to CSV files for accounting systems or to SEPA XML bank transfer orders, you need appropriate Export Settings records.

jo_faq_files_export
Exporting files (applying Export Settings) to the default location

File location

If you want produced PDF files for finalized invoices, dunning reminders and account statements to be output in a specific location (other than the group Owned by me in Salesforce Files), you need a corresponding File Distribution setting.

jo_faq_files_filedist
Defining a specific output location using a File Distribution setting

File export and file location

If you export data to CSV files for accounting systems or to SEPA XML bank transfer orders, you need appropriate Export Settings records. If you want the exported files to be output in a specific location, you need, in addition, a corresponding File Distribution setting.

To combine the two settings, the Name of the file distribution record must be specified as the Target in the export settings record.

jo_faq_files_export+filedist
Exporting files (applying Export Settings) to a specific location (applying File Distribution)

Configuring SEPA Creditor Fields

Exporting SEPA payment orders requires SEPA-relevant fields to be set on the business entity, irrespective of whether using payment instruments or the account to hold the customer's SEPA data.

The following fields on the business entity hold SEPA creditor data and must be set accordingly:

Field Description
Company The name of the business entity's company.
IBAN The IBAN (International Bank Account Number) of the business entity.
The saved IBAN can contain whitespaces. JustOn removes them on SEPA export.
SEPA Creditor ID Each biller in SEPA will be identified with a creditor identifier. This identifier, in connection with the mandate reference, allows the payer and the payer's bank to verify each SEPA direct debit and to process or reject the direct debit according to the payer's instructions. Billers will have to request this identifier according to local practice.

Info

Your bank may also require the BIC field to be set.

Configuring SEPA Payment Fields

Exporting SEPA Direct Debit orders without payment instruments requires the customer-relevant SEPA fields (that is, the payee's data) to be set on the invoice. The required data is usually taken from the account. Your business may, however, require to allow for exceptions: You may need to generate an invoice, and consequently, a payment order, with banking data that differs from that on the account. In this case, you need the corresponding data on the source object from which you create the invoice – either the subscription or the source object for arbitrary object billing.

Account Fields

The following account fields must be set (configured and filled):

Field Data Type Description
ON_BankAccount Text (34) The International Bank Account Number.
The saved IBAN can contain whitespaces. JustOn removes them on SEPA export.
ON_BankAccountOwner Text (255) The name of the owner of this bank account. Defaults to Account Name if empty.
ON_BankCode Text (11) The bank identifier code.
With an IBAN as bank account number, the bank code (BIC) is not required.
ON_PaymentMethod
or
ON_InvoicePaymentMethod
Picklist The payment method that is preferred for paying invoices of this account.
Use ON_PaymentMethod to fill the corresponding invoice field when creating invoices. Use ON_InvoicePaymentMethod to fill the corresponding subscription field when building subscriptions, out of which you then create invoices.
ON_DirectDebitMandateGranted Date The date on which the direct debit mandate has been granted.
ON_DirectDebitMandateReference Text (35) The unique reference key for the direct debit mandate as assigned by the creditor. The maximum length is 35 characters, and the allowed characters include A-Z a-z 0-9 / - ? : ( ) . , ‘ +
You can fill this field automatically using the SEPA mandate reference counter.
ON_DirectDebitSequenceType Picklist First - First direct debit transaction in a series
Recurrent - Recurrent direct debit transaction in a series
JustOn changes the sequence type on the source record from First to Recurrent when finalizing the first generated invoice.
When exporting account balances, this field is not used and the sequence type is always set to Recurrent.
According to recent SDD rule modifications, the use of the sequence type First in a first of a recurrent series of transactions is no longer mandatory. A transaction with the optional sequence type First is processed as a recurrent transaction.
For details, see SEPA Direct Debit Core rulebook.
ON_DirectDebitMandateGrantedByCustomer Checkbox Specifies whether a user has granted the direct debit mandate. Unchecked by default, is selected when a user has granted the direct debit mandate via the direct debit mandate page of the (legacy) JustOn Self-Service Extension.

Info

In case of issues or disputes with respect to the use of SEPA mandates, you may may need some detailed tracking or debugging information. This is why JustOn recommends to enable field history tracking for at least the fields ON_DirectDebitMandateGranted, ON_DirectDebitMandateGrantedByCustomer and ON_DirectDebitMandateReference. For details about enabling field history tracking for accounts, see Track Field History for Standard Objects in the Salesforce Help.

Source Object Fields

You may need to generate an invoice, and consequently, a payment order, with banking data that differs from that on the account. In this case, you need the corresponding data on the source object from which you create the invoice – either the subscription or the source object for arbitrary object billing.

Note that the subscription fields are available by default. When using other source objects, you must create these fields as ON fields. For help about creating fields, see Managing Object Fields.

Info

The fields on the source object overwrite the values set on the account.

Note

Be aware that JustOn ignores all bank data fields on the account if there is a relevant source field set. That is, you must set and overwrite all bank data fields even if you want to modify just one value.

Field Data Type Description
BankAccount
ON_BankAccount
Text (34) The International Bank Account Number.
The saved IBAN can contain whitespaces. JustOn removes them on SEPA export.
BankAccountOwner
ON_BankAccountOwner
Text (255) The name of the owner of this bank account. If empty, defaults to Legal Account Name if available, otherwise defaults to Account Name.
BankCode
ON_BankCode
Text (11) The bank identifier code.
With an IBAN as bank account number, the bank code (BIC) is not required.
InvoicePaymentMethod
ON_InvoicePaymentMethod
Picklist The payment method that is preferred for paying invoices of this account.
DirectDebitMandateGranted
ON_DirectDebitMandateGranted
Date The date on which the direct debit mandate has been granted.
DirectDebitMandateReference
ON_DirectDebitMandateReference
Text (35) The unique reference key for the direct debit mandate as assigned by the creditor. The maximum length is 35 characters, and the allowed characters include A-Z a-z 0-9 / - ? : ( ) . , ‘ +
You can fill this field automatically using the SEPA mandate reference counter.
DirectDebitSequenceType
ON_DirectDebitSequenceType
Picklist First - First direct debit transaction in a series
Recurrent - Recurrent direct debit transaction in a series
JustOn changes the sequence type on the source record from First to Recurrent when finalizing the first generated invoice.
According to recent SDD rule modifications, the use of the sequence type First in a first of a recurrent series of transactions is no longer mandatory. A transaction with the optional sequence type First is processed as a recurrent transaction.
For details, see SEPA Direct Debit Core rulebook.

Invoice Fields

The invoice fields are copied from the account or, if set, from the source object.

Field Data Type Description
BankAccount Text (34) The International Bank Account Number.
The saved IBAN can contain whitespaces. JustOn removes them on SEPA export.
BankAccountOwner Text (255) The name of the owner of this bank account. If empty, defaults to ON_BankAccountOwner if available, otherwise defaults to Account Name.
BankCode Text (11) The bank identifier code.
With an IBAN as bank account number, the bank code (BIC) is not required.
PaymentMethod Picklist The payment method that is preferred for paying invoices of this account.
DirectDebitMandateGranted Date The date on which the direct debit mandate has been granted.
DirectDebitMandateReference Text (35) The unique reference key for the direct debit mandate as assigned by the creditor. The maximum length is 35 characters, and the allowed characters include A-Z a-z 0-9 / - ? : ( ) . , ‘ +
You can fill this field automatically using the SEPA mandate reference counter.
DirectDebitSequenceType Picklist First - First direct debit transaction in a series
Recurrent - Recurrent direct debit transaction in a series
JustOn changes the sequence type on the source record from First to Recurrent when finalizing the first generated invoice.
According to recent SDD rule modifications, the use of the sequence type First in a first of a recurrent series of transactions is no longer mandatory. A transaction with the optional sequence type First is processed as a recurrent transaction.
For details, see SEPA Direct Debit Core rulebook.

Payment Instrument Fields

If the corresponding process has set an active SEPA payment instrument for an account, JustOn uses the following fields of the payment instrument for the SEPA export:

  • Account Holder
  • IBAN
  • SWIFT-BIC
  • Direct Debit Mandate Granted
  • Direct Debit Mandate Reference

Note

If there is no active payment instrument, the SEPA-relevant information must be available on the invoice or, when exporting SEPA orders from balances, on the account.

Configuring SEPA Mandate Reference Counters

JustOn can fill the Direct Debit Mandate Reference field on the Account and Subscription objects with an auto-incrementing counter. This is useful if you do not wish to retrieve a direct debit mandate reference from an external system. Once set up, this feature ensures that existing direct debit mandate references are not overwritten. It allows you to set a value manually even if it already exists, and it still sets a counter automatically if it is missing.

For general information about counters, see Counters and Number Ranges.

Account Mandate Reference Counter

For the SEPA mandate reference counter for the Account object to work, JustOn requires the following fields on the Account object (see SEPA Payment Fields):

  • ON_InvoicePaymentMethod
  • ON_DirectDebitMandateReference
  • ON_DirectDebitSequenceType

In addition, JustOn requires the specific invoice counter MandateReferenceAccount to act as the SEPA mandate reference counter. Once set up, you can generate a SEPA mandate reference counter for an account using the button Set Mandate Reference.

Creating Account Counter

Create a specific invoice counter to act as the SEPA mandate reference counter.

  1. Click to enter Setup, then open Custom Settings.

    In Salesforce Lightning, navigate to Custom Code > Custom Settings.

    In Salesforce Classic, navigate to Develop > Custom Settings.

  2. Click Manage in the row of Counters.

  3. Click New.
  4. Specify the details as necessary.

    • Name: MandateReferenceAccount
    • Template: Specify the pattern as necessary.

      Info

      The resulting mandate string can contain up to 35 characters. The allowed characters include the alphanumeric characters a-z A-Z 0-9, the punctuation and symbol characters +?/-:().,' and the space character.

      Note that there is no support for custom placeholders with SEPA mandate reference counters.

  5. Click Save.

Adding Counter Generation Button

To enable the manual counter generation for an account using a button:

  1. Navigate to the object management settings of the Account object.
  2. Click Page Layouts.
  3. In the Account Layout row, click Edit.
  4. Add the Set Mandate Reference button to the page layout.

    In Salesforce Lightning, drag the button from the Mobile & Lightning Actions palette to the Salesforce Mobile and Lightning Experience Actions section.

    In Salesforce Classic, drag the button from the Buttons palette to the Custom Buttons area.

  5. Click Save.

    For help about modifying page layouts, see Managing Pages.

Subscription Mandate Reference Counter

For the SEPA mandate reference counter for the Subscription object to work, JustOn requires the following fields on the Subscription object (see SEPA Payment Fields):

  • InvoicePaymentMethod
  • DirectDebitMandateReference

In addition, JustOn requires the specific invoice counter MandateReferenceSubscription to act as the SEPA mandate reference counter. Once set up, the SEPA mandate reference for the subscription is set automatically on subscription creation and modification if the following conditions are met:

  • The field DirectDebitMandateReference of the subscription is empty.
  • The field InvoicePaymentMethod of the subscription equals Direct Debit.

Creating Subscription Counter

Create a specific invoice counter to act as the SEPA mandate reference counter.

  1. Click to enter Setup, then open Custom Settings.

    In Salesforce Lightning, navigate to Custom Code > Custom Settings.

    In Salesforce Classic, navigate to Develop > Custom Settings.

  2. Click Manage in the row of Counters.

  3. Click New.
  4. Specify the details as necessary.

    • Name: MandateReferenceSubscription
    • Template: Specify the pattern as necessary.

      Info

      The resulting mandate string can contain up to 35 characters. The allowed characters include the alphanumeric characters a-z A-Z 0-9, the punctuation and symbol characters +?/-:().,' and the space character.

      Note that there is no support for custom placeholders with SEPA mandate reference counters.

  5. Click Save.

Configuring Payment Reference Text

Depending on your organization's requirements, you specify a string that is to be written as the payment reference for SEPA payments. To do so, you configure the template field Payment Reference.

  1. Open the template to be edited.
  2. In the Payment Information section, double-click the Payment Reference field and modify the information as required.

    Modify the default value [InvoiceNo] - [InvoiceDate] as necessary.

    You can use the placeholders that are available for the invoice context.

  3. Click Save.

Note

When exporting account balances, the payment reference is taken from the field Payment Reference of the export setting. You can use placeholders that refer to the balance, the account or the business entity.