BetalingsService

BetalingsService is the primary Danish Direct Debit solution for consumers, provided by the Danish banks and driven by Mastercard Payment Services (MPS), formerly NETS.

Mandate Registration

In BetalingsService terminology, an agreement is called a mandate. The following will use the term agreement and mandate interchangeably.

BetalingsService traditionally provides an “out-of-band” style agreement registration.

  1. INFO-Subscription generates a Debtor Number for each subscriber. The subscriber receives a physical invoice with identifiers (Debtor Number, Creditor Number, Creditor Group Number), where the Creditor Number and Creditor Group Number are configured in the BetalingsService account within INFO-Subscription.

  2. The subscriber registers this in the online banking solution (or some other means as described by MPS https://www.betalingsservice.dk)

  3. A mandate file is sent by MPS to INFO-Subscription via SFTP, where it is automatically processed.

  4. Recurring payments can be charged on the subscriber’s account, associated with the specific mandate.

The following sequence diagram illustrates the mandate registration and first claim processing flow:

        %%{init: { 'sequence': { 'mirrorActors': false } } }%%
sequenceDiagram
    actor Subscriber
    participant INFO as INFO-Subscription
    participant MPS as Mastercard Payment Services
    participant Bank as Subscriber's Bank

    Note over INFO: Prerequisites: BetalingsService Account Setup
    Note right of INFO: Account configured with<br/>Creditor Number & Creditor Group Number
    
    Note over INFO,Subscriber: 1. Physical Invoice Sent
    INFO->>INFO: Generate Debtor Number<br/>for Subscriber
    INFO->>Subscriber: Send Physical Invoice<br/>(Debtor Number, Creditor Number,<br/>Creditor Group Number)
    
    Note over Subscriber,Bank: 2. Out-of-Band Registration
    Subscriber->>Bank: Register Mandate in<br/>Online Banking Solution
    activate Bank
    Bank->>MPS: Submit Mandate Registration
    deactivate Bank
    
    Note over MPS,INFO: 3. Mandate Confirmation
    activate MPS
    MPS->>INFO: Send Mandate File<br/>(via SFTP)
    deactivate MPS
    activate INFO
    INFO->>INFO: Process Mandate File<br/>Create Payment Agreement
    deactivate INFO
    
    Note over INFO,MPS: 4. Recurring Payments (First Claim)
    activate INFO
    INFO->>INFO: Generate Invoice/Claim
    INFO->>MPS: Submit Transaction File<br/>(via SFTP)
    deactivate INFO
    
    activate MPS
    MPS->>Bank: Process Payment on Due Date
    deactivate MPS
    
    activate Bank
    Bank->>Subscriber: Debit Subscriber Account
    Bank->>MPS: Confirm Payment
    deactivate Bank
    
    activate MPS
    MPS->>INFO: Payment Confirmation File<br/>(via SFTP)
    deactivate MPS
    
    activate INFO
    INFO->>INFO: Process Payment File<br/>Mark Invoice as Paid
    deactivate INFO

    

Since all of this is “out-of-band”, there is little developer integration here.

The requirement is that an account is set up for BetalingsService (Account endpoint) and that mandates and payments are imported using the files from MPS. INFO-Subscription takes care of this for you, if configured during onboarding. Reach out to support to get help with this.

The rest is taken care of by INFO-Subscription in terms of billing, claims generation etc.

Manually Registering Mandates

A mandate registration requires the following:

  • A mandateNumber (an identifier from MPS)

  • A SubscriberId

  • An AccountId

  • A SubscriberNumber

The mandate is created by sending a POST request to the mandate endpoint, an example request body might look like:

{
    "accountId" : "a28373e1-5733-4682-98f0-549cb59800f8",
    "subscriberId" : "acecdb1d-b78b-45bd-9374-4feee7edaf72",
    "mandateNumber" : "123451",
    "subscriberNumber" : "2255412586",
}

The output of such a request is a new Id for the mandate, which can then be used to register a general payment agreement as described in the section for managing agreements.

Connected/Interactive Mandate Registration

MPS provides an alternative solution to the out-of-band registration option, the branded name for this is MPS’ E-Agreement service. Basically, it’s a website that allows for the registration to happen in a connected/interactive manner without the need for the consumer to go to the online banking solution.

Registration goes via BetalingService “Tilmeldingslink”, which is documented here: https://www.betalingsservice.dk/erhverv/l%C3%B8sninger/bs-tilmeldingslink Alternatively via file transfers, which is not currently included with INFO-Subscription.

Cancelling Mandates

At any point in time, the consumer may cancel the mandate, in which case an alternate means should be used to get the payment.

INFO-Subscription manages this scenario by:

  • Disabling the mandate once a cancellation is received.

  • Disabling the payment agreement and reverting to the default agreement (Invoice or Email).

  • Generating reminders on Invoice since no payment is going to be received with BetalingsService.

It is possible to cancel a mandate using the mandate endpoint.

At the time of writing, there are no common scenarios where this is needed, but the most likely would be some external lifecycle management of the mandates.

Creating Payments (Transactions)

A Transaction is the BetalingsService terminology for doing a debit/charge on the consumer’s account. Once submitted, if not cancelled by the merchant, will lead to an account transfer on the given due date.

Transactions are automatically created and cancelled for subscriptions on a BetalingsService mandate. There should be minimal need for manually creating transactions. Please let us know if you have specific scenarios that are not supported.

Transactions can be created directly using the API if required, using the transaction endpoint.

Caution

A mandate can have a maximum of one transaction per day. Using the subscription mandate for external charges runs the risk of conflicting with existing transactions. This in turn leads to unpaid invoices or other discrepancies.

Use this feature with some caution, or make sure you have separate Mandates.