Pay by Bank
Description
Deutsche Bank's Pay by Bank is a service for businesses that allows them to send digital payment requests to customers via their online banking or a dedicated app. Customers can then authorize the payment, which is processed as a SEPA Instant Credit Transfer or a regular SEPA Credit Transfer, making it an irrevocable, fast, and cost-effective option compared to credit cards. It functions as a message format that initiates a bank transfer, pre-filled with payment details to simplify reconciliation for the business.
Availability
Available to anyone with a bank account in Europe.
Transaction Types
Payment Flow
Example Pay by Bank redirect experience
API Implementation
Required value for payment_type parameter: pbb
Payment Page Redirect
Redirect the customer to the Pay by Bank experience hosted by Deutsche Bank after creating a payment.
Implementation flow:
- Make a Payment API request.
- Receive the API response with
client_action=redirect. - Redirect your customer to the
urlprovided inaction_data. - The customer selects their bank, authenticates with their bank, and authorises the payment.
- Customer is redirected back to your
success_urlorerror_url. You will also receive asynchronous postbacks.
Payment API
Payment API Request
payment_typeStringrequiredpbborder_idStringrequiredamountFloatrequiredcurrencyStringrequiredpostback_urlStringrequiredsuccess_urlStringrequirederror_urlStringrequiredPOST /rest/payment
Authorization: Basic <base64(api_key:api_password)>
Content-Type: application/json
{
"payment_type": "pbb",
"order_id": "PAYBYBANK-12345",
"amount": "29.90",
"currency": "EUR",
"postback_url": "https://your-postback.url.com",
"success_url": "https://your-success.url.com",
"error_url": "https://your-error.url.com"
}
Payment API Response
transaction_idStringpayment_typeStringstatus_codeIntegerstatusStringorder_idStringmessageStringadditional_transaction_dataStringpostback_url as part of the postback data.amountFloatincluded_feesStringerror_codeIntegerclient_actionStringurl in action_data) or postform (build and submit a POST form using the data in action_data). When not returned, no client-side action is required.action_dataObjectclient_action is specified. Contains: url (target URL of the action) and, in case of a postform, fields (key/value pairs of the data to be posted).{
"transaction_id": "4d79a749-0f9e-4f77-8ac4-5acb2ac55b43",
"payment_type": "pbb",
"status_code": 1,
"status": "started",
"order_id": "PAYBYBANK-12345",
"message": null,
"additional_transaction_data": null,
"amount": 29.9,
"included_fees": "0.00",
"error_code": 0,
"client_action": "redirect",
"action_data": {
"url": "https://testapi.betterpayment.de/pay-by-bank/4d79a749-0f9e-4f77-8ac4-5acb2ac55b43"
}
}
Refund API
Refund API Request
transaction_idStringrequiredamountFloatcommentStringPOST /rest/refund
Authorization: Basic <base64(api_key:api_password)>
Content-Type: application/json
{
"transaction_id": "4d79a749-0f9e-4f77-8ac4-5acb2ac55b43",
"amount": "29.90",
"comment": "Goods returned"
}
Refund API Response
The response is attributed to the Refund object — not the transaction. Thus, the status_code and status will differ from transaction values.
transaction_idStringrefund_idStringstatusStringstatus_codeIntegererror_codeInteger{
"transaction_id": "4d79a749-0f9e-4f77-8ac4-5acb2ac55b43",
"refund_id": "d64f85aa-3c43-4f18-9a43-4d2b46ddbb2c",
"status_code": 1,
"status": "successful",
"error_code": 0
}
Postbacks
For the full list of payment postback fields, see the Payment API. For refund postbacks, see the Refund API. For retry policy and signature verification, see Postbacks.
Test Data
SEPA Capability Embedded Flow Test Bank
Step 1 (AIS)
- username:
max.mustermann - password:
12345 - otp:
987654
Step 2 (PIS)
- username:
max.mustermann - password:
12345 - otp:
111111