Skip to main content

Declare a payment mandate for SEPA Direct Debit

Before accepting payments with SEPA Direct Debit B2B or Core, you need to declare a payment mandate to your Swan account. Each debtor must have their own payment mandate.

Review the requirements for SEPA Direct Debit payment mandates if needed.

Prerequisites
  • Debtor's account status: any except Closing or Closed
  • Merchant profile status: Enabled
  • SEPA Direct Debit B2B payment method status: Enabled
  • [B2B only] Debtor's account type: Company

Guide​

  1. Confirm you have a project access token or, if you're an account member, a user access token with CanManageAccountMembership permissions, and confirm the prerequisites are met.
  2. Call the addSepaDirectDebitPaymentMandate mutation. You don't need consent from the debtor.
  3. Replace $YOUR_PAYMENT_METHOD_ID with the ID for your payment method, from your Dashboard (line 4).
  4. Choose Recurrent or OneOff (line 5).
  5. Choose the language and signature date for the mandate (lines 6-7).
  6. Add information about the debtor, including name, IBAN, and their country of residence (lines 9-11).
  7. Choose either Core or B2B in your mandate name (line 13).
  8. Add validations and rejections that are helpful for you, as well as optional information such as a reference for your internal use.
  9. The payment mandate is ready to be created with the status Enabled. Creating the mandate is finalized after it's used for the first time.
B2B

For B2B, declare the mandate to the debtor's bank as well.

Mutation​

🔎 Open the mutation in API Explorer

mutation AddSddMandate {
addSepaDirectDebitPaymentMandate(
input: {
paymentMethodId: "$YOUR_PAYMENT_METHOD_ID"
sequence: Recurrent
language: it
signatureDate: "2023-10-10"
debtor: {
name: "Francesca Verrilli"
IBAN: "IT75M0300203280692352275489"
address: { country: "ITA" }
}
name: "B2B/Core SEPA Direct Debit Mandate"
}
) {
... on AddSepaDirectDebitPaymentMandateSuccessPayload {
__typename
paymentMandate {
id
statusInfo {
status
}
}
}
... on InternalErrorRejection {
__typename
message
}
... on PaymentMethodNotCompatibleRejection {
__typename
message
}
... on ValidationRejection {
__typename
message
fields {
code
message
path
}
}
... on PaymentMandateReferenceAlreadyUsedRejection {
__typename
message
}
... on SchemeWrongRejection {
__typename
message
}
... on DebtorAccountNotAllowedRejection {
__typename
message
}
... on DebtorAccountClosedRejection {
__typename
message
}
... on NotFoundRejection {
id
message
}
... on ForbiddenRejection {
__typename
message
}
}
}

Payload​

Note the id (line 6) for your SEPA Direct Debit payment mandate.

{
"data": {
"addSepaDirectDebitPaymentMandate": {
"__typename": "AddSepaDirectDebitPaymentMandateSuccessPayload",
"paymentMandate": {
"id": "$YOUR_MANDATE_ID",
"statusInfo": {
"status": "Enabled"
}
}
}
}
}