Skip to main content

Configuring Bacs

Bacs for FinDock is an implementation of the Bacs Direct Debit payment scheme. It supports collecting one-time and recurring payments using payment schedules and the FinDock Payment API.

This implementation also supports a variety of file and report types for handling Bacs direct debit payment management and reconciliation.

Prerequisites

  • FinDock is installed and configured.
  • A working connection to ProcessingHub and WebHub.

Install and activate Bacs extension#

Follow the standard procedure for installing and activating the Bacs for FinDock extension.

Create targets#

To complete the Bacs configuration, you need to add at least one Bacs target (account). For more information, see Creating Bacs targets.

Register Bacs mandates#

The Bacs extension generates mandates as Direct Debit Instructions (DDIs) when required, such as for direct debit collection runs.

If a recurring donation or opportunity (recurring payment or installment) is created, a mandate is automatically created with an org-specific Id (7 characters) and status “Pending registration.”

For more information, see Registering Bacs mandates.

Installment aggregation#

The Bacs Direct Debit scheme does not allow multiple transactions for the same mandate on the same date. If you have transactions like this, FinDock automatically aggregates to a single direct debit installment all transactions for each mandate-date combination.

Aggregation process#

After a payment schedule run for a Bacs target has generated and/or selected installments that meet the schedule’s criteria, FinDock checks if there are installments with the same mandate-date combination.

If such installments are found:

  1. An aggregated installment is created with an open amount equal to the sum of the open amounts of the individual installments.
  2. The payment method of the individual installments is set to Aggregated Installment.
  3. The individual installments are linked to the aggregated installment.
  4. The original installments are removed from the payment schedule.

Collection and payment#

If a payment is received for the aggregated installment, it is split and distributed to the original individual installment. Both the aggregated installment and linked individual installments are set to Collected, and all open amounts are set to zero. In addition, a corresponding negative payment is created for the aggregated installment to keep the sum of all payments equal to the actual direct debit payment amount.

Reversal#

If an aggregated installment is reversed, a negative payment is created and distributed across the original individual installments. The status of these installments is set to Reversed, and the open amount is set to the original value.

The payment method of the original installments is set back to direct debit, allowing them to be recollected. The for the Aggregated Installment positive payment is created in order to keep the sum of all Payments equal to the actual money flow.

Important notes#

  • Keep in mind when confirming the direct debit to the customer or donor that you mention the total amount rather than the amount of the single transaction.
  • Aggregated installments are not eligible for Gift Aid since they are not separate payments or donations.
  • In order to keep your reports in line with actual expected and/or realized cash flow, exclude aggregated installments from your reports. Use the field paybacs__IsAggregated__c to filter out installments that are aggregated installments.
  • For the same reporting reasons, NPSP Opportunities are not created for an aggregated installment.
  • Do not recollect Aggregated installments after a reversal, but recollect the Original Installments.

Match with Bacs processing date#

As part of the Bacs package, there is a Bacs-specific 'Processing Date" (paybacs__BACS_Processing_Date__c) that needs to be added to the Payment Schedule layout. Use this field to define the target processing date for the installments in a payment schedule according to the official Bacs processing calendar.

If you don't use the Processing Data field, FinDock falls back to Collection Date and uses that to inform the Bacs network to process the direct debit collection on the next possible processing date.

When a Bacs report is uploaded to ProcessingHub (via Chatter), the records in that file are matched against installments in the system. If a value is provided in the field ‘Bacs processing date’ on a payment schedule, then FinDock matches incoming Bacs reports on that field instead of using the collection date.

Sort code and account check#

For Bacs Direct Debit payments initiated through the FinDock Payment API, FinDock performs a sort code & bank account check to avoid failed payments due to incorrect code or account values. The checking is done automatically, so no additional work is needed to use. However, you do need to design your own solution for how to handle the error message if a customer or donor enters incorrect information.

In addition to the automates API check, you can add the FinDock Lightning component Check Sort Code and Bank Account to your Payment Profile layout to do the same validation when manually entering payment information.

To set up manual sort code and bank account checking:

  1. Go to a Payment Profile record.
  2. Click the settings cog in the upper right and select Edit Page.
    Edit Payment Profile Page layout
  3. Drag the Check Sort Code and Bank Account component to your page layout.
    Add LWC for sort code and account checking to layout
  4. Click Add Filter under Set Component Visibility to the right.
    Add filter for LWC visibility
  5. Click Advanced and under Field, click Select.
    Advanced filter settings for LWC
  6. In the pick lists, select Record, then Record Type, then Name, and click Done.
    Advanced filter field selection for LWC
  7. Add an equal operation with "Bank Account" as the value, then click Done.
    Operator setting for LWC filter
  8. Click Save in the upper right to save the layout change and component filter settings.
    Save Payment Profile layout changes

The component will now appear on payment profiles with UK bank accounts, but it is not visible for other payment profiles. To validate a sort code and bank account, just click the Validate button.

Payment API#

To test your Bacs configuration, you can use the following messages with the Payment API.

One-time Bacs Direct Debit#

{
"SuccessURL": "https://www.example.com/success",
"FailureURL": "https://www.example.com/error",
"WebhookURL" : "https://webhook.site/181568ec-8830-4672-af01-8c99da8e044f",
"Payer": {
"Contact": {
"SalesforceFields": {
"FirstName": "Eric",
"LastName": "Johnson",
"Email": "eric@johnson.com"
}
}
},
"OneTime": {
"Amount": "30"
},
"PaymentMethod": {
"Name": "Direct Debit",
"Processor": "PaymentHub-BACS",
"Target" : "BACS-target",
"Parameters" : {
"bankAccount" : "13537846",
"sortCode": "205132",
"holderName" : "E. Johnson",
"description": "test"
}
},
"Settings": {
"SourceConnector": "PaymentHub"
}
}

Recurring Bacs Direct Debit#

{
"SuccessURL": "https://www.example.com/success",
"FailureURL": "https://www.example.com/error",
"Payer": {
"Contact": {
"SalesforceFields": {
"FirstName": "Eric",
"LastName": "Johnson",
"Email": "eric@johnson.com"
}
}
},
"Recurring": {
"Amount": "25",
"Frequency": "Monthly",
"StartDate": "2020-11-01"
},
"PaymentMethod": {
"Name": "Direct Debit",
"Processor": "PaymentHub-BACS",
"Target" : "BACS-target",
"Parameters" : {
"bankAccount" : "13537846",
"sortCode": "205132",
"holderName" : "E. Johnson",
"description": "test"
}
},
"Settings": {
"SourceConnector": "PaymentHub"
}
}